#[repr(C)]pub struct Params {
pub handler_func: extern "C" fn(data: *const u8, ptr: *mut u8, width: isize, height: usize),
pub handler_data: *const u8,
}Expand description
Parameters of capture
Fields§
§handler_func: extern "C" fn(data: *const u8, ptr: *mut u8, width: isize, height: usize)Callback when the capture process succeeded.
The handler is called at most once. The result of the capture is encoded as follows:
-
widthis positive for a successful capture. The pointer is allocated by the scheduler and contains the image (length is the product of width and height). -
widthis negative for errors. The pointer is null and height is zero.
The handler is unregistered before being called, such that the handler may trigger another capture.
handler_data: *const u8Trait Implementations§
Auto Trait Implementations§
impl Freeze for Params
impl RefUnwindSafe for Params
impl !Send for Params
impl !Sync for Params
impl Unpin for Params
impl UnwindSafe for Params
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