Merge commit 'ddb133f4a9d1e2f75f99c148e8218e43682b40a2' * commit 'ddb133f4a9d1e2f75f99c148e8218e43682b40a2': Fix bug in native activity demo.
This commit is contained in:
@@ -74,14 +74,15 @@ static int engine_init_display(struct engine* engine) {
|
||||
selectConfigForNativeWindow(display, attribs, engine->app->window, &config);
|
||||
surface = eglCreateWindowSurface(display, config, engine->app->window, NULL);
|
||||
context = eglCreateContext(display, config, NULL, NULL);
|
||||
eglQuerySurface(display, surface, EGL_WIDTH, &w);
|
||||
eglQuerySurface(display, surface, EGL_HEIGHT, &h);
|
||||
|
||||
if (eglMakeCurrent(display, surface, surface, context) == EGL_FALSE) {
|
||||
LOGW("Unable to eglMakeCurrent");
|
||||
return -1;
|
||||
}
|
||||
|
||||
eglQuerySurface(display, surface, EGL_WIDTH, &w);
|
||||
eglQuerySurface(display, surface, EGL_HEIGHT, &h);
|
||||
|
||||
engine->display = display;
|
||||
engine->context = context;
|
||||
engine->surface = surface;
|
||||
|
||||
Reference in New Issue
Block a user