-
-
Notifications
You must be signed in to change notification settings - Fork 239
Closed
Labels
feature requestNew feature requestNew feature request
Description
In my project I re-use passes and effects with different cameras and with the new types (Thank You!) I'm having to // @ts-ignore the assignment since they are protected. Would it be acceptable to have these fields public? Alternatively I could clone the passes/effects, however it causes a pause on initial compile/upload when switching views. I could pre-render them all to upload them all at once as well to avoid the issue perhaps.
updatePostProcessingCamera(camera: Camera, renderLastPassToScreen: boolean) {
let lastPass: any = null;
for (const pass of this.passes) {
// @ts-ignore
pass.camera = camera;
pass.renderToScreen = false;
if (pass.enabled) {
lastPass = pass;
}
}
lastPass.renderToScreen = renderLastPassToScreen;
// some effects have cameras eg. DepthOfFieldEffect
for (const effect of this.effects) {
// @ts-ignore
if (effect.camera) {
// @ts-ignore
effect.camera = camera;
}
}
}
```Metadata
Metadata
Assignees
Labels
feature requestNew feature requestNew feature request