File tree Expand file tree Collapse file tree 1 file changed +10
-0
lines changed
src/AvTranscoder/transcoder Expand file tree Collapse file tree 1 file changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -238,6 +238,8 @@ bool Transcoder::processFrame()
238
238
for (size_t streamIndex = 0 ; streamIndex < _streamTranscoders.size (); ++streamIndex)
239
239
{
240
240
LOG_DEBUG (" Process stream " << streamIndex << " /" << (_streamTranscoders.size () - 1 ))
241
+
242
+ // if a stream failed to process
241
243
if (!_streamTranscoders.at (streamIndex)->processFrame ())
242
244
{
243
245
LOG_WARN (" Failed to process stream " << streamIndex)
@@ -291,6 +293,14 @@ ProcessStat Transcoder::process(IProgress& progress)
291
293
LOG_INFO (" End of process because the job was canceled." )
292
294
break ;
293
295
}
296
+
297
+ // check progressDuration
298
+ if (_eProcessMethod == eProcessMethodBasedOnDuration && progressDuration >= expectedOutputDuration)
299
+ {
300
+ LOG_INFO (" End of process because the output program duration ("
301
+ << progressDuration << " s) is equal or upper than " << expectedOutputDuration << " s." )
302
+ break ;
303
+ }
294
304
}
295
305
296
306
_outputFile.endWrap ();
You can’t perform that action at this time.
0 commit comments