mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-11-10 05:32:40 -05:00
ImageViewer Fix jpeg decoder
Image viewer compiles decoders as a plugin and removes CRT0 A resuklt static vars do not get initialized in decoders Change-Id: I72da326967c7b404b297897000f82852661a7ebb
This commit is contained in:
parent
87e37a4d48
commit
eb9f05f835
1 changed files with 3 additions and 7 deletions
|
|
@ -236,7 +236,7 @@ static fb_data (* const pixel_funcs[COLOUR_NUM_MODES][DITHER_NUM_MODES])(void) =
|
||||||
[DITHER_DIFFUSION] = pixel_fsdither_to_lcd,
|
[DITHER_DIFFUSION] = pixel_fsdither_to_lcd,
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
static fb_data *lcd_fb = NULL;
|
|
||||||
/* These defines are used fornormal horizontal strides and vertical strides. */
|
/* These defines are used fornormal horizontal strides and vertical strides. */
|
||||||
#if defined(LCD_STRIDEFORMAT) && LCD_STRIDEFORMAT == VERTICAL_STRIDE
|
#if defined(LCD_STRIDEFORMAT) && LCD_STRIDEFORMAT == VERTICAL_STRIDE
|
||||||
#define LCDADDR(x, y) (lcd_fb + LCD_HEIGHT*(x) + (y))
|
#define LCDADDR(x, y) (lcd_fb + LCD_HEIGHT*(x) + (y))
|
||||||
|
|
@ -260,13 +260,9 @@ void yuv_bitmap_part(unsigned char *src[3], int csub_x, int csub_y,
|
||||||
int src_x, int src_y, int stride,
|
int src_x, int src_y, int stride,
|
||||||
int x, int y, int width, int height,
|
int x, int y, int width, int height,
|
||||||
int colour_mode, int dither_mode)
|
int colour_mode, int dither_mode)
|
||||||
{
|
|
||||||
if (!lcd_fb)
|
|
||||||
{
|
{
|
||||||
struct viewport *vp_main = *(rb->screens[SCREEN_MAIN]->current_viewport);
|
struct viewport *vp_main = *(rb->screens[SCREEN_MAIN]->current_viewport);
|
||||||
lcd_fb = vp_main->buffer->fb_ptr;
|
fb_data *lcd_fb = vp_main->buffer->fb_ptr;
|
||||||
}
|
|
||||||
|
|
||||||
fb_data *dst, *dst_end;
|
fb_data *dst, *dst_end;
|
||||||
fb_data (*pixel_func)(void);
|
fb_data (*pixel_func)(void);
|
||||||
struct rgb_pixel px;
|
struct rgb_pixel px;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue