Ticket #8788: mencoder.pm.diff

File mencoder.pm.diff, 1.1 KB (added by anothersname@…, 10 years ago)

Patch to add eta timer to nuvexport mencoder jobs

Line 
1189c189
2<         my ($frames, $fps);
3---
4>         my ($frames, $fps, $start, $total_frames);
5191,195c191,200
6<         $fps    = 0.0;
7<         my $total_frames = $episode->{'last_frame'} > 0
8<                             ? $episode->{'last_frame'} - $episode->{'cutlist_frames'}
9<                             : 0;
10<     # Keep track of any warnings
11---
12>         $fps = 0.0;
13>          $start = time();
14>          $total_frames = 0;
15>          if (!$episode->{'total_frames'} || $episode->{'total_frames'} < 1) {
16>              $episode->{'total_frames'} = $episode->{'last_frame'} > 0
17>                                           ? $episode->{'last_frame'} - $episode->{'cutlist_frames'}
18>                                           : 0;
19>           }
20
21>      # Keep track of any warnings
22211,212c216,219
23<                 print "\rprocessed:  $frames of $total_frames frames ($pct\%), $fps fps ";
24<             }
25---
26>                 print "\rProcessed:  $frames of $total_frames frames, $fps fps ($pct\%, eta: ",
27>                        $self->build_eta($frames, $total_frames, $fps),
28>                        ')  ';
29>                  }