I am seeing problems on iOS where the input and output timestamps are
consistently out of alignment.

The output timestamp should be the real HostTime that the output reaches
the speakers, yes? And the input HostTime should be the HostTime that the
input reaches the mic?

To test this, I tried writing a single full-amplitude sample every 44100
samples, printing the timestamp passed in to the output callback,
TimeStamp->mHostTime, plus the frame offset into the vector.

Meanwhile the input callback listens for samples that exceed a peak
theshold. When the peak occurs, I print TimeStamp->mHostTime plus the frame
offset into the vector.

The input timestamp is consistently late, by 30-40ms. The lateness changes
when I try different vector sizes, but stays consistent within a few
milliseconds once audio is started.

Any idea what could be causing this? Am I using the timestamps incorrectly?

I need to precisely correlate input and output times for a recording app.

Thanks!
jhno
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/coreaudio-api/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to