diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-08-06 01:12:21 +0800 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2010-08-06 01:12:21 +0800 |
commit | 260d6ed02c12ccde6d8eec5a34118b71207757b6 (patch) | |
tree | c4741888236f20e1b3752a07e72de4efcae9b6ed /openbsc/include/openbsc | |
parent | 6357a8e3110a6cdecb5ee8fdbe59d806f257c1ba (diff) |
mgcp: Add a call tap feature to forward audio to another forward port
For debugging it is useful to forward (tee) UDP packets to another
system and use gstreamer to inspect the rtp stream. This is untested
code and might contain bugs.... and of course only tap your own calls.
Diffstat (limited to 'openbsc/include/openbsc')
-rw-r--r-- | openbsc/include/openbsc/mgcp_internal.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/openbsc/include/openbsc/mgcp_internal.h b/openbsc/include/openbsc/mgcp_internal.h index bdcd03030..19e8e3f2b 100644 --- a/openbsc/include/openbsc/mgcp_internal.h +++ b/openbsc/include/openbsc/mgcp_internal.h @@ -69,6 +69,21 @@ struct mgcp_rtp_end { int local_alloc; }; +enum { + MGCP_TAP_BTS_IN, + MGCP_TAP_BTS_OUT, + MGCP_TAP_NET_IN, + MGCP_TAP_NET_OUT, + + /* last element */ + MGCP_TAP_COUNT +}; + +struct mgcp_rtp_tap { + int enabled; + struct sockaddr_in forward; +}; + struct mgcp_endpoint { int ci; char *callid; @@ -89,6 +104,9 @@ struct mgcp_endpoint { /* SSRC/seq/ts patching for loop */ int allow_patch; + + /* tap for the endpoint */ + struct mgcp_rtp_tap taps[MGCP_TAP_COUNT]; }; #define ENDPOINT_NUMBER(endp) abs(endp - endp->cfg->endpoints) |