Vixen
02b45cc4
csharp
public readonly record struct FrameStatistics

What the renderer did last frame, as numbers only it can know.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

Pushed in by the host rather than read out of a renderer, because Vixen.Engine does not reference one — deliberately, so that a game's simulation layer never drags a graphics API behind it. The host sets this once a frame; the overlay reads it and formats it.

⚠ GpuMilliseconds is several frames old and is presented as such. A timestamp query is read back with its frame's fence, so a GPU figure that claims to be this frame's is lying — see [13](../../../../docs/plan/13-diagnostics.md) § GPU. Zero means "nobody measured", which the overlay draws as a dash rather than as a very fast frame.

Fields and properties (7)

  • public double GpuMilliseconds

    How long the GPU took, or zero if nothing measured it.

  • public int GpuLatency

    How many frames back GpuMilliseconds was actually measured.

  • public int DrawCalls

    How many draws were recorded.

  • public long Triangles

    How many triangles those draws asked for.

  • public int Visible

    How many render objects survived culling.

  • public int Culled

    How many did not.

  • public long GpuBytes

    How much GPU memory is in use, or zero if the backend cannot say.

Used by (1)

  • FrameStatsOverlayVixen.Engine