NightVision
构造函数
只读
类型
当前状态,取值见 State(initialized / enabled / disabled)
State
initialized
enabled
disabled
注意:旧实现的构造函数没有初始化 this._effect,首次 enable = true 会因 this._effect.enabled 读取 undefined 而抛 TypeError。
this._effect
enable = true
this._effect.enabled
undefined
TypeError
是否开启。 首次置 true 时惰性创建并加入 scene.postProcessStages;重复切换幂等。
true
scene.postProcessStages
选中对象(可选):只对给定实体生效。 详见 BlackAndWhite 的 selected 说明。
selected
选中的实体或实体数组
销毁:从 scene.postProcessStages 移除并 destroy() 本阶段,释放 GPU 资源。 重复调用安全。
destroy()
是否已销毁
NightVision