This is a duplicate post, originally posted in gstreamer-bugs, but that list seems to be dormant so I am posting this issue here.
I have a project using Gstreamer that sends stereo audio to clients located on two loudspekers, where the audio is rendered and played back. I am using rtpbin to implement synchronized streaming with NTP running on all machines. The pipeline is running without errors and seems to work properly (speakers are producing sound, etc).
I recently generated a pipeline diagram on the sender/server side of the system. But it does not seem to match up with the Gstreamer commands that I am running.
My sender/server side commands are:
rtpbin name=server_rtpbin rtp-profile=avpf ntp-time-source=ntp
alsasrc device='hifiberry_capture' ! audio/x-raw,rate=48000,format=S32LE,channels=2 ! queue ! audioconvert ! audio/x-raw,format=F32LE ! deinterleave name=input
input.src_0 ! tee name=input_ch0
input.src_1 ! tee name=input_ch1
audiointerleave name=client0_stream latency=100000000 ! audioconvert ! audioresample quality=10 ! audio/x-raw,rate=48000,format=S24LE ! audioconvert ! rtpL24pay ! server_rtpbin.send_rtp_sink_0
server_rtpbin.send_rtp_src_0 ! udpsink host=192.168.100.101 port=32768
server_rtpbin.send_rtcp_src_0 ! udpsink host=192.168.100.101 port=32769 sync=false async=false
udpsrc port=32768 ! server_rtpbin.recv_rtcp_sink_0
input_ch0. ! queue ! client0_stream.sink_0
input_ch1. ! queue ! client0_stream.sink_1
audiointerleave name=client1_stream latency=100000000 ! audioconvert ! audioresample quality=10 ! audio/x-raw,rate=48000,format=S24LE ! audioconvert ! rtpL24pay ! server_rtpbin.send_rtp_sink_1
server_rtpbin.send_rtp_src_1 ! udpsink host=192.168.100.102 port=32768
server_rtpbin.send_rtcp_src_1 ! udpsink host=192.168.100.102 port=32769 sync=false async=false
udpsrc port=32769 ! server_rtpbin.recv_rtcp_sink_1
input_ch0. ! queue ! client1_stream.sink_0
input_ch1. ! queue ! client1_stream.sink_1
The pipeline diagram generated from these commands is attached.
Up to the point where the input reaches the GstDeinterleave element everything looks correct. Then there is only one GstTee element (input_ch0) , but my pipeline commands request TWO of them (input_ch0 and input_ch1). Both input channels are supposed to be sent to both of the clients. But if you look at the GstAudioInterleave elements in the diagram, one has two channels and the other one has only one channel. This is not what the Gstreamer commands are requesting. So, why is this? I suspect a bug.
I cannot find an error with my Gstreamer pipeline commands, so I think the error might be either with the generation of the pipeline diagram OR Gstreamer has an internal error in how it is building the actual pipeline from my commands and the pipeline diagram is revealing the error.
Thanks for your help with this.
gstreamer-devel mailing list
server_pipeline.png (1M) Download Attachment
For additional information, I am attaching the gstreamer output for this pipeline. Its’ too large to just copy and paste directly, but upon inspection it seems to contain entries for both tees, input_ch0 and input_ch1. So the error I am observing is like not with gstreamer itself, but with the DOT pipeline graph generation from the debug data file. There is more evidence for this contained in the gstreamer output:
Got message #164 from element "input_ch0" (state-changed): GstMessageStateChanged, old-state=(GstState)GST_STATE_NULL, new-state=(GstState)GST_STATE_READY, pending-state=(GstState)GST_STATE_VOID_PENDING;
Got message #165 from element "input_ch1" (state-changed): GstMessageStateChanged, old-state=(GstState)GST_STATE_NULL, new-state=(GstState)GST_STATE_READY, pending-state=(GstState)GST_STATE_VOID_PENDING;
/GstPipeline:pipeline0/GstTee:input_ch0.GstPad:sink: caps = audio/x-raw, format=(string)F32LE, layout=(string)interleaved, rate=(int)48000, channels=(int)1
/GstPipeline:pipeline0/GstTee:input_ch1.GstPad:sink: caps = audio/x-raw, format=(string)F32LE, layout=(string)interleaved, rate=(int)48000, channels=(int)1
The last two statements seem to be correct. I mistakenly said in my first post that both channels were to be streamed to both clients, but in fact I stream only the left audio channel to the left client and the right audio channel to the right audio client. So these statements do reflect the intended behavior and that of the gstreamer commands used to launch the pipeline.
This points to an error in the pipeline diagram generation.
gstreamer-devel mailing list
gst_server_output.txt (95K) Download Attachment
|Free forum by Nabble||Edit this page|