THotPDF.RegisterTransferFunctionState Method
Registers a reusable transfer function state resource for the document creation workflow. Call it before page commands reference the resource name so colour, pattern, font, image, or profile data is available in the PDF resource tree
Declaration
function RegisterTransferFunctionState(Combined: THPDFObject; const PerChannel: array of THPDFObject): AnsiString;
Unit
HPDFDoc
Parameters
| Name | Purpose |
|---|---|
Combined | One function applied to every output channel, or nil when a per-channel array is supplied |
PerChannel | Up to four channel functions ordered red or cyan, green or magenta, blue or yellow, and gray or black |
Return value
Returns an AnsiString value
Usage notes
- Use this API in the document creation workflow before the affected page, resource, field, or catalog object is finalised
- Keep object names, field names, resource names, and returned handles stable until the document is finalised
- When
Combinedisnil, missing ornilPerChannelentries are emitted as/Identityso later channel positions are preserved in the required four-entry/TR2array - The loaded-page renderer evaluates each array entry independently, accepts
/Identityand/Defaultentries, and atomically replaces all transfer lookup channels