audio objects 'update' relations

Status
Not open for further replies.

rvh

Well-known member
I'm new to the teensy and its AudioLibrary, so please excuse the multiple questions. Firstly, where can I find out how the update routines are invoked for multiple audio objects in a a project? Are they all serviced synchronously once every 128 samples (by default)? And perhaps in the order dictated by your Audioconnections declarations? Also, if I have a stereo stream, is the update at the same time interval, meaning every 256 samples and left/right interleaved in the audioblock? Lastly, presumably if I want to add my own audio object, do I simply link it to other objects using Audio connections?

I'm sure this must all be documented somewhere, but I'm having trouble finding it. Feel free to just ponit me to the relevant documentation. Thanks very much.
 
Firstly, where can I find out how the update routines are invoked for multiple audio objects in a a project?

The AudioStream.cpp source code is where.

And this forum... ;)



Are they all serviced synchronously once every 128 samples (by default)?

Yup.


And perhaps in the order dictated by your Audioconnections declarations?

In the order the objects (not their connections) are instantiated.


Also, if I have a stereo stream, is the update at the same time interval, meaning every 256 samples and left/right interleaved in the audioblock?

As far as the audio system is concerned, there is no stereo. All connections are mono. But a good number of objects happen to have 2 of them.


Lastly, presumably if I want to add my own audio object, do I simply link it to other objects using Audio connections?

Yes. You follow this API when writing the code.

https://www.pjrc.com/teensy/td_libs_AudioNewObjects.html

Then your object can connect when any others in the library.


I'm sure this must all be documented somewhere, but I'm having trouble finding it. Feel free to just ponit me to the relevant documentation.

Some parts aren't really well documented. The 31 page tutorial was originally intended to have 4 sections instead of only 3, where the 4 would dive deep into the internals of the library and how you add your own synthesis and effects. But there are never enough hours in every day and sadly that part was never written. But there is at least 1 web page about the API, which hopefully makes reading the code easier.
 
Status
Not open for further replies.
Back
Top