Compute matching renderer and render-target dimensions.
Three.js floors logical × pixelRatio when it sizes the canvas. Use
the same rule here so every off-screen attachment exactly matches the
backbuffer at non-integer DPRs. If either physical axis exceeds the
framebuffer limit, reduce both axes by one common factor, floor the
resulting physical dimensions to even values for encoder compatibility,
then derive the renderer's logical size from those physical dimensions.
Compute matching renderer and render-target dimensions.
Three.js floors
logical × pixelRatiowhen it sizes the canvas. Use the same rule here so every off-screen attachment exactly matches the backbuffer at non-integer DPRs. If either physical axis exceeds the framebuffer limit, reduce both axes by one common factor, floor the resulting physical dimensions to even values for encoder compatibility, then derive the renderer's logical size from those physical dimensions.