Commit 7d69fdb7 authored by Andrew Clayton's avatar Andrew Clayton Committed by Tristan Matthews
Browse files

vpx: decoder: Set i_sar_num and i_sar_den

Since commit 0bceaf96

 ("vpx: increase decoder capability (refs #16836)")
made libvpx the default this has broken the default playback of VP8/9
video where the sample aspect ratio (SAR) is not equal to one. e.g

Given a video like

    vp8, yuv420p, 720x576, SAR 64:45 DAR 16:9, 25 fps

which is meant to be played back at 1024x576, will playback at 720x576
due to not passing the SAR value through.

I have many such videos as encoded from PAL DVD's. Another example is

    vp8, yuv420p, 720x576, SAR 16:15 DAR 4:3, 25 fps

this should actually playback at 768x576.

So this commit simply passes the SAR values through. Without this
passing --codec=ffmpeg or --codec=avcodec also restores previous
Signed-off-by: default avatarAndrew Clayton <>
Signed-off-by: Tristan Matthews's avatarTristan Matthews <>
parent 83e21b1d
......@@ -328,6 +328,11 @@ static int OpenDecoder(vlc_object_t *p_this)
dec-> = dec->;
dec-> = dec->;
if (dec-> > 0 && dec-> > 0) {
dec-> = dec->;
dec-> = dec->;
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