mirror of https://github.com/mpv-player/mpv
video: remove libavutil PSEUDOPAL stuff
Not needed anymore with newest libavutil.
This commit is contained in:
parent
e3e2c794ef
commit
c338c0d90a
|
@ -212,9 +212,7 @@ struct mp_imgfmt_desc mp_imgfmt_get_desc(int mpfmt)
|
|||
desc.bytes[p] = desc.bpp[p] / 8;
|
||||
}
|
||||
|
||||
// PSEUDOPAL is a complete braindeath nightmare, however it seems various
|
||||
// parts of FFmpeg expect that it has a palette allocated.
|
||||
if (pd->flags & (AV_PIX_FMT_FLAG_PAL | AV_PIX_FMT_FLAG_PSEUDOPAL))
|
||||
if (pd->flags & AV_PIX_FMT_FLAG_PAL)
|
||||
desc.flags |= MP_IMGFLAG_PAL;
|
||||
|
||||
if ((desc.flags & (MP_IMGFLAG_YUV | MP_IMGFLAG_RGB))
|
||||
|
|
|
@ -478,8 +478,7 @@ static void mp_image_copy_cb(struct mp_image *dst, struct mp_image *src,
|
|||
memcpy_pic_cb(dst->planes[n], src->planes[n], line_bytes, plane_h,
|
||||
dst->stride[n], src->stride[n], cpy);
|
||||
}
|
||||
// Watch out for AV_PIX_FMT_FLAG_PSEUDOPAL retardation
|
||||
if ((dst->fmt.flags & MP_IMGFLAG_PAL) && dst->planes[1] && src->planes[1])
|
||||
if (dst->fmt.flags & MP_IMGFLAG_PAL)
|
||||
memcpy(dst->planes[1], src->planes[1], AVPALETTE_SIZE);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue