1 /* resample.h
2  *
3  * 20/9/09
4  * 	- from proto.h
5  */
6 
7 /*
8 
9     This file is part of VIPS.
10 
11     VIPS is free software; you can redistribute it and/or modify
12     it under the terms of the GNU Lesser General Public License as published by
13     the Free Software Foundation; either version 2 of the License, or
14     (at your option) any later version.
15 
16     This program is distributed in the hope that it will be useful,
17     but WITHOUT ANY WARRANTY; without even the implied warranty of
18     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19     GNU Lesser General Public License for more details.
20 
21     You should have received a copy of the GNU Lesser General Public License
22     along with this program; if not, write to the Free Software
23     Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
24     02110-1301  USA
25 
26  */
27 
28 /*
29 
30     These files are distributed with VIPS - http://www.vips.ecs.soton.ac.uk
31 
32  */
33 
34 #ifndef VIPS_RESAMPLE_H
35 #define VIPS_RESAMPLE_H
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif /*__cplusplus*/
40 
41 typedef enum {
42 	VIPS_KERNEL_NEAREST,
43 	VIPS_KERNEL_LINEAR,
44 	VIPS_KERNEL_CUBIC,
45 	VIPS_KERNEL_MITCHELL,
46 	VIPS_KERNEL_LANCZOS2,
47 	VIPS_KERNEL_LANCZOS3,
48 	VIPS_KERNEL_LAST
49 } VipsKernel;
50 
51 typedef enum {
52 	VIPS_SIZE_BOTH,
53 	VIPS_SIZE_UP,
54 	VIPS_SIZE_DOWN,
55 	VIPS_SIZE_FORCE,
56 	VIPS_SIZE_LAST
57 } VipsSize;
58 
59 int vips_shrink( VipsImage *in, VipsImage **out,
60 	double hshrink, double vshrink, ... )
61 	__attribute__((sentinel));
62 int vips_shrinkh( VipsImage *in, VipsImage **out, int hshrink, ... )
63 	__attribute__((sentinel));
64 int vips_shrinkv( VipsImage *in, VipsImage **out, int vshrink, ... )
65 	__attribute__((sentinel));
66 
67 int vips_reduce( VipsImage *in, VipsImage **out,
68 	double hshrink, double vshrink, ... )
69 	__attribute__((sentinel));
70 int vips_reduceh( VipsImage *in, VipsImage **out, double hshrink, ... )
71 	__attribute__((sentinel));
72 int vips_reducev( VipsImage *in, VipsImage **out, double vshrink, ... )
73 	__attribute__((sentinel));
74 
75 int vips_thumbnail( const char *filename, VipsImage **out, int width, ... )
76 	__attribute__((sentinel));
77 int vips_thumbnail_buffer( void *buf, size_t len, VipsImage **out,
78 	int width, ... )
79 	__attribute__((sentinel));
80 int vips_thumbnail_image( VipsImage *in, VipsImage **out, int width, ... )
81 	__attribute__((sentinel));
82 int vips_thumbnail_source( VipsSource *source, VipsImage **out,
83 	int width, ... )
84 	__attribute__((sentinel));
85 
86 int vips_similarity( VipsImage *in, VipsImage **out, ... )
87 	__attribute__((sentinel));
88 int vips_rotate( VipsImage *in, VipsImage **out, double angle, ... )
89 	__attribute__((sentinel));
90 int vips_affine( VipsImage *in, VipsImage **out,
91 	double a, double b, double c, double d, ... )
92 	__attribute__((sentinel));
93 
94 int vips_resize( VipsImage *in, VipsImage **out, double scale, ... )
95 	__attribute__((sentinel));
96 
97 int vips_mapim( VipsImage *in, VipsImage **out, VipsImage *index, ... )
98 	__attribute__((sentinel));
99 
100 int vips_quadratic( VipsImage *in, VipsImage **out, VipsImage *coeff, ... )
101 	__attribute__((sentinel));
102 
103 #ifdef __cplusplus
104 }
105 #endif /*__cplusplus*/
106 
107 #endif /*VIPS_RESAMPLE_H*/
108