* @brief Sets the selected sample rate index for the input device. */
| 839 | * @brief Sets the selected sample rate index for the input device. |
| 840 | */ |
| 841 | void IO::Drivers::Audio::setSelectedSampleRate(int index) |
| 842 | { |
| 843 | if (isOpen()) |
| 844 | return; |
| 845 | |
| 846 | if (index < 0 || index >= sampleRates().size()) |
| 847 | index = 0; |
| 848 | |
| 849 | m_selectedSampleRate = index; |
| 850 | configureInput(); |
| 851 | persistSettings(); |
| 852 | } |
| 853 | |
| 854 | //-------------------------------------------------------------------------------------------------- |
| 855 | // Input device parameter setters |