From c214e7bb0c3e97d22ecedb1c62f193e19a1d4818 Mon Sep 17 00:00:00 2001 From: Jens Arnold Date: Mon, 7 Aug 2006 01:46:42 +0000 Subject: Grayscale library ported to the grayscale iPods, first version. Added C reference versions of gray_update_rect() for both horizontal and vertical pixel packing. gray_update_rect() and gray_ub_gray_bitmap_part() not yet assembler optimised. Grayscale screendump doesn't work yet. * Fixed button assignments for iPod in grayscale.c git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10468 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/lib/gray.h | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'apps/plugins/lib/gray.h') diff --git a/apps/plugins/lib/gray.h b/apps/plugins/lib/gray.h index 398462f..460aa83 100644 --- a/apps/plugins/lib/gray.h +++ b/apps/plugins/lib/gray.h @@ -27,7 +27,7 @@ #include "plugin.h" -#ifdef HAVE_LCD_BITMAP /* and also not for the Player */ +#ifdef HAVE_LCD_BITMAP /* not for the Player */ #define GRAY_BRIGHTNESS(y) (y) @@ -109,9 +109,6 @@ void gray_ub_scroll_down(int count); /*** Internal stuff ***/ -#define _PBLOCK_EXP 3 -#define _PBLOCK (1 << _PBLOCK_EXP) - /* flag definitions */ #define _GRAY_RUNNING 0x0001 /* greyscale overlay is running */ #define _GRAY_DEFERRED_UPDATE 0x0002 /* lcd_update() requested */ @@ -124,10 +121,16 @@ void gray_ub_scroll_down(int count); struct _gray_info { int x; - int by; /* 8-pixel units */ + int y; int width; int height; +#if LCD_PIXELFORMAT == HORIZONTAL_PACKING + int bx; /* 8-pixel units */ + int bwidth; /* 8-pixel units */ +#else /* vertical packing */ + int by; /* 8-pixel units */ int bheight; /* 8-pixel units */ +#endif int depth; /* number_of_bitplanes = (number_of_grayscales - 1) */ unsigned long flags; /* various flags, see #defines */ #ifndef SIMULATOR -- cgit v1.1