refactored xr_entry func.
This commit is contained in:
@@ -19,7 +19,7 @@ wgpu-hal = "0.17.1"
|
|||||||
openxr = { version = "0.17.1", features = ["linked"] }
|
openxr = { version = "0.17.1", features = ["linked"] }
|
||||||
|
|
||||||
[target.'cfg(not(target_os = "linux"))'.dependencies]
|
[target.'cfg(not(target_os = "linux"))'.dependencies]
|
||||||
openxr = { version = "0.17.1", features = ["linked", "static"] }
|
openxr = { version = "0.17.1", features = ["static"] }
|
||||||
|
|
||||||
[dev-dependencies]
|
[dev-dependencies]
|
||||||
bevy = "0.12"
|
bevy = "0.12"
|
||||||
|
|||||||
@@ -36,9 +36,9 @@ pub fn initialize_xr_graphics(
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub fn xr_entry() -> xr::Entry {
|
pub fn xr_entry() -> xr::Entry {
|
||||||
#[cfg(feature = "linked")]
|
#[cfg(target_os = "linux")]
|
||||||
let entry = xr::Entry::linked();
|
let entry = xr::Entry::linked();
|
||||||
#[cfg(not(feature = "linked"))]
|
#[cfg(not(target_os = "linux"))]
|
||||||
let entry = unsafe { xr::Entry::load().unwrap() };
|
let entry = unsafe { xr::Entry::load().unwrap() };
|
||||||
entry
|
entry
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user