Spaces:
Running
Running
File size: 590 Bytes
6cd9596 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
/**
* @author mrdoob / http://mrdoob.com/
* @author alteredq / http://alteredqualia.com/
*/
import { Color } from '../math/Color.js';
function FogExp2( color, density ) {
this.name = '';
this.color = new Color( color );
this.density = ( density !== undefined ) ? density : 0.00025;
}
Object.assign( FogExp2.prototype, {
isFogExp2: true,
clone: function () {
return new FogExp2( this.color, this.density );
},
toJSON: function ( /* meta */ ) {
return {
type: 'FogExp2',
color: this.color.getHex(),
density: this.density
};
}
} );
export { FogExp2 };
|