Add a get_system_info method to XRInterface

This commit is contained in:
Bastiaan Olij 2023-03-13 12:26:10 +11:00
parent 550a779851
commit e31c2e4277
14 changed files with 69 additions and 1 deletions

View file

@ -385,8 +385,13 @@ bool OpenXRAPI::create_instance() {
if (XR_FAILED(result)) {
// not fatal probably
print_line("OpenXR: Failed to get XR instance properties [", get_error_string(result), "]");
runtime_name = "";
runtime_version = "";
} else {
print_line("OpenXR: Running on OpenXR runtime: ", instanceProps.runtimeName, " ", OpenXRUtil::make_xr_version_string(instanceProps.runtimeVersion));
runtime_name = instanceProps.runtimeName;
runtime_version = OpenXRUtil::make_xr_version_string(instanceProps.runtimeVersion);
print_line("OpenXR: Running on OpenXR runtime: ", runtime_name, " ", runtime_version);
}
for (OpenXRExtensionWrapper *wrapper : registered_extension_wrappers) {