first commit

This commit is contained in:
dasha 2026-01-05 23:50:53 +03:00
commit 7dd9dd689e
40 changed files with 4100 additions and 0 deletions

21
Utils/ProgressReporter.h Normal file
View file

@ -0,0 +1,21 @@
#pragma once
#include <string>
#include <chrono>
class ProgressReporter {
public:
ProgressReporter(int totalItems, int barWidth = 50);
/// Call every iteration with the current index (0-based).
/// Returns false if you should “throttle” (i.e. skip redraw).
bool update(int currentIndex);
/// Call once at the end to clear or finalize the line.
void finish();
private:
int m_total;
int m_width;
int m_lastPercent{ -1 };
std::chrono::steady_clock::time_point m_lastDraw;
};