sipxmedialib  Version 3.3
Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
CoreAudioHardware Class Reference

Container for CoreAudio hardware device specific. More...

#include <MpCoreAudioHardware.h>

Public Member Functions

 CoreAudioHardware (AudioDeviceID devid, bool isInput)
 
AudioDeviceID getAudioDeviceID () const
 
bool IsInput () const
 
bool IsValid () const
 
double getActualSampleRate () const
 
int getLatency () const
 
double getSuitableSampleRateFor (double sr)
 
int getAvailableSampleRates (double *pBuff, const int bufLen) const
 
bool getStreamFormat (AudioStreamBasicDescription &desc) const
 
bool setStreamFormat (const AudioStreamBasicDescription &desc)
 
unsigned getBufferSize () const
 
bool setBufferSize (unsigned sr)
 

Static Public Member Functions

static CoreAudioHardware invalid ()
 
static CoreAudioHardware fromDefaultOutput ()
 
static CoreAudioHardware fromDefaultInput ()
 
static void dumpAudioStreamBasicDescription (const char *header, const AudioStreamBasicDescription &desc)
 
static bool isEqualAudioStreamBasicDescription (const AudioStreamBasicDescription &desc, const AudioStreamBasicDescription &desc2)
 

Protected Attributes

AudioDeviceID mDevId
 Device handle. More...
 
bool mIsInput
 Whether input or output operations. More...
 

Detailed Description

Container for CoreAudio hardware device specific.

Constructor & Destructor Documentation

CoreAudioHardware ( AudioDeviceID  devid,
bool  isInput 
)
inline

Member Function Documentation

AudioDeviceID getAudioDeviceID ( ) const
inline
bool IsInput ( ) const
inline
bool IsValid ( ) const
inline
static CoreAudioHardware invalid ( )
inlinestatic
static CoreAudioHardware fromDefaultOutput ( )
inlinestatic
static CoreAudioHardware fromDefaultInput ( )
inlinestatic
double getActualSampleRate ( ) const
inline
int getLatency ( ) const
inline
double getSuitableSampleRateFor ( double  sr)
inline
int getAvailableSampleRates ( double *  pBuff,
const int  bufLen 
) const
inline
bool getStreamFormat ( AudioStreamBasicDescription &  desc) const
inline
bool setStreamFormat ( const AudioStreamBasicDescription &  desc)
inline
static void dumpAudioStreamBasicDescription ( const char *  header,
const AudioStreamBasicDescription &  desc 
)
inlinestatic
static bool isEqualAudioStreamBasicDescription ( const AudioStreamBasicDescription &  desc,
const AudioStreamBasicDescription &  desc2 
)
inlinestatic
unsigned getBufferSize ( ) const
inline
bool setBufferSize ( unsigned  sr)
inline

Member Data Documentation

AudioDeviceID mDevId
protected

Device handle.

bool mIsInput
protected

Whether input or output operations.