pub struct RGBColor(pub u8, pub u8, pub u8);
Expand description
The color described by its RGB value
Tuple Fields§
§0: u8
§1: u8
§2: u8
Trait Implementations§
source§impl BackendStyle for RGBColor
impl BackendStyle for RGBColor
source§fn color(&self) -> BackendColor
fn color(&self) -> BackendColor
Get the color of current style
source§fn stroke_width(&self) -> u32
fn stroke_width(&self) -> u32
Get the stroke width of current style
source§impl Color for RGBColor
impl Color for RGBColor
source§fn to_backend_color(&self) -> BackendColor
fn to_backend_color(&self) -> BackendColor
Normalize this color representation to the backend color
source§fn to_rgba(&self) -> RGBAColor
fn to_rgba(&self) -> RGBAColor
Convert the color into the RGBA color which is internally used by Plotters
source§fn filled(&self) -> ShapeStylewhere
Self: Sized,
fn filled(&self) -> ShapeStylewhere Self: Sized,
Make a filled style form the color
source§fn stroke_width(&self, width: u32) -> ShapeStylewhere
Self: Sized,
fn stroke_width(&self, width: u32) -> ShapeStylewhere Self: Sized,
Make a shape style with stroke width from a color
source§impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for BlackWhite
impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for BlackWhite
source§fn get_color_normalized(
&self,
h: FloatType,
min: FloatType,
max: FloatType
) -> RGBColor
fn get_color_normalized( &self, h: FloatType, min: FloatType, max: FloatType ) -> RGBColor
A slight abstraction over get_color function where lower and upper bound can be specified.
source§fn get_color(&self, h: FloatType) -> ColorType
fn get_color(&self, h: FloatType) -> ColorType
Takes a scalar value 0.0 <= h <= 1.0 and returns the corresponding color.
Typically color-scales are named according to which color-type they return.
To use upper and lower bounds with ths function see get_color_normalized.
source§impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for Bone
impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for Bone
source§fn get_color_normalized(
&self,
h: FloatType,
min: FloatType,
max: FloatType
) -> RGBColor
fn get_color_normalized( &self, h: FloatType, min: FloatType, max: FloatType ) -> RGBColor
A slight abstraction over get_color function where lower and upper bound can be specified.
source§fn get_color(&self, h: FloatType) -> ColorType
fn get_color(&self, h: FloatType) -> ColorType
Takes a scalar value 0.0 <= h <= 1.0 and returns the corresponding color.
Typically color-scales are named according to which color-type they return.
To use upper and lower bounds with ths function see get_color_normalized.
source§impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for Copper
impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for Copper
source§fn get_color_normalized(
&self,
h: FloatType,
min: FloatType,
max: FloatType
) -> RGBColor
fn get_color_normalized( &self, h: FloatType, min: FloatType, max: FloatType ) -> RGBColor
A slight abstraction over get_color function where lower and upper bound can be specified.
source§fn get_color(&self, h: FloatType) -> ColorType
fn get_color(&self, h: FloatType) -> ColorType
Takes a scalar value 0.0 <= h <= 1.0 and returns the corresponding color.
Typically color-scales are named according to which color-type they return.
To use upper and lower bounds with ths function see get_color_normalized.
source§impl<FloatType: Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for DerivedColorMap<RGBColor>
impl<FloatType: Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for DerivedColorMap<RGBColor>
source§fn get_color_normalized(
&self,
h: FloatType,
min: FloatType,
max: FloatType
) -> RGBColor
fn get_color_normalized( &self, h: FloatType, min: FloatType, max: FloatType ) -> RGBColor
A slight abstraction over get_color function where lower and upper bound can be specified.
source§fn get_color(&self, h: FloatType) -> ColorType
fn get_color(&self, h: FloatType) -> ColorType
Takes a scalar value 0.0 <= h <= 1.0 and returns the corresponding color.
Typically color-scales are named according to which color-type they return.
To use upper and lower bounds with ths function see get_color_normalized.
source§impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for ViridisRGB
impl<FloatType: Debug + Float + FromPrimitive + ToPrimitive> ColorMap<RGBColor, FloatType> for ViridisRGB
source§fn get_color_normalized(
&self,
h: FloatType,
min: FloatType,
max: FloatType
) -> RGBColor
fn get_color_normalized( &self, h: FloatType, min: FloatType, max: FloatType ) -> RGBColor
A slight abstraction over get_color function where lower and upper bound can be specified.
source§fn get_color(&self, h: FloatType) -> ColorType
fn get_color(&self, h: FloatType) -> ColorType
Takes a scalar value 0.0 <= h <= 1.0 and returns the corresponding color.
Typically color-scales are named according to which color-type they return.
To use upper and lower bounds with ths function see get_color_normalized.
source§impl PartialEq<RGBColor> for RGBColor
impl PartialEq<RGBColor> for RGBColor
impl Copy for RGBColor
impl Eq for RGBColor
impl StructuralEq for RGBColor
impl StructuralPartialEq for RGBColor
Auto Trait Implementations§
impl RefUnwindSafe for RGBColor
impl Send for RGBColor
impl Sync for RGBColor
impl Unpin for RGBColor
impl UnwindSafe for RGBColor
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more