summaryrefslogtreecommitdiff
path: root/glcddrivers/gu256x64-3900.c
diff options
context:
space:
mode:
Diffstat (limited to 'glcddrivers/gu256x64-3900.c')
-rw-r--r--glcddrivers/gu256x64-3900.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/glcddrivers/gu256x64-3900.c b/glcddrivers/gu256x64-3900.c
index 938c01f..2d379bd 100644
--- a/glcddrivers/gu256x64-3900.c
+++ b/glcddrivers/gu256x64-3900.c
@@ -20,7 +20,9 @@
* This file is released under the GNU General Public License. Refer
* to the COPYING file distributed with this package.
*
- * (c) 2004 Ralf Mueller (ralf AT bj-ig.de)
+ * (c) 2004 Ralf Mueller (ralf AT bj-ig.de)
+ * (c) 2005-2010 Andreas Regel <andreas.regel AT powarman.de>
+ * (c) 2011 Wolfgang Astleitner <mrwastl AT users.sourceforge.net>
*/
#include <errno.h>
@@ -523,9 +525,13 @@ void cDriverGU256X64_3900::SetPixel(int x, int y, uint32_t data)
c = 0x80 >> (y % 8);
- m_pDrawMem[x][y/8] = m_pDrawMem[x][y/8] | c;
+ if (data == GLCD::cColor::White)
+ m_pDrawMem[x][y/8] |= c;
+ else
+ m_pDrawMem[x][y/8] &= ( 0xFF ^ c );
}
+#if 0
void cDriverGU256X64_3900::Set8Pixels(int x, int y, unsigned char data)
{
int n;
@@ -539,6 +545,7 @@ void cDriverGU256X64_3900::Set8Pixels(int x, int y, unsigned char data)
SetPixel(x + n, y, GLCD::cColor::White);
}
}
+#endif
void cDriverGU256X64_3900::Refresh(bool refreshAll)
{