pub struct IoSurfaceRingDescriptor {
pub logical_size: LogicalSize,
pub buffer_count: u32,
pub context: MetalContextDescriptor,
}Expand description
A ring of IOSurfaces that the library allocates, for
MapHandle::attach_io_surface_ring().
Each surface has the map’s size in pixels, logical_size times the map’s
scale factor, and the pixel format kCVPixelFormatType_32BGRA, which Metal
names MTLPixelFormatBGRA8Unorm.
See mln_io_surface_ring_descriptor in the
C API reference.
Fields§
§logical_size: LogicalSize§buffer_count: u32How many surfaces the ring has, from 1 to 8.
context: MetalContextDescriptorThe MTLDevice to render with. A null device picks the system’s default.
Implementations§
Source§impl IoSurfaceRingDescriptor
impl IoSurfaceRingDescriptor
pub fn new(logical_size: LogicalSize, buffer_count: u32) -> Self
Trait Implementations§
Source§impl Clone for IoSurfaceRingDescriptor
impl Clone for IoSurfaceRingDescriptor
Source§fn clone(&self) -> IoSurfaceRingDescriptor
fn clone(&self) -> IoSurfaceRingDescriptor
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 IoSurfaceRingDescriptor
Source§impl Debug for IoSurfaceRingDescriptor
impl Debug for IoSurfaceRingDescriptor
Source§impl PartialEq for IoSurfaceRingDescriptor
impl PartialEq for IoSurfaceRingDescriptor
impl StructuralPartialEq for IoSurfaceRingDescriptor
Auto Trait Implementations§
impl !Send for IoSurfaceRingDescriptor
impl !Sync for IoSurfaceRingDescriptor
impl Freeze for IoSurfaceRingDescriptor
impl RefUnwindSafe for IoSurfaceRingDescriptor
impl Unpin for IoSurfaceRingDescriptor
impl UnsafeUnpin for IoSurfaceRingDescriptor
impl UnwindSafe for IoSurfaceRingDescriptor
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