X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=drv%2Flcd_gfx_qt.cpp;h=e42be22d2fc98ae90c11b087dd32c738fea32450;hb=633a26b43c6a9a43ecb1d08425fbb53145e10bc1;hp=f838ac7d4e23ae5522239ed25f6432d7e308b4da;hpb=20d3c79024c12bb366270c0c1fdda53c4c55e734;p=bertos.git diff --git a/drv/lcd_gfx_qt.cpp b/drv/lcd_gfx_qt.cpp old mode 100755 new mode 100644 index f838ac7d..e42be22d --- a/drv/lcd_gfx_qt.cpp +++ b/drv/lcd_gfx_qt.cpp @@ -1,8 +1,33 @@ /** * \file * * * \version $Id$ @@ -12,44 +37,15 @@ * \brief Custom control for graphics LCD emulation (interface) */ -/*#* - *#* $Log$ - *#* Revision 1.6 2006/02/20 02:00:40 bernie - *#* Port to Qt 4.1. - *#* - *#* Revision 1.5 2006/02/15 09:13:16 bernie - *#* Switch to BITMAP_FMT_PLANAR_V_LSB. - *#* - *#* Revision 1.4 2006/02/10 12:33:49 bernie - *#* Make emulator display a bit larger. - *#* - *#* Revision 1.3 2006/01/23 23:11:07 bernie - *#* Use RASTER_SIZE() to compute... err... the raster size. - *#* - *#* Revision 1.2 2006/01/17 02:30:43 bernie - *#* Fix QImage format. - *#* - *#* Revision 1.1 2006/01/16 03:51:35 bernie - *#* Add LCD Qt emulator. - *#* - *#*/ - #include "lcd_gfx_qt.h" #include #include #include // CONFIG_BITMAP_FMT -#if _QT < 4 - #include - #include - #include - #include -#else - #include - #include - #include - #include -#endif +#include +#include +#include +#include // Display colors #define LCD_FG_COLOR 0x0, 0x0, 0x0 @@ -118,7 +114,7 @@ void EmulLCD::writeRaster(uint8_t *new_raster) uint8_t v = 0; for (int xbit = 0; xbit < 8; ++xbit) v |= (new_raster[(xbyte * 8 + xbit) + (y / 8) * WIDTH] & (1 << (y%8)) ) - ? (1 << (7 - xbit)) : 0; + ? 0 : (1 << (7 - xbit)); raster[y * ((WIDTH + 7) / 8) + xbyte] = v; } @@ -136,17 +132,17 @@ void EmulLCD::writeRaster(uint8_t *new_raster) #include #include -/*! +DECLARE_WALL(wall_before_raster, WALL_SIZE) +/** * Raster buffer to draw into. * * Bits in the bitmap bytes have vertical orientation, * as required by the LCD driver. */ -DECLARE_WALL(wall_before_raster, WALL_SIZE) -static uint8_t lcd_raster[RASTER_SIZE(EmulLCD::WIDTH, EmulLCD::HEIGHT)]; +static uint8_t lcd_raster[RAST_SIZE(EmulLCD::WIDTH, EmulLCD::HEIGHT)]; DECLARE_WALL(wall_after_raster, WALL_SIZE) -/*! Default LCD bitmap */ +/** Default LCD bitmap */ struct Bitmap lcd_bitmap; /*extern "C"*/ void lcd_init(void) @@ -157,7 +153,7 @@ struct Bitmap lcd_bitmap; gfx_bitmapClear(&lcd_bitmap); } -/*extern "C"*/ void lcd_blit_bitmap(Bitmap *bm) +/*extern "C"*/ void lcd_blitBitmap(Bitmap *bm) { //FIXME CHECK_WALL(wall_before_raster); //FIXME CHECK_WALL(wall_after_raster);