summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-07-15 13:30:32 +0200
committerwm4 <wm4@nowhere>2015-07-15 13:30:32 +0200
commit7ef8f457a8631ff09a928ee5aa6bb3f5fabfce11 (patch)
tree245c02caf273fc0dca86e89a051bec1452874392
parentbc68794acc067d8862525caa41ab3922ef9239bc (diff)
downloadmpv-7ef8f457a8631ff09a928ee5aa6bb3f5fabfce11.tar.bz2
mpv-7ef8f457a8631ff09a928ee5aa6bb3f5fabfce11.tar.xz
vaapi: destroy derived VAImage after each use
Appears to be required by some hardware. Whatever.
-rw-r--r--video/vaapi.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/video/vaapi.c b/video/vaapi.c
index ed021cfdd1..9bc5953ad0 100644
--- a/video/vaapi.c
+++ b/video/vaapi.c
@@ -395,6 +395,8 @@ int va_surface_upload(struct mp_image *va_dst, struct mp_image *sw_src)
return -1;
}
+ if (p->is_derived)
+ va_surface_image_destroy(p);
return 0;
}
@@ -433,6 +435,8 @@ static struct mp_image *try_download(struct mp_image *src,
}
va_image_unmap(p->ctx, image);
}
+ if (p->is_derived)
+ va_surface_image_destroy(p);
return dst;
}