Vips.Image.countlines (original) (raw)
Method
VipsImagecountlines
Declaration [src]
int
vips_countlines (
VipsImage* in,
double* nolines,
VipsDirection direction,
...
)
Description [src]
Function which calculates the number of transitions between black and white for the horizontal or the vertical direction of an image. black<128 , white>=128 The function calculates the number of transitions for all Xsize or Ysize and returns the mean of the result Input should be one band, 8-bit.
This method is not directly available to language bindings.
Parameters
nolines
Type: double*
Output average number of lines.
The argument will be set by the function.
direction
Type: VipsDirection
Count lines horizontally or vertically.
...
Type: ``
NULL-terminated list of optional named arguments.
Return value
Type: int
0 on success, -1 on error.