Capítulo 654 de 859
This class can be used to define a linear fog that grows linearly denser with the distance.
far units away from the active camera wo…near units from the active camera won't be affected by fog.const scene = new THREE.Scene();
scene.fog = new THREE.Fog( 0xcccccc, 10, 15 );
Constructor
| Signature |
|---|
| `new Fog( color : number |
Properties
| Property | Description |
|---|---|
.color : Color | The fog's color. |
.far : number | The maximum distance at which fog stops being calculated and applied. Objects that are more than far units away from the active camera won't be affected by fog. |
.isFog : boolean (readonly) | This flag can be used for type testing. |
.name : string | The name of the fog. |
.near : number | The minimum distance to start applying fog. Objects that are less than near units from the active camera won't be affected by fog. |
Methods
| Method | Description |
|---|---|
.clone() : Fog | Returns a new fog with copied values from this instance. |
| `.toJSON( meta : Object | string ) : Object` |