Skip to content

EngineProfiler

Inherits: RefCounted < Object

Base class for creating custom profilers.

This class can be used to implement custom profilers that are able to interact with the engine and editor debugger.

See EngineDebugger and EditorDebuggerPlugin for more information.

Returns Method
void _add_frame(data: Array) virtual
void _tick(frame_time: float, process_time: float, physics_time: float, physics_frame_time: float) virtual
void _toggle(enable: bool, options: Array) virtual

_add_frame

void _add_frame(data: Array) virtual

Called when data is added to profiler using EngineDebugger.profiler_add_frame_data().

_tick

void _tick(frame_time: float, process_time: float, physics_time: float, physics_frame_time: float) virtual

Called once every engine iteration when the profiler is active with information about the current frame. All time values are in seconds. Lower values represent faster processing times and are therefore considered better.

_toggle

void _toggle(enable: bool, options: Array) virtual

Called when the profiler is enabled/disabled, along with a set of options.