Your browser (Internet Explorer 6) is out of date. It has known security flaws and may not display all features of this and other websites. Learn how to update your browser.
X

Crude Deferred Shading implemented!

So today I finished implementing a really basic and unoptimized deferred shader. The basic rundown of what I did today is basically:

– Use the data gathered from the geometry buffers and use them to calculate basic directional light on every fragment by sampling the textures.

– Run a second pass with a shader meant to calculate the point lights, using the following attenuation formula

threshold (1)

 

And here’s the current results, just using three lights and some textured cubes, as you can notice the z depth test isnt implemented yet and so things that arent actually in the light gets lit up.

update

 

Tomorrow I aim to implement some handling so I can spawn as many lights as I want as well as fixing and testing for the depth before I compute the lighting and get it to look reasonably well.

 

 

Be Sociable, Share!

Leave a comment  

name*

email*

website

Submit comment