THotPDF.DecodeLoadedImageRegionAtResolutionCached Method

Decodes a loaded-image region at an exact target resolution through the renderer's bounded cache and per-key singleflight coordinator

Declaration

function DecodeLoadedImageRegionAtResolutionCached(
  AImageStream: THPDFStreamObject;
  RegionLeft, RegionTop, RegionRight, RegionBottom,
  TargetPixelWidth, TargetPixelHeight: Integer): TBitmap;

Parameters

The region is expressed in source pixels and the target dimensions select the exact output bitmap size

Return value

Returns a newly allocated TBitmap owned by the caller or nil when the request cannot be decoded

Concurrency

The key includes stream identity, source region, target dimensions, and decode policy so only equivalent requests are coalesced

Related APIs

Reduced-DCT JPEG Decoding · Sharded Loaded-Image Decode Cache