Cannot get simple beginners app to work on tablet using the latest version of Unity - unity3d

I am new to unity 2021.2.10f and I have become stuck on getting a simple app working on a tablet /real hardware.
I am using unity 2021.2.10f my project is simply the built in
"3D Sample Scene(URP)" I did not change anything to it except added an icon to it (so I can see it in the tablet menu when it is installed on the android tablet)- the unity project can easily be
recreated-I could not upload it since it the project was large (more than 350MB) for my internet connection.
This is how the the unity project looks on my computer
enter image description here
When I compile this to an android apk I just get a pink/magenta screen (as shown below).
enter image description here
I also get the message below from the tablet.
enter image description here
After googling around for an answer I found out
this pink/magenta screen means it is a shader problem.After more googling for an answer it was recommended to tick or untick to reset the
~"Auto Graphic API" as a fix-but this did not work for me.
I also changed the color space from Gamma to linear-and again this did not work for me. My tablet is a Maitai MT107.
So my question is -how do I get this to work?
In previous years and using older versions of unity I have been able to get unity made apps to work perfectly on several different tablets (though not an MT-107).
Also the compiled version of this project does not
work in latest version of Bluestacks on Windows 10-it shows a blank black screen instead of a pink screen-may be it is related to that-
maybe if I can get it to work with the Bluestacks emulator it will work on real hardware-but I do not know what exactly the problem is that is stopping the app working on the MT107.

I figured it out using Shingo's comments.
My tablet only supports GL ES2 because
I ran CPU-Z to find that out.
I made a simple test program (just the default empty project with the blue sky) with
unity 2020 (NOT the latest version) when GL ES 2 is selected.
Here is the gotcha-it looks like ES2 was removed in the latest version
of Unity 2021.2.10f-but it can be selected in the following way.
I started off by making my test program in unity 2020 save and closed the project. I selected GLES 2, as shown below,in this older version of unity (NOT using "Auto Graphic API")
Then I re-opened it, this makes unity convert the project so it
works in the latest version of unity 2021.2.10f-then I can see the GLES 2 (depreciated) appears in the
latest version of Unity. The GLES2 option circled in blue shown below
-GLES 2 support does not appear in the project if the project is not converted from the older version of unity.
Now I can use the latest version of unity to use with a tablet that supports
only GLES 2 by adding to the empty test program to eventually write my complete program.
I am happy I can still use my tablet with unity because: it wasn't cheap to
buy and bought this year, if it works on this tablet it will work on a GLES3 tablet (because of backwards compatiability).

Related

Vuforia & Unity: Build UWP Successfully but No Live Camera Feed (Black Screen)

Unity Version: Unity 2019.3.9f1
Vuforia Version: 9.0.12
The app works fine in unity editor, it builds and runs successfully without error but no camera feed (black screen). Can't seem to find up to date solutions online.
Updated the Vuforia version to 9.2.7 does not seem to solve the problem.
I don't think to check the "Vuforia Augmented Reality Supported" under the "XR Settings" is an option, because it's able to deprecate. Also Checking the "Windows Mixed Reality" plug-in under XR Plug-in Management didn't solve the problem.
I already checked the "InternetClient" and "WebCam" in the publish setting for UWP.
Do I need to change anything in ARCamera's "Open Vuforia Engine configuration"? Some solutions mention disabling the Vuforia play mode will help, but I can't seem to find the option anywhere.
Anyone encountered the same issue and find a solution? Thanks.
I don't have a current solution, but would like to share my experience working with vuforia, UWP.
I found that there are varying breaking versions of unity and vuforia's SDK.
The latest version may not necessarily work I had to trial and error before I found a compatible version, so you might want to try that out. perhaps a older version of either unity/vuforia in reference with https://library.vuforia.com/platform-support/supported-versions.html
And yeah, definitely run your "hello world" tests on the sample projects first.
Best of luck, it's a great SDK ,once you get it to work.

Hololens 1 does not detect air tap or other gestures in MRTK scene

I am currently working on developing an application for the Hololens 1 using Unity and MRTK.
I have been unable to get the air tap or any other input working in my application. The ring pointer for airtap does not appear in the application even though it works in the Unity Play Mode Input Simulation and other applications on the device. I tried it with the MRTK examples and even those did not work on the device.
Also I had to add the Tracked Pose Driver from the Player Settings to get the camera working properly but have not figured out how to get the application to accept gesture input.
Also tried the solution listed here: Why is 'air tap' gesture not working on HoloLens1 in my Unity/MRTK app?
but that did not work.
Will appreciate any guidance to solve this problem.
I finally got my project working after a lot of trying.
It turned out that initially, I had unknowingly configured the project to use XR SDK in Unity 2019 and thus had to configure MRTK accordingly. Thank you to Kevleigh for helping me with the issue here: https://github.com/microsoft/MixedRealityToolkit-Unity/issues/7850
While this did work for my example project, I couldn't get the main project to work with the same settings even after installing all the plugins.
Finally, I had to switch to Unity 2018 and I got the project working with MRTK 2.3 and the default configuration. So, while Unity 2019 did not work for me you can get it working with XR SDK as suggested in the above link.

Hololens Unity app always deploys in 2D instead of 3D

