va/picture: make sure destination buffer is protected if needed
Reviewed-by: Boyuan Zhang <boyuan.zhang@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7006>
This commit is contained in:
@@ -702,6 +702,15 @@ vlVaEndPicture(VADriverContextP ctx, VAContextID context_id)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ((surf->templat.bind & PIPE_BIND_PROTECTED) != context->desc.base.protected_playback) {
|
||||||
|
if (context->desc.base.protected_playback) {
|
||||||
|
surf->templat.bind |= PIPE_BIND_PROTECTED;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
surf->templat.bind &= ~PIPE_BIND_PROTECTED;
|
||||||
|
realloc = true;
|
||||||
|
}
|
||||||
|
|
||||||
if (realloc) {
|
if (realloc) {
|
||||||
struct pipe_video_buffer *old_buf = surf->buffer;
|
struct pipe_video_buffer *old_buf = surf->buffer;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user