1mlib_ImageRotateIndex(3MLIBm)ediaLib Library Functionmslib_ImageRotateIndex(3MLIB)
2
3
4

NAME

6       mlib_ImageRotateIndex - rotate color-indexed image
7

SYNOPSIS

9       cc [ flag... ] file... -lmlib [ library... ]
10       #include <mlib.h>
11
12       mlib_status mlib_ImageRotateIndex(mlib_image *dst, const mlib_image *src,
13            mlib_d64 angle, mlib_d64 xcenter, mlib_d64 ycenter, mlib_filter filter,
14            mlib_edge edge, const void *colormap);
15
16

DESCRIPTION

18       The  mlib_ImageRotateIndex()  function rotates the source image about a
19       user-defined rotation center in user-defined radians.
20
21
22       The width and height of the destination image can be different from the
23       width  and  height of the source image. The (xcenter, ycenter) point of
24       the source image is mapped to the center of the destination image.  You
25       should  ensure  that the destination buffer is large enough to hold the
26       resulting bounding box to avoid clipping part of the image.
27
28
29       The source and destination images must be single-channel images.
30
31
32       The image data type must be MLIB_BYTE or MLIB_SHORT.
33
34
35       The center of the upper-left corner pixel of an  image  is  located  at
36       (0.5, 0.5).
37

PARAMETERS

39       The function takes the following arguments:
40
41       dst         Pointer to destination image.
42
43
44       src         Pointer to source image.
45
46
47       angle       Angle  of rotation. The angle is measured in radians clock‐
48                   wise.
49
50
51       xcenter     X coordinate of rotation center in the source image.
52
53
54       ycenter     Y coordinate of rotation center in the source image.
55
56
57       filter      Type of resampling filter. It can be one of the following:
58
59                     MLIB_NEAREST
60                     MLIB_BILINEAR
61                     MLIB_BICUBIC
62                     MLIB_BICUBIC2
63
64
65
66       edge        Type of edge condition. It can be one of the following:
67
68                     MLIB_EDGE_DST_NO_WRITE
69                     MLIB_EDGE_DST_FILL_ZERO
70                     MLIB_EDGE_OP_NEAREST
71                     MLIB_EDGE_SRC_EXTEND
72                     MLIB_EDGE_SRC_PADDED
73
74
75
76       colormap    Internal data structure for  inverse  color  mapping.  This
77                   data   structure   is   generated   by  the  mlib_ImageCol‐
78                   orTrue2IndexInit() function.
79
80

RETURN VALUES

82       The function returns MLIB_SUCCESS if successful. Otherwise  it  returns
83       MLIB_FAILURE.
84

ATTRIBUTES

86       See attributes(5) for descriptions of the following attributes:
87
88
89
90
91       ┌─────────────────────────────┬─────────────────────────────┐
92       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
93       ├─────────────────────────────┼─────────────────────────────┤
94       │Interface Stability          │Committed                    │
95       ├─────────────────────────────┼─────────────────────────────┤
96       │MT-Level                     │MT-Safe                      │
97       └─────────────────────────────┴─────────────────────────────┘
98

SEE ALSO

100       mlib_ImageRotate(3MLIB), mlib_ImageRotate_Fp(3MLIB), attributes(5)
101
102
103
104SunOS 5.11                        2 Mar 2007      mlib_ImageRotateIndex(3MLIB)
Impressum