pub struct AshAppTexture {
pub image: Image,
pub view: ImageView,
pub image_layout: ImageLayout,
/* private fields */
}Expand description
Host-owned ash texture that Damascene can sample during paint.
The image must be a single-sampled 2D image created with
vk::ImageUsageFlags::SAMPLED, and the host must keep both the
image and view alive while this wrapper may be painted. Before Damascene
draw commands execute, the host must transition the image to the
same readable layout recorded in this wrapper.
Fields§
§image: Image§view: ImageView§image_layout: ImageLayoutTrait Implementations§
Source§impl AppTextureBackend for AshAppTexture
impl AppTextureBackend for AshAppTexture
Source§fn id(&self) -> AppTextureId
fn id(&self) -> AppTextureId
Stable identity allocated by the constructor — must round-trip
the same value on every call for the lifetime of
self.Source§fn size_px(&self) -> (u32, u32)
fn size_px(&self) -> (u32, u32)
Pixel size of the underlying texture. The backend uses this for
sanity checks; the widget rect comes from layout, not from here.
Source§fn format(&self) -> SurfaceFormat
fn format(&self) -> SurfaceFormat
Pixel format of the underlying texture. Used by the backend to
pick a sampler / shader path.
Source§fn as_any(&self) -> &dyn Any
fn as_any(&self) -> &dyn Any
Downcast hatch for the backend’s record path. Each backend
asserts the trait object is its own concrete type; mixing
backends in one runtime is unsupported.
Source§fn backend_name(&self) -> &'static str
fn backend_name(&self) -> &'static str
Human-readable concrete backend type for diagnostics.
Source§impl Clone for AshAppTexture
impl Clone for AshAppTexture
Source§fn clone(&self) -> AshAppTexture
fn clone(&self) -> AshAppTexture
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for AshAppTexture
Auto Trait Implementations§
impl Freeze for AshAppTexture
impl RefUnwindSafe for AshAppTexture
impl Send for AshAppTexture
impl Sync for AshAppTexture
impl Unpin for AshAppTexture
impl UnsafeUnpin for AshAppTexture
impl UnwindSafe for AshAppTexture
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
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.