65 #define SIMAGE_VERSION_1_1 68 #define SIMAGE_VERSION_1_2 71 #define SIMAGE_VERSION_1_3 74 #define SIMAGE_VERSION_1_4 80 #define SIMAGE_VERSION_1_5 84 #define SIMAGE_VERSION_1_6 92 #if !defined(SIMAGE_MAJOR_VERSION) 93 #undef SIMAGE_MAJOR_VERSION 95 #if !defined(SIMAGE_MINOR_VERSION) 96 #undef SIMAGE_MINOR_VERSION 98 #if !defined(SIMAGE_MICRO_VERSION) 99 #undef SIMAGE_MICRO_VERSION 101 #if !defined(SIMAGE_VERSION) 102 #undef SIMAGE_VERSION 108 #ifdef SIMAGE_DLL_API 109 # error Leave the internal SIMAGE_DLL_API define alone. 143 #if defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__) 144 # ifdef SIMAGE_INTERNAL 145 # ifdef SIMAGE_MAKE_DLL 146 # define SIMAGE_DLL_API __declspec(dllexport) 150 # define SIMAGE_DLL_API __declspec(dllimport) 152 # ifndef SIMAGE_NOT_DLL 153 # error Define either SIMAGE_DLL or SIMAGE_NOT_DLL as appropriate for your linkage! 160 #ifndef SIMAGE_DLL_API 161 # define SIMAGE_DLL_API 179 SIMAGE_DLL_API
void simage_version(
int * major,
int * minor,
int * micro);
200 int * width,
int * height,
201 int * numcomponents);
227 SIMAGE_DLL_API
unsigned char *
simage_resize(
unsigned char * imagedata,
228 int width,
int height,
230 int newwidth,
int newheight);
237 unsigned char *(*load_func)(
const char * name,
int * width,
int * height,
238 int * numcomponents);
240 const unsigned char * header,
int headerlen);
263 const unsigned char * bytes,
264 int w,
int h,
int numcomponents,
265 const char * filenameextension);
268 const unsigned char * bytes,
269 int width,
int height,
int nc),
270 int (*error_func)(
char * textbuffer,
int bufferlen),
271 const char * extensions,
272 const char * fullname,
273 const char * description,
298 unsigned char * prealloc );
306 unsigned char * data,
int copydata);
406 SIMAGE_DLL_API
unsigned char *
simage_resize3d(
unsigned char * imagedata,
407 int width,
int height,
410 int newwidth,
int newheight,
492 unsigned char * buf);
int s_image_set_component_order(s_image *image, int order)
Definition: simage12.c:94
char * filename
Definition: stream.c:38
int simage_get_num_savers(void)
Definition: simage_write.c:524
int simage_save_image(const char *filename, const unsigned char *bytes, int w, int h, int numcomponents, const char *filenameextension)
Definition: simage_write.c:433
int s_stream_seek(s_stream *stream, int offset, int whence, s_params *params)
Definition: stream.c:295
int s_image_height(s_image *image)
Definition: simage12.c:79
const char * simage_get_last_error(void)
Definition: simage.c:317
void s_movie_exporter_add(s_movie_create_func *create, s_movie_put_func *put, s_movie_close_func *close)
Definition: movie.c:222
void s_dlclose_func(void *handle)
Definition: simage.h:496
static s_dlsym_func * dlsym
Definition: simage.c:489
int s_image_width(s_image *image)
Definition: simage12.c:72
void * s_dlopen_func(const char *filename)
Definition: simage.h:494
void s_stream_importer_add(s_stream_open_func *open, s_stream_get_func *get, s_stream_close_func *close)
Definition: stream.c:225
s_params * s_params_create(void)
Definition: params.c:49
void s_stream_exporter_add(s_stream_create_func *create, s_stream_put_func *put, s_stream_close_func *close)
Definition: stream.c:260
int s_movie_put_image(s_movie *movie, s_image *image, s_params *params)
Definition: movie.c:169
const char * simage_get_saver_fullname(void *handle)
Definition: simage_write.c:560
unsigned char * simage_resize3d(unsigned char *imagedata, int width, int height, int numcomponents, int layers, int newwidth, int newheight, int newlayers)
Definition: simage13.c:29
s_movie * s_movie_open(const char *filename)
Definition: movie.c:106
s_params * s_params_copy(s_params *params)
Definition: params.c:94
int simage_check_save_supported(const char *filenameextension)
Definition: simage_write.c:515
unsigned char * simage_read_image(const char *filename, int *width, int *height, int *numcomponents)
Definition: simage.c:290
int simage_next_power_of_two(int val)
Definition: simage.c:381
void s_movie_importer_add(s_movie_open_func *open, s_movie_get_func *get, s_movie_close_func *close)
Definition: movie.c:199
s_stream * s_stream_open(const char *filename, s_params *params)
Definition: stream.c:111
static s_dlopen_func * dlopen
Definition: simage.c:488
void s_movie_close_func(s_movie *)
Definition: simage.h:295
int s_stream_seek_func(s_stream *, int, int, s_params *)
Definition: simage.h:451
Definition: simage_private.h:34
int s_stream_put_func(s_stream *, void *, int, s_params *)
Definition: simage.h:421
int simage_check_supported(const char *filename)
Definition: simage.c:326
void s_image_destroy(s_image *image)
Definition: simage12.c:56
void * s_stream_get_buffer(s_stream *stream, void *prealloc, int *size, s_params *params)
Definition: stream.c:176
void * simage_get_saver_handle(int idx)
Definition: simage_write.c:542
void * simage_add_loader(const struct simage_plugin *l, int addbefore)
Definition: simage.c:333
s_stream_put_func * put
Definition: stream.c:43
void s_params_set(s_params *params,...)
Definition: params.c:187
int s_movie_create_func(const char *, s_movie *, s_params *)
Definition: simage.h:292
int(* identify_func)(const char *filename, const unsigned char *header, int headerlen)
Definition: simage.h:239
s_image * s_image_create(int w, int h, int components, unsigned char *prealloc)
Definition: simage12.c:30
int s_stream_create_func(const char *, s_stream *, s_params *)
Definition: simage.h:419
s_stream_close_func * close
Definition: stream.c:44
void s_stream_exporter_add_ex(s_stream_create_func *create, s_stream_put_func *put, s_stream_seek_func *seek, s_stream_tell_func *tell, s_stream_close_func *close)
Definition: stream.c:268
s_stream_seek_func * seek
Definition: stream.c:45
const char * simage_get_saver_description(void *handle)
Definition: simage_write.c:567
s_params * s_stream_params(s_stream *stream)
Definition: stream.c:204
unsigned char * s_image_data(s_image *image)
Definition: simage12.c:108
int s_movie_put_func(s_movie *, s_image *, s_params *)
Definition: simage.h:294
void * s_dlsym_func(void *handle, const char *symbolname)
Definition: simage.h:495
s_stream_open_func * open
Definition: stream.c:40
void s_stream_importer_add_ex(s_stream_open_func *open, s_stream_get_func *get, s_stream_seek_func *seek, s_stream_tell_func *tell, s_stream_close_func *close)
Definition: stream.c:233
s_image * s_movie_get_image(s_movie *movie, s_image *prealloc, s_params *params)
Definition: movie.c:163
static s_dlclose_func * dlclose
Definition: simage.c:490
int s_stream_open_func(const char *, s_stream *, s_params *)
Definition: simage.h:418
s_stream_tell_func * tell
Definition: stream.c:46
void s_stream_destroy(s_stream *stream)
Definition: stream.c:196
int s_stream_tell(s_stream *stream, s_params *params)
Definition: stream.c:304
s_stream_create_func * create
Definition: stream.c:41
void * simage_add_saver(int(*save_func)(const char *name, const unsigned char *bytes, int width, int height, int nc), int(*error_func)(char *textbuffer, int bufferlen), const char *extensions, const char *fullname, const char *description, int addbefore)
Definition: simage_write.c:469
void * s_stream_get_func(s_stream *, void *, int *, s_params *)
Definition: simage.h:420
void s_stream_close_func(s_stream *)
Definition: simage.h:422
void simage_free_image(unsigned char *imagedata)
Definition: simage.c:404
void simage_version(int *major, int *minor, int *micro)
Definition: simage.c:396
void simage_remove_loader(void *handle)
Definition: simage.c:344
void s_movie_close(s_movie *movie)
Definition: movie.c:176
int s_stream_tell_func(s_stream *, s_params *)
Definition: simage.h:452
void s_movie_destroy(s_movie *movie)
Definition: movie.c:182
int s_image_read_line(s_image *image, int line, unsigned char *buf)
Definition: simage.c:451
s_image * s_movie_get_func(s_movie *, s_image *, s_params *)
Definition: simage.h:293
void s_set_dynamic_loader_interface(s_dlopen_func *dlopen, s_dlsym_func *dlsym, s_dlclose_func *dlclose)
Definition: simage.c:493
void s_image_set(s_image *image, int w, int h, int components, unsigned char *data, int copydata)
Definition: simage12.c:126
int s_image_save(const char *filename, s_image *image, s_params *params)
Definition: simage12.c:191
s_movie * s_movie_create(const char *filename, s_params *params)
Definition: movie.c:135
int s_image_get_component_order(s_image *image)
Definition: simage12.c:102
void s_stream_close(s_stream *stream)
Definition: stream.c:190
s_image * s_image_load(const char *filename, s_image *prealloc)
Definition: simage12.c:163
s_params * params
Definition: stream.c:48
unsigned char * simage_resize(unsigned char *imagedata, int width, int height, int numcomponents, int newwidth, int newheight)
Definition: resize.c:512
void s_params_destroy(s_params *params)
Definition: params.c:57
int s_stream_put_buffer(s_stream *stream, void *buffer, int size, s_params *params)
Definition: stream.c:183
int s_params_get(s_params *params,...)
Definition: params.c:251
void simage_remove_saver(void *handle)
Definition: simage_write.c:489
const char * simage_get_saver_extensions(void *handle)
Definition: simage_write.c:553
int s_image_components(s_image *image)
Definition: simage12.c:86
s_image * s_image_open(const char *file, int oktoreadall)
Definition: simage.c:413
int s_movie_open_func(const char *, s_movie *)
Definition: simage.h:291
int(* error_func)(char *textbuffer, int bufferlen)
Definition: simage.h:241
s_stream * s_stream_create(const char *filename, s_params *params)
Definition: stream.c:145