mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-12-08 12:45:26 -05:00
Lcd save function pointer to frame buffer get_address_fn before loops
Calling multiple levels of indirection in a loop slows things down Really these need to be rewritten to take a start and end address like most of the rest of the codebase But this is safer without having test hardware in hand Change-Id: Idae7b92ee779d020ed7fcc9334e2d5a9c710e64d
This commit is contained in:
parent
60e5786b48
commit
cfeeb7889d
23 changed files with 78 additions and 40 deletions
|
|
@ -198,9 +198,10 @@ static void create_llp(int x, int y, int width, int height)
|
|||
|
||||
width = width>>1;
|
||||
|
||||
void* (*fbaddr)(int x, int y) = FB_CURRENTVP_BUFFER->get_address_fn;
|
||||
/* build LLPs */
|
||||
for (i=0; i<height; i++)
|
||||
llp_setup((void *)FBADDR(x,y+i),
|
||||
llp_setup((void *)fbaddr(x,y+i),
|
||||
(void*)(LCD_BUFF+((i%4)*4*width)),
|
||||
&(scr_llp[i]),
|
||||
width);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue