pub struct ExtensionProperties {
pub name: Extension,
pub spec_version: u32,
}Expand description
A wrapper for
VkExtensionProperties.
Structure specifying an extension properties.
Can convert to the ash::vk::ExtensionProperties C binding with From or Into.
§Examples
use ash::vk;
use std::ffi::CStr;
use vulkan_layer::{Extension, ExtensionProperties};
let extension_properties = ExtensionProperties {
name: Extension::KHRSurface,
spec_version: 25,
};
let extension_properties_ffi: vk::ExtensionProperties = extension_properties.clone().into();
assert_eq!(
unsafe { CStr::from_ptr(extension_properties_ffi.extension_name.as_ptr()) },
ash::vk::KhrSurfaceFn::name()
);
assert_eq!(extension_properties_ffi.spec_version, 25);Fields§
§name: ExtensionThe name of the extension.
spec_version: u32spec_version is the version of this extension. It is an integer, incremented with
backward compatible changes.
Trait Implementations§
Source§impl Clone for ExtensionProperties
impl Clone for ExtensionProperties
Source§fn clone(&self) -> ExtensionProperties
fn clone(&self) -> ExtensionProperties
Returns a copy 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 From<ExtensionProperties> for ExtensionProperties
impl From<ExtensionProperties> for ExtensionProperties
Source§fn from(_: ExtensionProperties) -> Self
fn from(_: ExtensionProperties) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ExtensionProperties
impl RefUnwindSafe for ExtensionProperties
impl Send for ExtensionProperties
impl Sync for ExtensionProperties
impl Unpin for ExtensionProperties
impl UnwindSafe for ExtensionProperties
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
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