mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-04-07 08:21:41 -04:00
render/gles2: use gles2_pixel_format::has_alpha for shader selection
This commit is contained in:
parent
cc5ef1d2ff
commit
8207f0f081
1 changed files with 1 additions and 2 deletions
|
|
@ -120,8 +120,7 @@ static bool gles2_render_texture_with_matrix(
|
||||||
GLuint prog = renderer->shaders.tex_rgba;
|
GLuint prog = renderer->shaders.tex_rgba;
|
||||||
if (texture->target == GL_TEXTURE_EXTERNAL_OES) {
|
if (texture->target == GL_TEXTURE_EXTERNAL_OES) {
|
||||||
prog = renderer->shaders.tex_ext;
|
prog = renderer->shaders.tex_ext;
|
||||||
} else if (texture->pixel_format->wl_format == WL_SHM_FORMAT_XRGB8888 ||
|
} else if (!texture->pixel_format->has_alpha) {
|
||||||
texture->pixel_format->wl_format == WL_SHM_FORMAT_XBGR8888) {
|
|
||||||
prog = renderer->shaders.tex_rgbx;
|
prog = renderer->shaders.tex_rgbx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue