PANDORE Version 6 GREYC-IMAGE

pregionrectangularity



Measures region rectangularity degree.



Synopsis

pregionrectangularity name [-m mask] [rg_in|-] [col_out|-]

Description

pregionrectangularity measures the rectangularity of the regions inside the region map rg_in. Each region rectangularity is stored as a float in the array named name inside the collection col_out. The ith item in the array corresponds to the i+1th region because the region 0 is not considered.

Rectangularity is the ratio of a region area to the area of the minimum bounding rectangle. The maximum value is 1.0 for a square.

Parameters

Inputs

Outputs

Result

Returns SUCCESS or FAILURE.

Examples

Displays rectangularity of the regions yielded by a simple binarization of tangram.pan:

   pbinarization 100 1e30 tangram.pan a.pan
   plabeling 8 a.pan b.pan
   pregionrectangularity rectangularity b.pan c.pan
   pcol2txt c.pan

See also

Region Features Extraction

C++ prototype

PRegioinRectangularity( const Reg2d &rg_in, Collection &cold, const std::string &name );

Version française

Calcul de la rectangularité des régions.


Author: Alexandre Duret-Lutz