Skip to main content

EncodeExt

Trait EncodeExt 

Source
pub trait EncodeExt: Sealed {
    // Required method
    fn encode_into(
        &self,
        paints: &mut Vec<EncodedPaint>,
        transform: Affine,
        tint: Option<Tint>,
    ) -> Paint;
}
Expand description

A trait for encoding paints.

Required Methods§

Source

fn encode_into( &self, paints: &mut Vec<EncodedPaint>, transform: Affine, tint: Option<Tint>, ) -> Paint

Encode the paint and push it into a vector of encoded paints, returning the corresponding paint in the process. This will also validate the paint.

Implementations on Foreign Types§

Source§

impl EncodeExt for Gradient

Source§

fn encode_into( &self, paints: &mut Vec<EncodedPaint>, transform: Affine, _tint: Option<Tint>, ) -> Paint

Encode the gradient into a paint.

Implementors§