diff options
author | Jens Arnold <amiconn@rockbox.org> | 2009-06-01 21:28:03 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2009-06-01 21:28:03 +0000 |
commit | c1d27d105c3333b5df67c97d88885efa2a49bc9a (patch) | |
tree | 143ea17a46fe2a4bc86386ffa381d9c9f8249029 /apps/plugins/lib | |
parent | aa7d43f7a61998080be228f94aa3d26b5c1dfbc5 (diff) | |
download | rockbox-c1d27d105c3333b5df67c97d88885efa2a49bc9a.tar.gz rockbox-c1d27d105c3333b5df67c97d88885efa2a49bc9a.zip |
Speed up mono bitmap drawing on horizontally packed greyscale targets (greyscale iPods). Average speedup is 80% on PP5002, and 55% on PP502x. * Simplify mono bitmap drawing in the 16 bit driver and the greylib a bit, also giving a slight speedup (3% on PP502x, 1.5% on coldfire).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21163 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/lib')
-rw-r--r-- | apps/plugins/lib/grey_draw.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/apps/plugins/lib/grey_draw.c b/apps/plugins/lib/grey_draw.c index c1e6376cfe..3b81694426 100644 --- a/apps/plugins/lib/grey_draw.c +++ b/apps/plugins/lib/grey_draw.c | |||
@@ -447,6 +447,7 @@ void grey_mono_bitmap_part(const unsigned char *src, int src_x, int src_y, | |||
447 | src_end = src + width; | 447 | src_end = src + width; |
448 | dwidth = _grey_info.width; | 448 | dwidth = _grey_info.width; |
449 | dst = &_grey_info.buffer[_GREY_MULUQ(dwidth, y) + x]; | 449 | dst = &_grey_info.buffer[_GREY_MULUQ(dwidth, y) + x]; |
450 | dst_end = dst + _GREY_MULUQ(dwidth, height); | ||
450 | 451 | ||
451 | if (drmode & DRMODE_INVERSEVID) | 452 | if (drmode & DRMODE_INVERSEVID) |
452 | { | 453 | { |
@@ -461,8 +462,6 @@ void grey_mono_bitmap_part(const unsigned char *src, int src_x, int src_y, | |||
461 | unsigned data = (*src_col ^ dmask) >> src_y; | 462 | unsigned data = (*src_col ^ dmask) >> src_y; |
462 | int fg, bg; | 463 | int fg, bg; |
463 | 464 | ||
464 | dst_end = dst_col + _GREY_MULUQ(dwidth, height); | ||
465 | |||
466 | #define UPDATE_SRC do { \ | 465 | #define UPDATE_SRC do { \ |
467 | data >>= 1; \ | 466 | data >>= 1; \ |
468 | if (data == 0x001) { \ | 467 | if (data == 0x001) { \ |