hello, I'm new here. I am a developer. MacOSX 10.7
I have a portaudio (v1.9) specific question.
I'm writing a program that records audio. Using a callback.
I'm trying to synchronise audio and MIDI as precisely as possible.
That is, I send MIDI notes to an external synth device, and record the audio that's played.
Just after calling Pa_StartStream(), I get the Start Time with Pa_GetStreamTime().
About 370 ms later, when the 1st call back is fired, the ADC time of the 1st audio input buffer is 8 millisecond before the Start Time.
what does that means ?
seems that portaudio (upon CoreAudio) was already recording before I told it ?
And, why always 8 ms ?
What kind of accuracy can portaudio achieve ?
If any idea … thank you !
greetings
portaudio timing
Forum rules
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
If you require help using Audacity, please post on the forum board relevant to your operating system:
Windows
Mac OS X
GNU/Linux and Unix-like
Re: portaudio timing
Topic moved to "General Audio Programming".
You would probably do better to ask this type of question on the Portaudio mailing list. The Audacity developers rarely come to the forum, and when they do they generally only respond to questions that are specifically about Audacity.
See my previous post for how to contact Portaudio. http://forum.audacityteam.org/viewtopic ... 02#p228802
You would probably do better to ask this type of question on the Portaudio mailing list. The Audacity developers rarely come to the forum, and when they do they generally only respond to questions that are specifically about Audacity.
See my previous post for how to contact Portaudio. http://forum.audacityteam.org/viewtopic ... 02#p228802
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)
Re: portaudio timing
Just a quick thought.
8ns = 0.008 = 1/125 which in turn is 384 samples (typical aligned small buffer) from a 48000hrz sample rate.
You're always going to have latency equal to the size of your buffer.
8ns = 0.008 = 1/125 which in turn is 384 samples (typical aligned small buffer) from a 48000hrz sample rate.
You're always going to have latency equal to the size of your buffer.