THotPDF.DecodeLoadedImageStream Method
Method summary: THotPDF.DecodeLoadedImageStream MethodTBitmap, including supported filter and colour-space processing
Declaration
function DecodeLoadedImageStream(AImageStream: THPDFStreamObject): TBitmap;
Unit
HPDFDoc
Parameters
| Name | Purpose |
|---|---|
AImageStream | Loaded PDF stream object containing image data |
Return value
Bitmap containing the decoded imageTBitmap on success or nil when the image format or geometry is unsupported
Usage notes
- Use this API with stream objects returned by loaded-document inspection workflows
- The caller owns the returned bitmap instance
DecodeParmsorDP - LZW decoding honours
EarlyChangeand rejects invalid dictionary transitions instead of treating compressed bytes as pixels - TIFF Predictor 2 and PNG predictors 10 through 15 are supported for complete rows with valid image geometry
- Width, height, component count, bit depth, row size, and output size are checked before raster allocation
- Malformed Flate, LZW, or predictor data raises its decoding exception so callers can distinguish corruption from an unsupported image format
- Use
ExtractLoadedImagewhen selecting images by the index returned from loaded-image enumeration
Related APIs
- THotPDF
- THotPDF.GetLoadedImageCount Method
- THotPDF.GetLoadedImageInfo Method
- THotPDF.ExtractLoadedImage Method