40 PString Decode(
const short * sampleData, PINDEX numSamples,
unsigned mult = 1,
unsigned div = 1);
109 DefaultSampleRate = 8000,
119 unsigned masterVolume = MaxVolume,
120 unsigned sampleRate = DefaultSampleRate
127 unsigned masterVolume = MaxVolume,
128 unsigned sampleRate = DefaultSampleRate
148 unsigned milliseconds,
149 unsigned volume = MaxVolume
155 bool Juxtapose(
unsigned frequency1,
unsigned frequency2,
unsigned milliseconds,
unsigned volume);
156 bool Modulate (
unsigned frequency,
unsigned modulate,
unsigned milliseconds,
unsigned volume);
157 bool PureTone (
unsigned frequency,
unsigned milliseconds,
unsigned volume);
158 bool Silence (
unsigned milliseconds);
160 unsigned CalcSamples(
unsigned milliseconds,
unsigned frequency1,
unsigned frequency2 = 0);
162 void AddSample(
int sample,
unsigned volume);
182 enum { DefaultToneLen = 100 };
188 const char * dtmf = NULL,
189 unsigned milliseconds = DefaultToneLen
197 unsigned milliseconds = DefaultToneLen
205 unsigned milliseconds = DefaultToneLen
213 unsigned milliseconds = DefaultToneLen
222 double frequency2 = 0,
223 unsigned milliseconds = DefaultToneLen
232 Generate(
"440+480:2-4");
241 Generate(
"350+440:1");
250 Generate(
"480+620:0.5-0.5");
269 #endif // PTLIB_DTMF_H
void GenerateDialTone()
Generate PCM data for 1 second of US standard dial tone of 350/440hz.
Definition: dtmf.h:239
int h[NumTones]
Definition: dtmf.h:54
#define PCLASSINFO(cls, par)
Declare all the standard PTLib class information.
Definition: object.h:1049
char key[256]
Definition: dtmf.h:48
this class can be used to generate PCM data for DTMF tones at a sample rate of 8khz ...
Definition: dtmf.h:177
int p1[NumTones]
Definition: dtmf.h:51
This class can be used to generate PCM data for tones (such as telephone calling tones and DTMF) at a...
Definition: dtmf.h:102
unsigned m_sampleRate
Definition: dtmf.h:164
int inputAmplitude
Definition: dtmf.h:55
void GenerateBusyTone()
Generate PCM data for a single cadence of the US standard busy tone of 480/620hz for 1/2 second...
Definition: dtmf.h:248
int sampleCount
Definition: dtmf.h:55
int k[NumTones]
Definition: dtmf.h:54
unsigned m_masterVolume
Definition: dtmf.h:166
unsigned m_lastFrequency2
Definition: dtmf.h:168
int m_angle2
Definition: dtmf.h:169
The character string class.
Definition: pstring.h:108
unsigned m_maxFrequency
Definition: dtmf.h:165
Array of short integers.
Definition: array.h:589
int tonesDetected
Definition: dtmf.h:55
char m_lastOperation
Definition: dtmf.h:167
int y[NumTones]
Definition: dtmf.h:54
void GenerateRingBackTone()
Generate PCM data for a single cadence of the US standard ring tone of 440/480hz for 2 seconds...
Definition: dtmf.h:230
PString Decode(const short *sampleData, PINDEX numSamples, unsigned mult=1, unsigned div=1)
Ultimate parent class for all objects in the class library.
Definition: object.h:1118