Documentation

Decoder
in package

<p>The main class which implements QR Code decoding -- as opposed to locating and extracting the QR Code from an image.</p>

Tags
author

Sean Owen

Table of Contents

decode()  : DecoderResult
<p>Decodes a QR Code represented as a {@link \chillerlan\QRCode\Decoder\BitMatrix}.
correctErrors()  : array<string|int, mixed>
<p>Given data and error-correction codewords received, possibly corrupted by errors, attempts to correct the errors in-place using Reed-Solomon error correction.</p>
decodeBitStream()  : DecoderResult
decodeParser()  : DecoderResult
getDataBlocks()  : array<string|int, mixed>
<p>When QR Codes use multiple data blocks, they are actually interleaved.

Methods

correctErrors()

<p>Given data and error-correction codewords received, possibly corrupted by errors, attempts to correct the errors in-place using Reed-Solomon error correction.</p>

private correctErrors(array<string|int, mixed> $codewordBytes, int $numDataCodewords) : array<string|int, mixed>
Parameters
$codewordBytes : array<string|int, mixed>
$numDataCodewords : int
Return values
array<string|int, mixed>

getDataBlocks()

<p>When QR Codes use multiple data blocks, they are actually interleaved.

private getDataBlocks(array<string|int, mixed> $rawCodewords, Version $version, EccLevel $eccLevel) : array<string|int, mixed>

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.

Parameters
$rawCodewords : array<string|int, mixed>

bytes as read directly from the QR Code

$version : Version

version of the QR Code

$eccLevel : EccLevel

error-correction level of the QR Code

Tags
throws
InvalidArgumentException
Return values
array<string|int, mixed>

DataBlocks containing original bytes, "de-interleaved" from representation in the QR Code

Search results