From a693444a7e9c07fcc6879e8b8167c1c58f2ebd03 Mon Sep 17 00:00:00 2001 From: Francois Lettock <26750683+skilurius@users.noreply.github.com> Date: Fri, 10 May 2024 16:44:39 +0200 Subject: [PATCH] Add rtp patch for baresip (#1438) --- .../baresip-openipc/0003-send-rtp-data.patch | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 general/package/baresip-openipc/0003-send-rtp-data.patch diff --git a/general/package/baresip-openipc/0003-send-rtp-data.patch b/general/package/baresip-openipc/0003-send-rtp-data.patch new file mode 100644 index 00000000..1a337d90 --- /dev/null +++ b/general/package/baresip-openipc/0003-send-rtp-data.patch @@ -0,0 +1,34 @@ +diff --git a/include/baresip.h b/include/baresip.h +index 2049ac74..a1b0501e 100644 +--- a/include/baresip.h ++++ b/include/baresip.h +@@ -540,12 +540,15 @@ typedef int (auplay_alloc_h)(struct auplay_st **stp, const struct auplay *ap, + struct auplay_prm *prm, const char *device, + auplay_write_h *wh, void *arg); + ++typedef void (auplay_send_h)(const void *sampv, size_t sampc); ++ + /** Defines an Audio Player */ + struct auplay { + struct le le; + const char *name; + struct list dev_list; + auplay_alloc_h *alloch; ++ auplay_send_h *asend; + }; + + int auplay_register(struct auplay **pp, struct list *auplayl, +diff --git a/src/audio.c b/src/audio.c +index 67af6f0e..add06d6b 100644 +--- a/src/audio.c ++++ b/src/audio.c +@@ -1035,6 +1035,9 @@ static int aurx_stream_decode(struct aurx *rx, bool marker, + rx->aubuf_started = true; + lock_rel(rx->lock); + ++ if (rx->ap->asend) ++ rx->ap->asend(af.sampv, num_bytes); ++ + out: + return err; + }