KernelAPI reference
Struct FrameSample
Namespace: MicroEngine.Core
Assembly: MicroEngine.dll
Guide: Game lifecycle and time
One frame as FrameProfiler measured it. Times are in milliseconds.
public readonly struct FrameSample : IEquatable<FrameSample>Implements
Constructors
FrameSample(double, double, double, double, double, int, double, double, long, int)
One frame as FrameProfiler measured it. Times are in milliseconds.
public FrameSample(double Interval, double Events, double Update, double Render, double Present, int Steps, double SimulatedTime, double InterpolatedTime, long Allocated, int Collections)Parameters
Interval double
Time from the start of the previous frame to the start of this one (0 for the first frame).
Events double
Polling system events (PumpEvents).
Update double
Running the fixed steps of this frame.
Render double
The game drawing its frame (BeginFrame and the scenes).
Present double
Finishing and presenting the frame (EndFrame); with VSync on, this is mostly the wait for the display.
Steps int
Fixed steps run in this frame.
SimulatedTime double
Seconds of game time after the frame’s last step (Time).
InterpolatedTime double
Seconds of game time a game drawing with FrameBlend shows.
Allocated long
Bytes the loop’s thread allocated during the frame.
Collections int
Garbage collections (any generation) that happened during the frame.
Properties
Allocated
Bytes the loop’s thread allocated during the frame.
public long Allocated { get; init; }Property Value
Collections
Garbage collections (any generation) that happened during the frame.
public int Collections { get; init; }Property Value
Events
Polling system events (PumpEvents).
public double Events { get; init; }Property Value
InterpolatedTime
Seconds of game time a game drawing with FrameBlend shows.
public double InterpolatedTime { get; init; }Property Value
Interval
Time from the start of the previous frame to the start of this one (0 for the first frame).
public double Interval { get; init; }Property Value
Present
Finishing and presenting the frame (EndFrame); with VSync on, this is mostly the wait for the display.
public double Present { get; init; }Property Value
Render
The game drawing its frame (BeginFrame and the scenes).
public double Render { get; init; }Property Value
SimulatedTime
Seconds of game time after the frame’s last step (Time).
public double SimulatedTime { get; init; }Property Value
Steps
Fixed steps run in this frame.
public int Steps { get; init; }Property Value
Update
Running the fixed steps of this frame.
public double Update { get; init; }Property Value
Methods
Deconstruct(out double, out double, out double, out double, out double, out int, out double, out double, out long, out int)
public void Deconstruct(out double Interval, out double Events, out double Update, out double Render, out double Present, out int Steps, out double SimulatedTime, out double InterpolatedTime, out long Allocated, out int Collections)Parameters
Interval double
Events double
Update double
Render double
Present double
Steps int
SimulatedTime double
InterpolatedTime double
Allocated long
Collections int
Equals(object)
public override bool Equals(object obj)Parameters
obj object
Returns
Equals(FrameSample)
public bool Equals(FrameSample other)Parameters
other FrameSample
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(FrameSample, FrameSample)
public static bool operator ==(FrameSample left, FrameSample right)Parameters
left FrameSample
right FrameSample
Returns
operator !=(FrameSample, FrameSample)
public static bool operator !=(FrameSample left, FrameSample right)Parameters
left FrameSample
right FrameSample