aboutsummaryrefslogtreecommitdiff
path: root/backends/platform/android/texture.cpp
diff options
context:
space:
mode:
authordhewg2011-03-13 22:56:44 +0100
committerdhewg2011-03-13 23:30:17 +0100
commitc63c2a9e59ab9f9013a5e0e1f6c443352ce4f20f (patch)
treee6ad3c3528a0285f5f80f77e206b80b119d4ed59 /backends/platform/android/texture.cpp
parent2dd669d808b89f0d3777d196091b404a4e9baf05 (diff)
downloadscummvm-rg350-c63c2a9e59ab9f9013a5e0e1f6c443352ce4f20f.tar.gz
scummvm-rg350-c63c2a9e59ab9f9013a5e0e1f6c443352ce4f20f.tar.bz2
scummvm-rg350-c63c2a9e59ab9f9013a5e0e1f6c443352ce4f20f.zip
ANDROID: Fix texture clear color
Diffstat (limited to 'backends/platform/android/texture.cpp')
-rw-r--r--backends/platform/android/texture.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/backends/platform/android/texture.cpp b/backends/platform/android/texture.cpp
index 499de00f56..b129b5ed48 100644
--- a/backends/platform/android/texture.cpp
+++ b/backends/platform/android/texture.cpp
@@ -267,6 +267,10 @@ void GLESTexture::fillBuffer(uint32 color) {
setDirty();
}
+void GLESTexture::clearBuffer() {
+ fillBuffer(_pixelFormat.ARGBToColor(0xff, 0, 0, 0));
+}
+
void GLESTexture::drawTexture(GLshort x, GLshort y, GLshort w, GLshort h) {
if (_all_dirty) {
_dirty_rect.top = 0;
@@ -377,6 +381,10 @@ void GLESPaletteTexture::fillBuffer(uint32 color) {
setDirty();
}
+void GLESPaletteTexture::clearBuffer() {
+ fillBuffer(0);
+}
+
void GLESPaletteTexture::updateBuffer(GLuint x, GLuint y, GLuint w, GLuint h,
const void *buf, int pitch_buf) {
setDirtyRect(Common::Rect(x, y, x + w, y + h));
@@ -497,6 +505,10 @@ void GLESFakePaletteTexture::fillBuffer(uint32 color) {
setDirty();
}
+void GLESFakePaletteTexture::clearBuffer() {
+ fillBuffer(_palettePixelFormat.ARGBToColor(0xff, 0, 0, 0));
+}
+
void GLESFakePaletteTexture::updateBuffer(GLuint x, GLuint y, GLuint w,
GLuint h, const void *buf,
int pitch_buf) {