[−][src]Struct imgui::DrawData
All draw data required to render a frame.
Fields
total_idx_count: i32
For convenience, sum of all draw list index buffer sizes
total_vtx_count: i32
For convenience, sum of all draw list vertex buffer sizes
display_pos: [f32; 2]
Upper-left position of the viewport to render.
(= upper-left corner of the orthogonal projection matrix to use)
display_size: [f32; 2]
Size of the viewport to render.
(= display_pos + display_size == lower-right corner of the orthogonal matrix to use)
framebuffer_scale: [f32; 2]
Amount of pixels for each unit of display_size.
Based on io.display_frame_buffer_scale. Typically [1.0, 1.0] on normal displays, and [2.0, 2.0] on Retina displays, but fractional values are also possible.
Implementations
impl DrawData
[src]
pub fn draw_lists(&self) -> DrawListIterator<'_>ⓘNotable traits for DrawListIterator<'a>
impl<'a> Iterator for DrawListIterator<'a> type Item = &'a DrawList;
[src]
Notable traits for DrawListIterator<'a>
impl<'a> Iterator for DrawListIterator<'a> type Item = &'a DrawList;
Returns an iterator over the draw lists included in the draw data
pub fn deindex_all_buffers(&mut self)
[src]
Converts all buffers from indexed to non-indexed, in case you cannot render indexed buffers.
This is slow and most likely a waste of resources. Always prefer indexed rendering!
pub fn scale_clip_rects(&mut self, fb_scale: [f32; 2])
[src]
Scales the clip rect of each draw command.
Can be used if your final output buffer is at a different scale than imgui-rs expects, or if there is a difference between your window resolution and framebuffer resolution.
Trait Implementations
impl RawCast<ImDrawData> for DrawData
[src]
Auto Trait Implementations
impl RefUnwindSafe for DrawData
impl !Send for DrawData
impl !Sync for DrawData
impl Unpin for DrawData
impl UnwindSafe for DrawData
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,