1mlib_ImageConstXor(3MLIB) mediaLib Library Functions mlib_ImageConstXor(3MLIB)
2
3
4
6 mlib_ImageConstXor - Xor with a constant
7
9 cc [ flag... ] file... -lmlib [ library... ]
10 #include <mlib.h>
11
12 mlib_status mlib_ImageConstXor(mlib_image *dst, const mlib_image *src,
13 const mlib_s32 *c);
14
15
17 The mlib_ImageConstXor() function computes the exclusive Or of the
18 source image with a constant on a pixel-by-pixel basis.
19
20
21 It uses the following equation:
22
23 dst[x][y][i] = c[i] ^ src[x][y][i]
24
25
26
27 The data type of the images can be MLIB_BIT, MLIB_BYTE, MLIB_SHORT,
28 MLIB_USHORT, or MLIB_INT.
29
31 The function takes the following arguments:
32
33 dst Pointer to destination image.
34
35
36 src Pointer to source image.
37
38
39 c Array of constants to be applied to each pixel. c[i] contains
40 the constant for channel i.
41
42
44 The function returns MLIB_SUCCESS if successful. Otherwise it returns
45 MLIB_FAILURE.
46
48 See attributes(5) for descriptions of the following attributes:
49
50
51
52
53 ┌─────────────────────────────┬─────────────────────────────┐
54 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
55 ├─────────────────────────────┼─────────────────────────────┤
56 │Interface Stability │Committed │
57 ├─────────────────────────────┼─────────────────────────────┤
58 │MT-Level │MT-Safe │
59 └─────────────────────────────┴─────────────────────────────┘
60
62 mlib_ImageConstXor_Inp(3MLIB), attributes(5)
63
64
65
66SunOS 5.11 2 Mar 2007 mlib_ImageConstXor(3MLIB)