mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Added support for lower sample rates to audio devices
This commit is contained in:
parent
926e1fe38f
commit
0b71fdb9a8
3 changed files with 8 additions and 3 deletions
|
|
@ -289,7 +289,8 @@ public:
|
|||
|
||||
if (OK (AudioObjectGetPropertyData (deviceID, &pa, 0, nullptr, &size, ranges)))
|
||||
{
|
||||
for (auto r : { 44100, 48000, 88200, 96000, 176400,
|
||||
for (auto r : { 8000, 11025, 16000, 22050, 32000,
|
||||
44100, 48000, 88200, 96000, 176400,
|
||||
192000, 352800, 384000, 705600, 768000 })
|
||||
{
|
||||
auto rate = (double) r;
|
||||
|
|
|
|||
|
|
@ -346,7 +346,9 @@ public:
|
|||
|
||||
if (asioObject != nullptr)
|
||||
{
|
||||
for (auto rate : { 32000, 44100, 48000, 88200, 96000, 176400, 192000, 352800, 384000, 705600, 768000 })
|
||||
for (auto rate : { 8000, 11025, 16000, 22050, 32000,
|
||||
44100, 48000, 88200, 96000, 176400,
|
||||
192000, 352800, 384000, 705600, 768000 })
|
||||
if (asioObject->canSampleRate ((double) rate) == 0)
|
||||
newRates.add ((double) rate);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -387,7 +387,9 @@ public:
|
|||
// Got a format that is supported by the device so we can ask what sample rates are supported (in whatever format)
|
||||
}
|
||||
|
||||
for (auto rate : { 44100, 48000, 88200, 96000, 176400, 192000, 352800, 384000, 705600, 768000 })
|
||||
for (auto rate : { 8000, 11025, 16000, 22050, 32000,
|
||||
44100, 48000, 88200, 96000, 176400,
|
||||
192000, 352800, 384000, 705600, 768000 })
|
||||
{
|
||||
if (rates.contains (rate))
|
||||
continue;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue