Our project is being haunted by a very inexplicable bug and we're having a hard time establishing a cause.
Building to Android (minimum API 7.1, target API 'automatic') produces a black screen. No camera feed, no UI elements, no nothing. The cameras clear flags are set to Solid Color (blue). Strangely enough, this only happens when certain conditions are met and not at other times, and there seems to be very little pattern-wise to go on. For example, it doesn't happen on a certain commit, but it does on the following commit. The only file changes between those commits include minor script changes that don't have anything to do with AR or cameras.
Any clues regarding what could cause this would be greatly appreciated, we've tried a lot of different settings configurations (turning off Auto Graphics API, Multithreaded rendering is off, etc).
Using two different 1st generation Pixels and Unity 2018.1.0b11
Hi, it's not easy to help with your description of the issue. Could you repro on the simplest possible project that you could share with me? And attach logs from logcat when the issue happens.
logcat.txt
I have a logcat of the very same issue
Thanks for attaching the logcat, I think it's really useful. I added it to our internal tracking to fix it.
Hi, this issue has been fixed in ARCore Unity SDK v1.2.0. Feel free to reopen if you still experience the issue.
Hi All,
So first of all thank you 1.2 fixed the error for me on Unity 2018.1, Android 8 with scripting runtime on .net 3.5. Unfortunately yesterday we had to upgrade to .net 4.0 and the screen goes black again. Tried again creating a fresh Unity project, imported 1.2 sdk, set the scripting runtime to .NET4.x, and the issue came back. Attaching a logcat as well.
Csaba
logcat.txt
Hey,
On Unity 2018.1 this problem (black camera image(no update), ARCore manager can't enable session, session status is "None", other elements are ok) still occurs on scripting runtime .NET 4.X
(.Net 3.5 seems to be working).
@hofcsabaGit tested it on 1.2.
I have tested it on 1.2.1 - still the same.
public void EnableSession()
{
// ...
SetConfiguration(SessionComponent.SessionConfig);
// on .NET 4.X never got logs below
Debug.Log($"{this.GetType()} configuration done!");
ExternApi.ArPresto_setEnabled(true);
Debug.Log($"{this.GetType()} enabled!");
}
Most helpful comment
Hi All,
So first of all thank you 1.2 fixed the error for me on Unity 2018.1, Android 8 with scripting runtime on .net 3.5. Unfortunately yesterday we had to upgrade to .net 4.0 and the screen goes black again. Tried again creating a fresh Unity project, imported 1.2 sdk, set the scripting runtime to .NET4.x, and the issue came back. Attaching a logcat as well.
Csaba
logcat.txt