SetRenderSurfaceCacheLimit
Rendering, performance, memory management
Description
Sets independent entry-count and byte ceilings for fully composited tile surfaces
Cached surfaces retain the resolved result of images, Form XObjects, patterns and soft masks, allowing repeated tile requests or different output encoders to avoid replaying that page region
Syntax
Function SetRenderSurfaceCacheLimit(MaxEntries: Integer; MaxBytes: Int64): Integer;Parameters
| MaxEntries | Maximum number of cached composited tile surfaces; 0 disables retention |
|---|---|
| MaxBytes | Maximum total size of the cached surfaces in bytes; 0 disables retention |
Return values
1 on success, 0 when either limit is negative
Remarks
The cache is disabled by default, and setting either limit to zero disables retention
A retained tile is reused only while the page is unchanged: every request checks the page attributes, the content streams, the resource dictionaries, and the annotations with their appearance streams, so drawing on the page, rotating or cropping it, and adding, moving or filling in annotations and form fields are followed automatically
The data of an image, Form XObject or font that is rewritten in place while the page itself stays the same is not checked; call ClearRenderSurfaceCache after such a change