pub struct AndroidHardwareBufferRingDescriptor {
pub logical_size: LogicalSize,
pub buffer_count: u32,
pub usage: u64,
}Expand description
A ring of Android hardware buffers that the library allocates, for
MapHandle::attach_android_hardware_buffer_ring().
Each buffer has the map’s size in pixels, logical_size times the map’s
scale factor, and the format AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM. Its
usage is AHARDWAREBUFFER_USAGE_GPU_COLOR_OUTPUT,
AHARDWAREBUFFER_USAGE_GPU_SAMPLED_IMAGE, and the bits of usage.
See mln_android_hardware_buffer_ring_descriptor in the
C API reference.
Fields§
§logical_size: LogicalSize§buffer_count: u32How many buffers the ring has, from 1 to 8.
usage: u64More AHARDWAREBUFFER_USAGE_* bits that your reads need, such as
AHARDWAREBUFFER_USAGE_CPU_READ_OFTEN, or zero.
Implementations§
Source§impl AndroidHardwareBufferRingDescriptor
impl AndroidHardwareBufferRingDescriptor
pub const fn new( logical_size: LogicalSize, buffer_count: u32, usage: u64, ) -> Self
Trait Implementations§
Source§impl Clone for AndroidHardwareBufferRingDescriptor
impl Clone for AndroidHardwareBufferRingDescriptor
Source§fn clone(&self) -> AndroidHardwareBufferRingDescriptor
fn clone(&self) -> AndroidHardwareBufferRingDescriptor
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 AndroidHardwareBufferRingDescriptor
impl StructuralPartialEq for AndroidHardwareBufferRingDescriptor
Auto Trait Implementations§
impl Freeze for AndroidHardwareBufferRingDescriptor
impl RefUnwindSafe for AndroidHardwareBufferRingDescriptor
impl Send for AndroidHardwareBufferRingDescriptor
impl Sync for AndroidHardwareBufferRingDescriptor
impl Unpin for AndroidHardwareBufferRingDescriptor
impl UnsafeUnpin for AndroidHardwareBufferRingDescriptor
impl UnwindSafe for AndroidHardwareBufferRingDescriptor
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,
impl<T> ErasedDestructor for Twhere
T: 'static,
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