0

我正在使用来自 Google 的 vr360 图像的新库

当我在三星 Galaxy s6 (6.0) 上运行应用程序时遇到问题,它崩溃了。但是当我在其他设备上运行应用程序时,Nexus 4 (5.+) 都运行良好。

我尝试在 S6 上运行 Lab 应用程序并完美运行。演示网址:https ://codelabs.developers.google.com/codelabs/vr_view_app_101/index.html?index=..%2F..%2Findex#0

我的错误:

android.view.InflateException: Binary XML file line #8: Binary XML file line #8: Error inflating class com.google.vr.sdk.widgets.pano.VrPanoramaView

我的 XML:

<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical">


    <com.google.vr.sdk.widgets.pano.VrPanoramaView
        android:id="@+id/pano_view"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_margin="5dip" />

</LinearLayout>

我的摇篮:

   compile project(':gvr-android-sdk/libraries:common')
    compile project(':gvr-android-sdk/libraries:commonwidget')
    compile project(':gvr-android-sdk/libraries:panowidget')

和 Settings.gradle

include ':gvr-android-sdk/libraries:audio'
include ':gvr-android-sdk/libraries:base'
include ':gvr-android-sdk/libraries:common'
include ':gvr-android-sdk/libraries:commonwidget'
include ':gvr-android-sdk/libraries:panowidget'
include ':gvr-android-sdk/libraries:videowidget'
4

2 回答 2

1

将以下 abiFilters 添加到项目的 build.gradle 文件中的 buildTypes 中。

buildTypes {
    release {
        ndk {
            abiFilters "armeabi", "armeabi-v7a", "x86"
        }
    }}
于 2016-06-28T11:51:28.367 回答
-1

替换这个: compile project(':gvr-android-sdk/libraries:panowidget')

为此:编译项目(':gvr-android-sdk/libraries:videowidget')

于 2016-06-04T09:34:05.920 回答