Hi,
I have posted about this issue a few times.
So far, attempting to control the playback start times of 3 or 4 audioqueues by setting independant audiotimestamps in the AudioQueueEnqueueBufferWithParameters is not working.
I am using hosttime with the hosttime valid flags set in the sudiotimestamps. The times are derived form mach_absolute_time following some sample code originally from Doug Wyatt. The original code to get the host time has been re-written to be in Objective-C, but returns matching values to the sample code, so I don't think there is a problem with the times being set.
Is there a fundamental flaw in using this approach? ie. I set times at one second intervals in the time stamps, enqueue the buffers with those timestamps are parameters, then trigger playback by sending a notification to all three or four queues? As I understand the documentation, this should cause them to play in sequence starting 1 second apart, however they all just play loosely at once, the same playback I get if I pass NULL for the audiotimestamp in the enqueue buffer call, or when I was just calling AudioQueueEnqueueBuffer.
Any suggestions would be greatly appreciated.
|