Browse Source

gl2shim: workaround empty rgb5/rgb8 textures

pull/2/head
mittorn 1 year ago committed by Alibek Omarov
parent
commit
bf5fd40d64
  1. 2
      ref/gl/gl2_shim/gl2_shim.c

2
ref/gl/gl2_shim/gl2_shim.c

@ -1014,7 +1014,7 @@ static void APIENTRY GL2_TexImage2D( GLenum target, GLint level, GLint internalf
} }
internalformat = format; internalformat = format;
} }
if( internalformat == GL_LUMINANCE8_ALPHA8 || internalformat == GL_RGB ) if( internalformat == GL_LUMINANCE8_ALPHA8 || internalformat == GL_RGB || internalformat == GL_RGB8 || internalformat == GL_RGB5 )
internalformat = GL_RGBA; internalformat = GL_RGBA;
rpglTexImage2D( target, level, internalformat, width, height, border, format, type, data ); rpglTexImage2D( target, level, internalformat, width, height, border, format, type, data );
if( data != pixels ) if( data != pixels )

Loading…
Cancel
Save