Trait gfx_hal::adapter::PhysicalDevice [−][src]
Represents a physical device (such as a GPU) capable of supporting the given backend.
Required methods
unsafe fn open(
&self,
families: &[(&B::QueueFamily, &[QueuePriority])],
requested_features: Features
) -> Result<Gpu<B>, CreationError>
[src]
&self,
families: &[(&B::QueueFamily, &[QueuePriority])],
requested_features: Features
) -> Result<Gpu<B>, CreationError>
Create a new logical device with the requested features.
If requested_features
is empty, then only
the core features are supported.
Arguments
families
- which queue families to create queues from. The implementation may allocate more processing time to the queues with higher priority.requested_features
- device features to enable. Must be a subset of the features supported by this device.
Errors
- Returns
TooManyObjects
if the implementation can't create a new logical device. - Returns
MissingFeature
if the implementation does not support a requested feature.
Examples
use gfx_hal::{adapter::PhysicalDevice, Features}; let gpu = physical_device.open(&[(&family, &[1.0; 1])], Features::empty());
fn format_properties(&self, format: Option<Format>) -> Properties
[src]
Fetch details for a particular format.
fn image_format_properties(
&self,
format: Format,
dimensions: u8,
tiling: Tiling,
usage: Usage,
view_caps: ViewCapabilities
) -> Option<FormatProperties>
[src]
&self,
format: Format,
dimensions: u8,
tiling: Tiling,
usage: Usage,
view_caps: ViewCapabilities
) -> Option<FormatProperties>
Fetch details for a particular image format.
fn memory_properties(&self) -> MemoryProperties
[src]
Fetch details for the memory regions provided by the device.
fn features(&self) -> Features
[src]
Returns the features of this PhysicalDevice
. This usually depends on the graphics API being
used, as well as the actual platform underneath.
fn capabilities(&self) -> Capabilities
[src]
Returns the capabilities of this PhysicalDevice
. Similarly to Features
, they
fn limits(&self) -> Limits
[src]
Returns the resource limits of this PhysicalDevice
.
Provided methods
fn is_valid_cache(&self, _cache: &[u8]) -> bool
[src]
Check cache compatibility with the PhysicalDevice
.