How can I remove one, or multiple segments from a webm video using avconv (without reencoding)?


To remove a single segment of a webm file you can use the standard method of seeking to a particular section of your file and then specifying a time duration to extract.

For example the following will take a section from 1 minute into a file and copy 60 seconds following this into another file:

avconv -ss 00:01:00 -i video.webm -t 60 -c copy cut.webm

To extract multiple segments of a webm file you can use avconv's basic stream segmenter. For example the following will split a webm video into 60 second segments and generate a playlist file as well:

avconv -i test.webm -c copy \
       -f segment -segment_time 60 -segment_list list.pls \

A few choices to make with the segmenter but the above examples covers the basics...

| improve this answer | |
  • Good answer. I tested it with segment_time = 10 sec and a 1:04 long file. A roughly one minute long file seems was split into seven files. The time stamps were a bit strange in VLC. Each file was reported at the added time length of all the files before, including the file itself. However each file played at a shorter time, and the whole playtime added up to 1:04, same as the original file. – theodorn Feb 29 '16 at 11:35

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.