Unity-Technologies / arfoundation-samples

Example content for Unity projects based on AR Foundation
Other
3.07k stars 1.15k forks source link

Black Screen #2

Closed nems808 closed 4 years ago

nems808 commented 6 years ago

Unity 2018.1.5f I have built and ran the demo scene with a cube successfully before. Now, the build is only showing a black screen and the camera permission is never raised when starting the build for the first time. Does anyone have any ideas what might have changed?

Using Pixel XL, ARCore 1.3.180604066

ghost commented 6 years ago

Could you share the logcat output when you run the app? Anything stand out as unusual?

nems808 commented 6 years ago

I added Mapbox and by accident, I added their ARCore package. Removing it solved the problem.

kennethlng commented 6 years ago

In case anybody's still getting a black screen when opening the app, you have to add a Camera Usage Description in Player settings.

Using iPhone X

renaudbedard commented 6 years ago

I'm getting a black/dark grey screen running the sample as-is on Android also. The app got past the Unity splash screen but did not ask for Camera permission.

Unity 2018.2.0f2 ARCore XR Plugin 1.0.0-preview.17 AR Foundation 1.0.0-preview.13 Pixel 2 XL running Android 8.1 ARCore 1.3.180604066

I get these warnings in my Unity Console, I tried flushing the package cache, reinstalling the packages, but they keep showing up. Possibly related?

2018-07-10 15_56_23-

logcat excerpts :


07-10 15:49:30.883 1502-1579/com.example.arfoundationsample D/Unity: [VFS] Mount /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/base.apk
07-10 15:49:30.889 1502-1502/com.example.arfoundationsample I/TangoClientLibLoader: Pure Java path, not loading libtango_client_api.so at all.
07-10 15:49:30.890 1502-1502/com.example.arfoundationsample E/Tango: Java version of Tango Service not found, falling back to tangoservice_d.
07-10 15:49:30.891 1502-1502/com.example.arfoundationsample E/zygote: No implementation found for int com.google.atap.tango.TangoJNINative.Initialize(android.content.Context) (tried Java_com_google_atap_tango_TangoJNINative_Initialize and Java_com_google_atap_tango_TangoJNINative_Initialize__Landroid_content_Context_2)
07-10 15:49:30.891 1502-1502/com.example.arfoundationsample E/Unity: Error trying to call delegated method resume. null

07-10 15:49:30.995 1502-1579/com.example.arfoundationsample D/Unity: Unable to lookup library path for 'unitygar', native render plugin support disabled.
07-10 15:49:30.996 1502-1579/com.example.arfoundationsample E/Unity: Unable to find unitygar

07-10 15:49:33.732 1502-1579/com.example.arfoundationsample A/tango: jni_helper.cc:19 'vm' Must be non NULL
07-10 15:49:33.732 1502-1579/com.example.arfoundationsample E/CRASH: signal 6 (SIGABRT), code -6 (?), fault addr --------
    *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
    Build fingerprint: 'google/taimen/taimen:8.1.0/OPM2.171026.006.C1/4769658:user/release-keys'
    Revision: 'rev_10'
    pid: 1502, tid: 1579, name: UnityMain  >>> com.example.arfoundationsample <<<
        r0 00000000  r1 0000062b  r2 00000006  r3 00000008
        r4 000005de  r5 0000062b  r6 cc3fd59c  r7 0000010c
        r8 00000000  r9 cc3fd9f4  sl 0000018d  fp 00000000
        ip 00000000  sp cc3fd588  lr e7dfbc89  pc e7df5772  cpsr cc3fd218
    backtrace:
07-10 15:49:33.736 1502-1635/com.example.arfoundationsample D/NetworkSecurityConfig: No Network Security Config specified, using platform default
07-10 15:49:33.855 1502-1579/com.example.arfoundationsample E/CRASH:    #00  pc 0001a772  /system/lib/libc.so (abort+63)
        #01  pc 0000655d  /system/lib/liblog.so (__android_log_assert+156)
        #02  pc 00009d1d  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libtango_client_api2.so
        #03  il ........  at (wrapper managed-to-native) UnityEngine.XR.Tango.TangoInputTracking.Internal_TryGetPoseAtTime (double,UnityEngine.ScreenOrientation,UnityEngine.XR.Tango.CoordinateFrame,UnityEngine.XR.Tango.CoordinateFrame,UnityEngine.XR.Tango.PoseData&) <IL 0x00026, 0xffffffff>
        #04  il 00000064  at UnityEngine.XR.Tango.TangoInputTracking.TryGetPoseAtTime (UnityEngine.XR.Tango.PoseData&,UnityEngine.XR.Tango.CoordinateFrame,UnityEngine.XR.Tango.CoordinateFrame,double) [0x00015] in /Users/builduser/buildslave/unity/build/Runtime/AR/Tango/ScriptBindings/Tango.bindings.cs:306
        #05  il 00000053  at UnityEngine.SpatialTracking.PoseDataSource.TryGetTangoPose (UnityEngine.XR.Tango.CoordinateFrame,UnityEngine.Pose&) [0x00012] in C:\buildslave\unity\build\Extensions\UnitySpatialTracking\Runtime\TrackedPoseDriver.cs:149
        #06  il 000000fb  at UnityEngine.SpatialTracking.PoseDataSource.TryGetDataFromSource (UnityEngine.SpatialTracking.TrackedPoseDriver/TrackedPose,UnityEngine.Pose&) [0x0009d] in C:\buildslave\unity\build\Extensions\UnitySpatialTracking\Runtime\TrackedPoseDriver.cs:122
        #07  il 00000067  at UnityEngine.SpatialTracking.TrackedPoseDriver.TryGetPoseData (UnityEngine.SpatialTracking.TrackedPoseDriver/DeviceType,UnityEngine.SpatialTracking.TrackedPoseDriver/TrackedPose,UnityEngine.Pose&) [0x00027] in C:\buildslave\unity\build\Extensions\UnitySpatialTracking\Runtime\TrackedPoseDriver.cs:248
07-10 15:49:33.856 1502-1579/com.example.arfoundationsample E/CRASH:    #08  il 0000006f  at UnityEngine.SpatialTracking.TrackedPoseDriver.PerformUpdate () [0x0002e] in C:\buildslave\unity\build\Extensions\UnitySpatialTracking\Runtime\TrackedPoseDriver.cs:412
        #09  il 0000003b  at UnityEngine.SpatialTracking.TrackedPoseDriver.FixedUpdate () [0x0001a] in C:\buildslave\unity\build\Extensions\UnitySpatialTracking\Runtime\TrackedPoseDriver.cs:351
        #10  il 0000006b  at (wrapper runtime-invoke) object.runtime_invoke_void__this__ (object,intptr,intptr,intptr) <IL 0x0001c, 0x0006b>
