pub struct Context(/* private fields */);
Expand description
Stores the capabilities, information, and state about a set of voxel blitting operations. Adapters can be created or obtained from contexts.
Implementations§
Source§impl Context
impl Context
Sourcepub fn get_adapter<K: AdapterKind, A: AdapterDescriptor<K> + NamedAdapter>(
&self,
) -> Result<Adapter<K, A>, GvoxError>
pub fn get_adapter<K: AdapterKind, A: AdapterDescriptor<K> + NamedAdapter>( &self, ) -> Result<Adapter<K, A>, GvoxError>
Gets the adapter of the provided type and description, or returns an error if it could not be found.
Sourcepub fn register_adapter<K: AdapterKind, A: AdapterDescriptor<K> + NamedAdapter + RegisterableAdapter<K>>(
&self,
) -> Result<Adapter<K, A>, GvoxError>
pub fn register_adapter<K: AdapterKind, A: AdapterDescriptor<K> + NamedAdapter + RegisterableAdapter<K>>( &self, ) -> Result<Adapter<K, A>, GvoxError>
Registers an adapter for future use, or returns an error if it could not be added.
Sourcepub fn as_mut_ptr(&self) -> *mut GvoxContext
pub fn as_mut_ptr(&self) -> *mut GvoxContext
Retrieves a raw handle to the context.
Trait Implementations§
impl Eq for Context
impl Send for Context
impl Sync for Context
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Unpin for Context
impl UnwindSafe for Context
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