mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-24 11:45:16 +00:00
(gl_raster_font) Enable GL_R8 atlas for GL >= 3
This commit is contained in:
parent
4f69b5e34b
commit
f9f98f9f2e
@ -60,7 +60,12 @@ static bool gl_raster_font_upload_atlas(gl_raster_t *font,
|
||||
uint8_t *tmp = NULL;
|
||||
|
||||
#ifndef HAVE_OPENGLES
|
||||
if (font->gl->core_context)
|
||||
struct retro_hw_render_callback *cb = video_driver_callback();
|
||||
bool modern = font->gl->core_context ||
|
||||
(cb->context_type == RETRO_HW_CONTEXT_OPENGL &&
|
||||
cb->version_major >= 3);
|
||||
|
||||
if (modern)
|
||||
{
|
||||
GLint swizzle[] = { GL_ONE, GL_ONE, GL_ONE, GL_RED };
|
||||
glTexParameteriv(GL_TEXTURE_2D, GL_TEXTURE_SWIZZLE_RGBA, swizzle);
|
||||
|
Loading…
Reference in New Issue
Block a user