Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
DuplicateEditorMesh performance issue
#5
Hi _Aka_!

Thanks so much for your answers!

I should have added more markers to this Awake method, I was pretty sure that FindObjectsOfType was taking all the time, but I forgot all the things done in the Unity operators!
(but I think FindObjectsOfType will still garbage a lot. I still need to verify before saying wrong things again!)

The issue was happening when opening a scene, or switching back from play to edit mode.

I didn't modified Curvy heavily, just commented a line (and maybe that's the cause of the issue I realize that now, but I really think I have 700 legit DuplicateEditorMesh in my scene):


Code:
            if (firstChanged != null)
            {
#if UNITY_EDITOR
                DEBUG_ExecutionTime.Stop();
                if (!Application.isPlaying)
                {
                    // >>>>>>>>>> COMMENTED THIS LINE, because calling that from every Generator was showing it in the profiler, like a lot (I don't remember the duration)
                    //EditorUtility.UnloadUnusedAssetsImmediate(); //OPTIM is this necessary? It was added in changeset SHA-1: 4b04d2ea947cdb84fdc45f07f3e5cbf7b9531c94
                }
#endif
                OnRefreshEvent(new CurvyCGEventArgs(this, firstChanged));
            }
Reply


Messages In This Thread
RE: DuplicateEditorMesh performance issue - by Guillaume - 01-17-2022, 02:15 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Spline Issue Leading to Unity Freeze Pankaj09 1 379 08-24-2026, 11:28 PM
Last Post: _Aka_
  Connecting Multiple Spline Nodes Issue Ritesh Kadam 1 330 08-22-2026, 11:24 PM
Last Post: _Aka_
  Any performance 'hacks' for scene with lots of splines rickgplus 1 2,244 03-18-2025, 10:11 PM
Last Post: _Aka_
  Rasterized Path Range issue proton 7 5,330 04-30-2024, 11:17 AM
Last Post: _Aka_

Forum Jump: