aboutsummaryrefslogtreecommitdiff
path: root/sokol_app.h
diff options
context:
space:
mode:
authorAndre Weissflog <floooh@gmail.com>2024-02-07 19:02:50 +0100
committerAndre Weissflog <floooh@gmail.com>2024-02-07 19:02:50 +0100
commit233a83dfe4dd5cbade4e47fef8a71d5ac39620cb (patch)
tree976460b065f78ae48d70cb621db839f7f8f32c7e /sokol_app.h
parent6afa7e70c2ea73886f1627abd38236d8e875ceba (diff)
sokol_app.h android: query gl framebuffer binding
Diffstat (limited to 'sokol_app.h')
-rw-r--r--sokol_app.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/sokol_app.h b/sokol_app.h
index ae26f361..3539eeaa 100644
--- a/sokol_app.h
+++ b/sokol_app.h
@@ -2123,6 +2123,7 @@ inline void sapp_run(const sapp_desc& desc) { return sapp_run(&desc); }
#include <android/native_activity.h>
#include <android/looper.h>
#include <EGL/egl.h>
+ #include <GLES3/gl3.h>
#elif defined(_SAPP_LINUX)
#define GL_GLEXT_PROTOTYPES
#include <X11/Xlib.h>
@@ -8121,6 +8122,7 @@ _SOKOL_PRIVATE bool _sapp_android_init_egl_surface(ANativeWindow* window) {
return false;
}
_sapp.android.surface = surface;
+ glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint*)&_sapp.gl.framebuffer);
return true;
}
@@ -9811,7 +9813,7 @@ _SOKOL_PRIVATE void _sapp_glx_choose_visual(Visual** visual, int* depth) {
_SOKOL_PRIVATE void _sapp_glx_make_current(void) {
_sapp.glx.MakeCurrent(_sapp.x11.display, _sapp.glx.window, _sapp.glx.ctx);
- glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint*)&_sapp.gl.framebuffer);
+ glGetIntegerv(GL_FRAMEBUFFER_BINDING, (GLint*)&_sapp.gl.framebuffer);
}
_SOKOL_PRIVATE void _sapp_glx_create_context(void) {