[][src]Struct openxr::Instance

pub struct Instance { /* fields omitted */ }

Methods

impl Instance[src]

pub unsafe fn from_raw(
    entry: Entry,
    handle: Instance,
    exts: InstanceExtensions
) -> Result<Self>
[src]

Take ownership of an existing instance handle

Safety

handle must be the instance handle that was used to load exts.

pub fn as_raw(&self) -> Instance[src]

pub fn entry(&self) -> &Entry[src]

Access the entry points used to create self

pub fn fp(&self) -> &Instance[src]

Access the core function pointers

pub fn exts(&self) -> &InstanceExtensions[src]

Access the internal extension function pointers

impl Instance[src]

pub fn set_name(&mut self, name: &str) -> Result<()>[src]

Set the debug name of this Instance, if XR_EXT_debug_utils is loaded

pub fn properties(&self) -> Result<InstanceProperties>[src]

pub fn result_to_string(&self, result: Result) -> Result<String>[src]

pub fn structure_type_to_string(&self, ty: StructureType) -> Result<String>[src]

pub fn system(&self, form_factor: FormFactor) -> Result<SystemId>[src]

pub fn system_properties(&self, system: SystemId) -> Result<SystemProperties>[src]

pub unsafe fn string_to_path(&self, string: &str) -> Result<Path>[src]

Construct a Path from a string

Safety

A returned Path must not used with any other instance.

pub fn path_to_string(&self, path: Path) -> Result<String>[src]

pub fn vulkan_instance_extensions(&self, system: SystemId) -> Result<String>[src]

Identify the Vulkan instance extensions required by a system

Returns a space-delimited list of Vulkan instance extension names.

pub fn vulkan_device_extensions(&self, system: SystemId) -> Result<String>[src]

Identify the Vulkan device extensions required by a system

Returns a space-delimited list of Vulkan device extension names.

pub fn vulkan_graphics_device(
    &self,
    system: SystemId,
    vk_instance: VkInstance
) -> Result<VkPhysicalDevice>
[src]

Identify the Vulkan graphics device to use for a system

pub fn graphics_requirements<G: Graphics>(
    &self,
    system: SystemId
) -> Result<G::Requirements>
[src]

Query graphics API version requirements

pub unsafe fn create_session<G: Graphics>(
    &self,
    system: SystemId,
    info: &G::SessionCreateInfo
) -> Result<(Session<G>, FrameStream<G>)>
[src]

Create a session for a particular graphics API

Safety

The requirements documented by the graphics API extension must be respected. Among other requirements, info must contain valid handles, and certain operations must be externally synchronized.

pub fn create_session_headless(
    &self,
    system: SystemId
) -> Result<Session<Headless>>
[src]

Create a session without graphics support

pub fn poll_event<'a>(
    &self,
    storage: &'a mut EventDataBuffer
) -> Result<Option<Event<'a>>>
[src]

Get the next event, if available

Returns immediately regardless of whether an event was available.

pub fn enumerate_view_configurations(
    &self,
    system: SystemId
) -> Result<Vec<ViewConfigurationType>>
[src]

Enumerates the supported view configuration types

pub fn view_configuration_properties(
    &self,
    system: SystemId,
    ty: ViewConfigurationType
) -> Result<ViewConfigurationProperties>
[src]

Query properties of an individual view configuration

pub fn enumerate_view_configuration_views(
    &self,
    system: SystemId,
    ty: ViewConfigurationType
) -> Result<Vec<ViewConfigurationView>>
[src]

pub fn enumerate_environment_blend_modes(
    &self,
    system: SystemId
) -> Result<Vec<EnvironmentBlendMode>>
[src]

pub fn now(&self) -> Result<Time>[src]

Obtain the current Time

Requires KHR_convert_timespec_time

Auto Trait Implementations

impl Send for Instance

impl Sync for Instance

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> Same for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf for SP where
    SS: SubsetOf<SP>,