aboutsummaryrefslogtreecommitdiff
path: root/backends/graphics/opengl
diff options
context:
space:
mode:
authorJohannes Schickel2011-02-25 03:35:55 +0100
committerJohannes Schickel2011-02-25 03:35:55 +0100
commit972cdaea358160f56880ef82b2527c1ebb320c8a (patch)
tree8b1ff7f11549341a4758d17c08bf8868644fe2ba /backends/graphics/opengl
parente06b7431e8e199c169dd55b675bf7b8e70251e61 (diff)
downloadscummvm-rg350-972cdaea358160f56880ef82b2527c1ebb320c8a.tar.gz
scummvm-rg350-972cdaea358160f56880ef82b2527c1ebb320c8a.tar.bz2
scummvm-rg350-972cdaea358160f56880ef82b2527c1ebb320c8a.zip
OPENGL: Add support for RGB555 output format.
Diffstat (limited to 'backends/graphics/opengl')
-rw-r--r--backends/graphics/opengl/opengl-graphics.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/backends/graphics/opengl/opengl-graphics.cpp b/backends/graphics/opengl/opengl-graphics.cpp
index 8bca09b2d6..ea5702868c 100644
--- a/backends/graphics/opengl/opengl-graphics.cpp
+++ b/backends/graphics/opengl/opengl-graphics.cpp
@@ -873,6 +873,11 @@ void OpenGLGraphicsManager::getGLPixelFormat(Graphics::PixelFormat pixelFormat,
intFormat = GL_RGBA;
glFormat = GL_RGBA;
gltype = GL_UNSIGNED_SHORT_5_5_5_1;
+ } else if (pixelFormat == Graphics::PixelFormat(2, 5, 5, 5, 0, 10, 5, 0, 0)) { // RGB555
+ bpp = 2;
+ intFormat = GL_RGB;
+ glFormat = GL_BGRA;
+ gltype = GL_UNSIGNED_SHORT_1_5_5_5_REV;
} else if (pixelFormat == Graphics::PixelFormat(2, 4, 4, 4, 4, 12, 8, 4, 0)) { // RGBA4444
bpp = 2;
intFormat = GL_RGBA;