pub struct CoreDevice {
pub(crate) wgpu_device: Arc<Device>,
}Available on
wgpu_core only.Fields§
§wgpu_device: Arc<Device>Implementations§
Source§impl CoreDevice
impl CoreDevice
pub unsafe fn as_hal<A: Api>(&self) -> Option<impl Deref<Target = A::Device>>
pub unsafe fn create_texture_from_hal<A: Api>( &self, hal_texture: A::Texture, desc: &TextureDescriptor<'_>, initial_state: TextureUses, cleared: bool, ) -> CoreTexture
Sourcepub unsafe fn create_buffer_from_hal<A: Api>(
&self,
hal_buffer: A::Buffer,
desc: &BufferDescriptor<'_>,
) -> CoreBuffer
pub unsafe fn create_buffer_from_hal<A: Api>( &self, hal_buffer: A::Buffer, desc: &BufferDescriptor<'_>, ) -> CoreBuffer
§Safety
hal_buffermust be created fromdevice.hal_buffermust be created respectingdeschal_buffermust be initializedhal_buffermust not have zero size.
Trait Implementations§
Source§impl Clone for CoreDevice
impl Clone for CoreDevice
Source§fn clone(&self) -> CoreDevice
fn clone(&self) -> CoreDevice
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CoreDevice
impl Debug for CoreDevice
Source§impl DeviceInterface for CoreDevice
impl DeviceInterface for CoreDevice
fn features(&self) -> Features
fn limits(&self) -> Limits
fn adapter_info(&self) -> AdapterInfo
fn create_shader_module( &self, desc: ShaderModuleDescriptor<'_>, shader_bound_checks: ShaderRuntimeChecks, ) -> DispatchShaderModule
unsafe fn create_shader_module_passthrough( &self, desc: &ShaderModuleDescriptorPassthrough<'_>, ) -> DispatchShaderModule
fn create_bind_group_layout( &self, desc: &BindGroupLayoutDescriptor<'_>, ) -> DispatchBindGroupLayout
fn create_bind_group(&self, desc: &BindGroupDescriptor<'_>) -> DispatchBindGroup
fn create_pipeline_layout( &self, desc: &PipelineLayoutDescriptor<'_>, ) -> DispatchPipelineLayout
fn create_render_pipeline( &self, desc: &RenderPipelineDescriptor<'_>, ) -> DispatchRenderPipeline
fn create_mesh_pipeline( &self, desc: &MeshPipelineDescriptor<'_>, ) -> DispatchRenderPipeline
fn create_compute_pipeline( &self, desc: &ComputePipelineDescriptor<'_>, ) -> DispatchComputePipeline
unsafe fn create_pipeline_cache( &self, desc: &PipelineCacheDescriptor<'_>, ) -> DispatchPipelineCache
fn create_buffer(&self, desc: &BufferDescriptor<'_>) -> DispatchBuffer
fn create_texture(&self, desc: &TextureDescriptor<'_>) -> DispatchTexture
fn create_external_texture( &self, desc: &ExternalTextureDescriptor<'_>, planes: &[&TextureView], ) -> DispatchExternalTexture
fn create_blas( &self, desc: &CreateBlasDescriptor<'_>, sizes: BlasGeometrySizeDescriptors, ) -> (Option<u64>, DispatchBlas)
fn create_tlas(&self, desc: &CreateTlasDescriptor<'_>) -> DispatchTlas
fn create_sampler(&self, desc: &SamplerDescriptor<'_>) -> DispatchSampler
fn create_query_set(&self, desc: &QuerySetDescriptor<'_>) -> DispatchQuerySet
fn create_command_encoder( &self, desc: &CommandEncoderDescriptor<'_>, ) -> DispatchCommandEncoder
fn create_render_bundle_encoder( &self, desc: &RenderBundleEncoderDescriptor<'_>, ) -> DispatchRenderBundleEncoder
fn set_device_lost_callback(&self, device_lost_callback: BoxDeviceLostCallback)
fn on_uncaptured_error(&self, handler: Arc<dyn UncapturedErrorHandler>)
fn push_error_scope(&self, filter: ErrorFilter) -> u32
fn pop_error_scope(&self, index: u32) -> Pin<Box<dyn PopErrorScopeFuture>>
unsafe fn start_graphics_debugger_capture(&self)
unsafe fn stop_graphics_debugger_capture(&self)
fn poll(&self, poll_type: PollType<u64>) -> Result<PollStatus, PollError>
fn get_internal_counters(&self) -> InternalCounters
fn generate_allocator_report(&self) -> Option<AllocatorReport>
fn destroy(&self)
Source§impl Drop for CoreDevice
impl Drop for CoreDevice
Source§impl From<CoreDevice> for DispatchDevice
impl From<CoreDevice> for DispatchDevice
Source§fn from(value: CoreDevice) -> Self
fn from(value: CoreDevice) -> Self
Converts to this type from the input type.
Source§impl Hash for CoreDevice
impl Hash for CoreDevice
Source§impl Ord for CoreDevice
impl Ord for CoreDevice
Source§impl PartialEq for CoreDevice
impl PartialEq for CoreDevice
Source§impl PartialOrd for CoreDevice
impl PartialOrd for CoreDevice
impl Eq for CoreDevice
Auto Trait Implementations§
impl Freeze for CoreDevice
impl !RefUnwindSafe for CoreDevice
impl Send for CoreDevice
impl Sync for CoreDevice
impl Unpin for CoreDevice
impl !UnwindSafe for CoreDevice
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more