BinaryHitMiss  Method

Description         Binary Hit-Miss operation is used to extract geometrical features from a binary object. The masks used in the operation determine the type of features that are extracted. The function works for only 1 bit per pixel images. The Hit-Miss filter is defined as:

HitMiss(A,B,C) = (A q B) Ç (AC q C),

                            where A is the image wich is being operated on, B and C are specified structuring functions with the requirement B Ç C = Æ, and q operator means binary erosion.

Examples

Description: kepdoksiba9                                                                       Description: kepdoksiba10

Syntax                 RetVal = [BiFilter.]BinaryHitMiss hDib Mask1 Mheight1 Mwidth1 MPx1 MPy1 Mask2 Mheight2 Mwidth2 MPx2 MPy2 BackGrndisBlack iShowProgress hWnd

Returns               RetVal                    LONGLONG The handle of new filtered DIB, 0 if an error occurred, or -1 if the BIFilter.dll does not installed.

Remarks             hDib                       LONGLONG Handle of the image to filter.

                            Mask1                    short*              This parameter specifies the structuring function B used by the filtering.

                            Mheight1                short                Height of structuring matrix B.

                            Mwidth1                short                Width of structuring matrix B.

                            MPx1                      short                X coordinate of structuring matrix B origin.

                            MPy1                      short                Y coordinate of structuring matrix B origin.

                            Mask2                    short*              This parameter specifies the structuring function C used by the filtering.

                            Mheight2                short                Height of structuring matrix C.

                            Mwidth2                short                Width of structuring matrix C.

                            MPx2                      short                X coordinate of structuring matrix C origin.

                            MPy2                      short                Y coordinate of structuring matrix C origin.

                            BackGrndisBlack BOOL             Specifies the color of BackGround.

                            iShowProgress       short                This parameter specifies the displaying of the progressbar and the preview dialog.

Available values:

DISPLAY_NONE (0) - The progressbar and the preview dialog will not display before filtering.

DISPLAY_PROGRESS (1) - The progressbar will display during filtering procedure.

DISPLAY_DIALOG (2) - The preview dialog will display before filtering. This dialog shows the part of the image before and after filtering.

DISPLAY_BOTH (3) - The progressbar and the preview dialog will display.

IMPORTANT: The preview dialog will only display, if there is BIDlgs32.dll installed.

                            hWnd                     LONGLONG Handler of the parent window.

See Also