Fix cropped rendering - #824
Conversation
Resolves cropped rendering when WebGL drawing buffer is smaller than canvas due to hardware constraints by scaling viewport to drawing buffer rather than canvas size. See: https://stackoverflow.com/questions/29710696/webgl-drawing-buffer-size-does-not-equal-canvas-size https://registry.khronos.org/webgl/specs/latest/1.0/#2.2
|
Thanks for this and for the spec references — we merged it today, and I have to report it didn't survive contact with the test suite: clamping the viewport to The underlying clamped-canvas bug you describe is real — but the fix needs to distinguish the canvas-output path (where clamping to the drawing buffer is right) from FBO passes (where the viewport must match the texture size). If you're still around and want to rework it along those lines, we'd gladly take it; CI now runs on every PR so it'll get validated automatically. |
Resolves cropped rendering when WebGL drawing buffer is smaller than canvas due to hardware constraints by scaling viewport to drawing buffer rather than canvas size. See:
https://stackoverflow.com/questions/29710696/webgl-drawing-buffer-size-does-not-equal-canvas-size https://registry.khronos.org/webgl/specs/latest/1.0/#2.2