#[non_exhaustive]pub enum Compositing {
CellFlattened,
PixelLayered {
needs_full_frame: bool,
},
}Expand description
How a backend wants layers handed to Output::draw_layers.
Replaces the independent needs_full_frame/composites_layers booleans this crate used
before retroglyph#1278: those could express a combination no backend used and
crate::terminal::Terminal::present never honored (needs_full_frame() == true paired
with the default composites_layers() == false). Nesting needs_full_frame inside
PixelLayered makes that combination unrepresentable instead of merely undocumented.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
CellFlattened
Layers are flattened onto layer 0 before they reach the backend; one cell, one draw.
crate::terminal::Terminal::present composites all allocated layers into one frame
itself, so layers 1+ still appear on every backend, not only pixel ones, and the backend
receives only the changed cells.
PixelLayered
The backend composites layers itself (per pixel or quad), receiving the raw layered
stream from Output::draw_layers.
Fields
needs_full_frame: boolIf true, every Output::draw_layers call receives all cells from every
allocated layer, not just the changed ones, and the backend should clear its output
surface before drawing. Pixel-based backends need this because sub-cell offsets can
spill glyph pixels into adjacent cells: without a full redraw, orphaned pixels from
the previous frame linger.
Trait Implementations§
Source§impl Clone for Compositing
impl Clone for Compositing
Source§fn clone(&self) -> Compositing
fn clone(&self) -> Compositing
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for Compositing
Source§impl Debug for Compositing
impl Debug for Compositing
impl Eq for Compositing
Source§impl Hash for Compositing
impl Hash for Compositing
Source§impl PartialEq for Compositing
impl PartialEq for Compositing
Source§fn eq(&self, other: &Compositing) -> bool
fn eq(&self, other: &Compositing) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for Compositing
Auto Trait Implementations§
impl Freeze for Compositing
impl RefUnwindSafe for Compositing
impl Send for Compositing
impl Sync for Compositing
impl Unpin for Compositing
impl UnsafeUnpin for Compositing
impl UnwindSafe for Compositing
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> WasmNotSend for Twhere
T: Send,
impl<T> WasmNotSendSync for Twhere
T: WasmNotSend + WasmNotSync,
impl<T> WasmNotSync for Twhere
T: Sync,
§impl<C> WithAlpha for Cwhere
C: Copy,
impl<C> WithAlpha for Cwhere
C: Copy,
§fn with_alpha_first<A>(self, alpha: A) -> AlphaFirst<A, Self>
fn with_alpha_first<A>(self, alpha: A) -> AlphaFirst<A, Self>
self with alpha, storing alpha before the color in memory
(see [AlphaFirst]).§fn with_alpha_last<A>(self, alpha: A) -> AlphaLast<A, Self>
fn with_alpha_last<A>(self, alpha: A) -> AlphaLast<A, Self>
self with alpha, storing alpha after the color in memory
(see [AlphaLast]).