UNPKG

polygonjs-engine

Version:

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

27 lines (26 loc) 1.06 kB
import {TypedLightObjNode} from "./_BaseLight"; import {NodeParamsConfig} from "../utils/params/ParamsConfig"; import {TransformController as TransformController2, TransformedParamConfig} from "./utils/TransformController"; import {FlagsControllerD} from "../utils/FlagsController"; import {HierarchyController as HierarchyController2} from "./utils/HierarchyController"; class TransformedObjParamConfig extends TransformedParamConfig(NodeParamsConfig) { } export class BaseLightTransformedObjNode extends TypedLightObjNode { constructor() { super(...arguments); this.flags = new FlagsControllerD(this); this.hierarchy_controller = new HierarchyController2(this); this.transform_controller = new TransformController2(this); } initializeBaseNode() { super.initializeBaseNode(); this.hierarchy_controller.initializeNode(); this.transform_controller.initializeNode(); } cook() { this.transform_controller.update(); this.update_light_params(); this.update_shadow_params(); this.cookController.end_cook(); } }