1/* Image manipulation functions 2 * 3 * Project : minidlna 4 * Website : http://sourceforge.net/projects/minidlna/ 5 * Author : Justin Maggard 6 * Copyright (c) 2009 Justin Maggard 7 * This software is subject to the conditions detailed in the 8 * LICENCE file provided in this distribution. 9 * */ 10#include <sys/types.h> 11 12typedef u_int32_t pix; 13 14typedef struct { 15 int32_t width; 16 int32_t height; 17 pix *buf; 18} image; 19 20void 21image_free(image *pimage); 22 23int 24image_get_jpeg_date_xmp(const char * path, char ** date); 25 26int 27image_get_jpeg_resolution(const char * path, int * width, int * height); 28 29image * 30image_new_from_jpeg(const char * path, int is_file, const char * ptr, int size, int scale); 31 32image * 33image_resize(image * src_image, int32_t width, int32_t height); 34 35unsigned char * 36image_save_to_jpeg_buf(image * pimage, int * size); 37 38int 39image_save_to_jpeg_file(image * pimage, const char * path); 40