Struct Image
pub struct Image<Layers> { pub attributes: ImageAttributes, pub layer_data: Layers }
The complete exr image.
Layers can be either a single Layer or Layers.
Fields
attributes: ImageAttributesAttributes that apply to the whole image file. These attributes appear in each layer of the file. Excludes technical meta data. Each layer in this image also has its own attributes.
layer_data: LayersThe layers contained in the image file. Can be either a single
Layeror a list of layers.
Implementations
impl Image<NoneMore>
const fn empty(attributes: ImageAttributes) -> SelfCreate an empty image, to be filled with layers later on. Add at least one layer to obtain a valid image. Call
with_layer(another_layer)for each layer you want to add to this image.
impl<'s, ChannelData> Image<Layer<ChannelData>>
where
ChannelData: WritableChannels<'s> + 's,
fn from_layer(layer: Layer<ChannelData>) -> SelfUses the display position and size to the channel position and size of the layer.
fn from_encoded_channels(size: impl Into<Vec2<usize>>, encoding: Encoding, channels: ChannelData) -> SelfUses empty attributes.
fn from_channels(size: impl Into<Vec2<usize>>, channels: ChannelData) -> SelfUses empty attributes and fast compression.
impl<'s, Channels> Image<Layers<Channels>>
where
Channels: WritableChannels<'s> + 's,
fn from_layers(image_attributes: ImageAttributes, layer_data: impl Into<Layers<Channels>>) -> SelfCreate an image with multiple layers. The layer can be a
Vec<Layer>orLayers(a small vector).
impl<'s, InnerLayers> Image<InnerLayers>
where
InnerLayers: WritableLayers<'s> + 's,
fn with_layer<NewChannels>(self, layer: Layer<NewChannels>) -> Image<Recursive<InnerLayers, Layer<NewChannels>>> where NewChannels: 's + WritableChannels<'s>,Add another layer to this image. The layer type does not have to equal the existing layers in this image.
impl<'s, LayerData> Image<LayerData>
where
LayerData: WritableLayers<'s> + 's,
const fn new(image_attributes: ImageAttributes, layer_data: LayerData) -> SelfCreate an image with one or multiple layers. The layer can be a
Layer, orLayerssmall vector, orVec<Layer>or&[Layer].
Trait Implementations
impl<C> ValidateResult for Image<C>
where
C: ValidateResult,
fn validate_result(&self, other: &Self, options: ValidationOptions, location: impl Fn() -> String) -> ValidationResult
impl<Layers: Clone> Clone for Image<Layers>
fn clone(&self) -> Self
impl<Layers: Debug> Debug for Image<Layers>
fn fmt(&self, f: &mut Formatter<'_>) -> Result
impl<Layers: PartialEq> PartialEq for Image<Layers>
fn eq(&self, other: &Self) -> bool
impl<Layers: PartialEq> StructuralPartialEq for Image<Layers>
Auto Trait Implementations
impl<Layers> Freeze for Image<Layers>
where
Layers: Freeze,
impl<Layers> RefUnwindSafe for Image<Layers>
where
Layers: RefUnwindSafe,
impl<Layers> Send for Image<Layers>
where
Layers: Send,
impl<Layers> Sync for Image<Layers>
where
Layers: Sync,
impl<Layers> Unpin for Image<Layers>
where
Layers: Unpin,
impl<Layers> UnsafeUnpin for Image<Layers>
where
Layers: UnsafeUnpin,
impl<Layers> UnwindSafe for Image<Layers>
where
Layers: UnwindSafe,
Blanket Implementations
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for Image<Layers>
where
ST: ?Sized,
DT: ?Sized,
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for Image<Layers>
where
ST: ?Sized,
DT: ?Sized,
impl<T> Any for Image<Layers>
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for Image<Layers>
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for Image<Layers>
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> CloneToUninit for Image<Layers>
where
T: Clone,
unsafe fn clone_to_uninit(&self, dest: *mut u8)
impl<T> From<T> for Image<Layers>
fn from(t: T) -> TReturns the argument unchanged.
impl<T> Pointable for Image<Layers>
const ALIGN: usize = _;type Init = T;unsafe fn init(init: <T as Pointable>::Init) -> usizeunsafe fn deref<'a>(ptr: usize) -> &'a Tunsafe fn deref_mut<'a>(ptr: usize) -> &'a mut Tunsafe fn drop(ptr: usize)
impl<T> Read<Exclusive, BecauseExclusive> for Image<Layers>
where
T: ?Sized,
impl<T> ToOwned for Image<Layers>
where
T: Clone,
type Owned = T;fn to_owned(&self) -> Tfn clone_into(&self, target: &mut T)
impl<T, U> Into<U> for Image<Layers>
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for Image<Layers>
where
U: Into<T>,
type Error = never;fn try_from(value: U) -> Result<T, never>
impl<T, U> TryInto<U> for Image<Layers>
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>