--- a/src/dreamcast.h Sat Oct 27 05:48:22 2007 +0000 +++ b/src/dreamcast.h Wed Oct 31 11:53:35 2007 +0000 @@ -1,5 +1,5 @@ /** - * $Id: dreamcast.h,v 1.20 2007-10-27 05:48:22 nkeynes Exp $ + * $Id: dreamcast.h,v 1.21 2007-10-31 09:10:23 nkeynes Exp $ * * Public interface for dreamcast.c - * Central switchboard for the system. This pulls all the individual modules @@ -23,7 +23,7 @@ #define dreamcast_H 1 #include -#include +#include "lxdream.h" #ifdef __cplusplus extern "C" { @@ -31,9 +31,6 @@ #define DEFAULT_TIMESLICE_LENGTH 1000000 /* nanoseconds */ -#define MB *1024*1024 -#define KB *1024 - #define XLAT_NEW_CACHE_SIZE 32 MB #define XLAT_TEMP_CACHE_SIZE 2 MB #define XLAT_OLD_CACHE_SIZE 8 MB @@ -55,6 +52,15 @@ int dreamcast_save_state( const gchar *filename ); int dreamcast_load_state( const gchar *filename ); +/** + * Load the front-buffer image from the specified file. + * If the file is not a valid save state, returns NULL. Otherwise, + * returns a newly allocated frame_buffer that should be freed + * by the caller. (The data buffer is contained within the + * allocation and does not need to be freed separately) + */ +frame_buffer_t dreamcast_load_preview( const gchar *filename ); + #define SCENE_SAVE_MAGIC "%!-lxDream!Scene" #define SCENE_SAVE_VERSION 0x00010000