From 54aaa712ce2466f4951b7d3461e0f27a35aecd01 Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Mon, 29 Sep 2014 00:39:34 +0200 Subject: recording works now for receiver as well --- src/pipelines.c | 24 ++++-------------------- 1 file changed, 4 insertions(+), 20 deletions(-) (limited to 'src') diff --git a/src/pipelines.c b/src/pipelines.c index 6f70ee2..12b6eee 100644 --- a/src/pipelines.c +++ b/src/pipelines.c @@ -345,26 +345,6 @@ GstElement* create_sender_pipeline(options_t* opt, struct udp_sinks *udp) return pipeline; } -/* - V_RTP_CAPS='application/x-rtp,media=video,clock-rate=90000,encoding-name=VP8-DRAFT-IETF-01,caps="video/x-vp8"' - V_DEPAY='rtpvp8depay' - V_DECODER='vp8dec' - V_SINK='videoconvert ! videoscale add-borders=true ! xvimagesink' - - A_RTP_CAPS='application/x-rtp,media=audio,clock-rate=48000,payload=96,encoding-name=X-GST-OPUS-DRAFT-SPITTKA-00,caps="audio/x-opus"' - A_DEPAY='rtpopusdepay' - A_DECODER='opusdec' - A_SINK='audioconvert ! autoaudiosink' - - udpsrc caps=$V_RTP_CAPS port=$PORT_RTP_V ! rtpbin.recv_rtp_sink_0 - udpsrc caps=$A_RTP_CAPS port=$PORT_RTP_A ! rtpbin.recv_rtp_sink_1 - udpsrc port=$PORT_RTCP_V ! rtpbin.recv_rtcp_sink_0 - udpsrc port=$PORT_RTCP_A ! rtpbin.recv_rtcp_sink_1 - - rtpbin. ! $V_DEPAY ! tee ! queue ! $V_DECODER ! tee ! queue ! $V_SINK - rtpbin. ! $A_DEPAY ! tee ! queue ! $A_DECODER ! tee ! queue ! $A_SINK -*/ - static void rtpbin_pad_added(GstElement* rtp, GstPad* pad, gpointer user_data) { GstElement **depays = (GstElement**)user_data; @@ -437,6 +417,10 @@ GstElement* create_receiver_pipeline(options_t* opt, struct udp_sources *udp) depays[1] = audio.payloader_; g_signal_connect_closure(rtp, "pad-added", g_cclosure_new(G_CALLBACK(rtpbin_pad_added), depays, NULL), FALSE); + if(opt->rec_mux_) { + if(!create_recorder_elements(opt, pipeline, &video, &audio)) + return NULL; + } log_printf(DEBUG, "receiver pipeline created successfully!"); return pipeline; -- cgit v1.2.3