pub struct VideoSourceRect {
pub x: u32,
pub y: u32,
pub width: u32,
pub height: u32,
}Expand description
An input-space rectangle: the part of a frame a layer draws.
Unsigned, unlike VideoRect: a layer may hang off the canvas, but there
is nothing outside a frame to take.
Set on the layer rather than asked of the frame, and therefore possibly out of range — a layer is placed before any frame arrives, and the frame can change size underneath it when a captured window is resized. What falls outside is brought back in when it is drawn, not refused when it is set; the compositors bring it inside the frame when they draw.
Fields§
§x: u32Distance from the frame’s left edge, in input pixels.
y: u32Distance from the frame’s top edge, in input pixels.
width: u32Width of the region, in input pixels; must be nonzero.
height: u32Height of the region, in input pixels; must be nonzero.
Implementations§
Trait Implementations§
Source§impl Clone for VideoSourceRect
impl Clone for VideoSourceRect
Source§fn clone(&self) -> VideoSourceRect
fn clone(&self) -> VideoSourceRect
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for VideoSourceRect
Source§impl Debug for VideoSourceRect
impl Debug for VideoSourceRect
impl Eq for VideoSourceRect
Source§impl PartialEq for VideoSourceRect
impl PartialEq for VideoSourceRect
impl StructuralPartialEq for VideoSourceRect
Auto Trait Implementations§
impl Freeze for VideoSourceRect
impl RefUnwindSafe for VideoSourceRect
impl Send for VideoSourceRect
impl Sync for VideoSourceRect
impl Unpin for VideoSourceRect
impl UnsafeUnpin for VideoSourceRect
impl UnwindSafe for VideoSourceRect
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