blob: 315afaf5706fb66addb464e859398e2fa954c11a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
/*
* imgtools.c
*
* See the README file for copyright information and how to reach the author.
*
*/
#ifndef __IMGTOOLS_H
#define __IMGTOOLS_H
#include <stdio.h>
#define X_DISPLAY_MISSING 1
#include <jpeglib.h>
#include <Imlib2.h>
#include "common.h"
//***************************************************************************
// Image Manipulating
//***************************************************************************
int fromJpeg(Imlib_Image& image, unsigned char* buffer, int size);
long toJpeg(Imlib_Image image, MemoryStruct* data, int quality);
int scaleImageToJpegBuffer(Imlib_Image image, MemoryStruct* data, int width = 0, int height = 0);
int scaleJpegBuffer(MemoryStruct* data, int width = 0, int height = 0);
const char* strImlibError(Imlib_Load_Error err);
//***************************************************************************
#endif // __IMGTOOLS_H
|