Donner SVG main
0.8.0 ยท 766e862a0.8.0 main
SVG editor and embeddable C⁠+⁠+⁠20 engine.
Loading...
Searching...
No Matches
donner::geode::GeoEncoder::ScenePaint Struct Reference

Paint carried by one cross-entity batch instance: a solid colour, or a resolved gradient whose parameters and stops the encoder copies into the slot's persistent paint block. More...

#include "donner/svg/renderer/geode/GeoEncoder.h"

Public Member Functions

bool isGradient () const
 True when this instance paints with a gradient rather than a colour.

Public Attributes

css::RGBA color
 Unpremultiplied solid fill color when no gradient is selected.
const LinearGradientParams * linearGradient
 Borrowed linear-gradient parameters for the duration of the call.
const RadialGradientParams * radialGradient
 Borrowed radial-gradient parameters for the duration of the call.

Detailed Description

Paint carried by one cross-entity batch instance: a solid colour, or a resolved gradient whose parameters and stops the encoder copies into the slot's persistent paint block.

The block holds 16 stops, so ensureResidentSceneRecord declines a gradient with more and the caller draws it through the gradient fill calls. The gradient pointers are borrowed for the duration of the call only.

Member Data Documentation

◆ color

css::RGBA donner::geode::GeoEncoder::ScenePaint::color
Initial value:
0, 0, 0, 255)
Represents as 32-bit RGBA color, with each component in the range [0, 255].
Definition Color.h:25

Unpremultiplied solid fill color when no gradient is selected.

◆ linearGradient

const LinearGradientParams* donner::geode::GeoEncoder::ScenePaint::linearGradient
Initial value:
=
nullptr

Borrowed linear-gradient parameters for the duration of the call.

◆ radialGradient

const RadialGradientParams* donner::geode::GeoEncoder::ScenePaint::radialGradient
Initial value:
=
nullptr

Borrowed radial-gradient parameters for the duration of the call.


The documentation for this struct was generated from the following file: