[−][src]Struct metaflac::block::Picture
A structure representing a PICTURE block.
Fields
picture_type: PictureType
The picture type.
mime_type: String
The MIME type.
description: String
The description of the picture.
width: u32
The width of the picture in pixels.
height: u32
The height of the picture in pixels.
depth: u32
The color depth of the picture in bits-per-pixel.
num_colors: u32
For indexed-color pictures (e.g. GIF), the number of colors used, or 0 for non-indexed pictures.
data: Vec<u8>
The binary picture data.
Methods
impl Picture
[src]
pub fn new() -> Picture
[src]
Returns a new Picture
with zero/empty values.
pub fn from_bytes(bytes: &[u8]) -> Result<Picture>
[src]
Attempts to parse the bytes as a Picture
block. Returns a Picture
on success.
pub fn to_bytes(&self) -> Vec<u8>
[src]
Returns a vector representation of the picture block suitable for writing to a file.
Trait Implementations
impl Clone for Picture
[src]
impl Eq for Picture
[src]
impl PartialEq<Picture> for Picture
[src]
impl Debug for Picture
[src]
Auto Trait Implementations
impl Send for Picture
impl Sync for Picture
impl Unpin for Picture
impl UnwindSafe for Picture
impl RefUnwindSafe for Picture
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,