i have this command
uridecodebin uri=rtmp://127.0.0.1/test/test ! x264enc ! mpegtsmux ! multifilesink location=/%05d.ts sync=true next-file=key-unit-event post-messages=true This need a lot of cpu, because have x264enc, but the input already in h264. How i can do the same but without need encode and with audio? |
Do a h264parse instead of x264enc, that will ensure that if you have any
kind of h264 input (byte-stream or avc) it should work with your mpegtsmux On Sat, Aug 12, 2017 at 09:03:28AM -0700, RonRog wrote: > i have this command > > uridecodebin uri=rtmp://127.0.0.1/test/test ! x264enc ! mpegtsmux ! > multifilesink location=/%05d.ts sync=true next-file=key-unit-event > post-messages=true > > This need a lot of cpu, because have x264enc, but the input already in h264. > How i can do the same but without need encode and with audio? > > > > -- > View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Command-without-need-encode-tp4684184.html > Sent from the GStreamer-devel mailing list archive at 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 |
I've already been tried this, no error or file is generated that way.
dont wotk and without error uridecodebin uri=rtmp://127.0.0.1/test/test ! h264parse ! mpegtsmux ! multifilesink location=/%05d.ts sync=true next-file=key-unit-event post-messages=true work but without sound and a lot of cpu uridecodebin uri=rtmp://127.0.0.1/test/test ! x264enc ! mpegtsmux ! multifilesink location=/%05d.ts sync=true next-file=key-unit-event post-messages=true work fine but need set input codec rtmpsrc name=rtmpsrc location=rtmp://127.0.0.1/test/test timeout=5 ! queue ! flvdemux name=demuxer ! queue ! aacparse ! muxer. demuxer. ! queue ! h264parse ! mpegtsmux name=muxer ! multifilesink location=/%05d.ts sync=true next-file=key-unit-event post-messages=true I want a way to do this automatically, without even using the h264parse, something that works with any input which is already in the correct format, similar to copy of ffmpeg. |
On Sat, 2017-08-12 at 16:59 -0700, RonRog wrote:
Hi, > dont wotk and without error > uridecodebin uri=rtmp://127.0.0.1/test/test ! h264parse ! mpegtsmux ! > multifilesink location=/%05d.ts sync=true next-file=key-unit-event > post-messages=true That's because uridecodebin decodes, so the whole h264parse ... sink branch will never be linked and thus doesn't preroll. You should get a warning in newer versions of gst-launch. > work but without sound and a lot of cpu > uridecodebin uri=rtmp://127.0.0.1/test/test ! x264enc ! mpegtsmux ! > multifilesink location=/%05d.ts sync=true next-file=key-unit-event > post-messages=true Right, because you decode and then re-encode. > work fine but need set input codec > rtmpsrc name=rtmpsrc location=rtmp://127.0.0.1/test/test timeout=5 ! > queue ! > flvdemux name=demuxer ! queue ! aacparse ! muxer. demuxer. ! queue ! > h264parse ! mpegtsmux name=muxer ! multifilesink location=/%05d.ts > sync=true > next-file=key-unit-event post-messages=true > > I want a way to do this automatically, without even using the > h264parse, > something that works with any input which is already in the correct > format, > similar to copy of ffmpeg. There's parsebin in newer versions of GStreamer, so you might be able to do something like: mpegtsmux name=mux ! filesink location=foo.ts \ rtmpsrc ! parsebin name=parse \ parse. ! queue ! mux. \ parse. ! queue ! mux. - completely untested though! 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 http://gstreamer.freedesktop.org/conference/ _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Thank you all for the attention!
Sorry for my ignorance, in this case the place of rtmp link it's on property location? I have tried this with gstreamer 1.10: gst-launch-1.0 mpegtsmux name=mux ! filesink location=foo.ts \ rtmpsrc location=rtmp://127.0.0.1/test/test ! parsebin name=parse \ parse. ! queue ! mux. \ parse. ! queue ! mux. Anyway I get an error: Setting pipeline to PAUSED ... Pipeline is PREROLLING ... ERROR: from element /GstPipeline:pipeline0/GstRTMPSrc:rtmpsrc0: Internal data stream error. Additional debug info: gstbasesrc.c(2950): gst_base_src_loop (): /GstPipeline:pipeline0/GstRTMPSrc:rtmpsrc0: streaming stopped, reason not-linked (-1) ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... Freeing pipeline ... |
Free forum by Nabble | Edit this page |