Open zjli-2019 opened 5 years ago
Our AudioQueue API is unfortunately not the best bindings we've created 😒. I had a quick look, and I saw many ways it can be improved, but the fact that we must be backwards compatible makes it much more complicated sometimes. I've filed #6411 so that hopefully one day we can fix this.
I am working on iOS audio. After struggling with IntPtr-s, which might be a AudioQueueBuffer*, or pointing to raw samples, I finally managed to make things work.
But, I find below code seems not a good practice.
https://github.com/xamarin/xamarin-macios/blob/e45c3ba794e25c4ecb1c076678b733746ca184e4/src/AudioToolbox/AudioQueue.cs#L499
Steps to Reproduce
Check the source code of AudioQueue.FillAudioData(...).
Expected Behavior
Actual Behavior
The implementation seems not a good one.
Environment
N/A
Build Logs
N/A
Example Project (If Possible)
N/A