1
0
mirror of https://github.com/mpv-player/mpv synced 2025-02-19 14:26:57 +00:00

vd_lavc: reset last_sample_aspect_ratio in uninit_avctx()

In init_vo(), if sh->aspect is 0 or last_sample_aspect_ratio is set,
sh->aspect is overwritten. With software decoding fallback behaviour,
this makes the aspect ratio from container ignored since
last_sample_aspect_ratio is already set in first try with hardware
decoding.
This commit is contained in:
xylosper 2013-09-12 21:50:09 +09:00 committed by wm4
parent 1b8affee0e
commit c2ba42e02d

View File

@ -410,6 +410,7 @@ static void uninit_avctx(sh_video_t *sh)
#if !HAVE_AVUTIL_REFCOUNTING
mp_buffer_pool_free(&ctx->dr1_buffer_pool);
#endif
ctx->last_sample_aspect_ratio = (AVRational){0, 0};
}
static void uninit(sh_video_t *sh)