Skip to content

Commit

Permalink
OpenXR - Support multiple loaders
Browse files Browse the repository at this point in the history
  • Loading branch information
lvonasek committed Sep 24, 2022
1 parent ec22cee commit 1fdbde8
Show file tree
Hide file tree
Showing 10 changed files with 995 additions and 2,843 deletions.
12 changes: 10 additions & 2 deletions CMakeLists.txt
Expand Up @@ -120,8 +120,16 @@ if(OPENXR)
add_definitions(-DOPENXR)
add_library(openxr SHARED IMPORTED)
include_directories(ext/openxr)
set_property(TARGET openxr PROPERTY IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/ext/openxr/libs/arm64-v8a/libopenxr_loader.so")
message("OpenXR enabled")
if(OPENXR_PLATFORM_PICO)
add_definitions(-DOPENXR_PLATFORM_PICO)
set_property(TARGET openxr PROPERTY IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/ext/openxr/libs/pico/arm64-v8a/libopenxr_loader.so")
message("OpenXR for Pico enabled")
endif()
if(OPENXR_PLATFORM_QUEST)
add_definitions(-DOPENXR_PLATFORM_QUEST)
set_property(TARGET openxr PROPERTY IMPORTED_LOCATION "${CMAKE_SOURCE_DIR}/ext/openxr/libs/quest/arm64-v8a/libopenxr_loader.so")
message("OpenXR for Quest enabled")
endif()
endif()

if(GOLD)
Expand Down
2 changes: 2 additions & 0 deletions android/build.gradle
Expand Up @@ -160,6 +160,7 @@ android {
'-DANDROID_CPP_FEATURES=',
'-DANDROID_STL=c++_static',
'-DANDROID_ARM_NEON=TRUE',
'-DOPENXR_PLATFORM_PICO=TRUE',
'-DOPENXR=TRUE'
}
}
Expand All @@ -179,6 +180,7 @@ android {
'-DANDROID_CPP_FEATURES=',
'-DANDROID_STL=c++_static',
'-DANDROID_ARM_NEON=TRUE',
'-DOPENXR_PLATFORM_QUEST=TRUE',
'-DOPENXR=TRUE'
}
}
Expand Down
2 changes: 1 addition & 1 deletion android/src/org/ppsspp/ppsspp/NativeActivity.java
Expand Up @@ -1547,6 +1547,6 @@ public void recreate() {
}

private boolean isVRDevice() {
return BuildConfig.FLAVOR.startsWith("vr_") == 0;
return BuildConfig.FLAVOR.startsWith("vr_");
}
}
Binary file not shown.
1,705 changes: 39 additions & 1,666 deletions ext/openxr/openxr.h 100755 → 100644

Large diffs are not rendered by default.

0 comments on commit 1fdbde8

Please sign in to comment.