PANDORE Version 6 GREYC-IMAGE

psetcst



Sets constant to image, graph or region map.



Synopsis

psetcst cst [-m mask] [im_in|-] [im_out|-]

Description

psetcst builds the new output im_out by replacing each value by the specified constant value.

If im_in is an image, psetcst sets the specified value to each pixel. This operator can be used to create a new image im_out from the properties of the input image im_in.

For color or multispectral image, psetcst is computed separately on each band.

For region map, psetcst sets the specified value to each label.

For graph, psetcst sets the specified value to each node value.

The output file is of the same type as the input file.

Parameters

Inputs

Outputs

Result

Returns SUCCESS or FAILURE.

For region map, returns the new higher label value (ie. the constant value).

Examples

Creates a.pan with the same property as tangram.pan and sets all its pixels to 10.

   psetscst 10 tangram.pan a.pan

See also

Arithmetic

C++ prototype

Errc PSetCst( const Img2duc &im_in, Img2duc &im_out, Uchar cst );

Version française

Affectation d'une valeur à une image, un graphe ou une carte de région.


Author: Régis Clouard