mirror of
https://github.com/ClassiCube/ClassiCube.git
synced 2025-09-11 08:36:38 -04:00
GLES2: Log BGRA support
This commit is contained in:
parent
398eceafca
commit
9dff9a2b14
@ -546,6 +546,14 @@ static void GLBackend_Init(void) {
|
||||
glGetIntegerv(_GL_MAJOR_VERSION, &major);
|
||||
glGetIntegerv(_GL_MINOR_VERSION, &minor);
|
||||
customMipmapsLevels = major >= 3 && minor >= 2;
|
||||
|
||||
static const cc_string bgra_ext = String_FromConst("EXT_texture_format_BGRA8888");
|
||||
static const cc_string bgra_apl = String_FromConst("APPLE_texture_format_BGRA8888");
|
||||
cc_string extensions = String_FromReadonly((const char*)_glGetString(GL_EXTENSIONS));
|
||||
|
||||
cc_bool has_ext_bgra = String_CaselessContains(&extensions, &bgra_ext);
|
||||
cc_bool has_apl_bgra = String_CaselessContains(&extensions, &bgra_apl);
|
||||
Platform_Log2("BGRA support - Ext: %t, Apple: %t", &has_ext_bgra, &has_apl_bgra);
|
||||
#else
|
||||
customMipmapsLevels = true;
|
||||
const GLubyte* ver = glGetString(GL_VERSION);
|
||||
|
@ -114,7 +114,7 @@ static cc_uintptr ctx_visualID;
|
||||
static void GLContext_InitSurface(void); // replacement in Window_Switch.c for handheld/docked resolution fix
|
||||
#else
|
||||
static void GLContext_InitSurface(void) {
|
||||
void* window = Window_Main.Handle.ptr;
|
||||
EGLNativeWindowType window = (EGLNativeWindowType)Window_Main.Handle.ptr;
|
||||
if (!window) return; /* window not created or lost */
|
||||
ctx_surface = eglCreateWindowSurface(ctx_display, ctx_config, window, NULL);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user