|
Leptonica
1.54
|
#include "allheaders.h"Функции | |
| PIXACC * | pixaccCreate (l_int32 w, l_int32 h, l_int32 negflag) |
| PIXACC * | pixaccCreateFromPix (PIX *pix, l_int32 negflag) |
| void | pixaccDestroy (PIXACC **ppixacc) |
| PIX * | pixaccFinal (PIXACC *pixacc, l_int32 outdepth) |
| PIX * | pixaccGetPix (PIXACC *pixacc) |
| l_int32 | pixaccGetOffset (PIXACC *pixacc) |
| l_int32 | pixaccAdd (PIXACC *pixacc, PIX *pix) |
| l_int32 | pixaccSubtract (PIXACC *pixacc, PIX *pix) |
| l_int32 | pixaccMultConst (PIXACC *pixacc, l_float32 factor) |
| l_int32 | pixaccMultConstAccumulate (PIXACC *pixacc, PIX *pix, l_float32 factor) |
Input: pixacc
pix (to be added)
Return: 0 if OK, 1 on error
Input: w, h (of 32 bpp internal Pix)
negflag (0 if only positive numbers are involved;
1 if there will be negative numbers)
Return: pixacc, or null on error
Notes: (1) Use @negflag = 1 for safety if any negative numbers are going to be used in the chain of operations. Negative numbers arise, e.g., by subtracting a pix, or by adding a pix that has been pre-multiplied by a negative number. (2) Initializes the internal 32 bpp pix, similarly to the initialization in pixInitAccumulate().
Input: pix
negflag (0 if only positive numbers are involved;
1 if there will be negative numbers)
Return: pixacc, or null on error
Notes: (1) See pixaccCreate()
| void pixaccDestroy | ( | PIXACC ** | ppixacc | ) |
Input: pixacc
outdepth (8, 16 or 32 bpp)
Return: pixd (8 , 16 or 32 bpp), or null on error
Input: pixacc Return: offset, or -1 on error
Input: pixacc Return: pix, or null on error
Input: pixacc
factor
Return: 0 if OK, 1 on error
Input: pixacc
pix
factor
Return: 0 if OK, 1 on error
Notes: (1) This creates a temp pix that is @pix multiplied by the constant @factor. It then adds that into @pixacc.
Input: pixacc
pix (to be subtracted)
Return: 0 if OK, 1 on error