[vlc-commits] video_output: implement the hold_device for filters
Steve Lhomme
git at videolan.org
Mon Dec 2 13:42:34 CET 2019
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Tue Nov 12 08:49:43 2019 +0100| [638bb47c53d3925970c6a293488bbe85b4f0b7c4] | committer: Steve Lhomme
video_output: implement the hold_device for filters
For static, interactive filters and the SPU blender filters
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=638bb47c53d3925970c6a293488bbe85b4f0b7c4
---
src/video_output/video_output.c | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index 856fc343d1..c71f00ed2f 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -958,8 +958,15 @@ static int ThreadDisplayPreparePicture(vout_thread_t *vout, bool reuse,
return VLC_SUCCESS;
}
+static vlc_decoder_device * VoutHoldDecoderDevice(vlc_object_t *o, void *sys)
+{
+ VLC_UNUSED(o);
+ vout_thread_t *vout = sys;
+ return vout->p->dec_device ? vlc_decoder_device_Hold( vout->p->dec_device ) : NULL;
+}
+
static const struct filter_video_callbacks vout_video_cbs = {
- NULL, NULL /* TODO */
+ NULL, VoutHoldDecoderDevice,
};
static picture_t *ConvertRGB32AndBlend(vout_thread_t *vout, picture_t *pic,
@@ -1530,10 +1537,10 @@ static int vout_Start(vout_thread_t *vout, vlc_video_context *vctx, const vout_c
video_format_Copy(&sys->filter.src_fmt, &sys->original);
static const struct filter_video_callbacks static_cbs = {
- VoutVideoFilterStaticNewPicture, NULL/*TODO*/,
+ VoutVideoFilterStaticNewPicture, VoutHoldDecoderDevice,
};
static const struct filter_video_callbacks interactive_cbs = {
- VoutVideoFilterInteractiveNewPicture, NULL/*TODO*/,
+ VoutVideoFilterInteractiveNewPicture, VoutHoldDecoderDevice,
};
filter_owner_t owner = {
.video = &static_cbs,
More information about the vlc-commits
mailing list