st/va: ensure linear memory for dmabuf
authorJulien Isorce <j.isorce@samsung.com>
Tue, 14 Jun 2016 07:40:33 +0000 (08:40 +0100)
committerJulien Isorce <j.isorce@samsung.com>
Tue, 14 Jun 2016 07:40:33 +0000 (08:40 +0100)
commit1cdb4da1d6ce94d947e41d4f0e568074f4f59577
treec60dab717fdf7a51a3be5ce68f63bac7d9118a8f
parent5a87bc718197deab7577a028c64a7f591bbfaec4
st/va: ensure linear memory for dmabuf

In order to do zero-copy between two different devices
the memory should not be tiled.

Tested with GStreamer on a laptop that has 2 GPUs:
1- gstvaapidecode:
   HW decoding and dmabuf export with nouveau driver on Nvidia GPU.
2- glimagesink:
   EGLImage imports dmabuf on Intel GPU.

TEST: DRI_PRIME=1 gst-launch vaapidecodebin ! glimagesink

Signed-off-by: Julien Isorce <j.isorce@samsung.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
src/gallium/auxiliary/vl/vl_video_buffer.c
src/gallium/include/pipe/p_video_codec.h
src/gallium/state_trackers/va/surface.c