I'm making a Daydream app for android but it crashes immediately. I dont know what's causing this problem. I think it has something to do with the AndroidManifest but it looks fine to me. I hope someone can help me out because it gets really annoying. PS I'm working with Unity 5 so maybe it is'nt possible at all to make a Daydream app with Unity?
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.unity3d.player"
android:installLocation="preferExternal"
android:versionCode="1"
android:versionName="1.0">
<supports-screens
android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:xlargeScreens="true"
android:anyDensity="true"/>
<application
android:theme="@android:style/Theme.NoTitleBar.Fullscreen"
android:icon="@drawable/app_icon"
android:label="@string/app_name"
android:debuggable="true">
android:label="@string/app_name"
android:supportsRtl="true"
<activity android:name="com.unity3d.player.UnityPlayerActivity"
android:label="@string/app_name">
<meta-data android:name="unityplayer.UnityActivity" android:value="true" />
</activity>
<service
android:name=".MyDream"
android:exported="true"
android:icon="@drawable/app_icon"
android:label="@string/app_name"
android:permission="android.permission.BIND_DREAM_SERVICE">
<intent-filter>
<action android:name="android.service.dreams.DreamService" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</service>
</application>
</manifest>
It could be the Manifest.
You are missing important tags from it.
<!-- VR feature tags. -->
<uses-feature android:name="android.software.vr.mode" android:required="false"/>
<uses-feature android:name="android.hardware.vr.high_performance" android:required="false"/>
Also
<uses-feature android:glEsVersion="0x00020000" />
And to make sure there is no Marshmallow's runtime permission problem, alsi include
<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="22"
You need to download Google VR SDK for Unity to be able to properly develop Daydream App .
Below is the full Manifest from Google VR SDK.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
<application android:icon="@drawable/app_icon"
android:label="@string/app_name">
<activity android:name="com.google.unity.GoogleUnityActivity"
android:label="@string/app_name"
android:screenOrientation="landscape"
android:launchMode="singleTask"
android:configChanges="mcc|mnc|locale|touchscreen|keyboard|keyboardHidden|navigation|orientation|screenLayout|uiMode|screenSize|smallestScreenSize|fontScale">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="com.google.intent.category.CARDBOARD" />
</intent-filter>
<meta-data android:name="unityplayer.UnityActivity" android:value="true" />
</activity>
<meta-data android:name="IMMERSIVE_MODE" android:value="true" />
</application>
<!-- Set target sdk version to Lollipop to prevent issues with Marshmallow's runtime permissions. -->
<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="22" />
<uses-feature android:glEsVersion="0x00020000" />
<uses-feature android:name="android.hardware.sensor.accelerometer" android:required="true"/>
<uses-feature android:name="android.hardware.sensor.gyroscope" android:required="true"/>
<uses-permission android:name="android.permission.NFC"/>
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
<!-- VR feature tags. -->
<uses-feature android:name="android.software.vr.mode" android:required="false"/>
<uses-feature android:name="android.hardware.vr.high_performance" android:required="false"/>
</manifest>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.