| 236 | } |
| 237 | |
| 238 | float Port::getSampleRate() { |
| 239 | if (!device) |
| 240 | return 0; |
| 241 | try { |
| 242 | return device->getSampleRate(); |
| 243 | } |
| 244 | catch (Exception& e) { |
| 245 | WARN("Audio port could not get device sample rate: %s", e.what()); |
| 246 | return 0; |
| 247 | } |
| 248 | } |
| 249 | |
| 250 | void Port::setSampleRate(float sampleRate) { |
| 251 | if (!device) |