mirror of
https://github.com/mpv-player/mpv.git
synced 2025-12-26 21:00:21 +00:00
vaapi: destroy derived VAImage after each use
Appears to be required by some hardware. Whatever.
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user