LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-28-2012, 05:57 PM   #1
PayNow
LQ Newbie
 
Registered: Jun 2012
Posts: 7

Rep: Reputation: Disabled
How to convert VOB file using ffmpeg ?


hey guys,

i want to know how to convert .VOB to .mp4 using ffmpeg

i have do
Quote:
ffmpeg -i outss.VOB video.mp4
but see what i am getting can anyone help me ?


Code:
root@ks3092546:/var/www/video/VIDEO_TS ffmpeg -i outss.VOB video.mp4
FFmpeg version SVN-r0.5.9-4:0.5.9-1, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --extra-version=4:0.5.9-1 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libdirac --enable-libgsm --enable-libopenjpeg --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib --disable-stripping --disable-vhook --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-swscale --enable-x11grab --enable-libfaad --enable-libdc1394 --enable-shared --disable-static
  libavutil     49.15. 0 / 49.15. 0
  libavcodec    52.20. 1 / 52.20. 1
  libavformat   52.31. 0 / 52.31. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libavfilter    0. 4. 0 /  0. 4. 0
  libswscale     0. 7. 1 /  0. 7. 1
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Jun 10 2012 08:33:06, gcc: 4.4.5

Seems stream 0 codec frame rate differs from container frame rate: 59.94 (60000/1001) -> 29.97 (30000/1001)
Input #0, avi, from 'outss.VOB':
  Duration: 00:40:00.39, start: 0.000000, bitrate: 3453 kb/s
    Stream #0.0: Video: mpeg2video, yuv420p, 720x480 [PAR 32:27 DAR 16:9], 8000 kb/s, 29.97 tbr, 29.97 tbn, 59.94 tbc
    Stream #0.1: Audio: ac3, 48000 Hz, 5.1, s16, 448 kb/s
Output #0, mp4, to 'video.mp4':
    Stream #0.0: Video: mpeg4, yuv420p, 720x480 [PAR 32:27 DAR 16:9], q=2-31, 200 kb/s, 90k tbn, 29.97 tbc
    Stream #0.1: Audio: 0x0000, 48000 Hz, 5.1, s16, 64 kb/s
Stream mapping:
  Stream #0.0 -> #0.0
  Stream #0.1 -> #0.1
Unsupported codec for output stream #0.1
root@ks3092546:/var/www/video/VIDEO_TS
Thanks
 
Old 06-28-2012, 10:24 PM   #2
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 332Reputation: 332Reputation: 332Reputation: 332
The problem is the output audio stream; no codec was specified. If you want to copy the input audio, you can use '-acodec copy' or if you want mp3 audio you can specify '-acodec libmp3lame -ac 2 -ar 22050' for example.

Code:
ffmpeg -i outss.VOB -acodec libmp3lame -ac 2 -ar 22050 video.mp4
You can get the details for all options with 'man ffmpeg'.

Last edited by macemoneta; 06-28-2012 at 10:25 PM.
 
Old 06-29-2012, 05:36 AM   #3
PayNow
LQ Newbie
 
Registered: Jun 2012
Posts: 7

Original Poster
Rep: Reputation: Disabled
i am getting this error why ?

Code:
root@ks3092546:/var/www/video/VIDEO_TS# ffmpeg -i outss.VOB -acodec libmp3lame -ac 2 -ar 22050 video.mp4
FFmpeg version SVN-r0.5.9-4:0.5.9-1, Copyright (c) 2000-2009 Fabrice Bellard, et al.
  configuration: --extra-version=4:0.5.9-1 --prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib --enable-libdirac --enable-libgsm --enable-libopenjpeg --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib --disable-stripping --disable-vhook --enable-runtime-cpudetect --enable-gpl --enable-postproc --enable-swscale --enable-x11grab --enable-libfaad --enable-libdc1394 --enable-shared --disable-static
  libavutil     49.15. 0 / 49.15. 0
  libavcodec    52.20. 1 / 52.20. 1
  libavformat   52.31. 0 / 52.31. 0
  libavdevice   52. 1. 0 / 52. 1. 0
  libavfilter    0. 4. 0 /  0. 4. 0
  libswscale     0. 7. 1 /  0. 7. 1
  libpostproc   51. 2. 0 / 51. 2. 0
  built on Jun 10 2012 08:33:06, gcc: 4.4.5

Seems stream 0 codec frame rate differs from container frame rate: 59.94 (60000/1001) -> 29.97 (30000/1001)
Input #0, mpeg, from 'outss.VOB':
  Duration: 02:13:54.91, start: 0.060000, bitrate: 4447 kb/s
    Stream #0.0[0x1e0]: Video: mpeg2video, yuv420p, 720x480 [PAR 32:27 DAR 16:9], 7000 kb/s, 29.97 tbr, 90k tbn, 59.94 tbc
    Stream #0.1[0x80]: Audio: ac3, 48000 Hz, stereo, s16, 448 kb/s
