#[non_exhaustive]pub struct ImageInfo {
pub array_elements: u32,
pub depth: u32,
pub flags: ImageCreateFlags,
pub fmt: Format,
pub height: u32,
pub mip_level_count: u32,
pub sample_count: SampleCount,
pub tiling: ImageTiling,
pub ty: ImageType,
pub usage: ImageUsageFlags,
pub width: u32,
}
Expand description
Information used to create an Image
instance.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.array_elements: u32
The number of layers in the image.
depth: u32
Image extent of the Z axis, when describing a three dimensional image.
flags: ImageCreateFlags
A bitmask of describing additional parameters of the image.
fmt: Format
The format and type of the texel blocks that will be contained in the image.
height: u32
Image extent of the Y axis, when describing a two or three dimensional image.
mip_level_count: u32
The number of levels of detail available for minified sampling of the image.
sample_count: SampleCount
Specifies the number of samples per texel.
tiling: ImageTiling
Specifies the tiling arrangement of the texel blocks in memory.
The default value is vk::ImageTiling::OPTIMAL
.
ty: ImageType
The basic dimensionality of the image.
Layers in array textures do not count as a dimension for the purposes of the image type.
usage: ImageUsageFlags
A bitmask of describing the intended usage of the image.
width: u32
Image extent of the X axis.
Implementations§
source§impl ImageInfo
impl ImageInfo
sourcepub const fn cube(size: u32, fmt: Format, usage: ImageUsageFlags) -> ImageInfo
pub const fn cube(size: u32, fmt: Format, usage: ImageUsageFlags) -> ImageInfo
Specifies a cube image.
sourcepub const fn image_1d(
size: u32,
fmt: Format,
usage: ImageUsageFlags
) -> ImageInfo
pub const fn image_1d( size: u32, fmt: Format, usage: ImageUsageFlags ) -> ImageInfo
Specifies a one-dimensional image.
sourcepub const fn image_2d(
width: u32,
height: u32,
fmt: Format,
usage: ImageUsageFlags
) -> ImageInfo
pub const fn image_2d( width: u32, height: u32, fmt: Format, usage: ImageUsageFlags ) -> ImageInfo
Specifies a two-dimensional image.
sourcepub const fn image_2d_array(
width: u32,
height: u32,
array_elements: u32,
fmt: Format,
usage: ImageUsageFlags
) -> ImageInfo
pub const fn image_2d_array( width: u32, height: u32, array_elements: u32, fmt: Format, usage: ImageUsageFlags ) -> ImageInfo
Specifies a two-dimensional image array.
sourcepub const fn image_3d(
width: u32,
height: u32,
depth: u32,
fmt: Format,
usage: ImageUsageFlags
) -> ImageInfo
pub const fn image_3d( width: u32, height: u32, depth: u32, fmt: Format, usage: ImageUsageFlags ) -> ImageInfo
Specifies a three-dimensional image.
sourcepub fn default_view_info(self) -> ImageViewInfo
pub fn default_view_info(self) -> ImageViewInfo
Provides an ImageViewInfo
for this format, type, aspect, array elements, and mip levels.
sourcepub fn to_builder(self) -> ImageInfoBuilder
pub fn to_builder(self) -> ImageInfoBuilder
Converts an ImageInfo
into an ImageInfoBuilder
.
Trait Implementations§
source§impl From<ImageInfo> for ImageViewInfo
impl From<ImageInfo> for ImageViewInfo
source§impl From<ImageInfoBuilder> for ImageInfo
impl From<ImageInfoBuilder> for ImageInfo
source§fn from(info: ImageInfoBuilder) -> Self
fn from(info: ImageInfoBuilder) -> Self
source§impl PartialEq for ImageInfo
impl PartialEq for ImageInfo
impl Copy for ImageInfo
impl Eq for ImageInfo
impl StructuralPartialEq for ImageInfo
Auto Trait Implementations§
impl RefUnwindSafe for ImageInfo
impl Send for ImageInfo
impl Sync for ImageInfo
impl Unpin for ImageInfo
impl UnwindSafe for ImageInfo
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.