pub struct Paint {
pub type: PaintType,
pub visible: Option<bool>,
pub opacity: Option<f64>,
pub color: Option<Color>,
pub blend_mode: Option<BlendMode>,
pub gradient_handle_positions: Option<[Vector; 3]>,
}Expand description
A solid color, gradient, or image texture that can be applied as fills or strokes
Fields§
§type: PaintType§visible: Option<bool>Is the paint enabled?
opacity: Option<f64>Overall opacity of paint (colors within the paint can also have opacity values which would blend with this)
color: Option<Color>Solid color of the paint
blend_mode: Option<BlendMode>How this node blends with nodes behind it in the scene
gradient_handle_positions: Option<[Vector; 3]>This field contains three vectors, each of which are a position in normalized object space (normalized object space is if the top left corner of the bounding box of the object is (0, 0) and the bottom right is (1,1)). The first position corresponds to the start of the gradient (value 0 for the purposes of calculating gradient stops), the second position is the end of the gradient (value 1), and the third handle position determines the width of the gradient. See image examples below: