mirror of
https://github.com/mackron/miniaudio.git
synced 2026-04-22 00:06:59 +02:00
Update ma_audio_buffer_ref_init() to take a buffer.
This saves a mandatory call to ma_audio_buffer_ref_set_data(). With this change, an ma_audio_buffer_ref_init() call is all that is required to initialize a usable data source.
This commit is contained in:
@@ -87,7 +87,7 @@ int main(int argc, char** argv)
|
||||
|
||||
|
||||
/* Source/carrier. Attached to input bus 0 of the vocoder node. */
|
||||
result = ma_audio_buffer_ref_init(device.capture.format, device.capture.channels, &g_sourceData);
|
||||
result = ma_audio_buffer_ref_init(device.capture.format, device.capture.channels, NULL, 0, &g_sourceData);
|
||||
if (result != MA_SUCCESS) {
|
||||
printf("Failed to initialize audio buffer for source.");
|
||||
goto done2;
|
||||
|
||||
Reference in New Issue
Block a user