Enum rafx_api::RafxDeviceContext [−][src]
pub enum RafxDeviceContext { Empty(RafxDeviceContextEmpty), }
Expand description
A cloneable, thread-safe handle used to create graphics resources.
All device contexts, and resources created from them, must be dropped before the RafxApi
object that they came from is dropped or destroyed.
Variants
Implementations
impl RafxDeviceContext
[src]
impl RafxDeviceContext
[src]pub fn device_info(&self) -> &RafxDeviceInfo
[src]
pub fn device_info(&self) -> &RafxDeviceInfo
[src]Get metadata about the device
pub fn find_supported_format(
&self,
candidates: &[RafxFormat],
resource_type: RafxResourceType
) -> Option<RafxFormat>
[src]
&self,
candidates: &[RafxFormat],
resource_type: RafxResourceType
) -> Option<RafxFormat>
pub fn find_supported_sample_count(
&self,
candidates: &[RafxSampleCount]
) -> Option<RafxSampleCount>
[src]
&self,
candidates: &[RafxSampleCount]
) -> Option<RafxSampleCount>
pub fn create_queue(&self, queue_type: RafxQueueType) -> RafxResult<RafxQueue>
[src]
pub fn create_queue(&self, queue_type: RafxQueueType) -> RafxResult<RafxQueue>
[src]Create a queue
pub fn create_fence(&self) -> RafxResult<RafxFence>
[src]
pub fn create_fence(&self) -> RafxResult<RafxFence>
[src]Create a fence
pub fn create_semaphore(&self) -> RafxResult<RafxSemaphore>
[src]
pub fn create_semaphore(&self) -> RafxResult<RafxSemaphore>
[src]Create a semaphore
pub fn create_swapchain(
&self,
raw_window_handle: &dyn HasRawWindowHandle,
swapchain_def: &RafxSwapchainDef
) -> RafxResult<RafxSwapchain>
[src]
pub fn create_swapchain(
&self,
raw_window_handle: &dyn HasRawWindowHandle,
swapchain_def: &RafxSwapchainDef
) -> RafxResult<RafxSwapchain>
[src]Create a swapchain
pub fn wait_for_fences(&self, fences: &[&RafxFence]) -> RafxResult<()>
[src]
pub fn wait_for_fences(&self, fences: &[&RafxFence]) -> RafxResult<()>
[src]Wait for the given fences to complete. If a fence is in an unsubmitted state, the fence is ignored.
pub fn create_sampler(
&self,
sampler_def: &RafxSamplerDef
) -> RafxResult<RafxSampler>
[src]
pub fn create_sampler(
&self,
sampler_def: &RafxSamplerDef
) -> RafxResult<RafxSampler>
[src]Create a sampler
pub fn create_texture(
&self,
texture_def: &RafxTextureDef
) -> RafxResult<RafxTexture>
[src]
pub fn create_texture(
&self,
texture_def: &RafxTextureDef
) -> RafxResult<RafxTexture>
[src]Create a texture
pub fn create_buffer(
&self,
buffer_def: &RafxBufferDef
) -> RafxResult<RafxBuffer>
[src]
pub fn create_buffer(
&self,
buffer_def: &RafxBufferDef
) -> RafxResult<RafxBuffer>
[src]Create a buffer
pub fn create_shader_module(
&self,
shader_module_def: RafxShaderModuleDef<'_>
) -> RafxResult<RafxShaderModule>
[src]
&self,
shader_module_def: RafxShaderModuleDef<'_>
) -> RafxResult<RafxShaderModule>
pub fn create_shader(
&self,
stages: Vec<RafxShaderStageDef>
) -> RafxResult<RafxShader>
[src]
pub fn create_shader(
&self,
stages: Vec<RafxShaderStageDef>
) -> RafxResult<RafxShader>
[src]Create a shader
pub fn create_root_signature(
&self,
root_signature_def: &RafxRootSignatureDef<'_>
) -> RafxResult<RafxRootSignature>
[src]
pub fn create_root_signature(
&self,
root_signature_def: &RafxRootSignatureDef<'_>
) -> RafxResult<RafxRootSignature>
[src]Create a root signature
pub fn create_graphics_pipeline(
&self,
pipeline_def: &RafxGraphicsPipelineDef<'_>
) -> RafxResult<RafxPipeline>
[src]
pub fn create_graphics_pipeline(
&self,
pipeline_def: &RafxGraphicsPipelineDef<'_>
) -> RafxResult<RafxPipeline>
[src]Create a graphics pipeline
pub fn create_compute_pipeline(
&self,
pipeline_def: &RafxComputePipelineDef<'_>
) -> RafxResult<RafxPipeline>
[src]
pub fn create_compute_pipeline(
&self,
pipeline_def: &RafxComputePipelineDef<'_>
) -> RafxResult<RafxPipeline>
[src]Create a compute pipeline
pub fn create_descriptor_set_array(
&self,
descriptor_set_array_def: &RafxDescriptorSetArrayDef<'_>
) -> RafxResult<RafxDescriptorSetArray>
[src]
pub fn create_descriptor_set_array(
&self,
descriptor_set_array_def: &RafxDescriptorSetArrayDef<'_>
) -> RafxResult<RafxDescriptorSetArray>
[src]Create a descriptor set array
pub fn empty_device_context(&self) -> Option<&RafxDeviceContextEmpty>
[src]
pub fn empty_device_context(&self) -> Option<&RafxDeviceContextEmpty>
[src]Get the underlying metal API object. This provides access to any internally created metal objects.
Trait Implementations
impl Clone for RafxDeviceContext
[src]
impl Clone for RafxDeviceContext
[src]fn clone(&self) -> RafxDeviceContext
[src]
fn clone(&self) -> RafxDeviceContext
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl RefUnwindSafe for RafxDeviceContext
impl Send for RafxDeviceContext
impl Sync for RafxDeviceContext
impl Unpin for RafxDeviceContext
impl UnwindSafe for RafxDeviceContext
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Downcast for T where
T: Any,
impl<T> Downcast for T where
T: Any,
pub fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
pub fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read more
pub fn as_any(&self) -> &(dyn Any + 'static)
pub fn as_any(&self) -> &(dyn Any + 'static)
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read more
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> Resource for T where
T: Downcast + Send + Sync,
[src]
T: Downcast + Send + Sync,