From: Timur Tabi <timur@freescale.com>
To: Clemens Ladisch <cladisch@fastmail.net>
Cc: Takashi Iwai <tiwai@suse.de>, alsa-devel@alsa-project.org
Subject: Re: Confused about 'default' device
Date: Wed, 24 Oct 2007 11:36:09 -0500 [thread overview]
Message-ID: <471F7479.9000602@freescale.com> (raw)
In-Reply-To: <1193225838.26984.1217558213@webmail.messagingengine.com>
Clemens Ladisch wrote:
> Takashi Iwai wrote:
>> Timur Tabi wrote:
>>> I'm having a hard time understand when ALSA does sample rate and format
>>> conversion, and when it doesn't.
>>>
>>> When I issue the following command:
>>>
>>> mplayer -ao alsa filename.mov -v
>>>
>>> I get this output:
>>> ...
>>> alsa-init: using device default
>>> alsa-init: format s24le are not supported by hardware
>>>
>>> I was under the impression that ALSA can do format and sample rate conversion if
>>> necessary, but I guess that's not always the case.
>> It does. mplayer seems to try first the hardware device without
>> conversion and falls back to "default" PCM.
>
> In this case, it uses only the "default" PCM device. There seems to be
> some problem with its definition.
>
> Are there any definitions in ~/.asoundrc or /etc/asound.conf? If not,
> what driver is used, and does it have a file in /usr/share/alsa/cards/?
Ok, I made some progress.
According to http://alsa.opensrc.org/.asoundrc, because I'm using ALSA 1.0.8, I
need to have an .asoundrc. So I added this .asoundrc:
pcm.!default {
type hw
card 0
}
ctl.!default {
type hw
card 0
}
And now sample rate conversion works! However, sample format conversion does
not work. When I try to play a movie with an s24le sound track, I get this:
$ MPlayer-1.0rc1/mplayer -ao alsa
video/320x240/sm3_sneak_peek.mov
MPlayer 1.0rc1-3.3.5 (C) 2000-2006 MPlayer Team
AltiVec found
CPU: PowerPC
Playing video/320x240/sm3_sneak_peek.mov.
ISO: File Type Major Brand: Original QuickTime
Quicktime/MOV file format detected.
VIDEO: [avc1] 320x240 24bpp 29.970 fps 0.0 kbps ( 0.0 kbyte/s)
vo: couldn't open the X11 display ()!
vo: couldn't open the X11 display ()!
VO XOverlay need a subdriver
vo: couldn't open the X11 display ()!
==========================================================================
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family
Selected video codec: [ffh264] vfm: ffmpeg (FFmpeg H.264)
==========================================================================
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 48000 Hz, 2 ch, s24le, 2304.0 kbit/100.00% (ratio:
288000->288000)
Selected audio codec: [pcm] afm: pcm (Uncompressed PCM)
==========================================================================
alsa-init: format s24le are not supported by hardware, trying default
alsa-init: unable to set format: Invalid argument
Could not open/initialize audio device -> no sound.
Audio: no sound
Starting playback...
VDec: vo config request - 320 x 240 (preferred colorspace: Planar YV12)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
VDec: using Planar YV12 as output csp (no 0)
Movie-Aspect is undefined - no prescaling applied.
SwScaler: using unscaled yuv420p -> rgb32 special converter
VO: [fbdev] 320x240 => 320x240 ARGB
V: 2.4 74/ 74 4% 5% 0.0% 0 0
Exiting... (Quit)
Does this mean that sample rate conversion is supported, but not sample format
conversion?
next prev parent reply other threads:[~2007-10-24 16:36 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-23 19:40 Confused about 'default' device Timur Tabi
2007-10-23 20:45 ` Timur Tabi
2007-10-24 8:54 ` Takashi Iwai
2007-10-24 11:37 ` Clemens Ladisch
2007-10-24 12:35 ` Rene Herman
2007-10-24 12:41 ` Clemens Ladisch
2007-10-24 12:42 ` Rene Herman
2007-10-24 16:36 ` Timur Tabi [this message]
2007-10-25 7:02 ` Clemens Ladisch
2007-10-25 14:16 ` Timur Tabi
2007-10-25 15:02 ` Clemens Ladisch
2007-10-25 15:03 ` Timur Tabi
2007-10-26 6:45 ` Clemens Ladisch
2007-10-26 14:00 ` Timur Tabi
2007-10-26 14:43 ` Clemens Ladisch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=471F7479.9000602@freescale.com \
--to=timur@freescale.com \
--cc=alsa-devel@alsa-project.org \
--cc=cladisch@fastmail.net \
--cc=tiwai@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.