PANDORE Version 6 |
GREYC-IMAGE |
pskewanglecorrection
Skew angle detection and correction.
Synopsis
pskewanglecorrection [-m mask] [rg1_in|-] [rg2_in|-]
Description
pskewanglecorrection detects and corrects the skew
deviation in a document according to the writings orientation.
The mask of size width x height
that is used to estimate the skew angle. This mask is extracted from the
input image and represents the best tradeoff between density
and number of black and white transitions in row.
Then, the skew angle is determined by the angle which gives
the higher maximum in the Wigner-Ville distribution of
the horizontal distribution of the mask image.
Parameters
- width, height are the size of the mask that is used
to estimate the skew angle. This mask is extracted from the
input image and represents the best trade-off between density
and number of black and white transitions in row.
- max_skew_angle is the maximum degree accepted for the correction.
Inputs
- im1_in: a region map (segmented image).
- im2_in: a region map (reference image/ ground truth).
Result
The skew angle value in degree.
Examples
pskewanglecorrection 70 100 10 page.pan a.pan
See also
Reconstruction
C++ prototype
Errc PSkewAngleCorrection( const Img2duc &rg1_in, const Img2duc &rg2_in, int width, int height, int max_angle );
Author: Régis Clouard