Trait epi::TextureAllocator[][src]

pub trait TextureAllocator {
    fn alloc_srgba_premultiplied(
        &mut self,
        size: (usize, usize),
        srgba_pixels: &[Color32]
    ) -> TextureId;
fn free(&mut self, id: TextureId); }
Expand description

How to allocate textures (images) to use in egui.

Required methods

Allocate a new user texture.

There is no way to change a texture. Instead allocate a new texture and free the previous one with Self::free.

Free the given texture.

Implementors