From 3d4c68bb060bc926a1da72d6c00b86ebb87857c7 Mon Sep 17 00:00:00 2001 From: Andrew Mahone Date: Sat, 2 May 2009 03:47:46 +0000 Subject: Add read__fd functions to plugin API, add feature_wrappers.h handling for them, and add read_image.[ch] wrapper for reading image files with automatic type detection. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20840 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugin.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'apps/plugin.h') diff --git a/apps/plugin.h b/apps/plugin.h index ab570d4..19eb962 100644 --- a/apps/plugin.h +++ b/apps/plugin.h @@ -79,9 +79,7 @@ void* plugin_get_buffer(size_t *buffer_size); #ifdef HAVE_LCD_BITMAP #include "screendump.h" #include "scrollbar.h" -#if LCD_DEPTH > 1 #include "jpeg_load.h" -#endif #include "../recorder/bmp.h" #endif #include "statusbar.h" @@ -131,7 +129,7 @@ void* plugin_get_buffer(size_t *buffer_size); #define PLUGIN_MAGIC 0x526F634B /* RocK */ /* increase this every time the api struct changes */ -#define PLUGIN_API_VERSION 148 +#define PLUGIN_API_VERSION 149 /* update this to latest version if a change to the api struct breaks backwards compatibility (and please take the opportunity to sort in any @@ -806,9 +804,15 @@ struct plugin_api { #endif #endif -#if defined(HAVE_LCD_BITMAP) && LCD_DEPTH > 1 +#ifdef HAVE_LCD_BITMAP +#if LCD_DEPTH > 1 int (*read_jpeg_file)(const char* filename, struct bitmap *bm, int maxsize, int format, const struct custom_format *cformat); + int (*read_jpeg_fd)(int fd, struct bitmap *bm, int maxsize, + int format, const struct custom_format *cformat); +#endif + int (*read_bmp_fd)(int fd, struct bitmap *bm, int maxsize, + int format, const struct custom_format *cformat); #endif }; -- cgit v1.1