diff options
author | Filip Milivojevic <zekica@gmail.com> | 2015-03-08 19:58:58 +0100 |
---|---|---|
committer | Diogo Franco (Kovensky) <diogomfranco@gmail.com> | 2015-03-11 12:49:39 +0900 |
commit | 623a259eee523741642df4a28e8240a37581582a (patch) | |
tree | 6509b3e6303b16be89db7e9474d16913eee92cd0 /video | |
parent | fa81e835bc0d496b71777e6a3e46ecd3bc49a759 (diff) | |
download | mpv-623a259eee523741642df4a28e8240a37581582a.tar.bz2 mpv-623a259eee523741642df4a28e8240a37581582a.tar.xz |
vf_vavpp: fix deinterlacing
Add filter parameters to VAAPI deinterlacing filter to actually process
bottom fields instead of deinterlacing top field twice.
Signed-off-by: wm4 <wm4@nowhere>
(cherry picked from commit 5c3a6ca96e8bb5275149e5763f27c6aaed35113d)
Diffstat (limited to 'video')
-rw-r--r-- | video/filter/vf_vavpp.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/video/filter/vf_vavpp.c b/video/filter/vf_vavpp.c index 54648e124c..be7f7f4dad 100644 --- a/video/filter/vf_vavpp.c +++ b/video/filter/vf_vavpp.c @@ -163,6 +163,14 @@ static struct mp_image *render(struct vf_instance *vf, struct mp_image *in, status = vaMapBuffer(p->display, buffer, (void**)¶m); if (!check_error(vf, status, "vaMapBuffer()")) break; + + VAProcFilterParameterBufferDeinterlacing *filter_params; + status = vaMapBuffer(p->display, *(p->pipe.filters), (void**)&filter_params); + if (!check_error(vf, status, "vaMapBuffer()")) + break; + filter_params->flags = flags & VA_TOP_FIELD ? 0 : VA_DEINTERLACING_BOTTOM_FIELD; + vaUnmapBuffer(p->display, *(p->pipe.filters)); + param->surface = in_id; param->surface_region = NULL; param->output_region = NULL; |