Skip to content

Commit

Permalink
sensibalize
Browse files Browse the repository at this point in the history
  • Loading branch information
RedMan13 committed Aug 20, 2024
1 parent 161b2ef commit faf3ebd
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/engine/runtime.js
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ class Runtime extends EventEmitter {
miscLimits: true,
fencing: true,
dangerousOptimizations: false,
oobRendering: true
disableOffscreenRendering: false
};

this.compilerOptions = {
Expand Down Expand Up @@ -2206,6 +2206,7 @@ class Runtime extends EventEmitter {
this.renderer = renderer;
this.renderer.setLayerGroupOrdering(StageLayering.LAYER_GROUPS);
this.renderer.offscreenTouching = !this.runtimeOptions.fencing;
this.renderer.renderOffscreen = this.runtimeOptions.disableOffscreenRendering;
this.updatePrivacy();
}

Expand Down Expand Up @@ -3051,6 +3052,10 @@ class Runtime extends EventEmitter {
this.emit(Runtime.RUNTIME_OPTIONS_CHANGED, this.runtimeOptions);
if (this.renderer) {
this.renderer.offscreenTouching = !this.runtimeOptions.fencing;
// if these miss match then update (do full rerender as the state drastically changes output)
if (this.runtimeOptions.disableOffscreenRendering === this.renderer.renderOffscreen) {
this.renderer.setRenderOffscreen(!this.runtimeOptions.disableOffscreenRendering);
}
}
}

Expand Down

0 comments on commit faf3ebd

Please sign in to comment.