Change pipeline encoder h264 to h265 at runtime
Anton Pryima
zingfrid at gmail.com
Wed Dec 9 10:33:31 UTC 2020
Hello Mustafa.
First of all, I don't think you need to do anything particular with h264
pipeline. Of course, you can lose some number of last frames, but IMHO it
is not very critical to the Viewer. So, either send PIPELINE_FLUSH event or
do nothing with it at all. Just change the encoder.
Second, about metadata. I haven't the chance to work with mpegtsmux
element, but I did the same trick with other elements and notice, that some
elements create a separate pad for different GST_CAPS. So, while debugging
this, try to put on_pad_added callback to your mpegtsmux element, and
check, is it being called while you're pushing different frames to it. If
does, try to re-link sink to the new pad.
Best regards,
Anton.
On Wed, Dec 9, 2020 at 12:15 PM MustafaBkrc <mustafa.bkrc93 at gmail.com>
wrote:
> Hello Toshick
>
> Thank you for your reply, you are right, I dont need to send EOS event to
> downstream. Which event you can suggest? Maybe GST_EVENT_RECONFIGURE event
> could be useful. And is there any function to catch eos event before go to
> donwstream ?
>
> I also understood the problem that I wrote, the reason that I cannot send
> the stream is , after EOS event all pipeline stream stops so I have to
> start
> stream with the start stream event. I send the start event to the pad I
> blocked in which is decodebin element.
>
> But I face with another problem, the mpegtsmux still have the same metadata
> (about h264enc metadata I think). I realised that output of the ffplay.
> ffplay was still trying to solve stream with h264 encoder.
>
> So I also changed the mpegtsmux with the new one at runtime, them problem
> is
> solved. But this way code can be much more complicated if I add more
> element
> after decodebin or mpegtsmux element (maybe I have to change the all
> elements after decodebin until the udpsink element).
>
> I dont know how to reconfigure or inject metadata to mpegtsmux element or
> any element. Maybe If I change the metadata of mpegtsmux I dont have to
> change any element.
>
> If you know how can I change the metadata of mpegtsmux ( h264 metadata to
> h265 metadata ), I searched but I could not find a solution of doing this.
> Could you point me to correct way of changing metadata . I would be very
> appreciated.
>
> Best Regards,
> Mustafa.
>
>
>
> --
> Sent from: http://gstreamer-devel.966125.n4.nabble.com/
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20201209/c69197a9/attachment-0001.htm>
More information about the gstreamer-devel
mailing list