Hi When you are muxing multiple video streams with mpegtsmux, is there then a way to set/control (on the command line using gst-launch) the PIDs of video streams that the mpegtsmux chooses for each video stream?gst-launch-1.0 -v videotestsrc name=vsrc1 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! mpegtsmux name=muxer ! queue ! tcpserversink host=0.0.0.0 sync-method=2 recover-policy=keyframe port=5000 videotestsrc name=vsrc2 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! muxer. _______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
You can set the PID when requesting a sink pad from the mux. I.e. to use PID 300 and 301 instead.gst-launch-1.0 -v videotestsrc name=vsrc1 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! muxer.sink_300 mpegtsmux name=muxer ! queue ! tcpserversink host=0.0.0.0 sync-method=2 recover-policy=keyframe port=5000 videotestsrc name=vsrc2 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! muxer.sink_301 GstElement *mux; GstStructure *pm;mux = gst_element_factory_make ("mpegtsmux", NULL); On Tue, May 26, 2015 at 5:25 PM, Peter Maersk-Moller <[hidden email]> wrote:
_______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Well, my knowledge was just increased. You can actually set the prog-map preoperty using gst-launch This will put the video on PID 300 on program number 10, and PID 301 on program 11.gst-launch-1.0 -v videotestsrc name=vsrc1 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! muxer.sink_300 mpegtsmux name=muxer prog-map=program_map,sink_300=10,sink_301=11 ! queue ! tcpserversink host=0.0.0.0 sync-method=2 recover-policy=keyframe port=5000 videotestsrc name=vsrc2 is-live=true do-timestamp=true ! x264enc ! queue ! h264parse ! muxer.sink_301 On Wed, May 27, 2015 at 8:12 AM, Jesper Larsen <[hidden email]> wrote:
_______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Hi Jesper. Thanks for the info. Very helpful and very useful.Is there a way to filter which PID gets decoded when using decodebin or tsdemux On Wed, May 27, 2015 at 9:39 AM, Jesper Larsen <[hidden email]> wrote:
_______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
I'm not aware of any way of setting properties on child elements through gst-launch command. But you should be able to do the filtering using some tees, tsdemuxs, and decode bins.Imagine you have a program (10) with 1 video stream on PID 300, and two audio streams on PID 301, and 302. You should be able to play the video with one of the audio streams using something like: gst-launch-1.0 udpsrc ..... ! tsdemux program-number=10 name=d ! queue ! decodebin ! autovideosink d.audio_012d ! queue ! decodebin ! autoaudiosink That should choose the program number 10, play the video, and play the audio on PID 301 (if it is part of the program). Note that the muxer uses dec numbers for the PID while the demuxer uses hex. If you need to decode several programs at the same time, you can put a tee element in just before the tsdemux, and do a second branch with tsdemux udpsrc ... ! tee name=t ! tsdemux program-number=10 name=d1 t. ! tsdemux program-number=11 name=d2 .... You can see the templates for the pad names running gst-inspect-1.0 tsdemux Jesper On Wed, May 27, 2015 at 11:12 AM, Peter Maersk-Moller <[hidden email]> wrote:
_______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Hi Jesper. Thanks a million. Exactly the kind of granularity of control needed to mux a couple of video streams into one ts stream and needed to demux them again.On Wed, May 27, 2015 at 2:20 PM, Jesper Larsen <[hidden email]> wrote:
_______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Hi Peter,
Can u tell me how to get pid no of mpegts video wheather it is recorded or streamed file from v4l2src -- Sent from: http://gstreamer-devel.966125.n4.nabble.com/ _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Free forum by Nabble | Edit this page |