Re: A tool to extract part of a video
- From: David Bolt <blacklist-me@xxxxxxxxxx>
- Date: Sat, 18 Aug 2007 03:32:08 +0100
On Sat, 18 Aug 2007, David Bolt wrote:-
On Fri, 17 Aug 2007, Hatto von Aquitanien wrote:-
<Snip>
Any ideas?
Well, you could try:
ffmpeg -ss 00:28:30.000 -t 00:06:45.000 -vcodec mpeg4 -vtag xvid -i
V08546-22.flv V08546-22.avi
which should do the job.
Should, but doesn't. The video stream is correctly cropped out, but the
audio stream isn't. However, using these commands will work:
ffmpeg -i V08546-22.flv -vn -f s16le -acodec pcm_s16le -ac 2 -ar 22050 -ss 00:28:30.000 -t 00:06:45.000 - >audio
ffmpeg -i V08546-22.flv -an -f yuv4mpegpipe -ss 00:28:30.000 -t 00:06:45.000 - >video
ffmpeg -f s16le -acodec libmp3lame -ac 2 -ar 22050 -i audio -f yuv4mpegpipe -vcodec mpeg4 -vtag xvid -sameq -y V08546-22.avi
rm audio video
You will need a large space for the video file as it's the raw video
and, in my tests, ended up close to 1.4GB.
Alternatively, you can use a couple of named pipes and three consoles to
do the job[0] and not need a large amount of free drive space. To do
this, these steps should do nicely:
1, open up three separate consoles and change directory to that
containing V08546-22.flv ;
2, in one of the console windows type the commands "mkfifo audio" and
"mkfifo video" ;
3, using the first console, enter the following command:
ffmpeg -i V08546-22.flv -vn -f s16le -acodec pcm_s16le -ac 2 -ar 22050 -ss 00:28:30.000 -t 00:06:45.000 - >audio
4, using the second console, enter the following command:
ffmpeg -i V08546-22.flv -an -f yuv4mpegpipe -ss 00:28:30.000 -t 00:06:45.000 - >video
5, using the third console, enter the following command:
ffmpeg -f s16le -acodec libmp3lame -ac 2 -ar 22050 -i audio -f yuv4mpegpipe -vcodec mpeg4 -vtag xvid -sameq -y V08546-22.avi
6, once the AVI is built, delete the pipes "audio" and "video", unless
you're going to use them for other transcoding.
[0] According to an example given in the ffmpeg FAQ, it's possible to do
this with only one console, however all that happened when I tried is
the two jobs sent into the background stopped and waited for me to bring
them into the foreground.
Regards,
David Bolt
--
Member of Team Acorn checking nodes at 100 Mnodes/s: www.distributed.net
RISC OS 3.11 | SUSE 10.0 32bit | SUSE 10.1 32bit | openSUSE 10.2 32bit
RISC OS 3.6 | SUSE 10.0 64bit | SUSE 10.1 64bit | openSUSE 10.2 64bit
TOS 4.02 | SUSE 9.3 32bit | | openSUSE 10.3a6 32bit
.
- Follow-Ups:
- Re: A tool to extract part of a video
- From: Hatto von Aquitanien
- Re: A tool to extract part of a video
- References:
- A tool to extract part of a video
- From: Hatto von Aquitanien
- Re: A tool to extract part of a video
- From: David Bolt
- A tool to extract part of a video
- Prev by Date: Re: http://sofware.opensuse.org ... What is "1-click install"?
- Next by Date: Re: http://sofware.opensuse.org ... What is "1-click install"?
- Previous by thread: Re: A tool to extract part of a video
- Next by thread: Re: A tool to extract part of a video
- Index(es):
Relevant Pages
|