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>
Available on crate feature Implements
only.
pub fn new(info: &InstanceCreateInfo<'_>) -> Result<Self>
Implements
only.Create a new Vulkan instance
§Failures
On failure, this command returns
VK_ERROR_OUT_OF_HOST_MEMORY
VK_ERROR_OUT_OF_DEVICE_MEMORY
VK_ERROR_INITIALIZATION_FAILED
VK_ERROR_LAYER_NOT_PRESENT
VK_ERROR_EXTENSION_NOT_PRESENT
VK_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
Available on crate feature Implements
only.
impl Drop for InstanceObject
Available on crate feature
Implements
only.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!)
Available on crate feature
Implements
only.Return a function pointer for a command
Source§fn physical_device_count(&self) -> Result<u32>
fn physical_device_count(&self) -> Result<u32>
Available on crate feature
Implements
only.Counts the physical devices accessible to a Vulkan instance Read more
Source§fn enumerate_physical_devices(
&self,
sink: &mut [VkPhysicalDevice],
) -> Result<u32>
fn enumerate_physical_devices( &self, sink: &mut [VkPhysicalDevice], ) -> Result<u32>
Available on crate feature
Implements
only.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>>
Available on crate features
Implements
and alloc
only.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>>>
Available on crate features
Implements
and alloc
only.Enumerates the physical devices accessible to a Vulkan instance Read more
Source§impl InstanceExtensions for InstanceObject
impl InstanceExtensions for InstanceObject
Source§fn create_debug_report_callback_ext_fn(
&self,
) -> PFN_vkCreateDebugReportCallbackEXT
fn create_debug_report_callback_ext_fn( &self, ) -> PFN_vkCreateDebugReportCallbackEXT
Available on crate features
Implements
and VK_EXT_debug_report
only.Source§fn destroy_debug_report_callback_ext_fn(
&self,
) -> PFN_vkDestroyDebugReportCallbackEXT
fn destroy_debug_report_callback_ext_fn( &self, ) -> PFN_vkDestroyDebugReportCallbackEXT
Available on crate features
Implements
and VK_EXT_debug_report
only.Source§fn debug_report_message_ext_fn(&self) -> PFN_vkDebugReportMessageEXT
fn debug_report_message_ext_fn(&self) -> PFN_vkDebugReportMessageEXT
Available on crate features
Implements
and VK_EXT_debug_report
only.Source§fn create_debug_utils_messenger_ext_fn(
&self,
) -> PFN_vkCreateDebugUtilsMessengerEXT
fn create_debug_utils_messenger_ext_fn( &self, ) -> PFN_vkCreateDebugUtilsMessengerEXT
Available on crate features
Implements
and VK_EXT_debug_utils
only.Source§fn destroy_debug_utils_messenger_ext_fn(
&self,
) -> PFN_vkDestroyDebugUtilsMessengerEXT
fn destroy_debug_utils_messenger_ext_fn( &self, ) -> PFN_vkDestroyDebugUtilsMessengerEXT
Available on crate features
Implements
and VK_EXT_debug_utils
only.Source§fn set_debug_utils_object_name_ext_fn(&self) -> PFN_vkSetDebugUtilsObjectNameEXT
fn set_debug_utils_object_name_ext_fn(&self) -> PFN_vkSetDebugUtilsObjectNameEXT
Available on crate features
Implements
and VK_EXT_debug_utils
only.Source§fn get_physical_device_external_fence_properties_khr_fn(
&self,
) -> PFN_vkGetPhysicalDeviceExternalFencePropertiesKHR
fn get_physical_device_external_fence_properties_khr_fn( &self, ) -> PFN_vkGetPhysicalDeviceExternalFencePropertiesKHR
Available on crate features
Implements
and VK_KHR_external_fence_capabilities
only.Source§fn get_randr_output_display_ext_fn(&self) -> PFN_vkGetRandROutputDisplayEXT
fn get_randr_output_display_ext_fn(&self) -> PFN_vkGetRandROutputDisplayEXT
Available on crate features
Implements
and VK_EXT_acquire_xlib_display
only.Source§fn acquire_xlib_display_ext_fn(&self) -> PFN_vkAcquireXlibDisplayEXT
fn acquire_xlib_display_ext_fn(&self) -> PFN_vkAcquireXlibDisplayEXT
Available on crate features
Implements
and VK_EXT_acquire_xlib_display
only.Source§fn get_physical_device_surface_present_modes_2_ext_fn(
&self,
) -> PFN_vkGetPhysicalDeviceSurfacePresentModes2EXT
fn get_physical_device_surface_present_modes_2_ext_fn( &self, ) -> PFN_vkGetPhysicalDeviceSurfacePresentModes2EXT
Available on crate features
Implements
and VK_EXT_full_screen_exclusive
only.Source§fn get_physical_device_surface_capabilities_2_khr_fn(
&self,
) -> PFN_vkGetPhysicalDeviceSurfaceCapabilities2KHR
fn get_physical_device_surface_capabilities_2_khr_fn( &self, ) -> PFN_vkGetPhysicalDeviceSurfaceCapabilities2KHR
Available on crate features
Implements
and VK_KHR_get_surface_capabilities2
only.Source§fn release_display_ext_fn(&self) -> PFN_vkReleaseDisplayEXT
fn release_display_ext_fn(&self) -> PFN_vkReleaseDisplayEXT
Available on crate features
Implements
and VK_EXT_direct_mode_display
only.Source§fn get_physical_device_multisample_properties_ext_fn(
&self,
) -> PFN_vkGetPhysicalDeviceMultisamplePropertiesEXT
fn get_physical_device_multisample_properties_ext_fn( &self, ) -> PFN_vkGetPhysicalDeviceMultisamplePropertiesEXT
Available on crate features
Implements
and VK_EXT_sample_locations
only.Source§unsafe fn new_debug_report_callback_raw(
&self,
info: &DebugReportCallbackCreateInfo,
allocation_callbacks: Option<&VkAllocationCallbacks>,
) -> Result<VkDebugReportCallbackEXT>
unsafe fn new_debug_report_callback_raw( &self, info: &DebugReportCallbackCreateInfo, allocation_callbacks: Option<&VkAllocationCallbacks>, ) -> Result<VkDebugReportCallbackEXT>
Available on crate features
Implements
and VK_EXT_debug_report
only.Register a debug report callback Read more
Source§fn debug_message(
&self,
flags: VkDebugReportFlagsEXT,
object_type: DebugReportObjectType,
object: u64,
location: usize,
message_count: i32,
layer_prefix: &CStr,
message: &CStr,
)
fn debug_message( &self, flags: VkDebugReportFlagsEXT, object_type: DebugReportObjectType, object: u64, location: usize, message_count: i32, layer_prefix: &CStr, message: &CStr, )
Available on crate features
Implements
and VK_EXT_debug_report
only.Inject its own messages into the debug stream
Source§unsafe fn destroy_debug_report_callback_raw(
&self,
obj: VkDebugReportCallbackEXT,
allocation_callbacks: Option<&VkAllocationCallbacks>,
)
unsafe fn destroy_debug_report_callback_raw( &self, obj: VkDebugReportCallbackEXT, allocation_callbacks: Option<&VkAllocationCallbacks>, )
Available on crate features
Implements
and VK_EXT_debug_report
only.Destroy a debug report callback object Read more
Source§unsafe fn new_debug_utils_messenger_raw(
&self,
info: &DebugUtilsMessengerCreateInfo,
allocation_callbacks: Option<&VkAllocationCallbacks>,
) -> Result<VkDebugUtilsMessengerEXT>
unsafe fn new_debug_utils_messenger_raw( &self, info: &DebugUtilsMessengerCreateInfo, allocation_callbacks: Option<&VkAllocationCallbacks>, ) -> Result<VkDebugUtilsMessengerEXT>
Available on crate features
Implements
and VK_EXT_debug_utils
only.Create a debug messenger object Read more
Source§unsafe fn destroy_debug_utils_messenger_raw(
&self,
obj: VkDebugUtilsMessengerEXT,
allocation_callbacks: Option<&VkAllocationCallbacks>,
)
unsafe fn destroy_debug_utils_messenger_raw( &self, obj: VkDebugUtilsMessengerEXT, allocation_callbacks: Option<&VkAllocationCallbacks>, )
Available on crate features
Implements
and VK_EXT_debug_utils
only.Destroy a debug messenger object Read more
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