pub struct PixelRgb {
pub r: f32,
pub g: f32,
pub b: f32,
}
Expand description
A struct representing one or more pixels in the linear RGB color space.
If a “use-simd” feature is enabled this class is being implemented for SIMD f32x8
instead of f32
.
In that case the single instance holds a value of 8 pixels at once instead of a one.
Fields§
§r: f32
§g: f32
§b: f32
Implementations§
Trait Implementations§
source§impl AddAssign for PixelRgb
impl AddAssign for PixelRgb
source§fn add_assign(&mut self, rhs: PixelRgb)
fn add_assign(&mut self, rhs: PixelRgb)
Performs the
+=
operation. Read moresource§impl<__RhsT: Copy> DivAssign<__RhsT> for PixelRgb
impl<__RhsT: Copy> DivAssign<__RhsT> for PixelRgb
source§fn div_assign(&mut self, rhs: __RhsT)
fn div_assign(&mut self, rhs: __RhsT)
Performs the
/=
operation. Read moresource§impl<__RhsT: Copy> MulAssign<__RhsT> for PixelRgb
impl<__RhsT: Copy> MulAssign<__RhsT> for PixelRgb
source§fn mul_assign(&mut self, rhs: __RhsT)
fn mul_assign(&mut self, rhs: __RhsT)
Performs the
*=
operation. Read moresource§impl<__RhsT: Copy> RemAssign<__RhsT> for PixelRgb
impl<__RhsT: Copy> RemAssign<__RhsT> for PixelRgb
source§fn rem_assign(&mut self, rhs: __RhsT)
fn rem_assign(&mut self, rhs: __RhsT)
Performs the
%=
operation. Read moresource§impl SubAssign for PixelRgb
impl SubAssign for PixelRgb
source§fn sub_assign(&mut self, rhs: PixelRgb)
fn sub_assign(&mut self, rhs: PixelRgb)
Performs the
-=
operation. Read moreimpl Copy for PixelRgb
impl StructuralPartialEq for PixelRgb
Auto Trait Implementations§
impl Freeze for PixelRgb
impl RefUnwindSafe for PixelRgb
impl Send for PixelRgb
impl Sync for PixelRgb
impl Unpin for PixelRgb
impl UnwindSafe for PixelRgb
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)