[vlc-commits] vout: pass the format that goes with the vctx in vout_OpenWrapper()
Steve Lhomme
git at videolan.org
Fri Jul 17 08:18:12 CEST 2020
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Thu Jul 16 11:37:42 2020 +0200| [4df3d68ff395be1aca3389b42f49f29382859d51] | committer: Steve Lhomme
vout: pass the format that goes with the vctx in vout_OpenWrapper()
This way only video_output.c needs to know about the original format.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=4df3d68ff395be1aca3389b42f49f29382859d51
---
src/video_output/video_output.c | 2 +-
src/video_output/vout_internal.h | 2 +-
src/video_output/vout_wrapper.c | 5 ++---
3 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c
index 4c209ff292..af12f6e726 100644
--- a/src/video_output/video_output.c
+++ b/src/video_output/video_output.c
@@ -1617,7 +1617,7 @@ static int vout_Start(vout_thread_t *vout, vlc_video_context *vctx, const vout_c
dcfg.window_props.width = sys->window_width;
dcfg.window_props.height = sys->window_height;
- sys->display = vout_OpenWrapper(vout, sys->splitter_name, &dcfg, vctx);
+ sys->display = vout_OpenWrapper(vout, sys->splitter_name, &dcfg, &sys->original, vctx);
if (sys->display == NULL) {
vlc_mutex_unlock(&sys->display_lock);
goto error;
diff --git a/src/video_output/vout_internal.h b/src/video_output/vout_internal.h
index abeb4c24e5..7003ad83a1 100644
--- a/src/video_output/vout_internal.h
+++ b/src/video_output/vout_internal.h
@@ -265,7 +265,7 @@ void vout_IntfDeinit(vlc_object_t *);
/* */
vout_display_t *vout_OpenWrapper(vout_thread_t *, const char *,
- const vout_display_cfg_t *, vlc_video_context *);
+ const vout_display_cfg_t *, video_format_t *, vlc_video_context *);
void vout_CloseWrapper(vout_thread_t *, vout_display_t *vd);
/* */
diff --git a/src/video_output/vout_wrapper.c b/src/video_output/vout_wrapper.c
index 9e5b14a56b..2c2d896f5a 100644
--- a/src/video_output/vout_wrapper.c
+++ b/src/video_output/vout_wrapper.c
@@ -56,7 +56,7 @@ static void VoutViewpointMoved(void *sys, const vlc_viewpoint_t *vp)
*****************************************************************************/
vout_display_t *vout_OpenWrapper(vout_thread_t *vout,
const char *splitter_name, const vout_display_cfg_t *cfg,
- vlc_video_context *vctx)
+ video_format_t *fmt, vlc_video_context *vctx)
{
vout_thread_sys_t *sys = vout->p;
vout_display_t *vd;
@@ -73,8 +73,7 @@ vout_display_t *vout_OpenWrapper(vout_thread_t *vout,
else
modlist = "splitter,none";
- vd = vout_display_New(VLC_OBJECT(vout), &sys->original, vctx, cfg,
- modlist, &owner);
+ vd = vout_display_New(VLC_OBJECT(vout), fmt, vctx, cfg, modlist, &owner);
free(modlistbuf);
if (vd == NULL)
More information about the vlc-commits
mailing list