# Fog Play Demo Fog Demo — Distance-based fog via WorldEnvironment. Demonstrates: - Distance fog with adjustable density/start/end - Fog colour control - Height fog toggle - Fog mode switching (linear / exponential / exponential_squared) - Bloom + tonemap combined with fog Controls: A / D - Orbit camera left / right W / S - Zoom in / out Q / E - Raise / lower camera 1 - Toggle fog 2 - Toggle bloom 3 - Cycle fog mode Up / Down - Adjust fog density Left / Right - Adjust tonemap exposure Escape - Quit Run: uv run python packages/graphics/examples/3d_fog.py ## Source Code ```{literalinclude} ../../packages/graphics/examples/3d_fog.py :language: python :linenos: ```