Struct me3_framework::overlay::epaint::TextureAtlas
source · [−]pub struct TextureAtlas { /* private fields */ }
Expand description
Contains font data in an atlas, where each character occupied a small rectangle.
More characters can be added, possibly expanding the texture.
Implementations
sourceimpl TextureAtlas
impl TextureAtlas
pub fn new(size: [usize; 2]) -> TextureAtlas
pub fn size(&self) -> [usize; 2]
sourcepub fn prepared_discs(&self) -> Vec<PreparedDisc, Global>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
pub fn prepared_discs(&self) -> Vec<PreparedDisc, Global>ⓘNotable traits for Vec<u8, A>impl<A> Write for Vec<u8, A>where
A: Allocator,
A: Allocator,
Returns the locations and sizes of pre-rasterized discs (filled circles) in this atlas.
sourcepub fn fill_ratio(&self) -> f32
pub fn fill_ratio(&self) -> f32
When this get high, it might be time to clear and start over!
sourcepub fn take_delta(&mut self) -> Option<ImageDelta>
pub fn take_delta(&mut self) -> Option<ImageDelta>
Call to get the change to the image since last call.
Trait Implementations
sourceimpl Clone for TextureAtlas
impl Clone for TextureAtlas
sourcefn clone(&self) -> TextureAtlas
fn clone(&self) -> TextureAtlas
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations
impl RefUnwindSafe for TextureAtlas
impl Send for TextureAtlas
impl Sync for TextureAtlas
impl Unpin for TextureAtlas
impl UnwindSafe for TextureAtlas
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more