From 8813ca47a71388b6f6723424e5521db56bf85025 Mon Sep 17 00:00:00 2001 From: Scott Klum Date: Wed, 22 Jan 2014 14:17:38 -0500 Subject: [PATCH] Attempting to get consistent progress messages across br --- openbr/openbr_plugin.cpp | 2 +- openbr/plugins/misc.cpp | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/openbr/openbr_plugin.cpp b/openbr/openbr_plugin.cpp index f0e0e9c..1863520 100644 --- a/openbr/openbr_plugin.cpp +++ b/openbr/openbr_plugin.cpp @@ -863,7 +863,7 @@ void br::Context::printStatus() const float p = progress(); if (p < 1) { int s = timeRemaining(); - fprintf(stderr, "%05.2f%% REMAINING=%s COUNT=%g \r", 100 * p, QtUtils::toTime(s/1000.0f).toStdString().c_str(), totalSteps); + fprintf(stderr, "%05.2f%% ELAPSED=%s REMAINING=%s COUNT=%g/%g \r", p*100., QtUtils::toTime(Globals->startTime.elapsed()/1000.0f).toStdString().c_str(), QtUtils::toTime(s).toStdString().c_str(), Globals->currentStep, Globals->totalSteps); } } diff --git a/openbr/plugins/misc.cpp b/openbr/plugins/misc.cpp index 807d612..2aee23f 100644 --- a/openbr/plugins/misc.cpp +++ b/openbr/plugins/misc.cpp @@ -519,11 +519,7 @@ class ProgressCounterTransform : public TimeVaryingTransform // updated every second if (elapsed > 1000) { - float p = br_progress(); - int s = br_time_remaining(); - - fprintf(stderr, "%05.2f%% ELAPSED=%s REMAINING=%s COUNT=%g/%g \r", p*100., QtUtils::toTime(Globals->startTime.elapsed()/1000.0f).toStdString().c_str(), QtUtils::toTime(s).toStdString().c_str(), Globals->currentStep, Globals->totalSteps); - + Globals->printStatus(); timer.start(); } -- libgit2 0.21.4