Reputation: 737
I would like to stream .ts file over udp, for that i used the below pipeline.
But within a second it is reaching EOS
GST_DEBUG=3 gst-launch-1.0 -v filesrc location=avm.ts ! queue ! tsparse ! rtpmp2tpay ! udpsink host=192.168.1.139 port=8080
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Got EOS from element "pipeline0".
Execution ended after 0:00:00.177011430
At Receiving end i am not able to receive whole data, only first few frame are coming because of instant exit at sending end.
While Streaming a .ts file which contains video & text data, at receiving end only getting, text data.
At sending end below debug messages came.
0:00:00.030345526 7863 0xd9df60 WARN basesrc gstbasesrc.c:3483:gst_base_src_start_complete:<filesrc0> pad not activated yet
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/MpegTsMux:mpegtsmux0.GstPad:sink_65: caps = "application/x-metadata\,\ standard\=\(string\)klv"
0:00:00.031289005 7863 0xd710f0 FIXME basesink gstbasesink.c:3064:gst_base_sink_default_event:<udpsink0> stream-start event without group-id. Consider implementing group-id handling in the upstream elements
When i changed the pipeline and added identity, like,
gst-launch-1.0 filesrc location=vfpd.ts ! queue ! tsparse ! rtpmp2tpay ! identity silent=false ! udpsink -v host=192.168.1.139 port=8765
Then getting too many messages, like below,
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf40abac0
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (200 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf40abdf0
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf40db7f0
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf409d450
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf4007460
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (200 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf40bfc10
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf408f000
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (1328 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf409d560
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = chain ******* (identity0:sink) (952 bytes, dts: none, pts:none, duration: none, offset: -1, offset_end: -1, flags: 00004000 tag-memory ) 0x7fcaf408f330
/GstPipeline:pipeline0/GstIdentity:identity0: last-message = event ******* (identity0:sink) E (type: eos (28174), ) 0x7fcaf4003400
So, as of my understanding, it is sending all the packets in a single instance, that means no flow control.
The file is of 25 fps. And how can i stream the ts also in the same flow rate?
What does that warning means? And how to resolve it? How to resolve this issue? How can i slower the flow?
Upvotes: 3
Views: 2584
Reputation: 3932
First - the pipe looks good to me..
From your update:
Well it looks like as I expected it goes in one burst (as you already stated), the problem is that in you original stream there are no timing informations inside frames (thats those none for dts, pts and duration).. there are two possible explanations - there is some problem in your .ts file.. or there is problem in gstreamer pipe..
Personaly I think that your .ts file is wrong..
To eliminate the first one I would suggest analyzing the .ts file with some mpeg analyzator..
You should check if the mpeg ts stream does contain proper PCR values which is synchronization information for mpeg streams.
UPDATE:
Ok after little bit of hacking I found this solution, I hope it works on the reciever site, I tested just to stream it and it run for the length of the original ts file:
gst-launch-1.0 filesrc location=football.ts ! queue ! tsparse set-timestamps=true ! rtpmp2tpay ! udpsink -v host=192.168.1.139 port=8765
the set-timestamps
is properly marking the buffers with time information..
Upvotes: 4
Reputation: 737
I have used below pipeline, that solved my problem.
GST_DEBUG=3 gst-launch-1.0 -v filesrc location=avm.ts ! queue ! tsdemux ! mpegtsmux ! rtpmp2tpay ! udpsink host=192.168.1.139 port=8080
Upvotes: 1