Good DVB stream with mpegtsmux

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Good DVB stream with mpegtsmux

antoniodh1
Hello,

I am trying to get a good DVB stream with gst-launch-1.0 by means of mpegtsmux. I achieved to generate and send a stream over UDP. I can open and watch it with VLC in the receiver, however, if I analyze the TS with an analyzer, it gives me errors all the time (see the attached screenshot).

According to the errors, I think that the problem is in the adaptation field, but I do not know what is happening. Any clue?

This is the pipeline that I am using, is there anything wrong in it?
gst-launch-1.0 -v videotestsrc do-timestamp=true is-live=true ! x264enc ! queue ! h264parse ! mpegtsmux ! udpsink host=10.192.33.136 port=2400 sync=1

Thank you very much in advance.

Best regards,
Antonio.


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

screenshot.jpg (66K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Good DVB stream with mpegtsmux

antoniodh1
Hello again,

Well, I have been doing some tests. I tried to save the TS in a file and fed it to ffprobe, which said that the timestamps are incorrect (PTS < DTS, what has no sense):

[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324002999, dts=324008999, size=4040
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324009000, dts=324011999, size=4042
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324014999, dts=324020999, size=3925
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324020999, dts=324023999, size=4048
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324027000, dts=324032999, size=4050
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324032999, dts=324035999, size=3886
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324038999, dts=324044999, size=4019
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324045000, dts=324047999, size=3891
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324050999, dts=324056999, size=3927
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324056999, dts=324059999, size=3865
[mpegts @ 0x3854120] Invalid timestamps stream=0, pts=324063000, dts=324068999, size=3910

Then I tried to save the raw H.264 video, removing the muxer from pipeline and fed that file to ffprobe and, this time, it does not say anything about timestamps. So, I guess that the mpegtsmux is restamping the stream and it is doing it in a wrong way. Do you think this is possible? Is there any known bug about this?

Best regards,
Antonio.


2017-08-29 12:06 GMT+02:00 Antonio Jesús Díaz Honrubia <[hidden email]>:
Hello,

I am trying to get a good DVB stream with gst-launch-1.0 by means of mpegtsmux. I achieved to generate and send a stream over UDP. I can open and watch it with VLC in the receiver, however, if I analyze the TS with an analyzer, it gives me errors all the time (see the attached screenshot).

According to the errors, I think that the problem is in the adaptation field, but I do not know what is happening. Any clue?

This is the pipeline that I am using, is there anything wrong in it?
gst-launch-1.0 -v videotestsrc do-timestamp=true is-live=true ! x264enc ! queue ! h264parse ! mpegtsmux ! udpsink host=10.192.33.136 port=2400 sync=1

Thank you very much in advance.

Best regards,
Antonio.



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Good DVB stream with mpegtsmux

Arjen Veenhuizen
Not sure what is going wrong in mpegtsmux, but an h264 bitstream does not
contain any timing information in itself (except for some time-base info).
It is the container (in this case MPEG2TS) that adds such information. To
debug the problem, you could start with tuning the encoder to use
zero-latency mode, set profile to main and disable b-frames and see if the
problem persists.



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Good DVB stream with mpegtsmux

antoniodh1
Thank you very much for the info and the hep. In fact, those were the next steps that I did. The zero-latency had no effect since the same error was present, then I tried to set b-frames to 0, which solved the problem of the differences, so it seems that the muxer does not work properly with B frames. Anyway, I tried to analyze the resulting TS and the same errors (those shown in the screenshot attached to my first message) are still present in the analyzer.

Best regards,
Antonio.


2017-08-30 12:45 GMT+02:00 Arjen Veenhuizen <[hidden email]>:
Not sure what is going wrong in mpegtsmux, but an h264 bitstream does not
contain any timing information in itself (except for some time-base info).
It is the container (in this case MPEG2TS) that adds such information. To
debug the problem, you could start with tuning the encoder to use
zero-latency mode, set profile to main and disable b-frames and see if the
problem persists.



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Good DVB stream with mpegtsmux

Tim Müller
On Wed, 2017-08-30 at 13:02 +0200, Antonio Jesús Díaz Honrubia wrote:

Hi Antonio,

Out of curiosity - what version of GStreamer/mpegtsmux are you testing with?

Cheers
-Tim
-- 
Tim Müller, Centricular Ltd - http://www.centricular.com

Join us at the GStreamer Conference!
21-22 October 2017 in Prague, Czech Republic

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Good DVB stream with mpegtsmux

antoniodh1
Hello,

GStreamer and mpegtsmux versions are 1.4.4.

Best regards,
Antonio.


2017-08-30 13:22 GMT+02:00 Tim Müller <[hidden email]>:
On Wed, 2017-08-30 at 13:02 +0200, Antonio Jesús Díaz Honrubia wrote:

Hi Antonio,

Out of curiosity - what version of GStreamer/mpegtsmux are you testing with?

Cheers
-Tim
-- 
Tim Müller, Centricular Ltd - http://www.centricular.com

Join us at the GStreamer Conference!
21-22 October 2017 in Prague, Czech Republic

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel