Only do the alpha swizzle on alpha textures
Avoids problems if swizzles are used elsewhere (like in the newer X11 plugins)
This commit is contained in:
parent
81153cb16d
commit
51d338430f
@ -322,8 +322,8 @@ static void strip_mipmap_filter(GLint *filter)
|
||||
|
||||
static inline void apply_swizzle(struct gs_texture *tex)
|
||||
{
|
||||
gl_tex_param_i(tex->gl_target, GL_TEXTURE_SWIZZLE_R,
|
||||
(tex->format == GS_A8) ? GL_ALPHA : GL_RED);
|
||||
if (tex->format == GS_A8)
|
||||
gl_tex_param_i(tex->gl_target, GL_TEXTURE_SWIZZLE_R, GL_ALPHA);
|
||||
}
|
||||
|
||||
static bool load_texture_sampler(texture_t tex, samplerstate_t ss)
|
||||
|
Loading…
x
Reference in New Issue
Block a user