pub struct Buffer {
raw: Option<Buffer>,
target: u32,
size: BufferAddress,
map_flags: u32,
map_state: Arc<Mutex<BufferMapState>>,
drop_guard: Option<Arc<DropGuard>>,
}Fields§
§raw: Option<Buffer>§target: u32§size: BufferAddress§map_flags: u32Flags to use within calls to Device::map_buffer.
map_state: Arc<Mutex<BufferMapState>>Buffer mapping state.
If locked concurrently with the GL context, the GL context should be locked first.
drop_guard: Option<Arc<DropGuard>>Set when the buffer wraps an externally-owned GL name created via
Device::buffer_from_raw.
Buffer is Clone, so the guard is shared via Arc
and only fires its callback once every clone is dropped.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Buffer
impl !UnwindSafe for Buffer
impl Freeze for Buffer
impl Send for Buffer
impl Sync for Buffer
impl Unpin for Buffer
impl UnsafeUnpin for Buffer
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