103 static proto
void Enable(
bool enable,
bool immediate =
false,
bool sessionReset =
true);
222 static proto
int SetFlags(
int flags,
bool sessionReset =
true);
275 static proto
int AddFlags(
int flags,
bool sessionReset =
true);
293 static proto
int RemoveFlags(
int flags,
bool sessionReset =
true);
395 static proto
void SetInterval(
int interval,
bool sessionReset =
true);
680 static proto
float GetTimeOfFunc(
string funct,
typename clss,
bool immediate =
false);
692 static proto
float GetTimeOfFuncG(
string funct,
bool immediate,
bool immediate =
false);
705 static proto
int GetCountOfFunc(
string funct,
typename clss,
bool immediate =
false);
Set of methods for accessing script profiling data.
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
static proto int GetTimeResolution()
Get the currently set time resolution.
static proto void EnableAverage(bool enable)
Enable/disable returning calculated averages.
static proto EnProfilerModule GetModule()
Get the currently profiled module.
static proto int GetInterval()
Get the currently set interval.
static proto void GetTimePerFunc(notnull out array< ref EnProfilerTimeFuncPair > outArr, int count=int.MAX)
Obtain [SD] for Time Per Function.
Param2< int, string > EnProfilerCountFuncPair
Param2< float, string > EnProfilerTimeFuncPair
static proto int GetProfiledSessionFrames()
Get the total amount of frames profiled in this profiling session.
Param2< int, typename > EnProfilerCountClassPair
EnProfilerEnabledFlags
There are 3 states which can be toggled that governs whether script profiling is enabled or not.
static proto int GetAllocationsOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the allocations of a specific class.
static proto float GetTimeOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the time a specific class consumed.
static proto int GetCountOfFunc(string funct, typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the amount of times a specific function was called.
static proto int GetFlags()
Get the currently used flags across the API.
static proto int ClearFlags(bool sessionReset=true)
Remove all flags from the currently used set of EnProfilerFlags across the API.
static proto float GetTimeOfFunc(string funct, typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the time consumed by a specific function.
static proto void SetTimeResolution(int resolution)
Set the resolution of the fetched Time data.
static proto void GetCountPerFunc(notnull out array< ref EnProfilerCountFuncPair > outArr, int count=int.MAX)
Obtain [SD] for Count Per Function.
static proto void SortData()
The internal sorting that happens at the end of the frame (so it is NOT necessary to call this manual...
static proto void SetModule(EnProfilerModule module, bool sessionReset=true)
Set the module to be profiled.
static proto void GetInstancesPerClass(notnull out array< ref EnProfilerCountClassPair > outArr, int count=int.MAX)
Obtain [SD] for Instances Per Class.
static proto owned string ModuleToName(EnProfilerModule module)
Helper to convert EnProfilerModule to string.
static proto int GetTotalFrames()
Get the total amount of frames across all profiling session.
static proto void ResetSession(bool fullReset=false)
Perform [SR], clearing SessionFrame, ProfiledSessionFrames, [SD] and [PD] (except for [CI])
static proto bool IsAverage()
Check if returning of average data is enabled.
static proto int GetProfiledFrames()
Get the total amount of frames profiled across all profiling session.
Param2< float, typename > EnProfilerTimeClassPair
static bool IsEnabledP()
Return if script profiling is enabled through EnProfiler.
static proto void GetAllocationsPerClass(notnull out array< ref EnProfilerCountClassPair > outArr, int count=int.MAX)
Obtain [SD] for Allocations Per Class.
static bool IsEnabledC()
Return if script profiling is actually turned on inside of the script context.
static proto int GetInstancesOfClass(typename clss, bool immediate=false)
Obtain [SD] or [PD] regarding the [CI] of a specific class.
static proto int GetGameFrame()
Get the total amount of frames passed.
static proto float GetTimeOfFuncG(string funct, bool immediate, bool immediate=false)
Obtain [SD] or [PD] regarding the time consumed by a specific global function.
EnProfilerFlags
Flags that influences the behaviour of the EnProfiler API, applied through ...Flags functions.
static proto void GetTimePerClass(notnull out array< ref EnProfilerTimeClassPair > outArr, int count=int.MAX)
Obtain [SD] for Time Per Class.
static proto int SetFlags(int flags, bool sessionReset=true)
Override the currently used set of EnProfilerFlags across the API.
static proto void Enable(bool enable, bool immediate=false, bool sessionReset=true)
Enable the gathering of script profiling data.
EnProfilerModule
Current base scripted modules.
static proto bool NameToModule(string moduleName, out EnProfilerModule module)
Convert string to EnProfilerModule.
static bool RequestImmediateData()
Helper method to ascertain the profiler will record [PD] right after this call.
static proto void Dump()
Print out [SD] to script log.
static proto bool IsFlagsSet(int flags)
Check if the flags are set.
static proto int GetSessionFrame()
Get the total amount of frames in this profiling session.
static proto int RemoveFlags(int flags, bool sessionReset=true)
Remove flags from the currently used set of EnProfilerFlags across the API.
static bool IsEnabledD()
Return if script profiling is enabled through [DM].
static proto void SetInterval(int interval, bool sessionReset=true)
Set the interval for the [SD] to update.
static proto int IsEnabled()
Return if script profiling is enabled.
static proto int GetCountOfFuncG(string funct, bool immediate=false)
Obtain [SD] or [PD] regarding the amount of times a specific function was called.
static proto int AddFlags(int flags, bool sessionReset=true)
Add flags to the currently used set of EnProfilerFlags across the API.
@ DIAG
Script profiling UI is enabled in WIN+ALT debug menu, when this is true, it will override SCRP.
@ SCRP
It has been set to being always enabled through EnProfiler (SCRipt Profiler)
@ SCRC
Whether profiling is currently truly happening (SCRipt Context)
@ RECURSIVE
Whether to profile child modules.
@ RESET
When present, will reset [PD] on sorting, otherwise will accumulate on top of it.
@ ERROR
Can be returned from some methods.