aboutsummaryrefslogtreecommitdiff
path: root/backends/graphics/opengl/texture.h
diff options
context:
space:
mode:
Diffstat (limited to 'backends/graphics/opengl/texture.h')
-rw-r--r--backends/graphics/opengl/texture.h15
1 files changed, 9 insertions, 6 deletions
diff --git a/backends/graphics/opengl/texture.h b/backends/graphics/opengl/texture.h
index 8357f29d0e..68af406804 100644
--- a/backends/graphics/opengl/texture.h
+++ b/backends/graphics/opengl/texture.h
@@ -190,10 +190,15 @@ public:
*/
virtual bool hasPalette() const { return false; }
+ /**
+ * Set color key for paletted textures.
+ *
+ * This needs to be called after any palette update affecting the color
+ * key. Calling this multiple times will result in multiple color indices
+ * to be treated as color keys.
+ */
+ virtual void setColorKey(uint colorKey) {}
virtual void setPalette(uint start, uint colors, const byte *palData) {}
-
- virtual void *getPalette() { return 0; }
- virtual const void *getPalette() const { return 0; }
protected:
virtual void updateTexture();
@@ -222,11 +227,9 @@ public:
virtual bool hasPalette() const { return true; }
+ virtual void setColorKey(uint colorKey);
virtual void setPalette(uint start, uint colors, const byte *palData);
- virtual void *getPalette() { return _palette; }
- virtual const void *getPalette() const { return _palette; }
-
virtual Graphics::Surface *getSurface() { return &_clut8Data; }
virtual const Graphics::Surface *getSurface() const { return &_clut8Data; }