PANDORE Version 6 GREYC-IMAGE

pnot



Performs logical negation of image or graph and complementary of region map.



Synopsis

pnot [-m mask] [im_in|-] [im_out|-]

Description

pnot performs the logical negation of the input.

If input is an image, the negation operator uses the '!' C operator. If an input pixel is greater than 0 then output pixel is 0. If an input pixel is 0 then the output pixel is 1.

   pixel(im_out) = ! pixel(im_in)

For color or multispectral image, the "not" operator is computed separately on each band.

For the graph, the negation operator ! is applied to each node values.

For region map, pnot performs the complementary of the region map im_in. Regions with labels > 0 in im_in become region with label =0 in the im_out and region with label=0 becomes region with label=1. Resulted regions are not more necessarily connected components.

Inputs

Outputs

Result

Returns SUCCESS or FAILURE.
For region map, returns the new higher label value (0 or 1).

Examples

See also

logic

C++ prototype

Errc PNot( const Img2duc &im_in, Img2duc &im_out );

Author: Régis Clouard