Sets camera fog color (distant objects fade to this color, 0-255 RGB).
Takes camera (camera entity handle), r/g/b (red/green/blue 0-255).
Returns nothing.
3D Graphics
Parameters & Returns
Parameters
cameraInt
rInt
gInt
bInt
Returns
Void
Quick Summary
Sets camera fog color (distant objects fade to this color, 0-255 RGB).
Takes camera (camera entity handle), r/g/b (red/green/blue 0-255).
Returns nothing.
Technical Exegesis...
Sets camera fog color (distant objects fade to this color, 0-255 RGB). Takes camera (camera entity handle), r/g/b (red/green/blue 0-255). Returns nothing. Validates entity is camera type, allocates camera->Camera3D if null, sets camera->fogColor=(r/255, g/255, b/255). Controls color objects fade to with distance.
This function sets fog color. Fog color: color objects fade to as they reach fogFar distance (distant objects lerp from object color to fog color), RGB values 0-255 converted to 0.0-1.0 floats.
Sets camera fog color (distant objects fade to this color, 0-255 RGB). Takes camera (camera entity handle), r/g/b (red/green/blue 0-255). Returns nothing. Validates entity is camera type, allocates camera->Camera3D if null, sets camera->fogColor=(r/255, g/255, b/255). Controls color objects fade to with distance.
This function sets fog color. Fog color: color objects fade to as they reach fogFar distance (distant objects lerp from object color to fog color), RGB values 0-255 converted to 0.0-1.0 floats. Use cases: (1) Atmospheric color (gray for haze, white for mist, blue for sky fog), (2) Mood (yellow/brown for pollution, green for toxic atmosphere, red for ominous), (3) Time of day (orange for sunrise/sunset fog, blue for midday, dark blue for night), (4) Match clear color (fog color should match b3dCameraClsColor for seamless horizon), (5) Underwater (blue-green fog for water depth). Common patterns: gray haze b3dCameraFogColor(camera, 192, 192, 192), white mist b3dCameraFogColor(camera, 255, 255, 255), sky blue b3dCameraFogColor(camera, 135, 206, 235), pollution b3dCameraFogColor(camera, 180, 160, 120). Clear color matching: set fog color same as clear color (b3dCameraClsColor) for seamless horizon (objects fade to background color, no visible seam at far plane), critical for realistic outdoor scenes. Typical colors: outdoor haze (light gray 192,192,192), dense fog (white 255,255,255), underwater (cyan 0,128,192), space (black 0,0,0), sunset (orange 255,128,64). Fog only applies if fog mode enabled (b3dCameraFogMode mode=1). Camera allocation: if camera->camera==nullptr, allocates new Camera3D. Related: b3dCameraFogMode enables fog, b3dCameraFogRange sets fog distances, b3dCameraClsColor sets background (should match fog color).