[vlc-devel] [PATCH] opengl: display: place the initial picture
Steve Lhomme
robux4 at ycbcr.xyz
Tue Oct 13 11:47:57 CEST 2020
LGTM
On 2020-10-13 11:33, Alexandre Janniaux wrote:
> Otherwise, the display might never set the vlc_gl_t size and thought it
> would not use uninitialized vout_display_place_t objects, it would not
> initialized the OpenGL viewport and window aspect ratio either. It was
> leading to OpenGL display being at incorrect size, especially on
> Android, until the display size is changed, for example by rotating the
> phone.
> ---
> modules/video_output/opengl/display.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/modules/video_output/opengl/display.c b/modules/video_output/opengl/display.c
> index b4d79cf0ca..c62ab37298 100644
> --- a/modules/video_output/opengl/display.c
> +++ b/modules/video_output/opengl/display.c
> @@ -108,7 +108,6 @@ static int Open(vout_display_t *vd, const vout_display_cfg_t *cfg,
> return VLC_ENOMEM;
>
> sys->gl = NULL;
> - sys->place_changed = false;
>
> vout_window_t *surface = cfg->window;
> char *gl_name = var_InheritString(surface, MODULE_VARNAME);
> @@ -144,6 +143,10 @@ static int Open(vout_display_t *vd, const vout_display_cfg_t *cfg,
> if (sys->gl == NULL)
> goto error;
>
> + vout_display_PlacePicture(&sys->place, vd->source, cfg);
> + sys->place_changed = true;
> + vlc_gl_Resize (sys->gl, cfg->display.width, cfg->display.height);
> +
> /* Initialize video display */
> const vlc_fourcc_t *spu_chromas;
>
> --
> 2.28.0
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
>
More information about the vlc-devel
mailing list