I have a custom Gstreamer Pipeline thats split into two seperate parts, producer and consumer, linked together via Appsrc/Sink
The consumer eventually outputs its result via RTMP and needs to stay up even if the producer dies, for this reason I’ve put a livesync element in it after the appsrc’s
Now my issue is that the Producer pipeline is replaceable. This will obviously reset the PTS of the data that makes it to the livesync which will then complain about too late buffers. I’ve “hacked” this by manually adjusting the PTS but I hate that solution.
Effectively what I need is a way to “reset” the livesync / tell it that it should work off a new stream without affecting the rest of the pipeline (e.g., keeping its output timestamp). Is that something possible?
livesync should handle this automatically if you forward the Segment event from the Producer.
You could use the intersink / intersrc elements which will take care of this for you (along with other things such as setting latency on the consumer’s pipeline and so forth).
I have some logic in between my pipelines which is why I use AppSrc / AppSink directly. That being said, I was indeed not forwarding events other than setting the Caps on the target.
I have added that now, probing events that reach my appsink and send them to the appsrc in the target pipeline (w/ gst_element_send_event). That did not fix my cause, livesync still expects buffers at the running time from before I had restarted the producer
It does receive the Segment apparently, just doesnt seem to do anything with it:
One important thing I probably should re-iterate: The Pipeline containing the Livesync is never EOS, it does / should stay playing the entire time as mentioned before and the producer inputting into it is a live source.