DBR_DecodeBufferRect Function

Decodes barcode from a device-independent bitmap (DIB) in buffer by only searching a certain part of the image defined by the parameters top, left, width, height.

Syntax

int DBR_DecodeBufferRect(
        unsigned char* pDIBBuffer,
        int iBufferSize,
        const pReaderOptions pOptions,
        int iRectLeft,
        int iRectTop,
        int iRectWidth,
        int iRectHeight,
        pBarcodeResultArray *ppResults
);

Parameters

pDIBBuffer
A buffer data pointer to a DIB.
iBufferSize
An integer that defines the size of the buffer.
pOptions
Options for reading barcode.
iRectLeft
An integer value that defines the left margin coordinate of scanning zone.
iRectTop
An integer value that defines the top margin coordinate of scanning zone.
iRectWidth
An integer that defines the width of scanning zone.
iRectHeight
An integer that defines the height of scanning zone.
ppResults
A structure containing barcode results.

Return Value

Zero if the function completed successfully; otherwise nonzero.

Remarks

The DBR_DecodeBufferRect function reads an image from DIB buffer by specifying an area, and extract the barcode data.

See Also

C > Structs > ReaderOptions
C > Structs > BarcodeResultArray
C > Function > DecodeBuffer
C > Constant > BarcodeFormat
C > Constant > Error List