pub struct Backdrop { /* private fields */ }Expand description
A scene shown through a window of a GlyphBuffer’s cells.
Implementations§
Source§impl Backdrop
impl Backdrop
Sourcepub fn scene(&self) -> &GlyphBuffer
pub fn scene(&self) -> &GlyphBuffer
The picture shown: its cells, rectangles and sprites.
Sourcepub fn origin_px(&self) -> (f32, f32)
pub fn origin_px(&self) -> (f32, f32)
The scene pixel at the window’s top-left. Fractions pan smoothly; it may lie outside the scene (the clear colour shows there).
Sourcepub fn scene_offset(&self, scale: u32) -> (i64, i64)
pub fn scene_offset(&self, scale: u32) -> (i64, i64)
Where the scene’s top-left pixel is drawn, in window pixels right
of and below the window’s top-left, when a console pixel is scale
window pixels: the origin times zoom × scale, rounded to whole
window pixels so that glyphs stay sharp. Every renderer places the
scene with this, and draws a scene pixel zoom × scale pixels big.
Trait Implementations§
impl StructuralPartialEq for Backdrop
Auto Trait Implementations§
impl !Send for Backdrop
impl !Sync for Backdrop
impl Freeze for Backdrop
impl RefUnwindSafe for Backdrop
impl Unpin for Backdrop
impl UnsafeUnpin for Backdrop
impl UnwindSafe for Backdrop
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more