Profiling an actor's cpu gpu cost

How can I profile an actor’s cpu and gpu cost?

I want to know how many spend the time for drawing that actor.

And how many the time for cpp logic, like tick function ; cpu.

Also Is there any way? Somthing like,
make trace point in cpp function and computing how long does it takes for execute that function.

Any answer will be good for me.

Hey,

Unreal Insights is probably the best tool for this, heres the link to the Reference Page - Unreal Insights Reference | Unreal Engine 4.27 Documentation | Epic Developer Community

In this talk I go over some of the basic of using Insights and adding C++ Scope events to determine th time your logic is taking - https://www.youtube.com/watch?v=KxREK-DYu70

1 Like

Thanks a lot.
Maybe I should learn to use Unreal Insights deeper.
I heard that theres a lot of command options for execute Unreal Insights.
Perhaps do you happen to know about that?

Unreal Insights is definitely a tool you need to be familiar with if your profiling your project. What do you mean by “command options for execute Unreal Insights” sorry.

There are a lot of different channels you can profile for and depending on what you want different combinations will give you the best information. For Game Thread and CPU Id look at default,timings,counters,bookmarks,assetloadtime,task.

Is this possible?

function
{
START_PROFILE(MYTRACE)

  // Logic

END_PROFILE(MYTRACE)

}

and in unreal insights, it shows how many costs to execute logis between that tow macros.

is it possible?