setasign\FpdiPdfParser\PdfParser\Filter
Predictor Class Predictor
File: /FPDI PDF-Parser v2/PdfParser/Filter/Predictor.php
Class hierarchy
Summary
Properties
Methods
__construct()
public Predictor::__construct (
[ int $predictor = 1 [, int $colors = null [, int $bitsPerComponent = null [, int $columns = null ]]]]
)The constructor.
Parameters
- $predictor : int
- $colors : int
- $bitsPerComponent : int
- $columns : int
decode()
Decodes a string using a predictor function.
Parameters
- $data : string
The input string
Return Values
The decoded data
Exceptions
Throws \setasign\Fpdi\PdfParser\Filter\FilterException
Throws PredictorException
decodePng()
paethPredictor()
protected Predictor::paethPredictor (
int|float $left, int|float $above, int|float $upperLeft
): int|floatValue prediction using the Alan W. Paeth algorithm.
Parameters
- $left : int|float
The value to the left of the processed data entry.
- $above : int|float
The value above the processed data entry.
- $upperLeft : int|float
The value to the upper left of the processed data entry.
Return Values
Returns the prediction value according to the Peath algorithm