Pull-mode video sink in playback

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

Pull-mode video sink in playback

Yi-Lung Tsai
There is a function named "activate_pull" in GstBaseSink indicating a sink could be in pull-mode.
I wonder is it possible to develop a videosink in pull-mode for playback purpose.
If so, is there any example or sample code to do similar tasks?

Yi-Lung (Bruce) Tsai

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

Re: Pull-mode video sink in playback

Sebastian Dröge-3
On Fri, 2017-01-06 at 16:14 +0800, Yi-Lung Tsai wrote:
> There is a function named "activate_pull" in GstBaseSink indicating a
> sink could be in pull-mode.
> I wonder is it possible to develop a videosink in pull-mode for
> playback purpose.
> If so, is there any example or sample code to do similar tasks?

In theory that would be possible, but it's completely untested and will
probably not work without further changes. And most importantly, you
will need an element in front of your sink that can actually be pulled
from.

There were some experiments with that in 0.10 times and audio sinks,
but not much came out of that because IIRC the advantages were rather
minimal and did not warrant the added complexity.


Why would you like to have a pull mode video sink?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (981 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Pull-mode video sink in playback

Yi-Lung Tsai


On Jan 6, 2017, at 5:45 PM, Sebastian Dröge <[hidden email]> wrote:

On Fri, 2017-01-06 at 16:14 +0800, Yi-Lung Tsai wrote:
There is a function named "activate_pull" in GstBaseSink indicating a
sink could be in pull-mode.
I wonder is it possible to develop a videosink in pull-mode for
playback purpose.
If so, is there any example or sample code to do similar tasks?

In theory that would be possible, but it's completely untested and will
probably not work without further changes. And most importantly, you
will need an element in front of your sink that can actually be pulled
from.

There were some experiments with that in 0.10 times and audio sinks,
but not much came out of that because IIRC the advantages were rather
minimal and did not warrant the added complexity.


Why would you like to have a pull mode video sink?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

Thanks for the information.

We have an existing rendering engine for image and video.
However, it is designed in pull mode, from the view point of pipeline.
I wrote a video sink to integrate push-mode pipeline and pull-mode rendering engine.
This makes things a bit complicated and we suffered performance issue.

Our strategy now is setting render-delay to get video frame earlier in video sink.
Then let rendering engine get the buffer and render the buffer at the right time.
We are still working on it, and meanwhile I tried to find alternatives.
But pull-mode video sink is more complicated than I thought.

--
Yi-Lung (Bruce) Tsai


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