Method

VipsImagesign

Declaration [src]

int
vips_sign (
  VipsImage* in,
  VipsImage** out,
  ...
)

Description [src]

Finds the unit vector in the direction of the pixel value. For non-complex images, it returns a signed char image with values -1, 0, and 1 for negative, zero and positive pixels. For complex images, it returns a complex normalised to length 1.

See also: vips_abs().

This method is not directly available to language bindings.

Parameters

out VipsImage
 

Output image.

 The argument will be set by the function.
 The instance takes ownership of the data, and is responsible for freeing it.
...
 

NULL-terminated list of optional named arguments.

Return value

Returns: int
 

0 on success, -1 on error.