TDataBlock.getDataBlocks Method

Definition

When QR Codes use multiple data blocks, they are actually interleaved. That is, the first byte of data block 1 to n is written, then the second bytes, and so on. This method will separate the data into original blocks.

Delphi
class function getDataBlocks(const rawCodewords: TArray<Byte>; const version: TVersion; const ecLevel: TErrorCorrectionLevel): TArray<TDataBlock>

Parameters

rawCodewords
TArray<Byte>

bytes as read directly from the QR Code

version
TVersion

version of the QR Code

ecLevel
TErrorCorrectionLevel

error-correction level of the QR Code

Returns

TArray<TDataBlock>

{@link TDataBlock}s containing original bytes, "de-interleaved" from representation in the QR Code