Native GLES Application中如何使用Qualcom VRSDK?

weixin_39244999 2018-01-23 10:40:15
I want to use Qualcom VRSDK in Native GLES application.
...全文
1949 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
weixin_39244999 2018-01-23
  • 打赏
  • 举报
回复
Found it in the DOC: Snapdragon VR Libraries After installing the Snapdragon VR SDK, modify the application's "Android.mk" file to pull in "libsvrapi.so" and "libqvrservice_client.so". This is done using the "PREBUILT_SHARED_LIBRARY" and "LOCAL_SHARED_LIBRARIES" commands in the Android NDK build system. See the Snapdragon VR sample or the Android NDK build documentation for more information. Manually copy the file "svrApi.jar" from the Snapdragon VR SDK to the "libs" directory in your application. Application Manifest In the application's build file "AndroidManifest.xml", change the "<application>" entry to include "android:hasCode="true"". This tells the Android build system that there will be Java code in the native application. If this is not done, the Android build system will not add the "svrApi.jar" file to the final APK. Application Java Activity In order to include the Snapdragon VR SDK jar file in the final APK, your application must have at least a shell Java Activity class. This can be nothing more than an Activity that extents "android.app.NativeActivity". Its only function can be to call "System.loadLibrary( "svrapi" )" and your application's library. Be sure to modify "AndroidManifest.xml" to change the Activity name to this new Java class. Android State Machine Add the following Snapdragon VR calls to your native code: android_main() Call "svrInitialize()" before entering the main loop Call "svrShutdown()" before the application exits On APP_CMD_RESUME Call "svrBeginVr()" if VR has been initialized On APP_CMD_PAUSE Call "svrEndVr()" if VR has been initialized and "svrBeginVr()" has been called

2,639

社区成员

发帖
与我相关
我的任务
社区描述
本论坛以AI、WoS 、XR、IoT、Auto、生成式AI等核心板块组成,为开发者提供便捷及高效的学习和交流平台。 高通开发者专区主页:https://qualcomm.csdn.net/
人工智能物联网机器学习 技术论坛(原bbs) 北京·东城区
社区管理员
  • csdnsqst0050
  • chipseeker
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