[−][src]Struct gfx_texture::Texture
Represents a texture.
Fields
surface: Texture<R, R8_G8_B8_A8>Pixel storage for texture.
sampler: Sampler<R>Sampler for texture.
view: ShaderResourceView<R, [f32; 4]>View used by shader.
Methods
impl<R: Resources> Texture<R>[src]
impl<R: Resources> Texture<R>pub fn empty<F>(factory: &mut F) -> Result<Self, CombinedError> where | [src] |
Returns empty texture.
pub fn from_path<F, P>( | [src] |
Creates a texture from path.
pub fn from_image<F>( | [src] |
Creates a texture from image.
pub fn from_memory_alpha<F>( | [src] |
Creates texture from memory alpha.
pub fn update<C>( | [src] |
Updates the texture with an image.
Trait Implementations
impl<R: PartialEq> PartialEq<Texture<R>> for Texture<R> where
R: Resources, [src]
impl<R: PartialEq> PartialEq<Texture<R>> for Texture<R> where
R: Resources, impl<R: Clone> Clone for Texture<R> where
R: Resources, [src]
impl<R: Clone> Clone for Texture<R> where
R: Resources, fn clone(&self) -> Texture<R> | [src] |
fn clone_from(&mut self, source: &Self) | 1.0.0 [src] |
Performs copy-assignment from source. Read more
impl<R: Debug> Debug for Texture<R> where
R: Resources, [src]
impl<R: Debug> Debug for Texture<R> where
R: Resources, impl<R> ImageSize for Texture<R> where
R: Resources, [src]
impl<R> ImageSize for Texture<R> where
R: Resources, fn get_size(&self) -> (u32, u32) | [src] |
fn get_width(&self) -> u32 |
Gets the image width.
fn get_height(&self) -> u32 |
Gets the image height.
impl<F, R> CreateTexture<F> for Texture<R> where
F: Factory<R>,
R: Resources, [src]
impl<F, R> CreateTexture<F> for Texture<R> where
F: Factory<R>,
R: Resources, type Error = CombinedError
The error when creating texture.
fn create<S: Into<[u32; 2]>>( | [src] |
impl<R, C> UpdateTexture<Encoder<R, C>> for Texture<R> where
R: Resources,
C: CommandBuffer<R>, [src]
impl<R, C> UpdateTexture<Encoder<R, C>> for Texture<R> where
R: Resources,
C: CommandBuffer<R>, Auto Trait Implementations
impl<R> Send for Texture<R> where
<R as Resources>::Buffer: Send + Sync,
<R as Resources>::Mapping: Send,
<R as Resources>::Sampler: Send + Sync,
<R as Resources>::ShaderResourceView: Send + Sync,
<R as Resources>::Texture: Send + Sync,
impl<R> Send for Texture<R> where
<R as Resources>::Buffer: Send + Sync,
<R as Resources>::Mapping: Send,
<R as Resources>::Sampler: Send + Sync,
<R as Resources>::ShaderResourceView: Send + Sync,
<R as Resources>::Texture: Send + Sync, impl<R> Sync for Texture<R> where
<R as Resources>::Buffer: Send + Sync,
<R as Resources>::Mapping: Send,
<R as Resources>::Sampler: Send + Sync,
<R as Resources>::ShaderResourceView: Send + Sync,
<R as Resources>::Texture: Send + Sync,
impl<R> Sync for Texture<R> where
<R as Resources>::Buffer: Send + Sync,
<R as Resources>::Mapping: Send,
<R as Resources>::Sampler: Send + Sync,
<R as Resources>::ShaderResourceView: Send + Sync,
<R as Resources>::Texture: Send + Sync, Blanket Implementations
impl<T> From for T[src]
impl<T> From for Timpl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, impl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
🔬 This is a nightly-only experimental API. (
try_from)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> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, fn borrow_mut(&mut self) -> &mut T | [src] |
impl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error> | [src] |
impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId | [src] |
impl<T> SetParameter for T
impl<T> SetParameter for Tfn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where |
Sets value as a parameter of self.