module-rtp: fix compilation without opus

This commit is contained in:
Wim Taymans 2023-03-12 19:04:14 +01:00
parent 345582dd15
commit 59d5d93878
3 changed files with 11 additions and 6 deletions

View file

@ -2,12 +2,11 @@
/* SPDX-FileCopyrightText: Copyright © 2023 Wim Taymans <wim.taymans@gmail.com> */
/* SPDX-License-Identifier: MIT */
#ifdef HAVE_OPUS
#include <opus/opus.h>
#include <opus/opus_multistream.h>
struct rtp_opus_data {
};
static void rtp_opus_process_playback(void *data)
{
struct impl *impl = data;
@ -367,3 +366,9 @@ static int rtp_opus_init(struct impl *impl, enum spa_direction direction)
pw_log_error("opus error: %d", err);
return impl->stream_data ? 0 : err;
}
#else
static int rtp_opus_init(struct impl *impl, enum spa_direction direction)
{
return -ENOTSUP;
}
#endif