LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-06-2005, 05:11 AM   #1
oneandoneis2
Senior Member
 
Registered: Nov 2003
Location: London, England
Distribution: Ubuntu
Posts: 1,460

Rep: Reputation: 48
DVD -> movie files


I want to get some of my DVDs onto my computer. Two basic questions:

What's good software to use?

and

Since I want to put some of them onto small flash disks, what's the best format to get good quality without large file sizes?

Cheers!
 
Old 09-06-2005, 07:03 AM   #2
dracolich
Senior Member
 
Registered: Jul 2005
Distribution: Slackware
Posts: 1,274

Rep: Reputation: 63
Well, there's a utility caled vobcopy. You must also have the libdvdread, play and css packages installed. What size flash drives are you trying to use. I think if you convert the vob files into mpegs the sized won't change much. For some 90minute movies the vob file is around 800MB. If you can convert it to mpeg you could put it on a 1GB flash drive.
 
Old 09-06-2005, 09:11 AM   #3
oneandoneis2
Senior Member
 
Registered: Nov 2003
Location: London, England
Distribution: Ubuntu
Posts: 1,460

Original Poster
Rep: Reputation: 48
I've got all the software needed to play DVDs - not sure of the exact ones while I'm not on my own machine.

But the memory sticks I can use are no greater than 128MB, and the screen is 320*240 in 16-bit color. So it's not just a straightforward rip & go - even for short movie clips, it'll need downsizing!
 
Old 09-06-2005, 12:59 PM   #4
Boow
Member
 
Registered: Feb 2004
Distribution: Slackware 10.2
Posts: 669

Rep: Reputation: 32
Its possible but the picture quality would not be that good.
 
Old 09-06-2005, 03:19 PM   #5
Komakino
Senior Member
 
Registered: Feb 2004
Location: Somerset, England
Distribution: Slackware 10.2, Slackware 10.0, Ubuntu 9.10
Posts: 1,938

Rep: Reputation: 55
Quote:
Originally posted by Boow
Its possible but the picture quality would not be that good.
I agree - even for a 20 minute episode of family guy the quality is appalling if the file is anything less than around 200MB.
 
Old 09-06-2005, 03:51 PM   #6
JCipriani
Member
 
Registered: Aug 2005
Location: Pittsburgh, PA, USA
Distribution: Redhat 9, OS X 10.4.x, Win2K
Posts: 85

Rep: Reputation: 15
If you want a 20 minute episode of something to fit in 100MB, that gives you about 682kbps to work with, not including any overhead for the container file (like AVI frame headers, or MPG file headers, or whatever you use). A 64kbps mono MP3 will sound OK, 64kbps stereo is less OK but you don't lose the second channel; the same bitrate with AC3 will give you (according to some) slightly better quality. AC3 audio has the advantage of being able to store more than 2 channels so you can store 5.1 surround data as well if you need to. With 64kbps of audio data that leaves 618kbps for video. With a decent encoder and the right setting, you can probably actually get fairly decent quality out of that at 320x240, although you might consider dropping your frame rate down to 24fps or whatever it is. MPEG4 and DivX are two decent video codecs. Don't be disappointed though, if you end up with like, a 129MB file and you wanted a 128MB one. Sometimes there's some trial and error involved, heh. FYI, DVDs usually have AC3 audio tracks and MPEG2 video tracks.

Personally I like AVI files just because they are simple and widely supported, although MPG files are supported just as well. For simple projects, like stuff with 1 video track, 1 audio track, and no subtitles, I'd stay away from OGM and Matroska files (both good formats for more complex data) solely because some media players don't like those formats. So, an AVI file, 64kbps stereo/mono MP3 audio, and 618kbps MPEG4 or DivX variable bit rate (ie you average 618kbps, instead of always having 618kbps) video will serve you well. I choose MP3 over AC3, once again, because of compatibility issues.

Now, cartoons are not going to look as good as live action; the sharp edges and colors aren't going to show up well at low bitrates like that, but 618kbps is not that low.

As far as programs go, I am a huge fan of ffmpeg, which you can find here. The command line usage is intimidating at first but it's a powerful program. It can read VOB files too, once you have your VOB data ripped off your DVD. You'll need a lot of temporary hard drive space, btw.

Here's some hints for ffmpeg command line usage:
Code:
ffmpeg -i mydvd.vob -acodec mp3 -ab 96 -ac 2 -ar 44100 -vcodec msmpeg4 -size 320x240 -b 618 -f avi myrip.avi
That does what I just said above (with DivX video). The -hq option gives you higher quality encodings at the price of time, and you may also do two-pass encoding like so (with high quality mode turned on as well, in this example):
Code:
ffmpeg -i mydvd.vob -acodec mp3 -ab 96 -ac 2 -ar 44100 -vcodec msmpeg4 -size 320x240 -b 618 -hq -pass 1 -f avi myrip.avi
ffmpeg -i mydvd.vob -acodec mp3 -ab 96 -ac 2 -ar 44100 -vcodec msmpeg4 -size 320x240 -b 618 -hq -pass 2 -f avi myrip.avi
Two-pass encoding first encodes the file, but writes out a bunch of info to a log file. Then it encodes the file again using the info from the log file to make sure you get the bitrate you asked for but use the highest bandwidth in the most demanding spots in the video.

For VOB files with multiple audio/video channels, there are options you can specify to choose which input channels you want to map to output channels (I actually thing it's -map, can't remember off the top of my head). I also am not sure if I got the -size option right, once again, not looking at the docs at the moment. You can also set the output aspect ratio, too, which is useful when you want to say, encode 16:9 video at 320x240 resolution.

There's tons of other options you can use to tweak your videos until you find something you like. Unfortunately it's somewhat of an art -- there's lots of possibilities of what you can do. I'm sure there's an ffmpeg GUI front end out there somewhere too. Another good utility is avidemux, which you can search for. It's got a fairly decent GUI, lots of useful tools, and it's also scriptable so you can automate lots of tedious tasks for processing multiple videos. Also, mencoder, and transcode, are other pieces of video encoding software. Lots of people use mencoder instead of ffmpeg. I'm used to ffmpeg and I like it better, but in my limited experience with mencoder I did notice that it has a much faster MP3 audio encoder, at least. I always had trouble getting the video encoding quality that I wanted out of mencoder, though.

The Tools section and Forums over at http://www.videohelp.com/ are ridiculously useful. Ah, here we go, they have an actual Linux video tools section.

Jason

Last edited by JCipriani; 09-06-2005 at 04:11 PM.
 
Old 09-06-2005, 04:35 PM   #7
oneandoneis2
Senior Member
 
Registered: Nov 2003
Location: London, England
Distribution: Ubuntu
Posts: 1,460

Original Poster
Rep: Reputation: 48
Wow. Many thanks for that very detailed response, JC! I've got ffmpeg installed already, I'll have to have a play!

Cheers for all the feedback!
 
Old 09-06-2005, 05:11 PM   #8
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Quote:
Originally posted by JCipriani
MPEG4 and DivX are two decent video codecs.
??? AFAIK MPEG-4 is the standard. DivX is a MPEG-4 compliant codec (=coder/decoder), not decent though. XviD and FFmpeg (both do MPEG-4) are far suprior to DivX. At least it was so last time I checked... stand to be corrected...
 
Old 09-06-2005, 05:38 PM   #9
JCipriani
Member
 
Registered: Aug 2005
Location: Pittsburgh, PA, USA
Distribution: Redhat 9, OS X 10.4.x, Win2K
Posts: 85

Rep: Reputation: 15
Quote:
Originally posted by Emerson
DivX is a MPEG-4 compliant codec (=coder/decoder), not decent though. XviD and FFmpeg (both do MPEG-4) are far suprior to DivX. At least it was so last time I checked... stand to be corrected...
MPEG4 is a set of video and audio compression standards. DivX used to refer to an illegal and hacked version of Microsoft's version of MPEG4, but now refers to a legitimate video codec which is a subset of MPEG4 but still compliant with the MPEG4 standard. Think of MPEG4 as a huge set of video/audio compression features and standards; DivX is a codec with full support for a subset of these features.

XviD is a codec similar to DivX. Modern DivX is neither free nor open source, but OpenDivX is. XviD came from OpenDivX, if I remember correctly, and it's pretty much the open source version of DivX.

FFmpeg is not a codec or container format, it's just a program that you can use to encode media in various formats (and it does lots of other stuff too). FFmpeg is a command line interface to the various codecs I just mentioned, and more. At least, that's the FFmpeg I was referring to above. The FFmpeg guys do have some experimental codecs that they're working on, according to their documentation, but I wouldn't use those for obvious reasons.

Now, I got my example wrong -- or rather, my explanation wrong. The "msmpeg4" codec in ffmpeg is not DivX (anymore), it's Microsoft's version of MPEG4 (which is what I was referring to as MPEG4 in my above post, and which is also the codec that DivX used to be back when it was illegal, heh), sorry about any confusion there. In ffmpeg, the "mpeg4" codec is actually DivX 4. So to encode DivX video in ffmpeg you would use mpeg4, and to encode Microsoft MPEG4 video you'd use msmpeg4.

As far as superiority in practice goes... I've stared for good amounts of time at DivX, XviD, and MS MPEG4 videos before and I couldn't for the life of me see a difference in quality at the same bitrates. So, I just went for the one that was supported by all of the media players I had on all the machines I had at the time, which was MSMPEG4. Then I started using DivX but I actually don't remember what prompted me to make the switch. Probably because it required two less characters of typing on the ffmpeg command line. I don't know if ffmpeg supports XviD encoding; I know it can decode it though.

I think I got that all right.

Jason

Last edited by JCipriani; 09-06-2005 at 05:54 PM.
 
Old 09-06-2005, 05:54 PM   #10
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Yeah. I agree with most. However. DivX for Linux is crap. So, we can compare DivX for Win with XviD. I can say it depends on source material. If source is excellent, then XviD gives visibly better results. Not to mention it encodes faster. In real life, many DVD's out there offer only mediocre quality, thus XviD or libavcodec cannot produce anything better than DivX for Win.
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Movie DVD problem impeteperry Ubuntu 6 11-16-2005 12:38 AM
How to add text to movie (DVD)? pingu Linux - Software 1 10-14-2005 03:43 AM
How to store a 7.1 GB movie in a 4.3 GB DVD ?? karhu Linux - Software 3 08-03-2005 06:18 AM
Every DVD Player Fails to Play DVD Movie in SuSE 9.2 Pro....Please Help ! ! ! bedi-beparwah SUSE / openSUSE 2 03-14-2005 06:08 PM
How to get a screenshot of the DVD movie? ICO Linux - General 6 06-02-2004 03:20 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 12:44 PM.

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
Open Source Consulting | Domain Registration