Trait raylib::core::texture::RaylibTexture2D[][src]

pub trait RaylibTexture2D: AsRef<Texture2D> + AsMut<Texture2D> {
    fn width(&self) -> i32 { ... }
fn height(&self) -> i32 { ... }
fn mipmaps(&self) -> i32 { ... }
fn format(&self) -> i32 { ... }
fn update_texture(&mut self, pixels: &[u8]) { ... }
fn get_texture_data(&self) -> Result<Image, String> { ... }
fn gen_texture_mipmaps(&mut self) { ... }
fn set_texture_filter(&self, _: &RaylibThread, filter_mode: TextureFilter) { ... }
fn set_texture_wrap(&self, _: &RaylibThread, wrap_mode: TextureWrap) { ... } }

Provided methods

Updates GPU texture with new data.

Gets pixel data from GPU texture and returns an Image. Fairly sure this would never fail. If it does wrap in result.

Generates GPU mipmaps for a texture.

Sets global texture scaling filter mode.

Sets global texture wrapping mode.

Implementors