You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
48 lines
816 B
48 lines
816 B
import NodeMaterial from './NodeMaterial.js';
|
|
import { MeshBasicMaterial } from 'three';
|
|
|
|
const defaultValues = new MeshBasicMaterial();
|
|
|
|
class MeshBasicNodeMaterial extends NodeMaterial {
|
|
|
|
constructor( parameters ) {
|
|
|
|
super();
|
|
|
|
this.isMeshBasicNodeMaterial = true;
|
|
|
|
this.lights = true;
|
|
|
|
this.colorNode = null;
|
|
this.opacityNode = null;
|
|
|
|
this.alphaTestNode = null;
|
|
|
|
this.lightNode = null;
|
|
|
|
this.positionNode = null;
|
|
|
|
this.setDefaultValues( defaultValues );
|
|
|
|
this.setValues( parameters );
|
|
|
|
}
|
|
|
|
copy( source ) {
|
|
|
|
this.colorNode = source.colorNode;
|
|
this.opacityNode = source.opacityNode;
|
|
|
|
this.alphaTestNode = source.alphaTestNode;
|
|
|
|
this.lightNode = source.lightNode;
|
|
|
|
this.positionNode = source.positionNode;
|
|
|
|
return super.copy( source );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
export default MeshBasicNodeMaterial;
|
|
|