Search Unity

  1. We are migrating the Unity Forums to Unity Discussions by the end of July. Read our announcement for more information and let us know if you have any questions.
    Dismiss Notice
  2. Dismiss Notice

Question Shader error in 'TextMeshPro/Mobile/Distance Field': undeclared identifier

Discussion in 'Editor & General Support' started by richlv, Oct 25, 2023.

  1. richlv

    richlv

    Joined:
    Apr 26, 2023
    Posts:
    3
    Attempting to use a non-game project, https://github.com/mjstarrett/Landmarks (LM).

    LM currently is configured against an 2019.4.29f1, tried to use with the latest LTS version in that branch, 2019.4.40f1 - got errors upon build:

    Code (csharp):
    1. Shader error in 'TextMeshPro/Mobile/Distance Field': undeclared identifier '_Sharpness' at line 140 (on metal)
    2. Shader error in 'TextMeshPro/Mobile/Distance Field': undeclared identifier '_Sharpness' at line 140 (on glcore)
    Searched around, but without programming or Unity knowledge didn't get anywhere.
    Is there any hack or solution to allow the build to proceed?
     
  2. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    7,004
    Try using the specific Unity version the project was targeted at. Be sure to use a clean repository, do NOT downgrade the existing project. If the errors persist, open an issue on the github repository and hope the developer responds in due time.

    Note: you did not specify the platform you are trying to build for, nor does the repository mention (un)supported platforms. Both are important to know.
     
  3. richlv

    richlv

    Joined:
    Apr 26, 2023
    Posts:
    3
    Thank you so much for the response. Using the original version is in the plans, just not sure whether migrating scene to an older version will work.

    Had created https://github.com/mjstarrett/Landmarks/issues/17 , but not sure anybody would have a chance to help - any workarounds would be appreciated (if the older version would not help).

    Tried to build for Mac, not sure about the other versions - is that something the project would have to explicitly declare?
     
  4. richlv

    richlv

    Joined:
    Apr 26, 2023
    Posts:
    3
    Yay, they replied that older version of the LTS branch might help - will attempt to migrate the scene.