Commit e90f7358 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

vdpau: fix inverted logic

parent c5e461c7
...@@ -436,8 +436,12 @@ static picture_t *VideoPassthrough(filter_t *filter, picture_t *src) ...@@ -436,8 +436,12 @@ static picture_t *VideoPassthrough(filter_t *filter, picture_t *src)
if (psys->vdp != sys->vdp) if (psys->vdp != sys->vdp)
{ {
video_format_t fmt = src->format; video_format_t fmt = src->format;
fmt.i_chroma = (sys->chroma == VDP_CHROMA_TYPE_420) switch (sys->chroma)
? VLC_CODEC_UYVY : VLC_CODEC_NV12; {
case VDP_CHROMA_TYPE_420: fmt.i_chroma = VLC_CODEC_NV12; break;
case VDP_CHROMA_TYPE_422: fmt.i_chroma = VLC_CODEC_UYVY; break;
default: assert(0);
}
picture_t *pic = picture_NewFromFormat(&fmt); picture_t *pic = picture_NewFromFormat(&fmt);
if (unlikely(pic == NULL)) if (unlikely(pic == NULL))
......
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