VulkanPhysicalDeviceExt

Trait VulkanPhysicalDeviceExt 

Source
pub trait VulkanPhysicalDeviceExt: IsA<VulkanPhysicalDevice> + 'static {
    // Provided methods
    fn check_api_version(&self, major: u32, minor: u32, patch: u32) -> bool { ... }
    fn api_version(&self) -> (u32, u32, u32) { ... }
    fn extension_info(&self, name: &str) -> Option<u32> { ... }
    fn instance(&self) -> VulkanInstance { ... }
    fn layer_info(&self, name: &str) -> Option<(Option<GString>, u32, u32)> { ... }
    fn device_index(&self) -> u32 { ... }
}
Expand description

Trait containing all VulkanPhysicalDevice methods.

§Implementors

VulkanPhysicalDevice

Provided Methods§

Source

fn check_api_version(&self, major: u32, minor: u32, patch: u32) -> bool

Note: This is the intersection of the exposed supported API version as would be returned by api_version() and VulkanInstanceExt::check_version(). The latter will take into account any requested API version and may result in a different result than directly comparing against VulkanInstanceExt::version().

§major

the API major version to check

§minor

the API minor version to check

§patch

the API patch version to check

§Returns

whether the VulkanPhysicalDevice supports the version specified by major, minor and patch.

Source

fn api_version(&self) -> (u32, u32, u32)

Retrieves the advertised Vulkan API version of the VulkanPhysicalDevice.

§Returns
§major

major version

§minor

minor version

§patch

patch version

Source

fn extension_info(&self, name: &str) -> Option<u32>

Retrieves information about a device extension.

Will not find any extensions before VulkanInstanceExt::fill_info() has been called.

§name

the extension name to look for

§Returns

whether extension name is available

§spec_version

return value for the exteion specification version

Source

fn instance(&self) -> VulkanInstance

§Returns

The VulkanInstance associated with this physical device

Source

fn layer_info(&self, name: &str) -> Option<(Option<GString>, u32, u32)>

Retrieves information about a layer.

Will not find any layers before VulkanInstanceExt::fill_info() has been called.

§name

the layer name to look for

§Returns

whether layer name is available

§description

return value for the layer description or None

§spec_version

return value for the layer specification version

§implementation_version

return value for the layer implementation version

Source

fn device_index(&self) -> u32

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§