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

TextMeshPro TextMeshProUI Material Issue

Discussion in 'UGUI & TextMesh Pro' started by allpublic, May 15, 2021.

  1. allpublic

    allpublic

    Joined:
    Nov 10, 2020
    Posts:
    13
    Hey Guys

    I read here that I have to create a new Material for different TextMeshPros.
    I tried it but the text is still invisible.
    What I do wrong?
    Bildschirmfoto 2021-05-15 um 04.52.19.png Bildschirmfoto 2021-05-15 um 04.52.17.png Bildschirmfoto 2021-05-15 um 04.46.47.png
     
  2. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    6,588
    I can't really tell what is going on since none of your images show the material inspector of the text object. Please post an image of the text object along with material inspector with the debug portion of the material inspector visible.

    When geometry shows those pink squares / circles, it is indicative of the material not having a shader assigned to it or shader with compiler errors.

    What is the specific issue that you are having? Is it the pink quads from the first image or the missing text from the third image?
     
  3. allpublic

    allpublic

    Joined:
    Nov 10, 2020
    Posts:
    13
    Hey Stephan,

    thanks for taking a look.
    The specific issue is, that I'm missing the text. To see on the third image.
    Im using a UI canvas where I have the TextMeshProUI I use the NOTO fonts there.
    I tried to make a new material for the NOTO fonts so the conflict get solved. But it doesnt worked out.

    On the first picture one of the UI texts with NormalNotoSans Atlas Material. With Debug Settings on the second picture.

    On the third and forth picture from the text in worldspace where I created and use the Albanien Atlas Material.

    The Fonts have still fallback fonts where they reference each other.

    Bildschirmfoto 2021-05-15 um 19.09.52.png Bildschirmfoto 2021-05-15 um 19.09.31.png
    Bildschirmfoto 2021-05-15 um 19.08.54.png Bildschirmfoto 2021-05-15 um 19.08.37.png
     
  4. allpublic

    allpublic

    Joined:
    Nov 10, 2020
    Posts:
    13
    I think my issue is, that I don't know how to choose the new material preset that I copied.
    In the Material Preset options is only one selectable.
    I also can not drag and drop the new preset in to the TextMeshPro.
    Also I can not drag and drop the new preset in the Text Asset. Bildschirmfoto 2021-05-16 um 13.49.19.png Bildschirmfoto 2021-05-16 um 13.49.02.png Bildschirmfoto 2021-05-16 um 13.48.47.png
     
  5. Stephan_B

    Stephan_B

    Unity Technologies

    Joined:
    Feb 26, 2017
    Posts:
    6,588
    Due to the AssetDatabase not providing reverse dependencies. Meaning show me all the material that use Texture X, some naming convention is used to find material presets for a given font asset.

    This naming convention requires that each material preset have the same name prefix as the font asset. For instance, if the font asset is named "Arial SDF" then material preset for it should be called "Arial SDF - xxx" where xx is whatever will allow you to differentiate it. For example: "Arial SDF - Outline", "Arial SDF - Outline & Shadow", etc.

    Following the above naming convention will result in those presets being visible in the Material Preset pulldown options.
     
    allpublic likes this.
  6. allpublic

    allpublic

    Joined:
    Nov 10, 2020
    Posts:
    13
    Thank you so much Stephan! This worked out!

    Bildschirmfoto 2021-05-21 um 20.00.49.png