#include <opalmixer.h>
Inheritance diagram for OpalAudioMixer:
Public Types | |
typedef std::string | Key_T |
typedef std::map< Key_T, OpalAudioMixerStream * > | StreamInfoMap_T |
typedef std::map< Key_T, OpalAudioMixerStream::StreamFrame > | MixerPCMMap_T |
Public Member Functions | |
OpalAudioMixer (BOOL realTime=TRUE, BOOL _pushThread=TRUE) | |
virtual | ~OpalAudioMixer () |
virtual BOOL | OnWriteAudio (const MixerFrame &) |
BOOL | AddStream (const Key_T &key, OpalAudioMixerStream *stream) |
void | RemoveStream (const Key_T &key) |
void | RemoveAllStreams () |
void | StartThread () |
void | ThreadMain () |
void | ReadRoutine () |
void | WriteMixedFrame () |
BOOL | Write (const Key_T &key, const RTP_DataFrame &rtp) |
Protected Attributes | |
PINDEX | frameLengthMs |
size of each audio chunk in milliseconds | |
PMutex | mutex |
mutex for list of streams and thread handle | |
StreamInfoMap_T | streamInfoMap |
list of streams | |
unsigned | channelNumber |
counter for channels | |
BOOL | realTime |
TRUE if realtime mixing. | |
BOOL | pushThread |
TRUE if to use a thread to push data out. | |
PThread * | thread |
reader thread handle | |
BOOL | threadRunning |
used to stop reader thread | |
BOOL | audioStarted |
TRUE if output audio is running. | |
BOOL | firstRead |
TRUE if first use of CheckForRead. | |
PTime | timeOfNextRead |
absolute timestamp for next scheduled read | |
DWORD | outputTimestamp |
RTP timestamp for output data. | |
Classes | |
class | MixerFrame |
typedef std::string OpalAudioMixer::Key_T |
typedef std::map<Key_T, OpalAudioMixerStream *> OpalAudioMixer::StreamInfoMap_T |
typedef std::map<Key_T, OpalAudioMixerStream::StreamFrame> OpalAudioMixer::MixerPCMMap_T |
OpalAudioMixer::OpalAudioMixer | ( | BOOL | realTime = TRUE , |
|
BOOL | _pushThread = TRUE | |||
) |
virtual OpalAudioMixer::~OpalAudioMixer | ( | ) | [inline, virtual] |
virtual BOOL OpalAudioMixer::OnWriteAudio | ( | const MixerFrame & | ) | [virtual] |
BOOL OpalAudioMixer::AddStream | ( | const Key_T & | key, | |
OpalAudioMixerStream * | stream | |||
) |
void OpalAudioMixer::RemoveStream | ( | const Key_T & | key | ) |
void OpalAudioMixer::RemoveAllStreams | ( | ) |
void OpalAudioMixer::StartThread | ( | ) |
void OpalAudioMixer::ThreadMain | ( | ) |
void OpalAudioMixer::ReadRoutine | ( | ) |
void OpalAudioMixer::WriteMixedFrame | ( | ) |
BOOL OpalAudioMixer::Write | ( | const Key_T & | key, | |
const RTP_DataFrame & | rtp | |||
) |
PINDEX OpalAudioMixer::frameLengthMs [protected] |
size of each audio chunk in milliseconds
PMutex OpalAudioMixer::mutex [protected] |
mutex for list of streams and thread handle
StreamInfoMap_T OpalAudioMixer::streamInfoMap [protected] |
list of streams
unsigned OpalAudioMixer::channelNumber [protected] |
counter for channels
BOOL OpalAudioMixer::realTime [protected] |
TRUE if realtime mixing.
BOOL OpalAudioMixer::pushThread [protected] |
TRUE if to use a thread to push data out.
PThread* OpalAudioMixer::thread [protected] |
reader thread handle
BOOL OpalAudioMixer::threadRunning [protected] |
used to stop reader thread
BOOL OpalAudioMixer::audioStarted [protected] |
TRUE if output audio is running.
BOOL OpalAudioMixer::firstRead [protected] |
TRUE if first use of CheckForRead.
PTime OpalAudioMixer::timeOfNextRead [protected] |
absolute timestamp for next scheduled read
DWORD OpalAudioMixer::outputTimestamp [protected] |
RTP timestamp for output data.