Commit 12583bc5 authored by Zhao Zhili's avatar Zhao Zhili Committed by Thomas Guillem

vout: android: don't overwrite projection_mode for opaque

Fix "Failed to adapt decoder format to display" and fallback to software
decoder.
Signed-off-by: Thomas Guillem's avatarThomas Guillem <thomas@gllm.fr>
parent cc4ba5d3
...@@ -505,12 +505,6 @@ static int OpenCommon(vout_display_t *vd) ...@@ -505,12 +505,6 @@ static int OpenCommon(vout_display_t *vd)
vout_display_sys_t *sys; vout_display_sys_t *sys;
video_format_t sub_fmt; video_format_t sub_fmt;
/* There are three cases:
* 1. the projection_mode is PROJECTION_MODE_RECTANGULAR
* 2. gles2 vout failed
* 3. the module is forced */
vd->fmt.projection_mode = PROJECTION_MODE_RECTANGULAR;
vout_window_t *embed = vout_window_t *embed =
vout_display_NewWindow(vd, VOUT_WINDOW_TYPE_ANDROID_NATIVE); vout_display_NewWindow(vd, VOUT_WINDOW_TYPE_ANDROID_NATIVE);
...@@ -619,6 +613,11 @@ static int Open(vlc_object_t *p_this) ...@@ -619,6 +613,11 @@ static int Open(vlc_object_t *p_this)
if (vd->fmt.i_chroma == VLC_CODEC_ANDROID_OPAQUE) if (vd->fmt.i_chroma == VLC_CODEC_ANDROID_OPAQUE)
return VLC_EGENERIC; return VLC_EGENERIC;
/* There are two cases:
* 1. the projection_mode is PROJECTION_MODE_RECTANGULAR
* 2. gles2 vout failed */
vd->fmt.projection_mode = PROJECTION_MODE_RECTANGULAR;
return OpenCommon(vd); return OpenCommon(vd);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment