Loading libs/surfaceflinger/DisplayHardware/DisplayHardware.cpp +11 −4 Original line number Diff line number Diff line Loading @@ -166,10 +166,18 @@ void DisplayHardware::init(uint32_t dpy) } } eglQuerySurface(display, surface, EGL_WIDTH, &mWidth); eglQuerySurface(display, surface, EGL_HEIGHT, &mHeight); #ifdef EGL_ANDROID_swap_rectangle if (strstr(egl_extensions, "EGL_ANDROID_swap_rectangle")) { if (eglSetSwapRectangleANDROID(display, surface, 0, 0, mWidth, mHeight) == EGL_TRUE) { // This could fail if this extension is not supported by this // specific surface (of config) mFlags |= SWAP_RECTANGLE; } } // when we have the choice between UPDATE_ON_DEMAND and SWAP_RECTANGLE // choose UPDATE_ON_DEMAND, which is more efficient if (mFlags & UPDATE_ON_DEMAND) Loading @@ -177,6 +185,8 @@ void DisplayHardware::init(uint32_t dpy) #endif LOGI("flags : %08x", mFlags); mDpiX = mNativeWindow->xdpi; mDpiY = mNativeWindow->ydpi; mRefreshRate = fbDev->fps; Loading Loading @@ -204,9 +214,6 @@ void DisplayHardware::init(uint32_t dpy) context = eglCreateContext(display, config, NULL, NULL); //checkEGLErrors("eglCreateContext"); eglQuerySurface(display, surface, EGL_WIDTH, &mWidth); eglQuerySurface(display, surface, EGL_HEIGHT, &mHeight); /* * Gather OpenGL ES extensions Loading Loading
libs/surfaceflinger/DisplayHardware/DisplayHardware.cpp +11 −4 Original line number Diff line number Diff line Loading @@ -166,10 +166,18 @@ void DisplayHardware::init(uint32_t dpy) } } eglQuerySurface(display, surface, EGL_WIDTH, &mWidth); eglQuerySurface(display, surface, EGL_HEIGHT, &mHeight); #ifdef EGL_ANDROID_swap_rectangle if (strstr(egl_extensions, "EGL_ANDROID_swap_rectangle")) { if (eglSetSwapRectangleANDROID(display, surface, 0, 0, mWidth, mHeight) == EGL_TRUE) { // This could fail if this extension is not supported by this // specific surface (of config) mFlags |= SWAP_RECTANGLE; } } // when we have the choice between UPDATE_ON_DEMAND and SWAP_RECTANGLE // choose UPDATE_ON_DEMAND, which is more efficient if (mFlags & UPDATE_ON_DEMAND) Loading @@ -177,6 +185,8 @@ void DisplayHardware::init(uint32_t dpy) #endif LOGI("flags : %08x", mFlags); mDpiX = mNativeWindow->xdpi; mDpiY = mNativeWindow->ydpi; mRefreshRate = fbDev->fps; Loading Loading @@ -204,9 +214,6 @@ void DisplayHardware::init(uint32_t dpy) context = eglCreateContext(display, config, NULL, NULL); //checkEGLErrors("eglCreateContext"); eglQuerySurface(display, surface, EGL_WIDTH, &mWidth); eglQuerySurface(display, surface, EGL_HEIGHT, &mHeight); /* * Gather OpenGL ES extensions Loading