Skip to main content

GpuViewInfo

Struct GpuViewInfo 

Source
#[non_exhaustive]
pub struct GpuViewInfo {
Show 15 fields pub device: bool, pub output: bool, pub level: Option<Level>, pub generation: u32, pub apart: bool, pub attaches: u32, pub detaches: u32, pub frames: u64, pub draw_us: u64, pub reads: u64, pub read_us: u64, pub read_frame: u64, pub held: u64, pub size: (u32, u32), pub error: Option<String>,
}
Expand description

what a view does now (Ui::gpu_view_info; tests and measurements)

Fields (Non-exhaustive)§

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
§device: bool

its content is attached to a device: its frames come from the GPU

§output: bool

that device is the UI output’s (else the views’ own: no output in this run)

§level: Option<Level>

the device’s level

§generation: u32

the device’s generation (a new one after a lost device; 0: none)

§apart: bool

the output’s render pass drew it in the window’s last frame (else the CPU copies the frame read back)

§attaches: u32

the content attached and detached so far

§detaches: u32§frames: u64

frames drawn, the CPU time recording and submitting them took (us)

§draw_us: u64§reads: u64

frames read back into the CPU’s copy, the time that took (us: submit, wait, copy)

§read_us: u64§read_frame: u64

(G5e2) the newest frame read back into the CPU’s copy (1, 2, ..; 0: none): the framebuffer can hold the view’s newest frame once it equals frames (in the browser a read-back comes later)

§held: u64

(G5e3) frames that had to wait: a new ver (size, device) came while the view’s window had not shown its last frame yet, so the content was not asked to draw then (each ver counted once; the newest is drawn when the window’s frame has arrived)

§size: (u32, u32)

the size of its target (px)

§error: Option<String>

what the last failure said

Trait Implementations§

Source§

impl Clone for GpuViewInfo

Source§

fn clone(&self) -> Self

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 Debug for GpuViewInfo

Source§

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

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

impl Default for GpuViewInfo

Source§

fn default() -> Self

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

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> 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
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
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

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.

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 = !

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

fn try_from(value: U) -> Result<T, !>

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.