File size: 1,392 Bytes
7fd553e | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | // Copyright Epic Games, Inc. All Rights Reserved.
#include "LyraPerformanceSettings.h"
#include "Engine/PlatformSettingsManager.h"
#include "Misc/EnumRange.h"
#include "Performance/LyraPerformanceStatTypes.h"
#include UE_INLINE_GENERATED_CPP_BY_NAME(LyraPerformanceSettings)
//////////////////////////////////////////////////////////////////////
ULyraPlatformSpecificRenderingSettings::ULyraPlatformSpecificRenderingSettings()
{
MobileFrameRateLimits.Append({ 20, 30, 45, 60, 90, 120 });
}
const ULyraPlatformSpecificRenderingSettings* ULyraPlatformSpecificRenderingSettings::Get()
{
ULyraPlatformSpecificRenderingSettings* Result = UPlatformSettingsManager::Get().GetSettingsForPlatform<ThisClass>();
check(Result);
return Result;
}
//////////////////////////////////////////////////////////////////////
ULyraPerformanceSettings::ULyraPerformanceSettings()
{
PerPlatformSettings.Initialize(ULyraPlatformSpecificRenderingSettings::StaticClass());
CategoryName = TEXT("Game");
DesktopFrameRateLimits.Append({ 30, 60, 120, 144, 160, 165, 180, 200, 240, 360 });
// Default to all stats are allowed
FLyraPerformanceStatGroup& StatGroup = UserFacingPerformanceStats.AddDefaulted_GetRef();
for (ELyraDisplayablePerformanceStat PerfStat : TEnumRange<ELyraDisplayablePerformanceStat>())
{
StatGroup.AllowedStats.Add(PerfStat);
}
}
|