2

I' using ffmpeg 0.8 on windows (can not use later version because my service provider has only this version instilled on the servers, actually even 0.7.8)

Trying to cut media file (that is 10 sec long)

ffmpeg -ss 00:00:05.00  -i i.ogg o.ogg

result file is not actually what is wanted, got the output:

ffmpeg version 0.8, Copyright (c) 2000-2011 the FFmpeg developers
  built on Jun 23 2011 14:21:12 with gcc 4.5.3
  configuration: --enable-gpl --enable-version3 --enable-memalign-hack --enable-
runtime-cpudetect --enable-avisynth --enable-bzlib --enable-frei0r --enable-libo
pencore-amrnb --enable-libopencore-amrwb --enable-libfreetype --enable-libgsm --
enable-libmp3lame --enable-libopenjpeg --enable-librtmp --enable-libschroedinger
 --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enabl
e-libx264 --enable-libxavs --enable-libxvid --enable-zlib
  libavutil    51.  9. 1 / 51.  9. 1
  libavcodec   53.  7. 0 / 53.  7. 0
  libavformat  53.  4. 0 / 53.  4. 0
  libavdevice  53.  1. 1 / 53.  1. 1
  libavfilter   2. 23. 0 /  2. 23. 0
  libswscale    2.  0. 0 /  2.  0. 0
  libpostproc  51.  2. 0 / 51.  2. 0
i.ogg: could not seek to position 5.000
Input #0, ogg, from 'i.ogg':
  Duration: 00:00:10.02, start: 0.000000, bitrate: 57 kb/s
    Stream #0.0: Video: theora, yuv420p, 505x404 [PAR 1:1 DAR 5:4], 25 tbr, 25 t
bn, 25 tbc
    Stream #0.1: Audio: vorbis, 44100 Hz, stereo, s16, 64 kb/s
    Metadata:
      ENCODER         : Lavf53.4.0
File 'o.ogg' already exists. Overwrite ? [y/N] y
[buffer @ 0000000000329060] w:505 h:404 pixfmt:yuv420p tb:1/1000000 sar:1/1 sws_
param:
Output #0, ogg, to 'o.ogg':
  Metadata:
    encoder         : Lavf53.4.0
    Stream #0.0: Video: libtheora, yuv420p, 505x404 [PAR 1:1 DAR 5:4], q=2-31, 2
00 kb/s, 25 tbn, 25 tbc
    Stream #0.1: Audio: flac, 44100 Hz, stereo, s16, 64 kb/s
    Metadata:
      ENCODER         : Lavf53.4.0
Stream mapping:
  Stream #0.0 -> #0.0
  Stream #0.1 -> #0.1
Press [q] to stop, [?] for help
frame=    0 fps=  0 q=0.0 Lsize=      84kB time=00:00:00.00 bitrate=   0.0kbits/
s
video:0kB audio:80kB global headers:3kB muxing overhead 0.673916%

It works well with latest versions of ffmpeg. What my be the problem?

1 Answer 1

1

It looks like an ffmpeg bug or lack-of-feature. I would try to work around it by specifying the -ss option differently. The most obvious thing is just to try "-ss 5" instead of the HH:MM:SS syntax.

This, from the man page for 0.11, also looks promising. Maybe or maybe not available in your old version.

-ss position (input/output)

When used as an input option (before "-i"), seeks in this input file to position. When used as an output option (before an output filename), decodes but discards input until the timestamps reach position. This is slower, but more accurate.

position may be either in seconds or in "hh:mm:ss[.xxx]" form.

Presuming you really only want to cut, not to re-encode, you should also add codec options to copy instead (-acodec copy, -vcodec copy). -copyts can be useful also (copy timestamps). So, try something like this:

ffmpeg -i foo.ogg -acodec copy -vcodec copy -copyts -ss 5 foominus5.ogg
2
  • Thanks you suggestion does work. Actaully for OGG audio files, what I'm trying to fight now is how to convert video file to OGG audio, with later version of ffmpeg I used -q '1' and -map 'a' options to get rid of video in media, but these options does not work on old version.
    – WHITECOLOR
    Jul 15, 2013 at 12:39
  • Trying to resolve superuser.com/questions/620093/…
    – WHITECOLOR
    Jul 15, 2013 at 16:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .