Fog.js 415 B

123456789101112131415161718192021
  1. /**
  2. * @author mrdoob / http://mrdoob.com/
  3. * @author alteredq / http://alteredqualia.com/
  4. */
  5. THREE.Fog = function ( color, near, far ) {
  6. this.name = '';
  7. this.color = new THREE.Color( color );
  8. this.near = ( near !== undefined ) ? near : 1;
  9. this.far = ( far !== undefined ) ? far : 1000;
  10. };
  11. THREE.Fog.prototype.clone = function () {
  12. return new THREE.Fog( this.color.getHex(), this.near, this.far );
  13. };