mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-29 05:40:23 -04:00
sink,source: Add the ability to disable alternat sample rate switching
Setting the alternate sample rate to 0 in config disables this feature.
This commit is contained in:
parent
b9ff90fef8
commit
ac469a25c0
3 changed files with 6 additions and 3 deletions
|
|
@ -420,7 +420,8 @@ USA.
|
|||
default-rate-rate value or this alternate value, typically 44.1
|
||||
or 48kHz. Switching between default and alternate values is
|
||||
enabled only when the sinks/sources are suspended. This option
|
||||
is ignored in passthrough mode where the stream rate will be used.</p>
|
||||
is ignored in passthrough mode where the stream rate will be used.
|
||||
If set to zero, this feature is disabled.</p>
|
||||
</option>
|
||||
|
||||
</section>
|
||||
|
|
|
|||
|
|
@ -2201,7 +2201,8 @@ pa_sink *pa_alsa_sink_new(pa_module *m, pa_modargs *ma, const char*driver, pa_ca
|
|||
u->sink->update_requested_latency = sink_update_requested_latency_cb;
|
||||
u->sink->set_state = sink_set_state_cb;
|
||||
u->sink->set_port = sink_set_port_cb;
|
||||
u->sink->update_rate = sink_update_rate_cb;
|
||||
if (u->sink->alternate_sample_rate)
|
||||
u->sink->update_rate = sink_update_rate_cb;
|
||||
u->sink->userdata = u;
|
||||
|
||||
pa_sink_set_asyncmsgq(u->sink, u->thread_mq.inq);
|
||||
|
|
|
|||
|
|
@ -1939,7 +1939,8 @@ pa_source *pa_alsa_source_new(pa_module *m, pa_modargs *ma, const char*driver, p
|
|||
u->source->update_requested_latency = source_update_requested_latency_cb;
|
||||
u->source->set_state = source_set_state_cb;
|
||||
u->source->set_port = source_set_port_cb;
|
||||
u->source->update_rate = source_update_rate_cb;
|
||||
if (u->source->alternate_sample_rate)
|
||||
u->source->update_rate = source_update_rate_cb;
|
||||
u->source->userdata = u;
|
||||
|
||||
pa_source_set_asyncmsgq(u->source, u->thread_mq.inq);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue