ImgRemovePunchHoles

Top  Previous  Next

Prototype

 

ImgRemovePunchHoles(intImageHandle, intSides, intStyles, floatMaxBorderDistance, floatAverageDiameter)

 

Description

 

This function remove the black holes from punched sheets of paper.

 

Parameters

 

intImageHandle: integer value corresponding to the image handle.

 

intSides: integer value, indicading the sides to check for presence of punch holes; can be the sum of 1 (left side), 2 (top side), 4 (right side), 8 (bottom side).

 

intStyles: integer value, indicading the styles of punch holes to remove; can be the sum of 1 (European style 2 holes), 2 (European style 4 holes), 4 (American style 3 holes, variation "a"), 8 (America Style 2 holes), 16 (American style 3 holes, variation "b"), 32 (Sweeden Style, 3 holes, triohålning)

 

floatMaxBorderDistance: float valure, representig the max distance in inches from borders where the holes can be found.

 

floatAverageDiameter: float value, representig the average diameter of holes in inches; the system search for holes with +/- 30%

 

 

Returned value

 

The styles of holes removed if any, or 0 if no holes found.

 

Notes

 

This function can works only on bitnonal images.

 

Example

 

// Remove all american styles punch holes on left and right side up to 1.5 inches from margins with 0.2 inches of diameter.

ImgRemovePunchHoles(_CurrentImage, 5, 28, 1.5, 0.2);