cAudio  2.3.0
3d Audio Engine
cAudio 2.3.0 API documentation

Introduction

Welcome to the Main API Documentation for cAudio 2.3.0. cAudio is an advanced C++ wrapper around OpenAL, a professional and powerful audio library. Thus cAudio provides you with a number of classes to allow you to easily manipulate your audio world and intergrate audio effects like reverberation, doppler, attenuation, ect. cAudio also has a plugin system, allowing developers to extend the functionality of the library. Furthermore, cAudio is released under the zlib license, meaning it is free for you to use in your projects, even if they are commercial. Of course, we suggest you read the full text of the license by looking at the local license.txt file or cAudio.h.

Included with the SDK is a number of tutorials. We suggest you begin with them as they will guide you through the basics of cAudio usage and work up to more advanced topics.

Links

Namespaces: Central namespace for the entire engine. A good place to begin looking.
Class list: List of all classes in the engine with descriptions.
Class members: List of all methods.

Short example

Below is a simple "Hello World" example of how to use the engine. Of course this is only the "tip of the iceburg" when it comes to what cAudio is capable of.

#include <cAudio.h>
int main()
{
//Create an Audio Manager
//Create an audio source and load a sound from a file
cAudio::IAudioSource* mysound = manager->create("music","../../media/cAudioTheme1.ogg",true);
if(mysound)
{
//Play our source in 2D once.
mysound->play2d(false);
//Wait for the sound to finish playing
while(mysound->isPlaying())
}
//Shutdown cAudio
manager->shutDown();
return 0;
}
cAudio::createAudioManager
CAUDIO_API IAudioManager * createAudioManager(bool initializeDefault=true, const char *lFilePath="cAudioEngineLog.html")
Creates an interface to an Audio Manager.
Definition: cAudio.cpp:77
cAudio::IAudioManager::create
virtual IAudioSource * create(const char *name, const char *filename, bool stream=false)=0
Creates an Audio Source object using the highest priority data source that has the referenced filenam...
cAudio::cAudioSleep
CAUDIO_API void cAudioSleep(unsigned int ms)
Causes the current thread to give up control for a certain duration.
Definition: cAudioSleep.cpp:17
cAudio::IAudioSource::isPlaying
virtual bool isPlaying() const =0
Returns if the source is playing.
cAudio::IAudioManager
Interface for the playback capabilities of cAudio.
Definition: IAudioManager.h:24
cAudio::destroyAudioManager
CAUDIO_API void destroyAudioManager(IAudioManager *manager)
Destroys an interface to a previously created Audio Manager and frees the memory allocated for it.
Definition: cAudio.cpp:114
cAudio::IAudioManager::shutDown
virtual void shutDown()=0
Shuts the manager down, cleaning up audio sources in the process. Does not clean up decoders,...
cAudio::IAudioSource
Interface for a single audio source, which allow you to manipulate sound sources (speakers) in 2D or ...
Definition: IAudioSource.h:32
cAudio::IAudioSource::play2d
virtual bool play2d(const bool &toLoop=false)=0
Plays the source in 2D mode.