Enum NormalForm

pub enum NormalForm

Different normal forms of buffers.

A normal form is an unaliased buffer with some additional constraints. The ÌmageBuffer uses row major form with packed samples.

Variants

Unaliased

No pixel aliases another.

Unaliased also guarantees that all index calculations in the image bounds using dim_index*dim_stride (such as x*width_stride + y*height_stride) do not overflow.

PixelPacked

At least pixels are packed.

Images of these types can wrap [T]-slices into the standard color types. This is a precondition for GenericImage which requires by-reference access to pixels.

ImagePacked

All samples are packed.

This is orthogonal to PixelPacked. It requires that there are no holes in the image but it is not necessary that the pixel samples themselves are adjacent. An example of this behaviour is a planar image layout.

RowMajorPacked

The samples are in row-major form and all samples are packed.

In addition to PixelPacked and ImagePacked this also asserts that the pixel matrix is in row-major form.

ColumnMajorPacked

The samples are in column-major form and all samples are packed.

In addition to PixelPacked and ImagePacked this also asserts that the pixel matrix is in column-major form.

Trait Implementations

impl Clone for NormalForm

fn clone(&self) -> Self

impl Copy for NormalForm

impl Debug for NormalForm

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

impl Eq for NormalForm

impl Hash for NormalForm

fn hash<__H: Hasher>(&self, state: &mut __H)

impl PartialEq for NormalForm

fn eq(&self, other: &Self) -> bool

impl PartialOrd for NormalForm

fn partial_cmp(&self, other: &Self) -> Option<Ordering>

Compares the logical preconditions.

a < b if the normal form a has less preconditions than b.

impl StructuralPartialEq for NormalForm

Auto Trait Implementations

impl Freeze for NormalForm

impl RefUnwindSafe for NormalForm

impl Send for NormalForm

impl Sync for NormalForm

impl Unpin for NormalForm

impl UnsafeUnpin for NormalForm

impl UnwindSafe for NormalForm

Blanket Implementations

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for NormalForm where ST: ?Sized, DT: ?Sized,

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for NormalForm where ST: ?Sized, DT: ?Sized,

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

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

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

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

impl<T> From<T> for NormalForm

impl<T> IntoEither for NormalForm

impl<T> Pointable for NormalForm

impl<T> Read<Exclusive, BecauseExclusive> for NormalForm where T: ?Sized,

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

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

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

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