[MPlayer-users] Mencoder (1.0pre5, latest CVS) unable to record sound, 1.0pre3try2 works

Sakari Ailus sakari.ailus at saunalahti.fi
Sat Oct 23 20:19:13 CEST 2004


Hi,

It looks like recording sound does not work with latest versions of 
mencoder, while 1.0pre3try2 is still ok.

Here's output from the latest CVS version:

---
mencoder  tv:// -passlogfile /tmp/mrec-tmp-8812 -oac mp3lame -lavcopts 
vqscale=7:vcodec=mpeg4 -ovc lavc -o baz.avi -tv 
driver=v4l2:height=576:device=/dev/video0:adevice=/dev/dsp2:width=768 
-lameopts aq=0:vbr=0:br=64
MEncoder dev-CVS-041023-19:16-3.4.2 (C) 2000-2004 MPlayer Team

CPU: Advanced Micro Devices Athlon MP/XP Thoroughbred (Family: 6, 
Stepping: 1)
Detected cache-line size is 64 bytes
CPUflags: Type: 6 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 0
Compiled with runtime CPU detection - WARNING - this is not optimal!
To get best performance, recompile MPlayer with 
--disable-runtime-cpudetection.
Reading /home/sakke/.mplayer/codecs.conf: This codecs.conf is too old 
and incompatible with this MPlayer release! at line 6
Reading /etc/mplayer/codecs.conf: Can't open '/etc/mplayer/codecs.conf': 
No such file or directory
Using built-in default codecs.conf.
File not found: 'frameno.avi'
Failed to open frameno.avi
Reading config file /home/sakke/.mplayer/mencoder
Font /home/sakke/.mplayer/font/font.desc loaded successfully! (206 chars)
success: format: 9  data: 0x0 - 0x0
TV detected! ;-)
Selected driver: v4l2
  name: Video 4 Linux 2 input
  author: Martin Olschewski <olschewski at zpr.uni-koeln.de>
  comment: first try, more to come ;-)
Selected device: BT878 video (Pinnacle PCTV Stud
  Tuner cap:
  Tuner rxs: MONO
  Capabilites:  video capture  video overlay  VBI capture device  tuner 
  read/write  streaming
  supported norms: 0 = PAL; 1 = NTSC; 2 = SECAM; 3 = PAL-Nc; 4 = PAL-M; 
5 = PAL-N; 6 = NTSC-JP; 7 = PAL-60;
  inputs: 0 = Television; 1 = Composite1; 2 = S-Video;
  Current input: 0
  Current format: YUV420
v4l2: current audio mode is : MONO
audio block size too low, setting to 8192!
[V] filefmt:9  fourcc:0x32315659  size:768x576  fps:25.00  ftime:=0.0400
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 44101 Hz, 1 ch, 16 bit (0x10), ratio: 88202->88202 (705.6 kbit)
Selected audio codec: [pcm] afm:pcm (Uncompressed PCM)
==========================================================================
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1  (-1=autodetect) osd: 1
==========================================================================
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 768 x 576 (preferred csp: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is undefined - no prescaling applied.
videocodec: libavcodec (768x576 fourcc=58564944 [DIVX])
Using constant qscale = 7.000000 (VBR)
Selected video codec: [rawyv12] vfm:raw (RAW YV12)
==========================================================================
MP3 audio selected
Building audio filter chain for 44101Hz/1ch/16bit -> 44101Hz/1ch/16bit...
Writing AVI header...
ODML: Aspect information not (yet?) available or unspecified, not 
writing vprp header.
Forcing audio preload to 0, max pts correction to 0
ODML: Aspect information not (yet?) available or unspecified, not 
writing vprp header.
v4l2: select failed: Interrupted system calln   0mb  A-V:0.000 [1118:0]

not enough audio samples!
Pos:   9.4s    234f ( 0%)  25fps Trem:   0min   0mb  A-V:0.000 [1118:0]
Flushing video frames
---

The sound is recorded from a sound card /dev/dsp2 with OSS driver. It 
looks like mencoder detects number of channels etc. correcly, but still 
is unable to record any sound. The bit rate for sound is zero.

The TV tuner card uses bttv driver from V4L2.

Here's log from 1.0pre3try2, which works. The command line options are 
the same with the excepion of file name in case you're wondering.

---
encoder  tv:// -passlogfile /tmp/mrec-tmp-8943 -oac mp3lame -lavcopts 
vqscale=7:vcodec=mpeg4 -ovc lavc -o bar.avi -tv 
driver=v4l2:height=576:device=/dev/video0:adevice=/dev/dsp2:width=768 
-lameopts aq=0:vbr=0:br=64
MEncoder 1.0pre3try2-3.3.1 (C) 2000-2003 MPlayer Team

CPU: Advanced Micro Devices Athlon MP/XP Thoroughbred 2010 MHz (Family: 
6, Stepping: 1)
Detected cache-line size is 64 bytes
CPUflags: Type: 6 MMX: 1 MMX2: 1 3DNow: 1 3DNow2: 1 SSE: 1 SSE2: 0
Compiled with Runtime CPU Detection - WARNING - this is not optimal!
To get best performance, recompile MPlayer with 
--disable-runtime-cpudetection.
Reading /home/sakke/.mplayer/codecs.conf: This codecs.conf is too old 
and incompatible with this MPlayer release! at line 6
Reading /etc/mplayer/codecs.conf: Can't open '/etc/mplayer/codecs.conf': 
No such file or directory
Using built-in default codecs.conf.
File not found: 'frameno.avi'
Failed to open frameno.avi
Reading config file /home/sakke/.mplayer/mencoder
Font /home/sakke/.mplayer/font/font.desc loaded successfully! (206 chars)
success: format: 9  data: 0x0 - 0x0
TV detected! ;-)
Selected driver: v4l2
  name: Video 4 Linux 2 input
  author: Martin Olschewski <olschewski at zpr.uni-koeln.de>
  comment: first try, more to come ;-)
