1mlib_ImageConstSub(3MLIB) mediaLib Library Functions mlib_ImageConstSub(3MLIB)
2
3
4
6 mlib_ImageConstSub - Subtraction with a constant
7
9 cc [ flag... ] file... -lmlib [ library... ]
10 #include <mlib.h>
11
12 mlib_status mlib_ImageConstSub(mlib_image *dst, const mlib_image *src,
13 const mlib_s32 *c);
14
15
17 The mlib_ImageConstSub() function subtracts an image pixel from a con‐
18 stant 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
27 The function takes the following arguments:
28
29 dst Pointer to destination image.
30
31
32 src Pointer to source image.
33
34
35 c Array of constants from which each pixel is subtracted by chan‐
36 nel. c[i] contains the constant for channel i.
37
38
40 The function returns MLIB_SUCCESS if successful. Otherwise it returns
41 MLIB_FAILURE.
42
44 See attributes(5) for descriptions of the following attributes:
45
46
47
48
49 ┌─────────────────────────────┬─────────────────────────────┐
50 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
51 ├─────────────────────────────┼─────────────────────────────┤
52 │Interface Stability │Committed │
53 ├─────────────────────────────┼─────────────────────────────┤
54 │MT-Level │MT-Safe │
55 └─────────────────────────────┴─────────────────────────────┘
56
58 mlib_ImageConstSub_Fp(3MLIB), mlib_ImageConstSub_Fp_Inp(3MLIB),
59 mlib_ImageConstSub_Inp(3MLIB), attributes(5)
60
61
62
63SunOS 5.11 2 Mar 2007 mlib_ImageConstSub(3MLIB)