BUILD_WITH_CHRONO_STEADY_CLOCK - use std::chrono::steady_clock as a timer. By default is OFF
BUILD_WITH_CHRONO_HIGH_RESOLUTION_CLOCK - use std::chrono::high_resolution_clock as a timer. By default is OFF
If both is set to ON - use std::chrono::high_resolution_clock.
If both is set to OFF - use QueryPerformanceCounter/rtdsc timer.
Note: Do not forget clean CMakeCache file if you've changed an option.
Now you can use EASY_FRAME_COUNTER (which is only frame-counter) or EASY_FRAME (which is EASY_FRAME_COUNTER + EASY_BLOCK) or EASY_FRAME_FUNCTION (which is EASY_FRAME_COUNTER + EASY_FUNCTION) to measure frame time even if profiler is disabled.
To get frame time you can use profiler::main_thread::frameTimeLocalMax to get maximum frame duration since last call or profiler::main_thread::frameTime to get last frame time.
--- NOTE: You have to put EASY_MAIN_THREAD to your main thread to be able to use profiler::main_thread functions.
If you do not want to then you can use same functions from profiler::this_thread, but you will have to call them from your main thread.
- Disables warnings for no-braced-scalar-init which shows up for ATOMIC_VAR_INIT.
- Fixes compile warnings, mostly "moving a temporary objects prevents
copy elision" (-Wpessimizing-move) and unused variables.
- Adds some necessary fields to make the sample compile after having
build the core library.
1) Added macro EASY_CONST_NAME(name) to make possible to force EasyProfiler think that given block name is const and not changed during application execution (this rely to compile-time strings saved into a run-time variable);
2) Starting from now, EasyProfiler will not store partially finished frames - first, this means that profiler enabled during frame execution will skip all blocks from this frame, and second, this means that when dumping profiled information profiler will wait until all frames finish before dumping blocks.
1) Added active time calculation (this is duration excluding context switch time).
2) Columns "Duration", "Self Dur.", "Self %", "% / Frame", "Active time", "Active %" in Plain mode shows total values per frame (sum of all values per frame).