Skip to content

Commit

Permalink
fix(OrderIndependentTranslucentPass): revert size
Browse files Browse the repository at this point in the history
The viewport + scissor box should be reverted to the renderer's scissor
box + viewport size.
  • Loading branch information
floryst committed Mar 19, 2024
1 parent 5359685 commit 2f85a5e
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,11 @@ function vtkOpenGLOrderIndependentTranslucentPass(publicAPI, model) {
gl.depthFunc(gl.LEQUAL);
model.translucentRGBATexture.deactivate();
model.translucentRTexture.deactivate();

// restore scissor + viewport from renderer
const ts = renNode.getTiledSizeAndOrigin();
gl.scissor(ts.lowerLeftU, ts.lowerLeftV, ts.usize, ts.vsize);
gl.viewport(ts.lowerLeftU, ts.lowerLeftV, ts.usize, ts.vsize);
};

publicAPI.getShaderReplacement = () => {
Expand Down

0 comments on commit 2f85a5e

Please sign in to comment.