#include "i18n.h"
#define LOG_GENERAL(...) _film->log()->log (String::compose (__VA_ARGS__), Log::TYPE_GENERAL);
+#define LOG_DEBUG_ENCODE(...) _film->log()->log (String::compose (__VA_ARGS__), Log::TYPE_DEBUG_ENCODE);
#define LOG_TIMING(...) _film->log()->microsecond_log (String::compose (__VA_ARGS__), Log::TYPE_TIMING);
#define LOG_WARNING_NC(...) _film->log()->log (__VA_ARGS__, Log::TYPE_WARNING);
#define LOG_WARNING(...) _film->log()->log (String::compose (__VA_ARGS__), Log::TYPE_WARNING);
switch (qi.type) {
case QueueItem::FULL:
{
- LOG_GENERAL (N_("Writer FULL-writes %1 (%2)"), qi.frame, qi.eyes);
+ LOG_DEBUG_ENCODE (N_("Writer FULL-writes %1 (%2)"), qi.frame, qi.eyes);
if (!qi.encoded) {
qi.encoded = Data (_film->j2c_path (qi.frame, qi.eyes, false));
}
break;
}
case QueueItem::FAKE:
- LOG_GENERAL (N_("Writer FAKE-writes %1"), qi.frame);
+ LOG_DEBUG_ENCODE (N_("Writer FAKE-writes %1"), qi.frame);
_picture_asset_writer->fake_write (qi.size);
_last_written[qi.eyes].reset ();
++_fake_written;
break;
case QueueItem::REPEAT:
- LOG_GENERAL (N_("Writer REPEAT-writes %1"), qi.frame);
+ LOG_DEBUG_ENCODE (N_("Writer REPEAT-writes %1"), qi.frame);
dcp::FrameInfo fin = _picture_asset_writer->write (
_last_written[qi.eyes]->data().get(),
_last_written[qi.eyes]->size()
total *= 2;
}
if (total) {
- job->set_progress (float (_full_written + _fake_written) / total);
+ job->set_progress (float (_full_written + _fake_written + _repeat_written) / total);
}
}
}
}
- LOG_GENERAL ("Have existing frame %1", _first_nonexistant_frame);
+ LOG_DEBUG_ENCODE ("Have existing frame %1", _first_nonexistant_frame);
++_first_nonexistant_frame;
}