Volumetric Light Scattering - GLSL
Описание
This video presents the volumetric lightning model writen in openGL/GLSL language.
The presented program runs pretty fast for low detail setting (large blur) which is about 130fps, but
even for this settings visual effects are still satisfying. For high details rendering fps can drop even below 10 frames, tested
on NVIDIA GT 650M.
Basicaly the algorithm is following:
1) Standard shadow mapping + calculating the eye-fragment vector (v_sm) in shadow map frame. I draw this vector
to another FBO during the standard phong/shadowmap step.
2) Post processing on screen-quad:
a) Integrate along v_sm vector starting from nearest clip plane and check if current point lies in the shadow if not
accumulate color. The method is desribed in this example (http://developer.download.nvidia.com/SDK/10.5/direct3d/samples.html#VolumeLight).
but I used my own implementation.
b) Applying radial blur to the image ( http://fabiensanglard.net/lightScattering/) -
this step helps to descrease the numbuer of integral points in a) and remove aliasing and also enhance the effect.
c) Applying to pas gaussian blur to remove posible aliasing (http://www.gamerendering.com/2008/10/11/gaussian-blur-filter-shader/).
Рекомендуемые видео



















