[−][src]Struct rav1e::prelude::Plane
One data plane of a frame.
For example, a plane can be a Y luma plane or a U or V chroma plane.
Fields
cfg: PlaneConfig
Plane configuration.
Implementations
impl<T: Pixel> Plane<T>
[src]
pub fn new(
width: usize,
height: usize,
xdec: usize,
ydec: usize,
xpad: usize,
ypad: usize
) -> Self
[src]
width: usize,
height: usize,
xdec: usize,
ydec: usize,
xpad: usize,
ypad: usize
) -> Self
Allocates and returns a new plane.
pub fn slice(&self, po: PlaneOffset) -> PlaneSlice<T>
[src]
pub fn p(&self, x: usize, y: usize) -> T
[src]
Returns the pixel at the given coordinates.
pub fn data_origin(&self) -> &[T]
[src]
Returns plane data starting from the origin.
pub fn data_origin_mut(&mut self) -> &mut [T]
[src]
Returns mutable plane data starting from the origin.
pub fn copy_from_raw_u8(
&mut self,
source: &[u8],
source_stride: usize,
source_bytewidth: usize
)
[src]
&mut self,
source: &[u8],
source_stride: usize,
source_bytewidth: usize
)
Copies data into the plane from a pixel array.
pub fn downsampled(&self, frame_width: usize, frame_height: usize) -> Plane<T>
[src]
pub fn iter(&self) -> PlaneIter<T>
[src]
Iterates over the pixels in the plane, skipping the padding.
Trait Implementations
impl<T: Clone + Pixel> Clone for Plane<T>
[src]
impl<T: Pixel> Debug for Plane<T> where
T: Display,
[src]
T: Display,
impl<T: Eq + Pixel> Eq for Plane<T>
[src]
impl<T: PartialEq + Pixel> PartialEq<Plane<T>> for Plane<T>
[src]
impl<T: Pixel> StructuralEq for Plane<T>
[src]
impl<T: Pixel> StructuralPartialEq for Plane<T>
[src]
Auto Trait Implementations
impl<T> RefUnwindSafe for Plane<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Send for Plane<T>
impl<T> Sync for Plane<T>
impl<T> Unpin for Plane<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for Plane<T> where
T: RefUnwindSafe + UnwindSafe,
T: RefUnwindSafe + UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
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> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
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>,