detailed export state, prepare resolution for #6512

(Post-processing step should announce itself during an export)
This commit is contained in:
Robin Gareus 2016-02-09 13:15:54 +01:00
parent a1d2c13077
commit c00a07e811
3 changed files with 12 additions and 5 deletions

View file

@ -53,7 +53,13 @@ class LIBARDOUR_API ExportStatus {
/* Progress info */ /* Progress info */
volatile bool normalizing; volatile enum Progress {
Exporting,
Normalizing,
Tagging,
Uploading,
Command }
active_job;
volatile uint32_t total_timespans; volatile uint32_t total_timespans;
volatile uint32_t timespan; volatile uint32_t timespan;

View file

@ -272,9 +272,9 @@ ExportHandler::process_normalize ()
{ {
if (graph_builder->process_normalize ()) { if (graph_builder->process_normalize ()) {
finish_timespan (); finish_timespan ();
export_status->normalizing = false; export_status->active_job = ExportStatus::Exporting;
} else { } else {
export_status->normalizing = true; export_status->active_job = ExportStatus::Normalizing;
} }
export_status->current_normalize_cycle++; export_status->current_normalize_cycle++;
@ -316,6 +316,7 @@ ExportHandler::finish_timespan ()
* TODO: check Umlauts and encoding in filename. * TODO: check Umlauts and encoding in filename.
* TagLib eventually calls CreateFileA(), * TagLib eventually calls CreateFileA(),
*/ */
export_status->active_job = ExportStatus::Tagging;
graph_builder->reset (); graph_builder->reset ();
AudiofileTagger::tag_file(filename, *SessionMetadata::Metadata()); AudiofileTagger::tag_file(filename, *SessionMetadata::Metadata());
} }
@ -330,7 +331,7 @@ ExportHandler::finish_timespan ()
... ...
}; };
#endif #endif
export_status->active_job = ExportStatus::Command;
PBD::ScopedConnection command_connection; PBD::ScopedConnection command_connection;
std::map<char, std::string> subs; std::map<char, std::string> subs;
subs.insert (std::pair<char, std::string> ('f', filename)); subs.insert (std::pair<char, std::string> ('f', filename));

View file

@ -39,7 +39,7 @@ ExportStatus::init ()
_finished = false; _finished = false;
_errors = false; _errors = false;
normalizing = false; active_job = Exporting;
total_timespans = 0; total_timespans = 0;
timespan = 0; timespan = 0;