pub struct InstanceObject { /* private fields */ }Expand description
Opaque handle to a instance object
Implementations§
Source§impl InstanceObject
impl InstanceObject
Sourcepub fn new(info: &InstanceCreateInfo<'_>) -> Result<Self>
pub fn new(info: &InstanceCreateInfo<'_>) -> Result<Self>
Create a new Vulkan instance
§Failures
On failure, this command returns
VK_ERROR_OUT_OF_HOST_MEMORYVK_ERROR_OUT_OF_DEVICE_MEMORYVK_ERROR_INITIALIZATION_FAILEDVK_ERROR_LAYER_NOT_PRESENTVK_ERROR_EXTENSION_NOT_PRESENTVK_ERROR_INCOMPATIBLE_DRIVER
Sourcepub const unsafe fn manage(handle: VkInstance) -> Self
pub const unsafe fn manage(handle: VkInstance) -> Self
Sourcepub const fn unmanage(self) -> VkInstance
pub const fn unmanage(self) -> VkInstance
Purges internal values (Drop will not be called for this resource)
Trait Implementations§
Source§impl Drop for InstanceObject
impl Drop for InstanceObject
Source§impl Instance for InstanceObject
impl Instance for InstanceObject
Source§fn extra_procedure(&self, name: &CStr) -> Option<PFN_vkVoidFunction>
fn extra_procedure(&self, name: &CStr) -> Option<PFN_vkVoidFunction>
👎Deprecated: do not use this directly(this does not provide caching!)
Return a function pointer for a command
Source§fn physical_device_count(&self) -> Result<u32>
fn physical_device_count(&self) -> Result<u32>
Counts the physical devices accessible to a Vulkan instance Read more
Source§fn enumerate_physical_devices(
&self,
sink: &mut [MaybeUninit<VkPhysicalDevice>],
) -> Result<u32>
fn enumerate_physical_devices( &self, sink: &mut [MaybeUninit<VkPhysicalDevice>], ) -> Result<u32>
Enumerates the physical devices accessible to a Vulkan instance Read more
Source§fn iter_physical_devices(&self) -> Result<IterPhysicalDevices<'_, Self>>
fn iter_physical_devices(&self) -> Result<IterPhysicalDevices<'_, Self>>
Lazyly enumerates the physical devices accessible to a Vulkan instance Read more
Source§fn enumerate_physical_devices_alloc(
&self,
) -> Result<Vec<PhysicalDeviceObject<&Self>>>
fn enumerate_physical_devices_alloc( &self, ) -> Result<Vec<PhysicalDeviceObject<&Self>>>
Enumerates the physical devices accessible to a Vulkan instance Read more
Source§impl InstanceGetPhysicalDeviceProperties2Extension for InstanceObject
impl InstanceGetPhysicalDeviceProperties2Extension for InstanceObject
fn get_physical_device_properties2_khr_fn( &self, ) -> PFN_vkGetPhysicalDeviceProperties2KHR
fn get_physical_device_features2_khr_fn( &self, ) -> PFN_vkGetPhysicalDeviceFeatures2KHR
fn get_physical_device_format_properties2_khr_fn( &self, ) -> PFN_vkGetPhysicalDeviceFormatProperties2KHR
Source§impl VkHandle for InstanceObject
impl VkHandle for InstanceObject
type Handle = VkInstance
Source§fn native_ptr(&self) -> Self::Handle
fn native_ptr(&self) -> Self::Handle
Retrieve an underlying handle
fn as_transparent_ref(&self) -> VkHandleRef<'_, Self::Handle>
Source§impl VkHandleMut for InstanceObject
impl VkHandleMut for InstanceObject
Source§fn native_ptr_mut(&mut self) -> Self::Handle
fn native_ptr_mut(&mut self) -> Self::Handle
Retrieve an underlying mutable handle
fn as_transparent_ref_mut(&mut self) -> VkHandleRefMut<'_, Self::Handle>
Source§impl VkObject for InstanceObject
impl VkObject for InstanceObject
const TYPE: VkObjectType = 1i32
impl Send for InstanceObject
impl Sync for InstanceObject
Auto Trait Implementations§
impl !Freeze for InstanceObject
impl RefUnwindSafe for InstanceObject
impl Unpin for InstanceObject
impl UnwindSafe for InstanceObject
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