summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/va/picture.c
diff options
context:
space:
mode:
authorLeo Liu <[email protected]>2017-09-11 12:57:22 -0400
committerLeo Liu <[email protected]>2017-09-25 09:42:13 -0400
commit3ad8687295449154a91464b7990963fd88cf3cd1 (patch)
treea77f7a47f62681b301015d306a7e68c2f05b60bb /src/gallium/state_trackers/va/picture.c
parentdb28fdc0adabc7781b4dc8082d99003b63cf49c1 (diff)
st/va: use new vl_compositor_yuv_deint_full() to deint
We also set src rectangle explicitly just in case of the mismatch of size between interlaced buffer and progressive buffer Acked-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers/va/picture.c')
-rw-r--r--src/gallium/state_trackers/va/picture.c14
1 files changed, 11 insertions, 3 deletions
diff --git a/src/gallium/state_trackers/va/picture.c b/src/gallium/state_trackers/va/picture.c
index 19df52cb83e..81bd196ce00 100644
--- a/src/gallium/state_trackers/va/picture.c
+++ b/src/gallium/state_trackers/va/picture.c
@@ -668,9 +668,17 @@ vlVaEndPicture(VADriverContextP ctx, VAContextID context_id)
}
if (context->decoder->entrypoint == PIPE_VIDEO_ENTRYPOINT_ENCODE) {
- if (old_buf->interlaced)
- vl_compositor_yuv_deint(&drv->cstate, &drv->compositor, old_buf, surf->buffer);
- else
+ if (old_buf->interlaced) {
+ struct u_rect src_rect;
+
+ src_rect.x0 = 0;
+ src_rect.y0 = 0;
+ src_rect.x1 = surf->templat.width;
+ src_rect.y1 = surf->templat.height;
+ vl_compositor_yuv_deint_full(&drv->cstate, &drv->compositor,
+ old_buf, surf->buffer,
+ &src_rect, NULL, VL_COMPOSITOR_WEAVE);
+ } else
/* Can't convert from progressive to interlaced yet */
return VA_STATUS_ERROR_INVALID_SURFACE;
}