Unknown encoder 'libmp3lame'
root@ks3092546:/var/www/video/VIDEO_TS#
 
Old 06-29-2012, 08:36 AM   #4
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian sid + kde 3.5 & 4.4
Posts: 6,823

Rep: Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959
Why don't you start by trying to actually read the error messages and interpret what they mean?

Code:
Unknown encoder 'libmp3lame'
You apparently either don't have libmp3lame installed, or it's otherwise unlocatable, so ffmpeg can't use it.

Do you see the line at the top with all the "--enable" options? It tells you what external libraries and certain other features your version of ffmpeg has been compiled to use. Since I don't see "--enable-libmp3lame" listed, it appears you are using a version that doesn't support it. This isn't surprising. Since mp3 is a patent-encumbered codec, many Free distributions can't legally compile it into in their packages. So you'll have to find a version from a separate source that does have it enabled, or else compile your own version.

Another option is to simply use a codec that is enabled instead. mp2 is commonly available and supported by most media formats, for example. ffmpeg also has a built-in mp3 encoder of its own that might possibly be enabled (although lame is generally much better). Run "ffmpeg -codecs" for a full list of what's available to your version.

Since this is a common problem, a google search or two should turn up a source for you. Someone here might also be able to tell you if you tell us what distribution you're using.
 
Old 06-29-2012, 11:33 AM   #5
travalon
Member
 
Registered: Jun 2012
Location: AZ
Distribution: Mint 13, Ubuntu
Posts: 78

Rep: Reputation: Disabled
Just try Handbrake

Handbrake found Here:http://handbrake.fr/downloads.php
 
Old 06-29-2012, 01:53 PM   #6
schneidz
LQ Guru
 
Registered: May 2005
Location: boston, usa
Distribution: fc-15/ fc-20-live-usb/ aix
Posts: 5,120

Rep: Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876Reputation: 876
also, xvidenc, h264enc are good.
 
Old 06-30-2012, 05:09 AM   #7
PayNow
LQ Newbie
 
Registered: Jun 2012
Posts: 7

Original Poster
Rep: Reputation: Disabled
i am using debian ssh i can't find handbreak for debian
 
Old 06-30-2012, 07:32 AM   #8
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671Reputation: 671
You will want to specify the "q" range to use or the bitrate you want. The default (200k) in your example is to low for reasonable quality. Using "-sameq" is another possibility, but may result in too high of a bitrate from what you want.

Try looking for examples with Google. They are a good way to pick up esoteric options you may want to use to lower the size while not degrading quality.

DVD audio is MP2. You could use -acodec copy. The results should be acceptable.
The sweatspot for mp2 audio is "-acodec mp2 -ab 224k -ar 44100".

For mp3 audio, a sampling rate of "-ar 48k" is very common.

For most distros, there is a repository that that has restricted versions of media packages with features like mp3 builtin. You need this as well as downloading and installing the library & codecs.
I don't use Debian, but I think ftp.deb-multimedia.org may be such a repository.
 
Old 07-01-2012, 10:13 AM   #9
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Debian sid + kde 3.5 & 4.4
Posts: 6,823

Rep: Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959Reputation: 1959
Yes, for fully-enabled versions of most media apps on debian, use deb-multimedia.org as your source.


Actually, dvd audio can be mp2, ac3, DTS, or raw pcm, with ac3 being the most common. The output posted above shows that that source has ac3 audio. You should be able to use -acodec copy to keep the ac3 track, but if file-size is important, you can save a few megabytes by re-encoding it to mp2 or mp3 (and if audio quality isn't important, use a lower bitrate to shave off even more).

http://en.wikipedia.org/wiki/DVD-VIDEO

Last edited by David the H.; 07-01-2012 at 10:38 AM. Reason: updated url + addendum
 
1 members found this post helpful.
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to convert .VOB to mp4 using ffmpeg? sarbojit Linux - Newbie 2 05-12-2011 11:10 AM
[SOLVED] Converting VOB to XVID (using ffmpeg)? Steve W Linux - Software 5 12-10-2010 09:54 AM
ffmpeg to convert QuickTime mov-file into dv file arkadig Linux - Software 1 04-16-2008 09:31 AM
converting vob to xvid using ffmpeg schneidz Linux - Software 3 12-07-2006 03:03 PM
is there any way convert a .vob file to a .avi? jackstoage Linux - Software 8 10-05-2004 08:30 AM


All times are GMT -5. The time now is 02:56 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration