API referenceRendering & Viewer

rasSetOption

A generic, extensible per-cache integer option bag,

C
BOOL32 __stdcall rasGetOption(IPGC CachePtr, TPageCacheOptions Option, int32_t* Value);
BOOL32 __stdcall rasSetOption(IPGC CachePtr, TPageCacheOptions Option, int32_t Value);
Delphi
function rasGetOption(CachePtr: IPGC; Option: TPageCacheOptions; var Value: Integer): LongBool; stdcall;
function rasSetOption(CachePtr: IPGC; Option: TPageCacheOptions; Value: Integer): LongBool; stdcall;

Purpose. A generic, extensible per-cache integer option bag, indexed by a TPageCacheOptions enum ordinal — the catch-all configuration mechanism for cache behaviors that don't have their own dedicated ras* getter/setter pair.

Description. Both index into a fixed C.Opts array (bounds-checked 0..63Ord(Option) outside that range fails cleanly rather than indexing out of bounds). This chapter did not enumerate every TPageCacheOptions member or trace which ones are actually consulted elsewhere in the rendering/paint pipeline beyond this storage array itself — treat individual option semantics as stored, not independently confirmed effective, consistent with this SDK's recurring "generic option bag with unverified downstream consumption" pattern seen for other catch-all mechanisms.

Parameters.

ParameterDescription
CachePtrTarget page cache.
OptionOption index (0..63 valid; out-of-range fails).
ValueGet: output. Set: new value.

Return value. True if CachePtr resolves and Option is in range; False otherwise.

C# (P/Invoke)

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

Rasterizer/Rendering

Exported names

rasSetOption

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.