Understanding the Model
Understanding the Model
- Subject: Understanding the Model
- From: email@hidden
- Date: Thu, 4 Dec 2003 19:13:45 +0100 (NFT)
- Organisation: "Groupe Bull S.A., Grenoble, France"
While waiting for the arrival of my new Mac I have been reading what
information I can find regarding CoreAudio but I am left with a number
of questions regarding the overall model.
Firstly from the introductory material that I've found (CoreAudio for
Panther - CoreAudio.pdf dated 25/8/2003), here is how I imagine I would
have to proceed to play a note, say middle-A (440Hz), either to the
built-in speaker or a line-out:
1) Sample a sine wave:
Use the math sin function to sample a cycle at 440Hz, at say
44.1KHz using a 32-bit signed floating point number.
Save the sample in an in-memory buffer.
2) Create an AudioFile object that points to buffer created above
Do I need any additional AudioFormat objects?
I presume that there are methods in the AudioFile object that will
allow me to loop through (re-read) the buffer at will (or a certain
number of times).
3) Create an AudioUnit object and invoke the methods to pull the data
from the AudioFile created in step 2.
This will convert the sampled data to an appropriate form (in this
case analogue) and send it to the default or system output device.
Is this understanding correct?
Now if I want to shape the sine wave (add reverb, resonance etc...) must
this be done on the input data or can I add modules to perform each
shaping operation and then insert them between the input AudioFile and
the OutputDevice using an AUGraph object? In the latter case, I presume
that the modules must be implemented as AudioUnit objects. Are there
any Apple-provided objects that perform such transformations?
On the diagram at:
http://developer.apple.com/audio/coreaudio.html the
audio toolbox contains a Reverb object, yet this does not appear in the
latest pdf. Has this object been depricated?
Does the java.sound API use CoreAudio? What is the relationship between
the java.sound api and the java api to CoreAudio?
Is there a java interface to the vDSP routines (FFT etc...)?
Is the audio sdk included with the Jaguar developer tools or will I have
to download it seperately?
With thanks for any answers....
jez
-------
XS-BU Architecture,
mailto:email@hidden
Groupe Bull S.A.,
1 rue de Provence,
38432 Echirolles CEDEX
France.
_______________________________________________
coreaudio-api mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/coreaudio-api
Do not post admin requests to the list. They will be ignored.