15 #ifndef _MprFromMic_h_ 16 #define _MprFromMic_h_ 18 #define REAL_SILENCE_DETECTION 23 #include "os/OsDefs.h" 24 #include "os/OsMsgQ.h" 35 typedef void (*
MICDATAHOOK)(
const int nLength,
short* samples) ;
53 MprFromMic(
const UtlString& rName, OsMsgQ *pMicQ);
90 #ifndef REAL_SILENCE_DETECTION 91 unsigned long MinVoiceEnergy;
120 #endif // _MprFromMic_h_ MprFromMic(const UtlString &rName, OsMsgQ *pMicQ)
Constructor.
Definition: MprFromMic.cpp:47
void highpass_filter800(int16_t *, int16_t *, short)
Definition: MprFromMic.cpp:344
The "From Microphone" media processing resource.
Definition: MprFromMic.h:42
int mNumFrames
Definition: MprFromMic.h:89
static MICDATAHOOK s_fnMicDataHook
Definition: MprFromMic.h:114
Definition: MprFromMic.h:85
Definition: MprFromMic.h:46
MpSpeechType speech_detected(int16_t *, int)
Definition: MprFromMic.cpp:300
MpSpeechType
Type of audio data.
Definition: MpTypes.h:65
Abstract base class for all audio processing objects.
Definition: MpAudioResource.h:38
int16_t shpFilterBuf[80+10]
Definition: MprFromMic.h:88
virtual UtlBoolean doProcessFrame(MpBufPtr inBufs[], MpBufPtr outBufs[], int inBufsSize, int outBufsSize, UtlBoolean isEnabled, int samplesPerFrame=80, int samplesPerSecond=8000)
This method does the real work for the media processing resource and must be defined in each class de...
Definition: MprFromMic.cpp:75
Smart pointer to MpBuf.
Definition: MpBuf.h:160
MprFromMic & operator=(const MprFromMic &rhs)
Assignment operator (not implemented for this class)
OsMsgQ * mpMicQ
We will read audio data from this queue.
Definition: MprFromMic.h:87
void(* MICDATAHOOK)(const int nLength, short *samples)
Definition: MprFromMic.h:35
virtual ~MprFromMic()
Destructor.
Definition: MprFromMic.cpp:60
void Init_highpass_filter800()
Definition: MprFromMic.cpp:336
UtlBoolean isEnabled() const
Returns TRUE is this resource is currently enabled, FALSE otherwise.
Definition: MpResource.cpp:440