DirectX SDK |
This topic pertains only to application development in C++. See Direct3D Immediate Mode Visual Basic Samples.
The MFCFog sample does a fly-by over some terrain and allows you to see the effects of various fog parameters.
Source: (SDK root)\Samples\Multimedia\D3dim\Src\MFCFog
Executable: (SDK root)\Samples\Multimedia\D3dim\Bin\Mfcfog.exe
Change parameters by using the controls. For information on the parameters, see Fog. The effects are most striking in full-screen mode.
Games that use terrain typically turn on fog so that they can prevent the rendering of objects in the far distance.