steve3003 / unity-profiler-data-exporter

Utility to export data from the unity profiler
MIT License
123 stars 29 forks source link

DrawCall count #7

Closed resetme closed 5 years ago

resetme commented 5 years ago

Hi,

I have done a very similar tool that create a json file, it also compare many profiler using unity editor or web angular. is really helpful! In my tool I also have total average FPS, and today I was trying to add total average DrawCall but my code always give me 0 draw calls.

I google for some similar tools and I found this one, i checked the json export and the draw call value is 0 or N/A as well.

Any idea why we can't get the draw call count?

bbi-dennindalke commented 5 years ago

Did you check if you have the GPU profiler enabled and the Graphics Jobs feature disabled? Sometimes the Graphics jobs make the profiler unable to capture rendering data.

steve3003 commented 5 years ago

Yeah it looks like you need to have the GPU profiler enabled to get the DrawCalls column from ProfilerProperty. You could use ProfilerDriver.GetOverviewText(ProfilerArea.Rendering, frameNumber) to get the text shown on the rendering profiler instead and parse that to get the draw calls without enabling the GPU profiler.