Sets the alpha constants and the blend mode the paints that follow composite with, until the state is restored.
void SetCompositing(double strokeAlpha, double fillAlpha, BlendMode blendMode)
The stroking alpha constant (CA), 0 to 1: the opacity of StrokePath(PathView, in StrokeStyle, in DisplayColor), StrokePathWithShading(PathView, in StrokeStyle, in DisplayShading),
StrokePathWithTilingPattern(PathView, in StrokeStyle, in DisplayTilingPattern) and the stroke of DrawGlyphs(in GlyphRun).
The nonstroking alpha constant (ca), 0 to 1: the opacity of every other paint.
The blend function that combines the source colour with the backdrop.
ISO 32000-2 §11.6.4.4 (constant shape and opacity), §11.6.3 (blend mode) and §11.3 (the compositing formulas, §11.3.3 and §11.3.6; the blend functions of §11.3.5, Tables 134 and 135). Each paint's source alpha is its shape (coverage, and an image's own masks) times the alpha constant that applies to it, and it composites over the backdrop, the result of earlier painting, as αr × Cr = (1 − αs) × αb × Cb + (1 − αb) × αs × Cs + αb × αs × B(Cb, Cs), with αr = αs + αb − αs × αb. A replay starts with both alphas at 1 and the Normal blend mode; the call arrives before the first paint it applies to, only when one of the values changes, and SaveState() and RestoreState() save and restore it.
A shading pattern's paint arrives with its pattern's ExtGState applied (§11.6.7): its ca already multiplied into the
alpha of the paint, its blend mode, when not Normal, in place of the state's. The page's blending colour space is the
backend's (§11.3.4, §11.4.7) unless a page group names one. Transparency groups, including the implicit knockout group of a
combined fill and stroke (§11.7.4.4), arrive through DrawGroup(in DisplayGroup); soft masks through SetSoftMask(in DisplaySoftMask).