preliminary support for oculus mobile SDK

This commit is contained in:
Stephen Birarda 2014-11-18 16:39:05 -08:00
parent 713beda440
commit 9094fef8b8
2 changed files with 14 additions and 5 deletions

View file

@ -62,12 +62,12 @@
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<!-- Tell the system this app requires OpenGL ES 3.0. -->
<uses-­feature android:glEsVersion="0x00030000" android:required="true" />
<!-- camera permission required for GEAR VR passthrough camera -->
<uses-­permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.CAMERA" />
<!-- The following comment will be replaced upon deployment with default features based on the dependencies of the application.
Remove the comment if you do not require these default features. -->
<!-- Tell the system this app requires OpenGL ES 3.0. -->
<uses-feature android:glEsVersion="0x00030000" android:required="true" />
</manifest>

View file

@ -15,10 +15,19 @@ set(REQUIRED_HIFI_LIBRARIES "shared" "networking")
link_hifi_libraries(${REQUIRED_HIFI_LIBRARIES})
link_shared_dependencies()
set(ANDROID_SDK_ROOT $ENV{ANDROID_SDK})
set(ANDROID_SDK_ROOT $ENV{ANDROID_HOME})
set(ANDROID_APP_DISPLAY_NAME Interface)
set(ANDROID_API_LEVEL 19)
set(ANDROID_APK_PACKAGE io.highfidelity.gvrinterface)
set(ANDROID_APK_FULLSCREEN true)
# we need VRLib, so add a project.properties to our apk build folder that says that
find_path(_OCULUS_VRLIB_DIR NAME VRLib.vcxproj HINTS "/ovr_mobile_sdk/VRLib/")
if (NOT _OCULUS_VRLIB_DIR)
message(FATAL_ERROR "Could not find Oculus Mobile SDK VRLib.")
endif()
file(RELATIVE_PATH RELATIVE_VRLIB_PATH ${ANDROID_APK_OUTPUT_DIR} "${_OCULUS_VRLIB_DIR}")
file(WRITE "${ANDROID_APK_BUILD_DIR}/project.properties" "android.library.reference.1=${RELATIVE_VRLIB_PATH}")
qt_create_apk()