1IM_QUANTIM(3) Library Functions Manual IM_QUANTIM(3)
2
3
4
6 im_quantim, im_quantlut, im_spatres - quantise an image or a lut
7
9 #include <vips/vips.h>
10
11 int im_quantim(in, out, no_of_bits)
12 IMAGE *in, *out;
13 int no_of_bits;
14
15 int im_quantlut(lut, no_of_bits)
16 IMAGE *lut;
17 int no_of_bits;
18
19 int im_spatres(in, out, step)
20 IMAGE *in, *out;
21 int step;
22
24 im_quantim() quantises the image file held by in using no_of_bits and
25 writes the result to out. The no_of_bits should be between 1 and 7
26 inclusive. Input can have any number of bands. The function expects
27 as input a valid unsigned char image.
28
29 These functions are here for compatibility only. You should use the
30 boolean operations im_andconst(3), im_orconst(3), im_shrink(3),
31 im_zoom(3) and im_lowpass(3).
32
33 im_quantlut() creates an one band unsigned char lookup table which is
34 used by im_quantim(3). The no_of_bits should be between 1 and 7 inclu‐
35 sive.
36
37 im_spatres() reduces the spatial resolution of in by averaging
38 step*step pixels and replicating the result in out. The function can
39 be used in order to show the effect of reducing the spatial resolution
40 of a given image and the importance of post-filtering before display‐
41 ing. Input can have any number of bands.
42
44 All functions returns 0 on success and -1 on error.
45
47 im_andconst(3), im_orconst(3), im_shrink(3), im_zoom(3) im_lowpass(3).
48
50 N. Dessipris
51
53 N. Dessipris - 10/05/1991
54
55
56
57 10 May 1991 IM_QUANTIM(3)