diff options
| author | Andrew Mahone <andrew.mahone@gmail.com> | 2009-05-26 20:00:47 +0000 |
|---|---|---|
| committer | Andrew Mahone <andrew.mahone@gmail.com> | 2009-05-26 20:00:47 +0000 |
| commit | 92785b8f2f20b0fc16de7e771e5eb55fd8497ff8 (patch) | |
| tree | 3af2399c1e1be8e56cb1b5e6787efd738dad6d52 /apps/plugins/lib | |
| parent | c4ed88f59302882749023268ac456c415a4b1243 (diff) | |
| download | rockbox-92785b8f2f20b0fc16de7e771e5eb55fd8497ff8.zip rockbox-92785b8f2f20b0fc16de7e771e5eb55fd8497ff8.tar.gz rockbox-92785b8f2f20b0fc16de7e771e5eb55fd8497ff8.tar.bz2 rockbox-92785b8f2f20b0fc16de7e771e5eb55fd8497ff8.tar.xz | |
Use pre-multiplication in scaler to save one multiply per color component on ARM and Coldfire, at the cost of an extra add/shift in the horizontal scaler to reduce values to a workable range. SH-1 retains the same basic math, as
the use of 16x16->32 hardware multiplication in the earlier scaler stages saves more than removing the 32x32->40 multiply to descale output.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21091 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/lib')
| -rw-r--r-- | apps/plugins/lib/grey_draw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/plugins/lib/grey_draw.c b/apps/plugins/lib/grey_draw.c index 6315ad9..c1e6376 100644 --- a/apps/plugins/lib/grey_draw.c +++ b/apps/plugins/lib/grey_draw.c @@ -733,7 +733,7 @@ static void output_row_grey_32(uint32_t row, void * row_in, uint32_t *qp = (uint32_t*)row_in; uint8_t *dest = (uint8_t*)ctx->bm->data + ctx->bm->width * row; for (col = 0; col < ctx->bm->width; col++) - *dest++ = SC_MUL((*qp++) + ctx->round,ctx->divisor); + *dest++ = SC_OUT(*qp++, ctx); } static unsigned int get_size_grey(struct bitmap *bm) |