mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-14 02:27:39 -04:00
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
This commit is contained in:
parent
c4ed88f593
commit
92785b8f2f
5 changed files with 356 additions and 212 deletions
|
@ -49,8 +49,8 @@ static void output_row_null(uint32_t row, void * row_in,
|
|||
#else
|
||||
uint32_t *lim = in + ctx->bm->width;
|
||||
#endif
|
||||
for (; in < lim; in++)
|
||||
output = SC_MUL(*in + ctx->round, ctx->divisor);
|
||||
while (in < lim)
|
||||
output = SC_OUT(*in++, ctx);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue