From d35d0e3ebbc3751d3790cc476f21347b5c0bf0b2 Mon Sep 17 00:00:00 2001 From: DL1YCF Date: Tue, 18 May 2021 15:49:10 +0200 Subject: [PATCH] organize data for different audio modules --- receiver.h | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/receiver.h b/receiver.h index 222a15c..200e42d 100644 --- a/receiver.h +++ b/receiver.h @@ -23,7 +23,7 @@ #ifdef PORTAUDIO #include "portaudio.h" #endif -#ifdef ALSAAUDIO +#ifdef ALSA #include #endif #ifdef PULSEAUDIO @@ -124,19 +124,21 @@ typedef struct _receiver { PaStream *playback_handle; gint local_audio_buffer_inpt; // pointer in audio ring-buffer gint local_audio_buffer_outpt; // pointer in audio ring-buffer + float *local_audio_buffer; #endif -#ifdef ALSAAUDIO +#ifdef ALSA snd_pcm_t *playback_handle; snd_pcm_format_t local_audio_format; + void *local_audio_buffer; // different formats possible #endif #ifdef PULSEAUDIO pa_simple *playstream; gboolean output_started; + float *local_audio_buffer; #endif gint local_audio_cw; // flag for latency switching gint local_audio_buffer_size; gint local_audio_buffer_offset; - void *local_audio_buffer; GMutex local_audio_mutex; gint low_latency; -- 2.45.2