[MEncoder-users] Trouble cutting mpegs using an edl file

Paul Astrachan astracha at austin.rr.com
Mon Mar 2 20:25:32 CET 2009


Having some trouble with cutting mpegs using an edl file.

The command line that I use is
start /low /b /wait  "mencoder" "..\mplayer\mencoder"  -ss %2 -endpos %3 
-of mpeg -ovc copy  -mpegopts format=dvd:tsaf -msglevel all=9 -oac 
copy   "%~1" -edl %4 -o test.mpg >test.log 2>&1

Where %1 is the file to be cut
%2 is the start position
%3 is the end
%4 is the name of the edl file.
The file created is much shorter that it should be based on the cut 
positions. A large segment is missing from the middle that is not 
reflected by the cut positions
The log file seems to show a problem at the cutpoints.  Here is an example

Pos:3357.8s 100667f ( 0%) 386fps Trem:   0min   0mb  A-V:0.025 
[4497:192] A/Vms 4/0 D/B/S 0/0/34
EDL_SKIP: start [8100.000000], stop [8425.559570], length [325.559570]
s->pos=2D6D0000  newpos=3DCC1000  new_bufpos=3DCC1000  buflen=0 
s->pos=3DD04000  newpos=39871800  new_bufpos=39871800  buflen=0 
Cannot seek backward in linear streams!
Seek failed

There are a few like the above and then this one that looks suspicious.

Pos:2605.0s  78092f ( 0%) 536fps Trem:   0min   0mb  A-V:0.065 
[4497:192] A/Vms 4/0 D/B/S 0/0/19
EDL_SKIP: start [3488.760010], stop [3769.399902], length [280.639893]
s->pos=FFFFFFFF81D2F000  newpos=0  new_bufpos=0  buflen=0 
s->pos=34000  newpos=0  new_bufpos=0  buflen=0 
Cannot seek backward in linear streams!
Seek failed

And then finally the last one
Pos:3840.8s 115149f ( 0%) 393fps Trem:   0min   0mb  A-V:0.024 
[-4447:192] A/Vms 4/0 D/B/S 0/0/41
EDL_SKIP: start [9023.990234], stop [9171.910156], length [147.919922]
s->pos=4FD0C800  newpos=5740D800  new_bufpos=5740D800  buflen=0 
stream_seek: WARNING! Can't seek to 0x5740D800 !
MPEG Stream reached EOF

There were 11 cuts in my edl file but only 6 or so of them ended up 
being used before the end of file.

Can anyone shed some light on what could be going on here?  Are the two 
buffer positions the audio and video streams?
Could this be a timestamp issue?
Paul











More information about the MEncoder-users mailing list