Selected device: BT878 video (Pinnacle PCTV Stud
  Tuner cap:
  Tuner rxs: MONO
  Capabilites:  video capture  video overlay  VBI capture device  tuner 
  read/write  streaming
  supported norms: 0 = PAL; 1 = NTSC; 2 = SECAM; 3 = PAL-Nc; 4 = PAL-M; 
5 = PAL-N; 6 = NTSC-JP; 7 = PAL-60;
  inputs: 0 = Television; 1 = Composite1; 2 = S-Video;
  Current input: 0
  Current format: YUV420
v4l2: current audio mode is : MONO
audio block size too low, setting to 8192!
[V] filefmt:9  fourcc:0x32315659  size:768x576  fps:25.00  ftime:=0.0400
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 44100 Hz, 1 ch, 16 bit (0x10), ratio: 88200->88200 (705.6 kbit)
Selected audio codec: [pcm] afm:pcm (Uncompressed PCM)
==========================================================================
Opening video filter: [expand osd=1]
Expand: -1 x -1, -1 ; -1  (-1=autodetect) osd: 1
==========================================================================
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 768 x 576 (preferred csp: Planar YV12)
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is undefined - no prescaling applied.
videocodec: libavcodec (768x576 fourcc=58564944 [DIVX])
Using constant qscale = 7.000000 (VBR)
Selected video codec: [rawyv12] vfm:raw (RAW YV12)
==========================================================================
MP3 audio selected
Building audio filter chain for 44100Hz/1ch/16bit -> 44100Hz/1ch/16bit...
Writing AVI header...
Forcing audio preload to 0, max pts correction to 0
v4l2: select failed: Interrupted system calln   0mb  A-V:0.000 [2010:63]

not enough audio samples!
Pos:   2.2s     53f ( 0%)  21fps Trem:   0min   0mb  A-V:0.000 [1999:63]

CBR audio: 8000 bytes/sec, 209 bytes/block

Writing AVI index...
Fixing AVI header...

Video stream: 1999.581 kbit/s  (249947 bps)  size: 539887 bytes  2.160 
secs  53 frames

Audio stream:   63.999 kbit/s  (7999 bps)  size: 17136 bytes  2.142 secs
v4l2: 61 frames successfully processed, 0 frames dropped.
---

So far looks like a bug to me...

I don't know if this happens to everyone trying to record also sound 
with mencoder, but I've tried a few times and had the same result.

The newer mplayer was compiled with GCC 3.4.2, while the old one is with 
3.3.1. Should not matter, though...

-- 
Sakari Ailus
sakari.ailus at saunalahti.fi




More information about the MPlayer-users mailing list