update teletone see wiki for syntax changes in TTML

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5276 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale
2007-06-06 23:28:00 +00:00
parent 32bdf10952
commit 88fdfab48f
4 changed files with 269 additions and 163 deletions

View File

@@ -90,7 +90,8 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include <math.h>
#include <libteletone_detect.h>
#ifndef _MSC_VER
#include <stdint.h>
#endif
@@ -98,7 +99,7 @@
#include <stdio.h>
#include <time.h>
#include <fcntl.h>
#include <libteletone_detect.h>
static teletone_detection_descriptor_t dtmf_detect_row[GRID_FACTOR];
static teletone_detection_descriptor_t dtmf_detect_col[GRID_FACTOR];
@@ -208,8 +209,8 @@ void teletone_multi_tone_init(teletone_multi_tone_t *mt, teletone_tone_map_t *ma
}
int teletone_multi_tone_detect (teletone_multi_tone_t *mt,
int16_t sample_buffer[],
int samples)
int16_t sample_buffer[],
int samples)
{
int sample, limit, j, x = 0;
teletone_process_t v1, famp;
@@ -295,8 +296,8 @@ int teletone_multi_tone_detect (teletone_multi_tone_t *mt,
int teletone_dtmf_detect (teletone_dtmf_detect_state_t *dtmf_detect_state,
int16_t sample_buffer[],
int samples)
int16_t sample_buffer[],
int samples)
{
teletone_process_t row_energy[GRID_FACTOR];
teletone_process_t col_energy[GRID_FACTOR];
@@ -426,8 +427,8 @@ int teletone_dtmf_detect (teletone_dtmf_detect_state_t *dtmf_detect_state,
int teletone_dtmf_get (teletone_dtmf_detect_state_t *dtmf_detect_state,
char *buf,
int max)
char *buf,
int max)
{
if (max > dtmf_detect_state->current_digits) {
max = dtmf_detect_state->current_digits;