Struct image::codecs::jpeg::PixelDensity [−][src]
pub struct PixelDensity { pub density: (u16, u16), pub unit: PixelDensityUnit, }
Expand description
Represents the pixel density of an image
For example, a 300 DPI image is represented by:
use image::jpeg::*; let hdpi = PixelDensity::dpi(300); assert_eq!(hdpi, PixelDensity {density: (300,300), unit: PixelDensityUnit::Inches})
Fields
density: (u16, u16)
A couple of values for (Xdensity, Ydensity)
unit: PixelDensityUnit
The unit in which the density is measured
Implementations
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
Auto Trait Implementations
impl RefUnwindSafe for PixelDensity
impl Send for PixelDensity
impl Sync for PixelDensity
impl Unpin for PixelDensity
impl UnwindSafe for PixelDensity
Blanket Implementations
Mutably borrows from an owned value. Read more