NodeSampler.js 340 B

12345678910111213141516171819202122
  1. import Sampler from '../Sampler.js';
  2. class NodeSampler extends Sampler {
  3. constructor( name, textureNode, groupNode ) {
  4. super( name, textureNode ? textureNode.value : null );
  5. this.textureNode = textureNode;
  6. this.groupNode = groupNode;
  7. }
  8. update() {
  9. this.texture = this.textureNode.value;
  10. }
  11. }
  12. export default NodeSampler;