AddImageJPXFromString

Image handling

Description

Encodes bitmap bytes as JPEG 2000 and adds the result as a JPXDecode image XObject

Syntax

Function TPDFlib.AddImageJPXFromString(Const Source: AnsiString; Quality, Lossless: Integer): Integer;

Parameters

SourceSource bitmap bytes
QualityLossy quality from 1 to 100
Lossless1 selects reversible lossless encoding and 0 selects lossy encoding

Return values

Returns the new ImageID or 0 on failure

Remarks

Use this overload when the complete bitmap payload is already held in an AnsiString

See also

AddImageJPXFromFile, AddImageJPXFromStream