1mlib_ImageSetFormat(3MLIB)mediaLib Library Functionsmlib_ImageSetFormat(3MLIB)
2
3
4

NAME

6       mlib_ImageSetFormat - set format
7

SYNOPSIS

9       cc [ flag... ] file... -lmlib [ library... ]
10       #include <mlib.h>
11
12       mlib_status mlib_ImageSetFormat(mlib_image *img, mlib_format format);
13
14

DESCRIPTION

16       The  mlib_ImageSetFormat()  function  sets  a  new value for the format
17       field of a mlib_image structure.
18
19
20       The data type of the image  can  be  MLIB_BIT,  MLIB_BYTE,  MLIB_SHORT,
21       MLIB_USHORT, MLIB_INT, MLIB_FLOAT, or MLIB_DOUBLE.
22

PARAMETERS

24       The function takes the following arguments:
25
26       img       Pointer to a mediaLib image structure.
27
28
29       format    Image pixel format. It can be one of the following:
30
31                   MLIB_FORMAT_UNKNOWN
32                   MLIB_FORMAT_INDEXED
33                   MLIB_FORMAT_GRAYSCALE
34                   MLIB_FORMAT_RGB
35                   MLIB_FORMAT_BGR
36                   MLIB_FORMAT_ARGB
37                   MLIB_FORMAT_ABGR
38                   MLIB_FORMAT_PACKED_ARGB
39                   MLIB_FORMAT_PACKED_ABGR
40                   MLIB_FORMAT_GRAYSCALE_ALPHA
41                   MLIB_FORMAT_RGBA
42
43
44

RETURN VALUES

46       The  function  returns MLIB_SUCCESS if successful. Otherwise it returns
47       MLIB_FAILURE.
48

ATTRIBUTES

50       See attributes(5) for descriptions of the following attributes:
51
52
53
54
55       ┌─────────────────────────────┬─────────────────────────────┐
56       │      ATTRIBUTE TYPE         │      ATTRIBUTE VALUE        │
57       ├─────────────────────────────┼─────────────────────────────┤
58       │Interface Stability          │Committed                    │
59       ├─────────────────────────────┼─────────────────────────────┤
60       │MT-Level                     │MT-Safe                      │
61       └─────────────────────────────┴─────────────────────────────┘
62

SEE ALSO

64       mlib_ImageGetFormat(3MLIB),  mlib_ImageCreate(3MLIB),  mlib_ImageCreat‐
65       eStruct(3MLIB), mlib_ImageCreateSubimage(3MLIB), attributes(5)
66
67
68
69SunOS 5.11                        2 Mar 2007        mlib_ImageSetFormat(3MLIB)
Impressum