LatencyMeter class
Public types
Public functions
- void Initialize(VkDevice device, bool bPresentWaitSupported, double refreshMs)
- void SetEnabled(bool bEnabled)
- auto IsEnabled() const -> bool
- void SetRefreshMs(double refreshMs)
- auto OnPresent(uint64_t inputTimestamp, uint64_t renderStart, uint64_t presentCall) -> uint64_t
- void Poll(VkSwapchainKHR swapchain)
- Observe which pending presents have reached the screen. Never blocks.
- void OnSwapchainRecreated()
- The swapchain was recreated: its pending present IDs will never complete.
- auto TakeSummary() -> Summary
- Summarize and reset the current window of samples.
Function documentation
uint64_t LatencyMeter:: OnPresent(uint64_t inputTimestamp,
uint64_t renderStart,
uint64_t presentCall)
Record a main-window present. Returns the present ID to chain into VkPresentIdKHR (0 = attach none: disabled, unsupported, or no input timestamp yet). Timestamps are SDL perf counters.