aboutsummaryrefslogtreecommitdiffstats
path: root/drv_generic_graphic.c
diff options
context:
space:
mode:
authorJonathan McCrohan <jmccrohan@gmail.com>2012-03-08 21:03:40 +0000
committerJonathan McCrohan <jmccrohan@gmail.com>2012-03-08 21:03:40 +0000
commitd0b266cf85d3c7733259c76831de0cfd4c1731a1 (patch)
treeb786b2a475051603258720e0a5637c6bd9d3ce9a /drv_generic_graphic.c
parentca7ebcb88a240cbe8bb55919cd622bc057701e75 (diff)
downloadlcd4linux-d0b266cf85d3c7733259c76831de0cfd4c1731a1.tar.gz
Import upstream version 0.11.0~svn1180
Diffstat (limited to 'drv_generic_graphic.c')
-rw-r--r--drv_generic_graphic.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drv_generic_graphic.c b/drv_generic_graphic.c
index b76bd1f..b7a3ec8 100644
--- a/drv_generic_graphic.c
+++ b/drv_generic_graphic.c
@@ -1,4 +1,4 @@
-/* $Id: drv_generic_graphic.c 1156 2011-07-27 05:41:42Z michael $
+/* $Id: drv_generic_graphic.c 1170 2012-01-16 02:50:03Z michael $
* $URL: https://ssl.bulix.org/svn/lcd4linux/trunk/drv_generic_graphic.c $
*
* generic driver helper for graphic displays
@@ -267,10 +267,10 @@ static void drv_generic_graphic_render(const int layer, const int row, const int
}
for (y = 0; y < YRES; y++) {
- int mask = 1 << XRES;
for (x = 0; x < XRES; x++) {
- mask >>= 1;
- if (chr[y] & mask)
+ int mask = 1 << 6;
+ mask >>= ((x * 6) / (XRES)) + 1;
+ if (chr[(y * 8) / (YRES)] & mask)
drv_generic_graphic_FB[layer][(r + y) * LCOLS + c + x] = fg;
else
drv_generic_graphic_FB[layer][(r + y) * LCOLS + c + x] = bg;