UNPKG

polygonjs-engine

Version:

node-based webgl 3D engine https://polygonjs.com

22 lines (21 loc) 629 B
import {TypedCopNode} from "./_Base"; import {NodeParamsConfig} from "../utils/params/ParamsConfig"; import {InputCloneMode as InputCloneMode2} from "../../poly/InputCloneMode"; const ParamsConfig2 = new NodeParamsConfig(); export class NullCopNode extends TypedCopNode { constructor() { super(...arguments); this.params_config = ParamsConfig2; } static type() { return "null"; } initializeNode() { this.io.inputs.setCount(1); this.io.inputs.initInputsClonedState(InputCloneMode2.NEVER); } async cook(input_contents) { const texture = input_contents[0]; this.set_texture(texture); } }