Skip to main content

InstanceCreateInfo

Struct InstanceCreateInfo 

Source
pub struct InstanceCreateInfo<'a> {
    pub s_type: StructureType,
    pub p_next: *const c_void,
    pub flags: InstanceCreateFlags,
    pub p_application_info: *const ApplicationInfo<'a>,
    pub enabled_layer_count: u32,
    pub pp_enabled_layer_names: *const *const c_char,
    pub enabled_extension_count: u32,
    pub pp_enabled_extension_names: *const *const c_char,
    /* private fields */
}
Expand description

Native structure VkInstanceCreateInfo.

Khronos reference: VkInstanceCreateInfo

Fields§

§s_type: StructureType

Native field sType.

§p_next: *const c_void

Native field pNext.

§flags: InstanceCreateFlags

Native field flags.

§p_application_info: *const ApplicationInfo<'a>

Native field pApplicationInfo.

§enabled_layer_count: u32

Native field enabledLayerCount.

§pp_enabled_layer_names: *const *const c_char

Native field ppEnabledLayerNames.

§enabled_extension_count: u32

Native field enabledExtensionCount.

§pp_enabled_extension_names: *const *const c_char

Native field ppEnabledExtensionNames.

Implementations§

Source§

impl<'a> InstanceCreateInfo<'a>

Source

pub fn new() -> Self

Construct the record with its canonical sType tag and default native state.

Source

pub fn set_flags(self, value: InstanceCreateFlags) -> Self

Set native field flags without native effects.

Source

pub fn set_application_info(self, value: &'a ApplicationInfo<'a>) -> Self

Set native field pApplicationInfo without native effects.

Source

pub fn set_enabled_layer_count(self, value: u32) -> Self

Set native count enabledLayerCount directly without checking associated pointer extents. Use the borrowed array helpers to derive matching storage and counts together. Direct count edits support null-query/dynamic-state paths and remain a native-call validity obligation, including after earlier borrowed setters.

Source

pub fn set_enabled_layer_names( self, value: &'a [*const c_char], ) -> Result<Self, ConstructionError>

Borrow ppEnabledLayerNames and set checked native count enabledLayerCount. The borrow covers this storage only; nested raw pointers, format, alignment and asynchronous retention remain native-call obligations. Output storage must be initialized; returned sizes do not enlarge its capacity.

§Errors

Returns a construction error if the length exceeds the native count width.

Source

pub fn set_enabled_extension_count(self, value: u32) -> Self

Set native count enabledExtensionCount directly without checking associated pointer extents. Use the borrowed array helpers to derive matching storage and counts together. Direct count edits support null-query/dynamic-state paths and remain a native-call validity obligation, including after earlier borrowed setters.

Source

pub fn set_enabled_extension_names( self, value: &'a [*const c_char], ) -> Result<Self, ConstructionError>

Borrow ppEnabledExtensionNames and set checked native count enabledExtensionCount. The borrow covers this storage only; nested raw pointers, format, alignment and asynchronous retention remain native-call obligations. Output storage must be initialized; returned sizes do not enlarge its capacity.

§Errors

Returns a construction error if the length exceeds the native count width.

Source

pub fn push_next<T: Extends<Self>>( self, next: &'a mut T, ) -> Result<Self, ConstructionError>

Prepend one registry-compatible node, retaining its exclusive borrow.

The node must have a null p_next and both headers must have canonical tags. Existing links are never traversed and remain written after the borrow ends. Type compatibility does not establish enabled extensions or Vulkan valid usage.

§Errors

Returns a construction error for a changed structure tag or already-linked node.

Trait Implementations§

Source§

impl<'a> Default for InstanceCreateInfo<'a>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for DebugReportCallbackCreateInfoEXT<'a>

Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for ValidationFlagsEXT<'a>

Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for ValidationFeaturesEXT<'a>

Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for LayerSettingsCreateInfoEXT<'a>

Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for DebugUtilsMessengerCreateInfoEXT<'a>

Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for ExportMetalObjectCreateInfoEXT<'a>

Available on crate feature platform-metal only.
Source§

impl<'a, 'root> Extends<InstanceCreateInfo<'root>> for DirectDriverLoadingListLUNARG<'a>

Auto Trait Implementations§

§

impl<'a> !Send for InstanceCreateInfo<'a>

§

impl<'a> !Sync for InstanceCreateInfo<'a>

§

impl<'a> !UnwindSafe for InstanceCreateInfo<'a>

§

impl<'a> Forget for InstanceCreateInfo<'a>

§

impl<'a> Freeze for InstanceCreateInfo<'a>

§

impl<'a> Move for InstanceCreateInfo<'a>

§

impl<'a> RefUnwindSafe for InstanceCreateInfo<'a>

§

impl<'a> Unpin for InstanceCreateInfo<'a>

§

impl<'a> UnsafeUnpin for InstanceCreateInfo<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.