Native sampled colour functions
The native Cairo renderer evaluates FunctionType 0 sampled colour functions with Order 1 or Order 3, including multiple tint inputs and multiple alternate-colour outputs
Cubic evaluation extends the existing scalar four-knot interpolation convention by a tensor product across input dimensions; windows move inward at table edges, dimensions with fewer than four samples retain the existing linear fallback, and Size 1 remains constant
The one-input, one-output scalar transfer-function path keeps its existing behaviour
Sample processing
Inputs are clipped to Domain, mapped by Encode and clipped to table bounds; interpolation reads continuous most-significant-bit-first samples, applies Decode and clips completed components to Range
Sample depths of 1, 2, 4, 8, 12, 16, 24 and 32 bits are supported, with the first input dimension varying fastest
ISO 32000-1 section 7.10.2 defines the sampled-function layout and processing sequence; the numerical acceptance formula records the library's existing four-knot convention without claiming that the standard selects a unique cubic kernel
Resource limits
Tensor evaluation can visit four branches per input dimension; each visited node and each cubic sample bit joins aggregate operation limits and cancellation polling, whilst zero-weight branches do no sample work
Decoded streams, retained function data and evaluation storage join decoded-byte and active working-byte admission; large valid tables can require a caller-selected operation limit
Failures occur before PNG publication, and subsequent rendering can reuse the same thread and loaded-document API
Acceptance
Independent tensor equations solve interpolation weights through a Vandermonde system and verify native pixels for packed sample depths, multidimensional windows, short dimensions, encodings and output clipping
MuPDF and Poppler source differences are retained separately from native tensor acceptance; both readers also verify explicit RGB equation companions
See Tests/Linux/HeadlessSampledCubic.en-us.md for focused fixture and budget reproduction, and Native Linux Cairo renderer for rendering and ownership contracts