I'm developing an app for the Hololens 1 in Unity, and it runs perfectly fine on the device when using Holographic Remote. However whenever I build and deploy the application through Visual Studio, it then only launches in 2D mode on the Hololens (as a flat "window" you can position in space). What settings control this behaviour?
Unity version is 2019.1.4f1,
Visual Studio is 2017 Community Edition,
I'm on Windows 10.
Developer mode is turned on on both the HL and my desktop. Virtual Reality Support is ticked in Unity, the Mixed Reality SDK is added to the list and the Build settings are on x86 / D3D Project.
I tried replacing my scene with one of the examples from the MRTK, but to no avail. Strangely enough, if I make a clean new project with nothing except the MRTK example in it it does deploy properly, so there must be something in my project interfering. I just can't figure out what.
Expected behaviour is that the application launches in "room scale" mode, i.e. all other applications disappear and the objects in my scene can be viewed in 3D.
EDIT: This has been marked as a possible duplicate. The answers given there do not solve my problem, however. I already made sure that "Virtual Reality Supported" is ticked in the XR settings and the SDK is added to the list. I don't think I have a Windows Insider preview, but since I was able to deploy perfectly fine with a fresh project I don't think that's really the problem...
It appears Vuforia was causing the issues. I got it to deploy in 3D with 'Vuforia Augmented Reality Supported' ticked and the following settings in VuforiaConfiguration:
Camera Device Mode: MODE_OPTIMIZED_SPEED
Device Type: Digital Eyewear
Device Config: Hololens
Video Background DISABLED
Device Tracker DISABLED
Furthermore, 'Vuforia' must not be added to the list of Virtual Reality SDKs in XR Settings.
Note that I have not tried all subsets of these settings individually, some of them might not have an impact whatsoever (except for the last one, I am quite certain adding that SDK will force the app into 2D mode).
Also note that I haven't verified that Vuforia actually works correctly on the Hololens, just that I can deploy the app in 3D mode with it enabled, given the above settings. If someone could confirm that Vuforia is even supported by MRTK v2?
EDIT: apparently the problem is also caused by ticking "WSA Holographic Remoting Supported" in the XR Settings, so be sure to disable that.

Unity crashing with DirectX on new computer

I have recently purchased a new computer :
https://pcandparts.com/hp-gaming-laptop-power-15-cb005ne-acid-green/
And I have installed Unity on it. The problem is that every time I try to move the layouts unity screen becomes black and freezes.
https://gyazo.com/fdbbba09cbee7005b1b55637cea19855
After trying to search online, post on multiple forums, contacting Unity Team and Nvidia support I have found that the only solution is running unity from the command using -force-glcore
In fact, Nvidia support have been unable to find the solution and Unity Team was stressing that I update my graphic drivers and Directx version however both of them are latest versions and so is Windows 10.
https://gyazo.com/ee810b7d18be7580d3703e42c7b46526
https://gyazo.com/ea751dcf39ebfc791f2dce59cd219a0c
https://gyazo.com/d43718cc693a7c9cac44f4924bf968da
This is the latest email I have received from Unity Team :
https://gyazo.com/df2d7e960484cd8c682e5b733860e935
as well as the link for unity forum that also includes the error and editor logs:
https://answers.unity.com/questions/1511848/unity-editor-crash-2.html?childToView=1512288#comment-1512288
I also tried multiple versions of Unity from 2017 and 2018.
I will provide any additional information needed.
How can I solve the problem so I can run Unity smoothly and without having to go to force-glcore ? And what is truly happening?
Thank you in advance for taking the time to read
How can I solve the problem so I can run Unity smoothly and without
having to go to force-glcore ?
There are other things you can try.
1.Use DirectX9 instead of DirectX11. The default on the new Unity verions is DirectX11.
Go to File ---> Build Settings... ---> Player Settings ---> Other Settings then un-check the Auto Graphics API for Windows API checkbox. From there drag and move Direct3D9 above Direct3D11 click Apply and restart the Unity Editor.
If Direct3D9 is already above Direct3D11 then move Direct3D11 above Direct3D9.
2.If #1 doesn't work, try other graphics API. You can try other 3 graphics API such as Direct3D9, Vulkan and OpenGL Core.
These are hidden and you must click the + sign then manually add them to the menu then drag them to the top.
Then you can chose which one to add and then drag them to the top to force Unity use them.
Once of these should work for you. Chose the one that works the most. You don't need -force-glcore when opening Unity to use this. Your issue is mostly a driver issue sometimes, a workaround like this solves it until the driver is fixed.

Google VR SDK for Unity - Reticle not aligned

I've been working with the Google VR SDK for Unity but I've run in to some weird issues with adding a reticle, specifically using the GoogleVR prefab GvrReticle. Up until a couple weeks ago the reticle was lined up and looking fine in my projects but now I can't seem to get the reticle to work properly, both installed on device(iPhone or Android) or in the Unity preview mode. It appears slightly misaligned so that when you wear the device in it's headset you will get two dots instead of one reticle.
Even in a sample project that just includes the SDK and the barebones necessary for a reticle the result is the same(a double-vision reticle).
Has anyone else run into this problem or would know what might possibly be causing it?
I'm using the latest versions Unity(5.4.1f1) and googleVR(unity sdk v0.9.1) and I've tried doing builds on both PC and Mac with seemingly the same results. I've uploaded a sample project here: https://dl.dropboxusercontent.com/u/64965870/ReticleSample.zip
Had the same problem, solved with the new GoogleVR SDK Ver 1.10 (https://github.com/googlevr/gvr-unity-sdk)
try and replacing the current SDK with the newest, it's pretty easy to replace.