UNPKG

737 BJavaScriptView Raw
1/**
2 * @author mrdoob / http://mrdoob.com/
3 *
4 * parameters = {
5 * color: <THREE.Color>
6 * }
7 */
8
9import { Material } from './Material.js';
10import { Color } from '../math/Color.js';
11
12function ShadowMaterial( parameters ) {
13
14 Material.call( this );
15
16 this.type = 'ShadowMaterial';
17
18 this.color = new Color( 0x000000 );
19 this.transparent = true;
20
21 this.setValues( parameters );
22
23}
24
25ShadowMaterial.prototype = Object.create( Material.prototype );
26ShadowMaterial.prototype.constructor = ShadowMaterial;
27
28ShadowMaterial.prototype.isShadowMaterial = true;
29
30ShadowMaterial.prototype.copy = function ( source ) {
31
32 Material.prototype.copy.call( this, source );
33
34 this.color.copy( source.color );
35
36 return this;
37
38};
39
40
41export { ShadowMaterial };