summaryrefslogtreecommitdiff
path: root/src/sydra.c
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2014-09-22 06:55:10 +0200
committerChristian Pointner <equinox@spreadspace.org>2014-09-22 06:55:10 +0200
commitb9860e34425691a848702289283c68af8f7bad99 (patch)
tree5ab86baff77a1c8b82ef79e39a8bd983d91a930b /src/sydra.c
parentfixed license header - email (diff)
changing udp port mapping
Diffstat (limited to 'src/sydra.c')
-rw-r--r--src/sydra.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/sydra.c b/src/sydra.c
index 928eaf2..3e494e1 100644
--- a/src/sydra.c
+++ b/src/sydra.c
@@ -304,15 +304,11 @@ static gboolean create_udp_elements(options_t* opt, GstElement* pipeline, GstEle
log_printf(DEBUG, "udp elements created successfully!");
- int rtp_port_v = opt->rtp_port_base_;
- int rtcp_port_v = opt->rtp_port_base_ + 100;
- int rtp_port_a = opt->rtp_port_base_ + 200;
- int rtcp_port_a = opt->rtp_port_base_ + 300;
-
- g_object_set(G_OBJECT(udp_rtp_video), "host", opt->rtp_host_, "port", rtp_port_v, NULL);
- g_object_set(G_OBJECT(udp_rtcp_video), "host", opt->rtp_host_, "port", rtcp_port_v, "sync", FALSE, "async", FALSE, NULL);
- g_object_set(G_OBJECT(udp_rtp_audio), "host", opt->rtp_host_, "port", rtp_port_a, NULL);
- g_object_set(G_OBJECT(udp_rtcp_audio), "host", opt->rtp_host_, "port", rtcp_port_a, "sync", FALSE, "async", FALSE, NULL);
+ int rtp_port = opt->rtp_port_base_;
+ g_object_set(G_OBJECT(udp_rtp_video), "host", opt->rtp_host_, "port", rtp_port++, NULL);
+ g_object_set(G_OBJECT(udp_rtcp_video), "host", opt->rtp_host_, "port", rtp_port++, "sync", FALSE, "async", FALSE, NULL);
+ g_object_set(G_OBJECT(udp_rtp_audio), "host", opt->rtp_host_, "port", rtp_port++, NULL);
+ g_object_set(G_OBJECT(udp_rtcp_audio), "host", opt->rtp_host_, "port", rtp_port++, "sync", FALSE, "async", FALSE, NULL);
gst_bin_add_many(GST_BIN (pipeline), udp_rtp_video, udp_rtcp_video, udp_rtp_audio, udp_rtcp_audio, NULL);