07-10 15:49:33.859 1502-1579/com.example.arfoundationsample E/CRASH:    #00  pc 000225d3  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libmono.so
        #01  pc 001f7bb8  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libmono.so (mono_runtime_invoke+136)
        #02  pc 00fb72c4  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (ScriptingInvocation::Invoke(ScriptingExceptionPtr*, bool)+84)
        #03  pc 00dc5278  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (MonoBehaviour::CallUpdateMethod(int)+284)
        #04  pc 00a316f8  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (void BaseBehaviourManager::CommonUpdate<FixedBehaviourManager>()+68)
        #05  pc 00a316a0  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (FixedBehaviourManager::Update()+32)
        #06  pc 00d9a368  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (InitPlayerLoopCallbacks()::FixedUpdateScriptRunBehaviourFixedUpdateRegistrator::Forward()+72)
        #07  pc 00d9b0a4  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (ExecutePlayerLoop(NativePlayerLoopSystem*)+96)
        #08  pc 00d9b0f4  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (ExecutePlayerLoop(NativePlayerLoopSystem*)+176)
        #09  pc 00d9b29c  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (PlayerLoop()+284)
        #10  pc 0061b1f0  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (UnityPlayerLoop()+572)
        #11  pc 0061e934  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/lib/arm/libunity.so (nativeRender(_JNIEnv*, _jobject*)+52)
        #12  pc 0000836b  /data/app/com.example.arfoundationsample-3vYJGZ261B_PNlopl_wfqg==/oat/arm/base.odex (oatexec+17259)
    code around pc:
        e7df5750 21064630 f82ef062 46312002 f04f2200  0F.!b.... 1F."O.
        e7df5760 f0620800 4620f82f 22064629 7786f44f  ..b./. F)F."O..w
        e7df5770 f04fdf00 90035080 8004f8cd 1d38af01  ..O..P........8.
        e7df5780 f828f062 46392006 f062463a 2002f82b  b.(.. 9F:Fb.+.. 
        e7df5790 22004631 f816f062 46294620 f44f2206  1F."b... F)F."O.
        e7df57a0 df007786 f062207f 2300f825 b82af062  .w... b.%..#b.*.
        e7df57b0 c008f8df f8dc44fc 4760c000 00077988  .....D....`G.y..
        e7df57c0 4601460a 0063f06f f0622300 0000b823  .F.Fo.c..#b.#...
        e7df57d0 b082b580 4479490c 68096809 46699101  .....IyD.h.h..iF
        e7df57e0 f820f062 48092800 44789900 f04fbf08  b. ..(.H..xD..O.
        e7df57f0 680031ff 9a016800 d1021a80 b002ba08  .1.h.h..........
        e7df5800 f061bd80 bf00fe37 00076bfa 00076be6  ..a.7....k...k..
        e7df5810 b082b580 4479490c 68096809 46699101  .....IyD.h.h..iF
        e7df5820 f800f062 98004601 49082900 f04fbf08  b....F...).I..O.
        e7df5830 447930ff 68096809 1a899a01 b002d101  .0yD.h.h........
        e7df5840 f061bd80 bf00fe17 00076bba 00076b9e  ..a......k...k..
    code around lr:
        e7dfbc68 29002200 2202e9cd 6809d003 a9029102  .".)..."...h....
07-10 15:49:33.860 1502-1579/com.example.arfoundationsample E/CRASH:     e7dfbc78 2100e000 2200e9cd 2308466a fa86f05c  ...!..."jF.#\...
        e7dfbc88 d0043001 9800b10c 20006020 f04fe001  .0...... `. ..O.
        e7dfbc98 490630ff 68094479 9a056809 d1011a89  .0.IyD.h.h......
        e7dfbca8 bd10b006 fbe2f05b 00070770 00070734  ....[...p...4...
        e7dfbcb8 b0a1b5f0 48134606 460d466f 4614217c  .....F.HoF.F|!.F
        e7dfbcc8 68004478 90206800 f05c1d38 f04ffc27  xD.h.h .8.\.'.O.
        e7dfbcd8 900230ff f05b9500 9003fde9 f946f05c  .0....[.....\.F.
        e7dfbce8 0404e9cd 46294630 f05c463a 4906fc1f  ....0F)F:F\....I
        e7dfbcf8 68094479 9a206809 d1011a89 bdf0b021  yD.h.h .....!...
        e7dfbd08 fbb4f05b 00070708 000706d8 b082b510  [...............
        e7dfbd18 48114604 68004478 90016800 f05b4668  .F.HxD.h.h..hF[.
        e7dfbd28 3001fd55 4668d00b f05c4621 3001fa97  U..0..hF!F\....0
        e7dfbd38 4669d005 22002001 fd40f05b f04fe001  ..iF. ."[.@...O.
        e7dfbd48 490630ff 68094479 9a016809 d1011a89  .0.IyD.h.h......
        e7dfbd58 bd10b002 fb8af05b 000706b4 00070684  ....[...........
07-10 15:49:33.862 1502-1579/com.example.arfoundationsample E/MessageQueue: IdleHandler threw exception
    java.lang.Error: signal 6 (SIGABRT), code -6 (?), fault addr --------
    Build fingerprint: 'google/taimen/taimen:8.1.0/OPM2.171026.006.C1/4769658:user/release-keys'
    Revision: 'rev_10'
    pid: 1502, tid: 1579, name: UnityMain  >>> com.example.arfoundationsample <<<
        r0 00000000  r1 0000062b  r2 00000006  r3 00000008
        r4 000005de  r5 0000062b  r6 cc3fd59c  r7 0000010c
        r8 00000000  r9 cc3fd9f4  sl 0000018d  fp 00000000
        ip 00000000  sp cc3fd588  lr e7dfbc89  pc e7df5772  cpsr cc3fd218

        at libc.abort(abort:63)
        at liblog.__android_log_assert(__android_log_assert:156)
        at libtango_client_api2.00009d1d(Native Method)
        at TangoInputTracking.Internal_TryGetPoseAtTime(Native Method)
        at TangoInputTracking.TryGetPoseAtTime(Tango.bindings.cs:306)
        at PoseDataSource.TryGetTangoPose(TrackedPoseDriver.cs:149)
        at PoseDataSource.TryGetDataFromSource(TrackedPoseDriver.cs:122)
        at TrackedPoseDriver.TryGetPoseData(TrackedPoseDriver.cs:248)
        at TrackedPoseDriver.PerformUpdate(TrackedPoseDriver.cs:412)
        at TrackedPoseDriver.FixedUpdate(TrackedPoseDriver.cs:351)
        at Object.runtime_invoke_void__this__(Native Method)
        at libmono.000225d3(Native Method)
        at libmono.mono_runtime_invoke(mono_runtime_invoke:136)
        at libunity.ScriptingInvocation::Invoke(ScriptingExceptionPtr*, bool)(Invoke:84)
        at libunity.MonoBehaviour::CallUpdateMethod(int)(CallUpdateMethod:284)
        at libunity.void BaseBehaviourManager::CommonUpdate<FixedBehaviourManager>()(CommonUpdate:68)
        at libunity.FixedBehaviourManager::Update()(Update:32)
        at libunity.InitPlayerLoopCallbacks()::FixedUpdateScriptRunBehaviourFixedUpdateRegistrator::Forward()(InitPlayerLoopCallbacks:72)
        at libunity.ExecutePlayerLoop(NativePlayerLoopSystem*)(ExecutePlayerLoop:96)
        at libunity.ExecutePlayerLoop(NativePlayerLoopSystem*)(ExecutePlayerLoop:176)
        at libunity.PlayerLoop()(PlayerLoop:284)
        at libunity.UnityPlayerLoop()(UnityPlayerLoop:572)
        at libunity.nativeRender(_JNIEnv*, _jobject*)(nativeRender:52)
        at base.oatexec(oatexec:17259)```
kennethlng commented 6 years ago

I'm gonna guess it's the same issue. Did you try adding a Camera Usage Description? It's required when building out of Xcode (iOS) and I'm assuming it's the same case for Android.

Edit > Project Settings > Player > Other Settings > Camera Usage Description.

You can write in any random text.

renaudbedard commented 6 years ago

I figured it was the case, but no there is no Camera Usage Description field in the Player settings when building for Android.

ghost commented 6 years ago

Hi Renaud,

ARCore 1.3.180604066

Does that mean you are also using Google's ARCore plugin for Unity? "ARCore XR Plugin 1.0.0-preview.17" replaces (and is not compatible with) Google's plugin.

renaudbedard commented 6 years ago

I am not, I just cloned the GitHub repository, ticked the "ARCore Supported" box in the XR Settings, added my ARCoreSettings for good measure, changed the app bundle ID and deployed. The ARCore version I noted here is the redistributable that's installed on the phone (from the Play Store).

ghost commented 6 years ago

ticked the "ARCore Supported" box in the XR Settings

You should not tick this box (it's confusing, I know). In fact, there's a pre build verification step that shouldn't even let you deploy if you have checked this box -- not sure why it didn't get triggered. Try unchecking the box and see if that works for you.

renaudbedard commented 6 years ago

That was the problem! Thanks for the heads-up. There definitely wasn't anything blocking me from deploying with that setting checked though.

ghost commented 6 years ago

The reason it doesn't stop you from deploying is due to a change in 2018.2 (the name of the "ARCore Supported" checkbox changed, so the code that checks whether it is ticked doesn't catch it). That will be fixed in the next ARCore XR Plugin update.

albertoxamin commented 6 years ago

I'm having the same issue when building for iOS even though I did set the Camera Usage Description and Requires ARKit Support

image

ghost commented 6 years ago

@albertoxamin Is this a new project or a clone of this samples repo? What device and Xcode version are you using?

albertoxamin commented 6 years ago

@timj-unity If I clone the repo the Camera Request appears but if I import it through the new package manager or if I simply drag and drop the files into an existing project the issue appears. I am using Xcode 10 build 10L176w

ghost commented 6 years ago

When you say "drag and drop the files", do you mean you are only copying the assets folder? ARFoundation is delivered as a package, so you would also need to copy the Packages folder (specifically the manifest.json) or open the package manager window in your new project and install ARFoundation and ARKit. (Window > Package Manager)

albertoxamin commented 6 years ago

image I did install it through the package manager but I copied the assets to access the sample scene in an existing project

ghost commented 6 years ago

Your screenshot shows you've only installed ARFoundation but not ARKit support. ARKit should be available from the "All" menu.

albertoxamin commented 6 years ago

That did fix it, thanks

TevfikUfuk commented 6 years ago

I am using Unity 2018.2 and Samsung S8. I have this exact black screen issue when I run the app. How can I fix this?

TevfikUfuk commented 6 years ago

I think I found the problem. I build the codes inside PlacedObjectFix brach and it worked. But inside this project I updated ARFoundation and ARCore. Then I got a building error saying that:

BuildFailedException: ARCore XR Plugin does not support x86. See Player Settings > Other Settings > Target Architectures.

UnityEditor.XR.ARCore.ARCorePreprocessBuild.EnsureTargetArchitecturesAreSupported () (at C:/Users/tevfik_demirbas/AppData/Local/Unity/cache/packages/packages.unity.com/com.unity.xr.arcore@1.0.0-preview.18/Editor/ARCoreBuildProcessor.cs:34) UnityEditor.XR.ARCore.ARCorePreprocessBuild.OnPreprocessBuild (UnityEditor.Build.Reporting.BuildReport report) (at C:/Users/tevfik_demirbas/AppData/Local/Unity/cache/packages/packages.unity.com/com.unity.xr.arcore@1.0.0-preview.18/Editor/ARCoreBuildProcessor.cs:25) UnityEditor.Build.BuildPipelineInterfaces+cAnonStorey0.<>m1 (IPreprocessBuildWithReport bpp) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/BuildPipelineInterfaces.cs:376) UnityEditor.Build.BuildPipelineInterfaces.InvokeCallbackInterfacesPair[IPreprocessBuild,IPreprocessBuildWithReport] (System.Collections.Generic.List1 oneInterfaces, System.Action1 invocationOne, System.Collections.Generic.List1 twoInterfaces, System.Action1 invocationTwo, Boolean exitOnFailure) (at C:/buildslave/unity/build/Editor/Mono/BuildPipeline/BuildPipelineInterfaces.cs:356) UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()###

Then, I unchecked x86 in Player Settings. After I build, black screen issue showed up again.

ghost commented 6 years ago

@ufktvfk You should not use the PlacedObjectFix branch (I've removed it now), and ARCore is not supported on x86 Android phones, so the build error is correct in that case.

Are you git clone'ing this repo and running it without modification, or are you trying to copy it into an existing project?

TevfikUfuk commented 6 years ago

I downloaded this project as zip file and then open it via Unity(2018.1.5f). When I build to my phone(Samsung S8), it compiles but didnt ask for camera permission. It is just a black screen. When I go for app settings, I see that camepare permission is not given. I gave this poermsssion manually and open the app again. But this same black screen issue continues.

TevfikUfuk commented 6 years ago

My issue still exists. When I deploy the app to my Android device ( Samsung S8), I got a black screen. I am trying to update my Udemy course with AR Foundation so this problem is really critical for me.

TevfikUfuk commented 6 years ago

Maybe it is realted to only my phone. Is there any possiblity that someone can try with S8?

ghost commented 6 years ago

@ufktvfk Same issue here but on a Pixel XL. Cloned repo and I only get the camera background colour. Compiles and deploys without asking for camera permission. As in your case manually adding camera permission does nothing.

tdmowrer commented 6 years ago

@ufktvfk @Collision11 Are you sure you also have the ARCore XR Plugin from the package manager? That would explain why you don't get prompted for camera permission. And you've just cloned this repo without making any local changes?

We've tested on an S8 and Pixel XL and they both work as expected here.

ghost commented 6 years ago

@tdmowrer yes, both ARCore XR and Foundation plugins are in project. Straight up clone, build and run. Running 9.0 on the Pixel.

Edit: Enabled development build, deployed and was prompted for camera permissions. Functioned normally after this. Wiped from device, disabled dev build and redeployed attempting to recreate issue but once again prompted for permissions and functioned normally.

tdmowrer commented 6 years ago

@Collision11 Anything interesting from adb logcat? adb logcat Unity:* Unity-ARCore:* ArPresto:* *:S

ghost commented 6 years ago

@tdmowrer Yeah this is something on my end, tried to build out on desktop just now and same issue. Built out on laptop last night and was ok (but was interesting I had to enable dev build, first build didn't work).

logcat

08-21 17:29:56.946 14916 14934 E Unity   : Unable to find UnityARCore
08-21 17:29:57.082 14916 14934 E Unity   : DllNotFoundException: UnityARCore
08-21 17:29:57.082 14916 14934 E Unity   :   at (wrapper managed-to-native) UnityEngine.XR.ARCore.Api:UnityARCore_setCameraPermissionProvider (UnityEngine.XR.ARCore.Api/CameraPermissionRequestProvider)
08-21 17:29:57.082 14916 14934 E Unity   :   at UnityEngine.XR.ARCore.ARCoreCameraExtension.Register () [0x00000] in <filename unknown>:0
08-21 17:29:57.082 14916 14934 E Unity   :
08-21 17:29:57.082 14916 14934 E Unity   : (Filename:  Line: -1)
08-21 17:29:57.082 14916 14934 E Unity   :
tdmowrer commented 6 years ago

@Collision11 I've seen that before when you also have the GoogleARCore plugin in your project (this conflicts with the ARCore XR Plugin package). Is that the case?

ghost commented 6 years ago

@tdmowrer I have compiled builds previously on problem (desktop PC) system using ARCore, but current project is a straight clone from this repo, and I have not added anything from the Google repo. Can't be the device, because I can build to it functionally using the same cloned repo (this) on my macbook.

image

TevfikUfuk commented 6 years ago

I opened an empty project and install AR Foundation- ARCore XR- ARKit XR. Then I created a scene and put AR Session and AR Session Origin and deployed to my phone Samsuns S8. It didnt work. The same issue.

Also, I get a fresh copy of this repo but this time it is worked. Strange.

MichaelMilstead commented 6 years ago

Same problem here with "Unable to find UnityARCore". This started happening after I used ARCore in a different project, but I haven't added ARCore to the project that this error is happening on.

tjudemon commented 6 years ago

still got whole black screen!!

TevfikUfuk commented 6 years ago

I still have this problem too

tdmowrer commented 6 years ago

Hi folks,

We've been unable to reproduce this issue. Could you please submit a bug report and include a project which reproduces this issue (I know you've said this repo causes it, but there must be a variable we're missing).

Please post the case id here so I can find it faster.

-Tim

TevfikUfuk commented 6 years ago

Hi,

I submitted a bug related to this issue. Case id is 1078142.

tdmowrer commented 6 years ago

@ufktvfk Thank you; I've responded to your case. The project you attached doesn't include ARFoundation; did you mean to send me something else?

TevfikUfuk commented 6 years ago

Hi Tim, Sorry about that. Here is the new and correct bug report case id : Case 1078262

mobiius commented 6 years ago

I'm having the same issue with my Samsung S8. I created a new lightweight render pipeline project, removed the example assets, added an AR Session, AR Session Origin, and AR Default plane, installed AR Foundation 1.0.0-preview-17, ARCore 1.0.0-preview-18, and ARKit 1.0.0-preview-14 from the package manager. I don't get any warnings, errors or logs when building to device. (After I originally has x86 mode turned on, vulkan selected as default API and multithreaded rendering turned on.)

I build and get a black screen. (Everything still works however, I can scan for surfaces and tap to raycast the found surface.)

mobiius commented 6 years ago

Just to add to my above comment, I have another project which uses AR Foundation and it runs perfectly fine on my S8. I rolled back the component versions in my new project to match what works in my other project, (AR Foundation 1.0.0-preview-12, ARCore 1.0.0-preview-16, and ARKit 1.0.0-preview-11) and it still doesn't work in my new project. I thought it could be due to the scriptable render pipeline, but in the image that Collision11 posted above, they don't seem to be using it.

tdmowrer commented 6 years ago

@mobiius ARFoundation will not render the camera background when using the lightweight render pipeline (LWRP), so that is almost certainly your issue. We are working on LWRP compatibility, and it should be supported in the next ARFoundation release.

mobiius commented 6 years ago

What about the HDRP or should I switch back to the normal shaders? Will ARFoundation be updated quickly enough that I can keep things as they are in the mean time?

tdmowrer commented 6 years ago

@ufktvfk Is your S8 from China? According to Google's supported device list, only two manufacturers are supported in China (Xiaomi & Huawei), and I believe the Huawei P20 requires you to manually install ARCore from the Huawei Apps Gallery.

The "am I supported" check in ARFoundation requires a connection to the Play Store if ARCore is not already installed on the device, which does not work in China if I understand correctly.

tdmowrer commented 6 years ago

@mobiius

What about the HDRP or should I switch back to the normal shaders?

None of the scriptable render pipelines currently work with ARFoundation, only the legacy pipeline.

mobiius commented 6 years ago

Will ARFoundation be updated quickly enough that I can keep things as they are in the mean time? Are we talking days, weeks or months?

Thanks for the help so far BTW. :)

tdmowrer commented 6 years ago

Will ARFoundation be updated quickly enough that I can keep things as they are in the mean time? Are we talking days, weeks or months?

Our release cycle is completely decoupled from the rest of Unity, and I believe LWRP support is being QA'd, so it should be within a couple weeks I would say.

Thanks for the help so far BTW. :)

You're welcome! Thanks for being an early adopter :)

mobiius commented 6 years ago

should be within a couple weeks

Good to know, thanks. :)

mobiius commented 6 years ago

Oh, I now have a working scene, I just removed the LWRP profile from the Scriptable Render Pipeline Settings option and the camera now renders. When the fix has been implemented, i'll re-add the profile. :)

nathansisler commented 6 years ago

I was getting the black screen on Pixels and just rolled back my AR Foundation package to preview 14 and ARCore XR plugin to preview 16. Working now