Bug 42957 - avoid sample rate conversion when hardware supports it
Summary: avoid sample rate conversion when hardware supports it
Status: RESOLVED INVALID
Alias: None
Product: PulseAudio
Classification: Unclassified
Component: core (show other bugs)
Version: unspecified
Hardware: All All
: medium enhancement
Assignee: pulseaudio-bugs
QA Contact: pulseaudio-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-15 13:42 UTC by sam.right
Modified: 2011-11-16 04:57 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments

Description sam.right 2011-11-15 13:42:40 UTC
It looks like when hardware is initialised the sample rate is kind of fixed even though hardware are capable of multiple sample rates. 

Therefore I think it's better to act on first come and fist serve dynamic sample rates mode if the hardware can support it. For example if 44.1K audio is being sent to pulseaudio then if the hardware supports 44.1k sample rate then it should use 44.1k sample rate and while minutes later if a 48K audio is being sent to it and as the same time 44.1k audio is being played then the 48K audio should be re-sampled to 44.1K. 

This way we can have the best available audio quality and at the same time to avoid SRC which is painfully slow on embedded devices.
Comment 1 Arun Raghavan 2011-11-15 20:55:57 UTC
This has already been implemented in git master. See:

http://arunraghavan.net/2011/10/alternate-sample-rates/

The only addition to that is that we are now more aggressive in trying to switch formats as well (we try to switch even when streams are connected by only one of them is starting to play, for example).
Comment 2 sam.right 2011-11-16 04:57:19 UTC
WoW. Will definitely give it a try when it's released.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.