21 #ifndef LIGHTMETRICA_PROGRESS_BAR_H
22 #define LIGHTMETRICA_PROGRESS_BAR_H
24 #include <lightmetrica/common.h>
28 #include <condition_variable>
48 void SetConsoleWidth(
int consoleWidth);
49 void Begin(
const std::string& taskName);
52 void OnReportProgress(
double progress,
bool done);
53 void RequestUpdateProgress();
54 void ProcessProgressOutput();
58 std::atomic<bool> enableProgressBar;
59 std::atomic<bool> requiresProgressUpdate;
60 bool progressPrintDone;
63 std::mutex progressMutex;
64 std::string progressTaskName;
65 std::condition_variable progressDoneCond;
73 #endif // LIGHTMETRICA_PROGRESS_BAR_H
Definition: progressbar.h:36