summaryrefslogtreecommitdiffstats
path: root/video/out/vo_vaapi.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-11-29 14:19:29 +0100
committerwm4 <wm4@nowhere>2013-11-29 14:19:29 +0100
commit60cd30055812d95aba453bdcb9b316e63fda5a31 (patch)
treefb54dd4a2bf445f7a54966c2e6389d0a2f4a9a5a /video/out/vo_vaapi.c
parent0d255f07bf46948289a2698a4a7063514d0e1ef9 (diff)
downloadmpv-60cd30055812d95aba453bdcb9b316e63fda5a31.tar.bz2
mpv-60cd30055812d95aba453bdcb9b316e63fda5a31.tar.xz
vaapi: remove unused hw image formats, simplify
PIX_FMT_VDA_VLD and PIX_FMT_VAAPI_VLD were never used anywhere. I'm not sure why they were even added, and they sound like they are just for compatibility with XvMC-style decoding, which sucks anyway. Now that there's only a single vaapi format, remove the IMGFMT_IS_VAAPI() macro. Also get rid of IMGFMT_IS_VDA(), which was unused.
Diffstat (limited to 'video/out/vo_vaapi.c')
-rw-r--r--video/out/vo_vaapi.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/video/out/vo_vaapi.c b/video/out/vo_vaapi.c
index 9a9097acf1..c2d2bb9602 100644
--- a/video/out/vo_vaapi.c
+++ b/video/out/vo_vaapi.c
@@ -160,7 +160,7 @@ static int reconfig(struct vo *vo, struct mp_image_params *params, int flags)
vo_x11_config_vo_window(vo, NULL, vo->dx, vo->dy, vo->dwidth, vo->dheight,
flags, "vaapi");
- if (!IMGFMT_IS_VAAPI(params->imgfmt)) {
+ if (params->imgfmt != IMGFMT_VAAPI) {
if (!alloc_swdec_surfaces(p, params->w, params->h, params->imgfmt))
return -1;
}
@@ -173,7 +173,7 @@ static int reconfig(struct vo *vo, struct mp_image_params *params, int flags)
static int query_format(struct vo *vo, uint32_t imgfmt)
{
struct priv *p = vo->priv;
- if (IMGFMT_IS_VAAPI(imgfmt) || va_image_format_from_imgfmt(p->va_image_formats, imgfmt))
+ if (imgfmt == IMGFMT_VAAPI || va_image_format_from_imgfmt(p->va_image_formats, imgfmt))
return VFCAP_CSP_SUPPORTED | VFCAP_CSP_SUPPORTED_BY_HW;
return 0;
@@ -272,7 +272,7 @@ static void draw_image(struct vo *vo, struct mp_image *mpi)
{
struct priv *p = vo->priv;
- if (!IMGFMT_IS_VAAPI(mpi->imgfmt)) {
+ if (mpi->imgfmt != IMGFMT_VAAPI) {
struct mp_image *wrapper = p->swdec_surfaces[p->output_surface];
struct va_surface *surface = va_surface_in_mp_image(wrapper);
if (!surface || !va_surface_upload(surface, mpi)) {