Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > Linux, Mac OS X, & Co

Reply
 
Thread Tools Search this Thread Display Modes
Old 16th December 2006, 02:01   #1  |  Link
Staz
Registered User
 
Staz's Avatar
 
Join Date: May 2004
Posts: 128
Lame MP3 Encoding on Linux

Hi I am wanting to encode my DVD audio track to lame mp3.
This is the mencoder setting I use to rip the audio.
Code:
mencoder -dvd-device . dvd:// -aid <aid> -oac copy -of rawaudio -ovc copy -o test.ac3
But when I try to encode to mp3 using lame my result is a terrible screeching sound. Why is this? Also when lame is encoding the total frames is far less than it should me. eg : 24300/26094. There are far more frames than 26094 in the movie.

Code:
lame -V 5 --vbr-new test.ac3 test.mp3
I then tried using mencoder to output the audio track to PCM .wav

Code:
mplayer -dvd-device . dvd:// -vo null -vc dummy -ao pcm:file=output.wav
Then used lame again:

Code:
lame -V 5 --vbr-new output.wav test.mp3
The result actually sounded really good, but it was far quieter rips I have done on windows using robot4rip. Why is this? Also I heard that lame doesn't like to convert a 48khz source. Is this true? What is the best way to boost the audio on linux (get the optimal gain setting). I notice besweet has a -ota (-hybridgain) switch. What does this do and how can I closely replicate it on linux?

Thanks
Staz
Staz is offline   Reply With Quote
Old 16th December 2006, 06:58   #2  |  Link
shevegen
Registered User
 
Join Date: Nov 2003
Posts: 419
Yeah not sure why there is a screech but i have it also sometimes

i am using ffmpeg directly these days to get the audio from a DVD
especially if its already a .mp3 file

if its wav though, lame works always for me
__________________
OS: Paldo (Linux)
AviSynth for Linux, go go go!
shevegen is offline   Reply With Quote
Old 17th December 2006, 07:06   #3  |  Link
d'Oursse
Mushroomeur
 
Join Date: Jun 2003
Location: Mushrooms of Paris Town
Posts: 267
why don't you tell mencoder to convert your audio track directly to wav, instead of ac3 ?
d'Oursse is offline   Reply With Quote
Old 17th December 2006, 14:25   #4  |  Link
echo
Registered User
 
echo's Avatar
 
Join Date: Jan 2003
Posts: 130
Lame does not accept ac3 as input. That's why you're getting the screeching sounds and you have less frames. Always export to wav and then encode with lame as you did in your second try. And yes it's true that lame is tuned for 44.1kHz material but works OK for 48kHz too. You could also use mp3gain to boost the volume without clipping the audio.
echo is offline   Reply With Quote
Old 18th December 2006, 01:07   #5  |  Link
Staz
Registered User
 
Staz's Avatar
 
Join Date: May 2004
Posts: 128
I have been getting perfect results by exporting to .wav with mencoder, encoding to vbr mp3 with lame and then by using the following command in mp3gain:

Code:
mp3gain -r -k
I get the maximum gain possible without any clipping at all! Thanks everyone
Staz is offline   Reply With Quote
Old 2nd January 2007, 17:20   #6  |  Link
JVz
Registered User
 
Join Date: Dec 2006
Location: Chicago
Posts: 3
Have you considered using MPlayer's built-in LAME support instead?
JVz is offline   Reply With Quote
Old 13th January 2007, 23:16   #7  |  Link
lpn1160
open source geek
 
Join Date: Jun 2003
Location: global
Posts: 76
mplayer dvd://1 −alang en −dumpaudio −dumpfile audio.ac3 && ffmpeg -i audio.ac3 audio.wav && lame --abr 192 audio.wav

exit 0
clear
lpn1160 is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

Forum Jump


All times are GMT +1. The time now is 21:16.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.