28#ifndef STEAM_PLAY_DUMMY_TICK_SERVICE_H
29#define STEAM_PLAY_DUMMY_TICK_SERVICE_H
57 using Tick = function<void(
void)>;
65 : ThreadJoinable(
"Tick generator (dummy)"
70 INFO (
steam,
"DummyTickService started.");
77 WARN (
steam,
"Failure in DummyTickService");
80 INFO (
steam,
"DummyTickService shutdown.");
92 or( 1000000/fps < std::numeric_limits<uint>::max()
113 TRACE (proc_dbg,
"Tick Thread timer loop exiting...");
Variant of the standard case, requiring to wait and join() on the termination of this thread.
lib::Result< RES > join()
put the caller into a blocking wait until this thread has terminated
Tick generating service for a periodic callback, with adjustable frequency.
void timerLoop(Tick periodicFun)
std::atomic_uint timespan_
DummyTickService(Tick callback)
static const uint POLL_TIMEOUT
poll interval for new settings in wait state
void activate(uint fps)
set the periodic timer to run with a given frequency, starting now.
function< void(void)> Tick
Lumiera error handling (C++ interface).
Steam-Layer implementation namespace root.
Convenience front-end to simplify and codify basic thread handling.