Originally Posted By: HeelX
Distance fog is relatively cheap. You just calculate a blending factor based on the distance between the camera and the pixel and two distance thresholds (no fog and total fog). That is so cheap that it has virtually no impact on any framerate on the planet.

Well you can combine it with the object shader to improve fps.
If the pixel is "deeper" than fog_far - so it's fully covered in fog - then only the fog color has to be returned without calculating all the lighting / normalmapping.

For very complex object shaders this CAN be good but in this case I suggest to combine the shaders with the LOD-system and "turn off" the fancy shading for objects that are far away.

Besides that total-fog doesn't look good at all for 'normal conditions'.

Last edited by Kartoffel; 11/27/12 21:20.

POTATO-MAN saves the day! - Random