Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

TextMesh Pro TextMeshPro Stopped working on Android 5 after upgrading to Unity 2018.3

Discussion in 'UGUI & TextMesh Pro' started by Elestin, Dec 24, 2018.

  1. Elestin

    Elestin

    Joined:
    Apr 8, 2015
    Posts:
    10
    Hi,

    I use a lot of TextMenshProUGUI element in my project. It worked fine until I upgraded my project to 2018.3. Now texts are showing on Android 6 and 7 devices, but not showing on Android 5 device. I couldn't find any solution. What could be the reason?

    Thanks
     
  2. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    6,588
    Are you getting any errors or is it just that the text is not showing up?
     
  3. Elestin

    Elestin

    Joined:
    Apr 8, 2015
    Posts:
    10
    No i don't see any errors on logcat

    Edit: I get "Unable to find kernel32" on all android devices, but it doesn't cause any problems that I noticed
     
    Last edited: Dec 25, 2018
  4. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    6,588
    What version of Unity did you upgrade from?

    What version of TextMesh Pro are you using?

    If you create a new empty project and build one of the example scenes included with TMP, does the text render correctly?
     
  5. Elestin

    Elestin

    Joined:
    Apr 8, 2015
    Posts:
    10
    Thanks for the suggestion, I recreated the problem with a new project. The problem is TextMeshProUGUI is showing when using its default font asset Liberation Sans SDF but it doesn't work with another font asset that I created.

    Previous Unity version: 2018.1.11 (not exactly sure)
    Current Unity version: 2018.3.0
    TMP version 1.3.0
     
  6. Elestin

    Elestin

    Joined:
    Apr 8, 2015
    Posts:
    10
    Okay I think I solved the problem. The reason is that the shader of the LiberationSans SDF Material is TextMeshPro/Mobile/DistanceField, however the shader of the newly created font asset is TextMeshPro/DistanceField, so I changed it and it worked. But I couldn't find a solution to create the font asset with the correct shader. So I have to change it for every TextMeshPro I have. (This is the case with the new test project.)

    I couldn't test it on my real project yet. I will update here if anything different happens.

    I hope this helps to other people in case they have this problem.

    @Stephan_B thank you for the help.
     
  7. Elestin

    Elestin

    Joined:
    Apr 8, 2015
    Posts:
    10
    I tested it on my project, and I saw that some of the shaders were correct some were wrong. In this case I couldn't find any other solution than regenerating the font assets. So I updated them with "Update Atlas Texture" and everything works fine now.
     
  8. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    6,588
    When font assets are created, the default material embedded (sub asset) uses the full features Distance Field shader. This can be changed on the individual font assets by selecting (double click) this embedded material in the inspector and changing the shader it is using.

    As to why this behavior occurs, I guess when selecting Android 5, it also limits what shader model can be used. The mobile distance field shader has lower requirements than the full distance field shader.