Search Unity

TextMesh Pro Performance oddity

Discussion in 'UGUI & TextMesh Pro' started by Bosozuki, Jan 9, 2021.

  1. Bosozuki

    Bosozuki

    Joined:
    Dec 19, 2013
    Posts:
    63
    Have an oddity in terms of performance with text mesh pro.

    Setup:
    Unity 2020.2
    URP 10.2.2
    Textmesh pro 3.03

    Standard empty scene (directional light and Camera)

    I noticed a drop of roughly .5 to .7 ms in terms of performance after the the TextMesh Pro essential resources are added to the project.

    After drilling down through the profiler for a while it looks like when using URP text mesh pro adds camera stacking. i.e. an additional hidden camera to the scene. From what I can tell this is the only difference I can see.

    Is this intended? If so is there a way for us to remove the second camera and use a render pass instead? Or am I misinterpreting the profiler and something else is happening?

    Thanks
     
  2. Bosozuki

    Bosozuki

    Joined:
    Dec 19, 2013
    Posts:
    63
    I am misinterpreting the profiler it is not second camera causing the performance drop. I will keep searching and update
     
  3. Bosozuki

    Bosozuki

    Joined:
    Dec 19, 2013
    Posts:
    63
    So I found it.

    Long story short there is no issue with performance

    I was able to reproduce the performance drop.

    Steps

    Profile empty scene everything is normal

    Add a 3d text mesh pro object to the scene

    Profile scene with object, tiny performance as expected

    Delete 3d text mesh object

    IMPORTANT do not save the scene

    Profile scene without object and the performance is the same as if the text mesh pro object is in the scene

    Save the scene

    Profile of the scene is back to empty scene.


    So remember folks do not be like me, save your scene then profile