Skip to content

vrend: deal with BGRX upload on GLES

If the texture upload doesn't use GBM we end up with trying to upload a RGBA texture to a resources that had the internal format RGB8, so work around this by setting the format as GL_RGB8 and not only swizzle the input, but also remove the extra byte that holds the un-used alpha channel.

This patch doesn't handle passing sRGB data, that is, the texture upload should not fail, but the colors will be passed as if they were linear.

Edited by Gert Wollny

Merge request reports