aboutsummaryrefslogtreecommitdiffstats
path: root/src/anetz/anetz.c
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2017-01-27 16:57:34 +0100
committerAndreas Eversberg <jolly@eversberg.eu>2017-02-18 21:01:08 +0100
commit7ea3bc188df54a4dbe3026bc30ed39a5cded8fdb (patch)
tree696c78eca5f1676246fed55314c1eab67408c7f4 /src/anetz/anetz.c
parent538a9591285bdc2604c5e05c06e4b2d776f4bdf9 (diff)
Move samples of int16_t format to sample_t, that is of type double
This prepares the correction of all levels
Diffstat (limited to 'src/anetz/anetz.c')
-rw-r--r--src/anetz/anetz.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/anetz/anetz.c b/src/anetz/anetz.c
index 77493f7..c65d6f1 100644
--- a/src/anetz/anetz.c
+++ b/src/anetz/anetz.c
@@ -24,6 +24,7 @@
#include <stdlib.h>
#include <string.h>
#include <errno.h>
+#include "../common/sample.h"
#include "../common/debug.h"
#include "../common/timer.h"
#include "../common/call.h"
@@ -492,7 +493,7 @@ void call_out_release(int callref, __attribute__((unused)) int cause)
}
/* Receive audio from call instance. */
-void call_rx_audio(int callref, int16_t *samples, int count)
+void call_rx_audio(int callref, sample_t *samples, int count)
{
sender_t *sender;
anetz_t *anetz;
@@ -506,7 +507,7 @@ void call_rx_audio(int callref, int16_t *samples, int count)
return;
if (anetz->dsp_mode == DSP_MODE_AUDIO) {
- int16_t up[(int)((double)count * anetz->sender.srstate.factor + 0.5) + 10];
+ sample_t up[(int)((double)count * anetz->sender.srstate.factor + 0.5) + 10];
count = samplerate_upsample(&anetz->sender.srstate, samples, count, up);
jitter_save(&anetz->sender.dejitter, up, count);
}