pub struct Adapter { /* private fields */ }
Implementations§
source§impl Adapter
impl Adapter
sourcepub unsafe fn new_external(
fun: impl FnMut(&str) -> *const c_void
) -> Option<ExposedAdapter<Api>>
pub unsafe fn new_external( fun: impl FnMut(&str) -> *const c_void ) -> Option<ExposedAdapter<Api>>
Creates a new external adapter using the specified loader function.
Safety
- The underlying OpenGL ES context must be current.
- The underlying OpenGL ES context must be current when interfacing with any objects returned by wgpu-hal from this adapter.
pub fn adapter_context(&self) -> &AdapterContext
Trait Implementations§
source§impl Adapter<Api> for Adapter
impl Adapter<Api> for Adapter
unsafe fn open( &self, features: Features, _limits: &Limits ) -> Result<OpenDevice<Api>, DeviceError>
source§unsafe fn texture_format_capabilities(
&self,
format: TextureFormat
) -> TextureFormatCapabilities
unsafe fn texture_format_capabilities( &self, format: TextureFormat ) -> TextureFormatCapabilities
Return the set of supported capabilities for a texture format.
source§unsafe fn surface_capabilities(
&self,
surface: &Surface
) -> Option<SurfaceCapabilities>
unsafe fn surface_capabilities( &self, surface: &Surface ) -> Option<SurfaceCapabilities>
Returns the capabilities of working with a specified surface. Read more
source§unsafe fn get_presentation_timestamp(&self) -> PresentationTimestamp
unsafe fn get_presentation_timestamp(&self) -> PresentationTimestamp
Creates a
PresentationTimestamp
using the adapter’s WSI.impl Send for Adapter
impl Sync for Adapter
Auto Trait Implementations§
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