IGraphicsTimer

Description

interface Tinman.Engine.Rendering.IGraphicsTimer

Derived from

IDisposable
IBeginEnd

Extended by

GraphicsTimer abstract

Represents a timer that can be used to measure the execution time on the GPU.

  1. Create a GPU timer object by calling IGraphicsContext.CreateTimer.

  2. Call IBeginEnd.Begin while rendering a frame, to mark the begin of the query.

  3. Call IBeginEnd.End while rendering a frame, to mark the end of the query.

  4. Call Result at arbitrary times and consume the returned query value.

Public / Methods

Result


public method Result → ()

returns → float64

The timer query result value in milli-seconds or 0 if there are no results yet.

Returns the value of the timer query that has finished most recently.

The query that has finished most recently is not necessarily the one that has been issued by the last pair of IBeginEnd.Begin and IBeginEnd.End.