MoonWorks/src/FrameLimiterSettings.cs

36 lines
845 B
C#
Raw Normal View History

namespace MoonWorks
{
2023-09-19 20:19:41 +00:00
/// <summary>
/// The Game's frame limiter mode. Specifies a maximum rendering frames per second value.
/// </summary>
public enum FrameLimiterMode
{
2023-09-19 20:19:41 +00:00
/// <summary>
/// The game will render at the maximum possible framerate that the computing resources allow. <br/>
/// Note that this may lead to overheating, resource starvation, etc.
/// </summary>
Uncapped,
2023-09-19 20:19:41 +00:00
/// <summary>
/// The game will render no more than the specified frames per second.
/// </summary>
Capped
}
public struct FrameLimiterSettings
{
public FrameLimiterMode Mode;
2023-09-19 20:19:41 +00:00
/// <summary>
/// If Mode is set to Capped, this is the maximum frames per second that will be rendered.
2023-09-19 20:19:41 +00:00
/// </summary>
public int Cap;
public FrameLimiterSettings(
FrameLimiterMode mode,
int cap
) {
Mode = mode;
Cap = cap;
}
}
}