ao_coreaudio: simplify digital render callback

It was reported that it also works by not setting the read size in the
AudioBuffer (now idea how, but I will discover it later).
This commit is contained in:
Stefano Pigozzi
2013-07-22 21:53:17 +02:00
parent 8cf36cf950
commit c4bed92280
+3 -4
View File
@@ -124,11 +124,10 @@ static OSStatus render_cb_digital(
AudioBuffer buf = out_data->mBuffers[p->i_stream_index];
int requested = buf.mDataByteSize;
if (p->b_muted) {
if (p->b_muted)
mp_ring_drain(p->buffer, requested);
} else {
buf.mDataByteSize = mp_ring_read(p->buffer, buf.mData, requested);
}
else
mp_ring_read(p->buffer, buf.mData, requested);
return noErr;
}