Struct surfman::chains::SwapChainData
source · struct SwapChainData<Device: DeviceAPI> {
size: Size2D<i32>,
context_id: ContextID,
surface_access: SurfaceAccess,
back_buffer: BackBuffer<Device>,
pending_surface: Option<Device::Surface>,
recycled_surfaces: Vec<Device::Surface>,
}
Fields§
§size: Size2D<i32>
§context_id: ContextID
§surface_access: SurfaceAccess
§back_buffer: BackBuffer<Device>
§pending_surface: Option<Device::Surface>
§recycled_surfaces: Vec<Device::Surface>
Implementations§
source§impl<Device: DeviceAPI> SwapChainData<Device>
impl<Device: DeviceAPI> SwapChainData<Device>
fn validate_context( &self, device: &Device, context: &Device::Context, ) -> Result<(), Error>
fn swap_buffers( &mut self, device: &mut Device, context: &mut Device::Context, preserve_buffer: PreserveBuffer<'_>, ) -> Result<(), Error>
fn take_attachment_from( &mut self, device: &mut Device, context: &mut Device::Context, other: &mut SwapChainData<Device>, ) -> Result<(), Error>
fn resize( &mut self, device: &mut Device, context: &mut Device::Context, size: Size2D<i32>, ) -> Result<(), Error>
fn size(&self) -> Size2D<i32>
fn take_surface_texture( &mut self, device: &Device, context: &mut Device::Context, ) -> Result<Device::SurfaceTexture, Error>
fn recycle_surface_texture( &mut self, device: &Device, context: &mut Device::Context, surface_texture: Device::SurfaceTexture, ) -> Result<(), Error>
fn take_surface(&mut self) -> Option<Device::Surface>
fn take_pending_surface(&mut self) -> Option<Device::Surface>
fn recycle_surface(&mut self, surface: Device::Surface)
fn clear_surface( &mut self, device: &mut Device, context: &mut Device::Context, gl: &Gl, color: [f32; 4], ) -> Result<(), Error>
sourcefn is_attached(&self) -> bool
fn is_attached(&self) -> bool
Is this the attached swap chain?
fn destroy( &mut self, device: &mut Device, context: &mut Device::Context, ) -> Result<(), Error>
Auto Trait Implementations§
impl<Device> Freeze for SwapChainData<Device>
impl<Device> RefUnwindSafe for SwapChainData<Device>
impl<Device> Send for SwapChainData<Device>
impl<Device> Sync for SwapChainData<Device>
impl<Device> Unpin for SwapChainData<Device>
impl<Device> UnwindSafe for SwapChainData<Device>
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