pub enum MeshShading {
Triangles(Vec<MeshTriangle>),
Patches(Vec<MeshPatch>),
}Expand description
Evaluated geometry + colour for a Type 4–7 shading (§8.7.4.5.5–8).
All four mesh types reduce to either a list of Gouraud-shaded
triangles (Types 4 and 5) or a list of colour patches each bounded
by four cubic Bézier curves (Types 6 and 7), so this enum carries
the two shapes. Every coordinate is in the shading’s target
coordinate space (the pre-ctm space the stream’s Decode array
maps into); every colour is already reduced to device RGB through
the shading’s colour space (and its optional parametric Function).
Variants§
Triangles(Vec<MeshTriangle>)
Types 4 (free-form) and 5 (lattice-form) Gouraud-shaded triangle
meshes. Each triangle carries three MeshVertexes; the
interior colour is the Gouraud (barycentric-linear) interpolation
of the three vertex colours.
Patches(Vec<MeshPatch>)
Types 6 (Coons) and 7 (tensor-product) patch meshes. Each patch is a bicubic surface bounded by four cubic Bézier curves with a colour at each of its four corners (bilinearly interpolated over the patch interior).
Trait Implementations§
Source§impl Clone for MeshShading
impl Clone for MeshShading
Source§fn clone(&self) -> MeshShading
fn clone(&self) -> MeshShading
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for MeshShading
impl Debug for MeshShading
Source§impl PartialEq for MeshShading
impl PartialEq for MeshShading
Source§fn eq(&self, other: &MeshShading) -> bool
fn eq(&self, other: &MeshShading) -> bool
self and other values to be equal, and is used by ==.