cinder::audio Namespace Reference

Classes

struct  BufferT
struct  BufferList
class  Callback
class  LoaderSourceCallback
class  CocoaCaConverter
class  Io
class  Target
class  Source
class  Loader
class  IoException
class  IoExceptionFailedLoad
class  IoExceptionSourceNotFound
class  IoExceptionUnsupportedDataType
class  IoExceptionUnsupportedDataFormat
struct  IoRegistrar
struct  IoRegistrant
class  Track
class  OutputImpl
class  Output
class  LoaderSourceFile
class  SourceFile
class  LoaderSourceFileWav
class  SourceFileWav
class  LoaderSourceFileWindowsMedia
class  SourceFileWindowsMedia

Typedefs

typedef BufferT< void > Buffer
typedef BufferT< uint8_t > Buffer8u
typedef BufferT< int8_t > Buffer8i
typedef BufferT< uint16_t > Buffer16u
typedef BufferT< int16_t > Buffer16i
typedef BufferT< int32_t > Buffer32i
typedef BufferT< uint32_t > Buffer32u
typedef BufferT< float > Buffer32f
typedef shared_ptr< class SourceSourceRef
typedef shared_ptr< class LoaderLoaderRef
typedef HRESULT(* LoaderDataCallback )(void *audioData, uint32_t dataSize, void *track, uint64_t sampleTime, uint32_t sampleDuration)
typedef uint32_t TrackId
typedef shared_ptr< class TrackTrackRef
typedef shared_ptr< class
SourceFile
SourceFileRef
typedef shared_ptr< class
LoaderSourceFile
LoaderSourceFileRef
typedef shared_ptr< class
SourceFileWav
SourceFileWavRef
typedef shared_ptr< class
LoaderSourceFileWav
LoaderSourceFileWavRef
typedef shared_ptr< class
SourceFileWindowsMedia
SourceFileWindowsMediaRef
typedef shared_ptr< class
LoaderSourceFileWindowsMedia
LoaderSourceFileWindowsMediaRef

Enumerations

enum  {
  WAV_FORMAT_UNKOWN = 0x000, WAV_FORMAT_PCM = 0x0001, WAV_FORMAT_MS_ADPCM = 0x0002, WAV_FORMAT_IEEE_FLOAT = 0x0003,
  WAV_FORMAT_ALAW = 0x0006, WAV_FORMAT_MULAW = 0x0007, WAV_FORMAT_DIALOGIC_OKI_ADPCM = 0x0011, WAV_FORMAT_YAMAHA_ADPCM = 0x0016,
  WAV_FORMAT_GSM610 = 0x0031, WAV_FORMAT_G721_ADPCM = 0x0040, WAV_FORMAT_MPEG = 0x0050, WAV_FORMAT_MP3 = 0x0055
}

Functions

void silenceBuffers (BufferList *aBufferList)
template<typename T , typename U >
shared_ptr< Callback< T, U > > createCallback (T *callbackObj, void(T::*callbackFn)(uint64_t inSampleOffset, uint32_t inSampleCount, BufferT< U > *ioBuffer), bool ownCallbackObj=false, uint32_t aSampleRate=44100, uint16_t aChannelCount=2)
SourceRef load (const std::string &path, std::string extension="")
 Loads an audio from the file path path. Optional extension parameter allows specification of a file type. For example, "mp3" would force the file to load as a MP3.
SourceRef load (DataSourceRef dataSource, std::string extension="")
 Loads an audio from dataSource. Optional extension parameter allows specification of a file type. For example, "mp3" would force the file to load as a MP3.
 REGISTER_AUDIOIO (SourceFileWindowsMedia) class SourceFileWindowsMediaExceptionUnsupportedData
template<typename T >
void readStreamWithEndianess (IStreamRef aIStream, T *param, bool isBigEndian)

Variables

const uint32_t gRiffMarker = 'FFIR'
const uint32_t gRifxMarker = 'XFIR'
const uint32_t gWaveMarker = 'EVAW'
const uint32_t gDataMarker = 'atad'
const uint32_t gFmtMarker = ' tmf'

Typedef Documentation

typedef BufferT<uint8_t> cinder::audio::Buffer8u
typedef BufferT<uint16_t> cinder::audio::Buffer16u
typedef BufferT<uint32_t> cinder::audio::Buffer32u
typedef shared_ptr<class Source> cinder::audio::SourceRef
typedef shared_ptr<class Loader> cinder::audio::LoaderRef
typedef HRESULT(* cinder::audio::LoaderDataCallback)(void *audioData, uint32_t dataSize, void *track, uint64_t sampleTime, uint32_t sampleDuration)
typedef uint32_t cinder::audio::TrackId
typedef shared_ptr<class Track> cinder::audio::TrackRef
typedef shared_ptr<class SourceFile> cinder::audio::SourceFileRef

Enumeration Type Documentation

anonymous enum
Enumerator:
WAV_FORMAT_UNKOWN 
WAV_FORMAT_PCM 
WAV_FORMAT_MS_ADPCM 
WAV_FORMAT_IEEE_FLOAT 
WAV_FORMAT_ALAW 
WAV_FORMAT_MULAW 
WAV_FORMAT_DIALOGIC_OKI_ADPCM 
WAV_FORMAT_YAMAHA_ADPCM 
WAV_FORMAT_GSM610 
WAV_FORMAT_G721_ADPCM 
WAV_FORMAT_MPEG 
WAV_FORMAT_MP3 

Function Documentation

void cinder::audio::silenceBuffers ( BufferList *  aBufferList  ) 
template<typename T , typename U >
shared_ptr<Callback<T,U> > cinder::audio::createCallback ( T *  callbackObj,
void(T::*)(uint64_t inSampleOffset, uint32_t inSampleCount, BufferT< U > *ioBuffer)  callbackFn,
bool  ownCallbackObj = false,
uint32_t  aSampleRate = 44100,
uint16_t  aChannelCount = 2 
)
SourceRef cinder::audio::load ( const std::string &  path,
std::string  extension = "" 
)

Loads an audio from the file path path. Optional extension parameter allows specification of a file type. For example, "mp3" would force the file to load as a MP3.

SourceRef cinder::audio::load ( DataSourceRef  dataSource,
std::string  extension = "" 
)

Loads an audio from dataSource. Optional extension parameter allows specification of a file type. For example, "mp3" would force the file to load as a MP3.

cinder::audio::REGISTER_AUDIOIO ( SourceFileWindowsMedia   ) 
template<typename T >
void cinder::audio::readStreamWithEndianess ( IStreamRef  aIStream,
T *  param,
bool  isBigEndian 
)

Variable Documentation

const uint32_t cinder::audio::gRiffMarker = 'FFIR'
const uint32_t cinder::audio::gRifxMarker = 'XFIR'
const uint32_t cinder::audio::gWaveMarker = 'EVAW'
const uint32_t cinder::audio::gDataMarker = 'atad'
const uint32_t cinder::audio::gFmtMarker = ' tmf'