Skip to content

render/gles2: use byte-aligned rows for glReadPixels

M. Stoeckl requested to merge mstoeckl/wlroots:gles-read-align into master

This fixes a bug with a screenshot stride mismatch I encountered when using:

To reproduce the issue/check that this MR corrects the behavior:

swaymsg output '*' render_bit_depth 5
wayshot -s "0 0 101 100" -f out.png

Documentation for glPixelStorei / GL_PACK_ALIGNMENT: https://docs.gl/es2/glPixelStorei

Edited by M. Stoeckl

Merge request reports