Active Topics

 


Reply
Thread Tools
debernardis's Avatar
Posts: 2,142 | Thanked: 2,054 times | Joined on Dec 2006 @ Sicily
#1
When trying to convert two divx videos I had with 770encode.pl (default parameters, preset=mplayer), the resulting avi files played a loud, harsh noise instead of the original track. Same results with media converter. I had never this problem when ripping dvd's.

The audio track of those divx videos was in mp3 and I thought the problem could be that it was not rightly decoded and re-encoded, so instead of using wrapper programs I turned directly to mencode, changing the audio encoder from "mp3lame" to "copy". This way, the audio output was correct but the resulting file were almost as large as the original ones.

What kind of command line should I use to get an acceptable audio result while still reducing the file size to around 400 megabytes? Alternatively, what parameters should I pass to 770encode.pl or media converter to avoid that cacophony?

Thanks for your answers :-)
 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#2
What version of mencoder do you have installed? (just type `mencoder' on its own).

What operating system are you running, and on what kind of PC?

I've never had that problem with 770-encode (obviously, or I'd've fixed it) on my Mac, Windows machines or numerous Linux boxes - but given 770-encode is just a thin wrapper around mencoder, your problem probably lies there (definitely so, given it also happens with Media Converter).

So... we'll just have to get to the bottom of what... ;-)
__________________
Andrew Flegg -- mailto:andrew@bleb.org | http://www.bleb.org
Now known as
Jaffa
 
debernardis's Avatar
Posts: 2,142 | Thanked: 2,054 times | Joined on Dec 2006 @ Sicily
#3
Mencoder version:
Code:
$ mencoder
MEncoder 2:1.0~rc1-0ubuntu9.1 (C) 2000-2006 MPlayer Team
CPU: AMD Athlon(tm) 64 Processor 3500+ (Family: 15, Model: 47, Stepping: 2)
CPUflags: Type: 15 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
No file given

Exiting... (error parsing command line)
OS: Ubuntu Feisty, 2.6.20-16-generic kernel

Any hint? Thanks...
 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#4
Very similar setup to my own (although I upgraded to Gutsy a couple of weeks ago). Using Ubuntu's standard mencoder, I get:

Code:
andrew@serenity:~/Pending$ mencoder 
MEncoder 2:1.0~rc1-0ubuntu13 (C) 2000-2006 MPlayer Team
CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 4600+ (Family: 15, Model: 75, Stepping: 2)
CPUflags: Type: 15 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
No file given

Exiting... (error parsing command line)
andrew@serenity:~/Pending$ uname -a
Linux serenity 2.6.22-14-generic #1 SMP Sun Oct 14 21:45:15 GMT 2007 x86_64 GNU/Linux
Could you send me the original files? If they're too big, a command like the following should be sufficient:

Code:
dd if=theOriginal.avi of=cutDownVersion.avi bs=1M count=4
That should give you the first 4MB of "theOriginal.avi" in "cutDownVersion.avi" which should be plenty to help diagnose the problem.

Thanks for your help in getting to the bottom of this.

Cheers,

Andrew
__________________
Andrew Flegg -- mailto:andrew@bleb.org | http://www.bleb.org
Now known as
Jaffa
 
debernardis's Avatar
Posts: 2,142 | Thanked: 2,054 times | Joined on Dec 2006 @ Sicily
#5
I am just sending you the 4M sample; trying to convert it with 770encode.pl produced plenty of noise.
 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#6
Thanks - received it, will investigate after I get back from taking the family kite flying.

Initial test seems to convert properly (assuming it's supposed to be in Not English ;-)) on my box with the following command and output:

Code:
andrew@serenity:~/Pending$ 770-encode sicko4M.avi test.avi
Width needs trimming by 0.166666666666667 from 240 x 128
Invoking mencoder sicko4M.avi -o test.avi -srate 44100 -channels 1 -oac mp3lame -lameopts vbr=0:br=32:mode=3 -af volnorm,channels=1 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=80 -vf-add crop=533:320 -vf-add scale=240:144 -ofps 11.988 -ffourcc DIVX -noidx -force-avi-aspect 1.66666666666667...
MEncoder 2:1.0~rc1-0ubuntu13 (C) 2000-2006 MPlayer Team
CPU: AMD Athlon(tm) 64 X2 Dual Core Processor 4600+ (Family: 15, Model: 75, Stepping: 2)
CPUflags: Type: 15 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
success: format: 0  data: 0x0 - 0x400000
AVI file format detected.
VIDEO:  [XVID]  640x320  12bpp  23.976 fps  629.8 kbps (76.9 kbyte/s)
[V] filefmt:3  fourcc:0x44495658  size:640x320  fps:23.98  ftime:=0.0417
==========================================================================
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16le, 160.0 kbit/11.34% (ratio: 20000->176400)
Selected audio codec: [mp3] afm: mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1, osd: 1, aspect: 0.000000, round: 1
Opening video filter: [scale w=240 h=144]
Opening video filter: [crop w=533 h=320]
Crop: 533 x 320, -1 ; -1
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
==========================================================================
Forcing output FourCC to 58564944 [DIVX].
VDec: vo config request - 640 x 320 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 2.00:1 - prescaling to correct movie aspect.
videocodec: libavcodec (240x144 fourcc=58564944 [DIVX])
Writing header...1f ( 0%)  0.00fps Trem:   0min   0mb  A-V:0.000 [0:0]
ODML: vprp aspect is 16384:9830.
Writing header...
ODML: vprp aspect is 16384:9830.
Pos:  75.9s   1821f ( 0%) 370.05fps Trem:  13min 191mb  A-V:0.135 [90:31]
Broken frame at 0x11812C                                                  
Pos:  75.9s   1822f ( 0%) 370.10fps Trem:  13min 191mb  A-V:0.137 [90:31]
Flushing video frames
Writing index...
Writing header...
ODML: vprp aspect is 16384:9830.

Video stream:   90.043 kbit/s  (11255 B/s)  size: 854390 bytes  75.909 secs  1822 frames

Audio stream:   32.000 kbit/s  (3999 B/s)  size: 305319 bytes  76.330 secs
andrew@serenity:~/Pending$
What output do you get for it? That might help track down the differences.
__________________
Andrew Flegg -- mailto:andrew@bleb.org | http://www.bleb.org
Now known as
Jaffa
 
debernardis's Avatar
Posts: 2,142 | Thanked: 2,054 times | Joined on Dec 2006 @ Sicily
#7
The output seems absolutely the same. I also upgraded to gutsy, so the mencoder version is the same, but still I have noise instead that the original audiotrack. Very strange. Might be something in mp3lib?

Here is my output:
Code:
~/Desktop$ ../770-encode.pl sicko4M.avi out.avi
Width needs trimming by 0.166666666666667 from 240 x 128
Invoking mencoder sicko4M.avi -o out.avi -srate 44100 -channels 1 -oac mp3lame -lameopts vbr=0:br=32:mode=3 -af volnorm,channels=1 -ovc lavc -lavcopts vcodec=mpeg4:vbitrate=80 -vf-add crop=533:320 -vf-add scale=240:144 -ofps 11.988 -ffourcc DIVX -noidx -force-avi-aspect 1.66666666666667...
MEncoder 2:1.0~rc1-0ubuntu13 (C) 2000-2006 MPlayer Team
CPU: AMD Athlon(tm) 64 Processor 3500+ (Family: 15, Model: 47, Stepping: 2)
CPUflags: Type: 15 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
success: format: 0  data: 0x0 - 0x400000
AVI file format detected.
VIDEO:  [XVID]  640x320  12bpp  23.976 fps  629.8 kbps (76.9 kbyte/s)
[V] filefmt:3  fourcc:0x44495658  size:640x320  fps:23.98  ftime:=0.0417
==========================================================================
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16le, 160.0 kbit/11.34% (ratio: 20000->176400)
Selected audio codec: [mp3] afm: mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1, osd: 1, aspect: 0.000000, round: 1
Opening video filter: [scale w=240 h=144]
Opening video filter: [crop w=533 h=320]
Crop: 533 x 320, -1 ; -1
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffodivx] vfm: ffmpeg (FFmpeg MPEG-4)
==========================================================================
Forcing output FourCC to 58564944 [DIVX].
VDec: vo config request - 640 x 320 (preferred colorspace: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is 2.00:1 - prescaling to correct movie aspect.
videocodec: libavcodec (240x144 fourcc=58564944 [DIVX])
Writing header...1f ( 0%)  0.00fps Trem:   0min   0mb  A-V:0.000 [0:0]
ODML: vprp aspect is 16384:9830.
Writing header...
ODML: vprp aspect is 16384:9830.
Pos:  75.9s   1820f ( 0%) 262.06fps Trem:  19min 194mb  A-V:0.135 [91:31]
Broken frame at 0x11812C
Pos:  76.0s   1822f ( 0%) 261.93fps Trem:  19min 194mb  A-V:0.140 [92:31]
Flushing video frames
Writing index...
Writing header...
ODML: vprp aspect is 16384:9830.

Video stream:   92.048 kbit/s  (11506 B/s)  size: 874373 bytes  75.993 secs  1822 frames

Audio stream:   32.000 kbit/s  (3999 B/s)  size: 305319 bytes  76.330 secs
__________________
Ernesto de Bernardis

 
Posts: 87 | Thanked: 33 times | Joined on Aug 2007
#8
I had the same problem on my new installed Linux-Desktop and solved it by editing the file /etc/mplayer/codecs.conf:
move the entry "audiocodec mad" before the entry "audiocodec mp3".
 
debernardis's Avatar
Posts: 2,142 | Thanked: 2,054 times | Joined on Dec 2006 @ Sicily
#9
Thanks, this worked for me too.
Though, I had no /etc/mplayer/codecs.conf so I searched for it into the filesystem of my newly upgraded ubuntu gutsy box.
There was something like that in /usr/share/doc/mplayer/examples/etc/codecs.conf.gz so I gunzipped it, edited it by moving the "audiocodec mad" full section just before the "audiocodec mp3" section, and copied into /etc/mplayer .
So far, so good! Thanks, Nikem...
__________________
Ernesto de Bernardis

 
aflegg's Avatar
Posts: 1,463 | Thanked: 81 times | Joined on Oct 2005 @ UK
#10
Excellent. I'll make sure the next release of tablet-encode (as 770-encode will be called in future) references this thread.
__________________
Andrew Flegg -- mailto:andrew@bleb.org | http://www.bleb.org
Now known as
Jaffa
 
Reply


 
Forum Jump


All times are GMT. The time now is 20:14.