Navigation
API > API/Developer > API/Developer/FunctionalTesting
Class for use with functional tests which provides various performance measuring features. Recording of basic, unintrusive performance stats. Automatic captures using external CPU and GPU profilers. Triggering and ending of writing full stats to a file.
| Name | UAutomationPerformaceHelper |
| Type | class |
| Header File | /Engine/Source/Developer/FunctionalTesting/Classes/FunctionalTest.h |
| Include Path | #include "FunctionalTest.h" |
Syntax
UCLASS (MinimalAPI, Blueprintable)
class UAutomationPerformaceHelper : public UObject
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UAutomationPerformaceHelper
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UAutomationPerformaceHelper() |
FunctionalTest.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| OutputFileBase | FString | The path and base name for all output files. | FunctionalTest.h | |
| StartOfTestingTime | FString | FunctionalTest.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bGPUTraceIfBelowBudget | bool | If true we check the GPU times vs GPU budget each tick and trigger a GPU trace if we fall below budget. | FunctionalTest.h | |
| bRecordingBaselineBasicStats | bool | FunctionalTest.h | ||
| bRecordingBasicStats | bool | FunctionalTest.h | ||
| bRecordingCPUCapture | bool | FunctionalTest.h | ||
| bRecordingStatsFile | bool | FunctionalTest.h | ||
| Records | TArray< FPerfStatsRecord > | FunctionalTest.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void BeginRecording
(
FString RecordName, |
Begins recording a new named performance stats record. We start by recording the baseline. | FunctionalTest.h |
|
void BeginRecordingBaseline
(
FString RecordName |
Begins recording a new named performance stats record. We start by recording the baseline | FunctionalTest.h |
|
void BeginStatsFile
(
const FString& RecordName |
Begins recording stats to a file. | FunctionalTest.h |
|
void EndRecording() |
Stops recording performance stats. | FunctionalTest.h |
|
void EndRecordingBaseline() |
Stops recording the baseline and moves to the main record. | FunctionalTest.h |
|
void EndStatsFile() |
Ends recording stats to a file. | FunctionalTest.h |
|
const FPerfStatsRecord * GetCurrentRecord () |
FunctionalTest.h | ||
| FunctionalTest.h | |||
virtual UWorld * GetWorld() |
FunctionalTest.h | ||
bool IsCurrentRecordWithinGameThreadBudget() |
FunctionalTest.h |
|
|
bool IsCurrentRecordWithinGPUBudget() |
FunctionalTest.h |
|
|
bool IsCurrentRecordWithinRenderThreadBudget() |
FunctionalTest.h |
|
|
bool IsRecording() |
Returns true if this stats tracker is currently recording performance stats. | FunctionalTest.h |
|
void OnAllTestsComplete() |
Does any final work needed as all tests are complete. | FunctionalTest.h |
|
void OnBeginTests() |
Does any init work across all tests.. | FunctionalTest.h |
|
void Sample
(
float DeltaSeconds |
Adds a sample to the stats counters for the current performance stats record. | FunctionalTest.h |
|
void StartCPUProfiling() |
Communicates with external profiler to being a CPU capture. | FunctionalTest.h |
|
void StopCPUProfiling() |
Communicates with external profiler to end a CPU capture. | FunctionalTest.h |
|
void Tick
(
float DeltaSeconds |
FunctionalTest.h |
|
|
void TriggerGPUTraceIfRecordFallsBelowBudget() |
Will trigger a GPU trace next time the current test falls below GPU budget. | FunctionalTest.h |
|
void WriteLogFile
(
const FString& CaptureDir, |
Writes the current set of performance stats records to a csv file in the profiling directory. | FunctionalTest.h |
|