Skip to main content

WebPPicture

Struct WebPPicture 

Source
#[repr(C)]
pub struct WebPPicture {
Show 30 fields pub use_argb: c_int, pub colorspace: WebPEncCSP, pub width: c_int, pub height: c_int, pub y: *mut u8, pub u: *mut u8, pub v: *mut u8, pub y_stride: c_int, pub uv_stride: c_int, pub a: *mut u8, pub a_stride: c_int, pub pad1: [u32; 2], pub argb: *mut u32, pub argb_stride: c_int, pub pad2: [u32; 3], pub writer: Option<WebPWriterFunction>, pub custom_ptr: *mut c_void, pub extra_info_type: c_int, pub extra_info: *mut u8, pub stats: *mut WebPAuxStats, pub error_code: WebPEncodingError, pub progress_hook: Option<WebPProgressHook>, pub user_data: *mut c_void, pub pad3: [u32; 3], pub pad4: *mut u8, pub pad5: *mut u8, pub pad6: [u32; 8], pub memory_: *mut c_void, pub memory_argb_: *mut c_void, pub pad7: [*mut c_void; 2],
}
Expand description

Main exchange structure (C layout).

Fields§

§use_argb: c_int

Main flag for encoder selecting between ARGB or YUV input.

§colorspace: WebPEncCSP

Colorspace: should be YUV420 for now (Y'CbCr).

§width: c_int

Width (less or equal to WEBP_MAX_DIMENSION).

§height: c_int

Height (less or equal to WEBP_MAX_DIMENSION).

§y: *mut u8

Luma plane.

§u: *mut u8

Chroma U plane.

§v: *mut u8

Chroma V plane.

§y_stride: c_int

Luma stride.

§uv_stride: c_int

Chroma stride.

§a: *mut u8

Alpha plane.

§a_stride: c_int

Stride of the alpha plane.

§pad1: [u32; 2]

Padding for later use.

§argb: *mut u32

ARGB (32 bit) plane.

§argb_stride: c_int

Stride in pixels, not bytes.

§pad2: [u32; 3]

Padding for later use.

§writer: Option<WebPWriterFunction>

Byte-emission hook; can be NULL.

§custom_ptr: *mut c_void

Can be used by the writer.

§extra_info_type: c_int

1: intra type, 2: segment, 3: quant, …

§extra_info: *mut u8

If not NULL, an array of one byte per macroblock.

§stats: *mut WebPAuxStats

Pointer to side statistics (updated only if not NULL).

§error_code: WebPEncodingError

Error code for the latest error encountered during encoding.

§progress_hook: Option<WebPProgressHook>

If not NULL, report progress during encoding.

§user_data: *mut c_void

Free to be set to any value and used during callbacks.

§pad3: [u32; 3]

Padding for later use.

§pad4: *mut u8

Unused for now.

§pad5: *mut u8

Unused for now.

§pad6: [u32; 8]

Padding for later use.

§memory_: *mut c_void

Row chunk of memory for the YUVA planes.

§memory_argb_: *mut c_void

And for the ARGB plane.

§pad7: [*mut c_void; 2]

Padding for later use.

Trait Implementations§

Source§

impl Clone for WebPPicture

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for WebPPicture

Source§

impl Debug for WebPPicture

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.