Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 710e2c8e authored by Jef Oliver's avatar Jef Oliver Committed by Gerrit Code Review
Browse files

Merge "GLSurfaceView: add property to default to RGB565" into cm-10.1

parents de52bdcc d0bfd560
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -169,6 +169,8 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
    private final static boolean LOG_RENDERER = false;
    private final static boolean LOG_RENDERER_DRAW_FRAME = false;
    private final static boolean LOG_EGL = false;

    private final static boolean RGB565 = SystemProperties.getBoolean("ro.opengles.surface.rgb565", false);
    /**
     * The renderer only renders
     * when the surface is created, or when {@link #requestRender} is called.
@@ -974,7 +976,7 @@ public class GLSurfaceView extends SurfaceView implements SurfaceHolder.Callback
     */
    private class SimpleEGLConfigChooser extends ComponentSizeChooser {
        public SimpleEGLConfigChooser(boolean withDepthBuffer) {
            super(8, 8, 8, 0, withDepthBuffer ? 16 : 0, 0);
            super(RGB565 ? 5 : 8, RGB565 ? 6 : 8, RGB565 ? 5 : 8, 0, withDepthBuffer ? 16 : 0, 0);
        }
    }