16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-21 13:39:18 +02:00

Reorganize source files into logical subdirectories

Co-authored-by: Hirek193 <23196899+Hirek193@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-03-14 19:01:57 +00:00
parent f981f81d55
commit 0531086bb9
221 changed files with 131 additions and 108 deletions

View File

@@ -0,0 +1,41 @@
#pragma once
#include <deque>
#include <string>
namespace ui {
// klasa obsługująca linijkę napisu do dźwięku
struct TTranscript {
float fShow; // czas pokazania
float fHide; // czas ukrycia/usunięcia
std::string asText; // tekst gotowy do wyświetlenia (usunięte znaczniki czasu)
bool bItalic; // czy kursywa (dźwięk nieistotny dla prowadzącego)
};
// klasa obsługująca napisy do dźwięków
class TTranscripts {
public:
// constructors
TTranscripts() = default;
// methods
void AddLine( std::string const &txt, float show, float hide, bool it );
// dodanie tekstów, długość dźwięku, czy istotne
void Add( std::string const &txt, bool background = false );
// usuwanie niepotrzebnych (ok. 10 razy na sekundę)
void Update();
// members
std::deque<TTranscript> aLines;
private:
// members
float fRefreshTime { 360 }; // wartośc zaporowa
};
extern TTranscripts Transcripts;
} // namespace ui