From: Timur Tabi <timur@freescale.com>
To: Takashi Iwai <tiwai@suse.de>
Cc: ALSA development <alsa-devel@alsa-project.org>
Subject: Re: Requiring the same sample rate for playback and record?
Date: Mon, 14 Jul 2008 16:25:04 -0500 [thread overview]
Message-ID: <487BC430.8040109@freescale.com> (raw)
In-Reply-To: <s5h7icg4dsd.wl%tiwai@suse.de>
Takashi Iwai wrote:
> Right now there is no "elegant" way for this, unfortunately.
> A common way many drivers use is to remember the rate of the first
> stream, then add it to hw_constraint of the secondary streams.
Can you give me an example of a driver that does this? I can't seem to find one.
> But, this could be also a bit racy (unavoidable due to its design)
> although practically it seems working.
I've been trying to implement this, but I'm not sure how. I have a couple
questions:
1) Which snd_pcm_hw_constraint_xxx function should I use to specify a sample
rate or sample size constraint of a single number? I'm thinking
snd_pcm_hw_constraint_list().
2) Where should I be calling this function? In my _hw_params() function? What
I would like to do is require the constraint to be enforced only when a stream
is already playing. That is, if playback is paused, then the capture stream can
set any sample rate it wants. Is this doable, or just too complicated?
--
Timur Tabi
Linux kernel developer at Freescale
next prev parent reply other threads:[~2008-07-14 21:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-20 19:08 Requiring the same sample rate for playback and record? Timur Tabi
2008-06-23 11:00 ` Takashi Iwai
2008-06-23 12:08 ` Timur Tabi
2008-06-23 12:10 ` Takashi Iwai
2008-07-14 21:25 ` Timur Tabi [this message]
2008-07-16 10:59 ` Takashi Iwai
2008-07-16 15:11 ` Timur Tabi
2008-07-16 15:17 ` Liam Girdwood
2008-07-16 15:24 ` Takashi Iwai
2008-07-16 19:19 ` Timur Tabi
2008-07-17 10:10 ` Takashi Iwai
2008-07-25 19:55 ` Timur Tabi
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=487BC430.8040109@freescale.com \
--to=timur@freescale.com \
--cc=alsa-devel@alsa-project.org \
--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.