API referenceImages

pdfEnableImageCache

Configure a document-level image-decode cache size limit

C
BOOL32 __stdcall pdfEnableImageCache(PPDF IPDF, uint32_t MaxImageCount, uint32_t Size);
Delphi
function pdfEnableImageCache(const IPDF: PPDF; MaxImageCount, Size: Cardinal): LongBool; stdcall;

Purpose. Configure a document-level image-decode cache size limit (max cached image count and max cache byte size).

Description. Verified write-only no-op. Stores MaxImageCount into FImageCacheMax and Size into FImageCacheSize; both fields have exactly one reference each in the entire codebase — their own declaration and this setter. There is no image-decode cache anywhere in this SDK to actually bound; every image is decoded once at insertion time and its bytes stored directly in FImages (no re-decode-on-demand cache exists to limit).

Parameters.

ParameterDescription
IPDFDocument handle.
MaxImageCount, SizeStored but never read anywhere.

Return value. True if IPDF is valid; False otherwise.

C# (P/Invoke)

wrappers/dotnet/LumasPdf.cs
[return: MarshalAs(UnmanagedType.Bool)]
Area
Images
Category

Core

Exported names

pdfEnableImageCache

String variants

The …A form takes UTF-8, …W takes UTF-16; a bare name aliases the ANSI form.

See working code

Worked examples — complete programs in ten languages.