Environment Maps
Definition
An Environment Map tells objects what exists around them.
It acts as the surrounding world for:
- Reflections
- Lighting
- Realism
Example
scene.environment = hdrTexture;
What Happens?
Before:
Object floating in empty space
After:
Object surrounded by a real environment
Real-Life Example
Sunglasses reflect:
- Buildings
- Cars
- Trees
Environment maps allow 3D objects to do the same.
HDR Lighting
Definition
Using HDRI as a light source instead of relying only on traditional lights.
Traditional Lighting
const light = new THREE.DirectionalLight();
Only one light source.
HDR Lighting
scene.environment = hdrTexture;
Thousands of lighting values are used from the HDR image.