-
-
Notifications
You must be signed in to change notification settings - Fork 371
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is it possible to "push" audio to a device, like SDL_QueueAudio? #744
Comments
I'm not familiar with SDL_QueueAudio, but I suspect it's just the ability for you post a chunk of audio data to the device and it'll get played when the device get's to it. No, this is not currently supported directly (though of course you can do this yourself with a custom data source). This is something that a lot of people have asked for, and is something I want to support in some form. It's unlikely I'll support it directly with I'll keep this issue open as a feature request, but there is no timeline on when I'll get to this (probably won't be this year). |
+1 from me. I also have a use case where I already have a callback that receives audio data, and if there was an API in miniaudio to directly push the the PCM data into a data source, that would be great. |
It should be feasible to have something like ma_audio_queue queue;
ma_audio_queue_init(..., &queue);
ma_sound_init_from_data_source(..., &queue, ..., &sound); And then when new data needs to be pushed, do something like this: // Push data directly to the underlying data source. The sound will pick it up at playback time.
ma_audio_queue_push(&queue, dataSize, pData); So long as |
@SomeGuyDoinWork Did you manage to get something working with pl_mpeg and miniaudio? I have ended up in the same situation. |
Trying to get audio data from another library (pl_mpeg) and it has a callback that pushes the audio to a device. Does miniaudio support anything similar?
The text was updated successfully, but these errors were encountered: