Skip to main content

RenderStats

Struct RenderStats 

Source
pub struct RenderStats {
Show 17 fields pub quads: usize, pub glyphs: usize, pub draw_calls: usize, pub atlas_glyphs: usize, pub images: usize, pub cached_images: usize, pub paths: usize, pub path_edges: usize, pub breaks_kind: usize, pub breaks_image: usize, pub breaks_clip: usize, pub uploaded_bytes: usize, pub glyphs_rasterized: u64, pub atlas_resets: u64, pub atlas_used: u32, pub atlas_size: u32, pub gpu_time: Option<Duration>,
}
Expand description

Counters for profiling and tests.

Fields§

§quads: usize

Quad instances drawn, shadows included.

§glyphs: usize

Glyphs drawn.

§draw_calls: usize

Draw calls issued for the frame.

§atlas_glyphs: usize

Glyphs resident in the atlas.

§images: usize

Image quads drawn.

§cached_images: usize

Image textures resident on the GPU.

§paths: usize

Shapes made of curves drawn.

§path_edges: usize

Straight pieces those curves were cut into.

§breaks_kind: usize

Draw calls split because the kind of primitive changed, as text after a quad.

§breaks_image: usize

Draw calls split because the image changed.

§breaks_clip: usize

Draw calls split because the clip changed.

§uploaded_bytes: usize

Bytes of instances sent to the GPU this frame.

§glyphs_rasterized: u64

Glyphs rasterized since the renderer was created.

§atlas_resets: u64

Times the glyph atlas lost everything: it grew or it was full.

§atlas_used: u32

How full the glyph atlas is, in thousandths of its height.

§atlas_size: u32

Side of the glyph atlas in pixels.

§gpu_time: Option<Duration>

How long the GPU took on a recent frame, when timing is on and it can tell. It arrives some frames late, so it is not this frame’s.

Implementations§

Source§

impl RenderStats

Source

pub fn work(&self) -> RenderWork

The part of these stats the diagnostics keep.

Trait Implementations§

Source§

impl Clone for RenderStats

Source§

fn clone(&self) -> RenderStats

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for RenderStats

Source§

impl Debug for RenderStats

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for RenderStats

Source§

fn default() -> RenderStats

Returns the “default value” for a type. Read more
Source§

impl Eq for RenderStats

Source§

impl PartialEq for RenderStats

Source§

fn eq(&self, other: &RenderStats) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for RenderStats

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> AutoreleaseSafe for T
where T: ?Sized,

Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WasmNotSend for T
where T: Send,

§

impl<T> WasmNotSendSync for T
where T: WasmNotSend + WasmNotSync,

§

impl<T> WasmNotSync for T
where T: Sync,

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more