Struct zng_view_api::window::FrameUpdateRequest
source · pub struct FrameUpdateRequest {
pub id: FrameId,
pub transforms: Vec<FrameValueUpdate<PxTransform>>,
pub floats: Vec<FrameValueUpdate<f32>>,
pub colors: Vec<FrameValueUpdate<Rgba>>,
pub extensions: Vec<(ApiExtensionId, ApiExtensionPayload)>,
pub clear_color: Option<Rgba>,
pub capture: FrameCapture,
pub wait_id: Option<FrameWaitId>,
}
Expand description
Data for rendering a new frame that is derived from the current frame.
Fields§
§id: FrameId
ID of the new frame.
transforms: Vec<FrameValueUpdate<PxTransform>>
Bound transforms.
floats: Vec<FrameValueUpdate<f32>>
Bound floats.
colors: Vec<FrameValueUpdate<Rgba>>
Bound colors.
extensions: Vec<(ApiExtensionId, ApiExtensionPayload)>
Update payload for API extensions.
The zng-view
crate implements this by calling DisplayListExtension::update
with the payload.
clear_color: Option<Rgba>
New clear color.
capture: FrameCapture
Create an image or mask from this rendered frame.
The Event::FrameImageReady
is send with the image.
wait_id: Option<FrameWaitId>
Identifies this frame as the response to the WindowChanged
resized frame request.
Implementations§
source§impl FrameUpdateRequest
impl FrameUpdateRequest
sourcepub fn empty(id: FrameId) -> FrameUpdateRequest
pub fn empty(id: FrameId) -> FrameUpdateRequest
A request that does nothing, apart from re-rendering the frame.
sourcepub fn has_bounds(&self) -> bool
pub fn has_bounds(&self) -> bool
If some property updates are requested.
Trait Implementations§
source§impl Clone for FrameUpdateRequest
impl Clone for FrameUpdateRequest
source§fn clone(&self) -> FrameUpdateRequest
fn clone(&self) -> FrameUpdateRequest
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for FrameUpdateRequest
impl Debug for FrameUpdateRequest
source§impl<'de> Deserialize<'de> for FrameUpdateRequest
impl<'de> Deserialize<'de> for FrameUpdateRequest
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for FrameUpdateRequest
impl RefUnwindSafe for FrameUpdateRequest
impl Send for FrameUpdateRequest
impl Sync for FrameUpdateRequest
impl Unpin for FrameUpdateRequest
impl UnwindSafe for FrameUpdateRequest
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§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>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more