Search Unity

TextMesh Pro Loading font material in Editor script

Discussion in 'UGUI & TextMesh Pro' started by alchemyincarnate, Feb 5, 2020.

  1. alchemyincarnate

    alchemyincarnate

    Joined:
    Feb 25, 2014
    Posts:
    10
    Hello

    The gist is I'm having performance issues when loading font material and setting it to fontSharedMaterial on an Editor script. It becomes very laggy to navigate the inspector for the particular object where I load the material onto.

    Other details:
    - it seems to be using an instance of the material (unlike if you set it via inspector material preset)
    - it fixes itself if I change the preset to another material via inspector (not code), then change it back manually (again via inspector, but this is not what I want)
    - it works fine during runtime no matter how many materials I load set via fontSharedMaterial
     
  2. alchemyincarnate

    alchemyincarnate

    Joined:
    Feb 25, 2014
    Posts:
    10
    bump, do let me know if there is any other info needed
     
  3. Stephan_B

    Stephan_B

    Joined:
    Feb 26, 2017
    Posts:
    6,595
    Since some of these cases are hard to reproduce, could you please submit a bug report with the include project to allow me to easily reproduce / take a look at the behavior?

    Please provide me with the case # once Unity emails it to you.
     
    alchemyincarnate likes this.