pub struct StyleImageInfo {
pub width: u32,
pub height: u32,
pub pixels: Vec<u8>,
pub stretch_x: Vec<ImageStretch>,
pub stretch_y: Vec<ImageStretch>,
pub content: Option<ImageContent>,
pub text_fit_width: Option<StyleImageTextFit>,
pub text_fit_height: Option<StyleImageTextFit>,
pub pixel_ratio: f32,
pub sdf: bool,
pub keep_unused: bool,
}Expand description
An image in the map’s style.
See mln_style_image_info in the
C API reference.
Fields§
§width: u32§height: u32§pixels: Vec<u8>The premultiplied RGBA pixels, in rows of width * 4 bytes, from the
top row down.
stretch_x: Vec<ImageStretch>§stretch_y: Vec<ImageStretch>§content: Option<ImageContent>§text_fit_width: Option<StyleImageTextFit>§text_fit_height: Option<StyleImageTextFit>§pixel_ratio: f32§sdf: bool§keep_unused: boolTrait Implementations§
Source§impl Clone for StyleImageInfo
impl Clone for StyleImageInfo
Source§fn clone(&self) -> StyleImageInfo
fn clone(&self) -> StyleImageInfo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for StyleImageInfo
impl Debug for StyleImageInfo
Source§impl Default for StyleImageInfo
impl Default for StyleImageInfo
Source§fn default() -> StyleImageInfo
fn default() -> StyleImageInfo
Returns the “default value” for a type. Read more
Source§impl PartialEq for StyleImageInfo
impl PartialEq for StyleImageInfo
impl StructuralPartialEq for StyleImageInfo
Auto Trait Implementations§
impl Freeze for StyleImageInfo
impl RefUnwindSafe for StyleImageInfo
impl Send for StyleImageInfo
impl Sync for StyleImageInfo
impl Unpin for StyleImageInfo
impl UnsafeUnpin for StyleImageInfo
impl UnwindSafe for StyleImageInfo
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,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more