Basic lights using the Phong reflection model in WebGL with phong shading
Here's a simple DEMO showcasing an implementation of WebGL shadows using an off screen frame buffer with bit shifted depth values.
Go ahead and give it a try: WebGL Lights
git clone https://github.com/FarhadG/webgl-lights.git
cd webgl-lights
Open
or serve
up the index.html
file. All of the logic happens inside of main.js
.
MIT