summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary
diff options
context:
space:
mode:
authorJulien Isorce <j.isorce@samsung.com>2016-06-14 08:40:33 +0100
committerJulien Isorce <j.isorce@samsung.com>2016-06-14 08:40:33 +0100
commit1cdb4da1d6ce94d947e41d4f0e568074f4f59577 (patch)
treec60dab717fdf7a51a3be5ce68f63bac7d9118a8f /src/gallium/auxiliary
parent5a87bc718197deab7577a028c64a7f591bbfaec4 (diff)
downloadexternal_mesa3d-1cdb4da1d6ce94d947e41d4f0e568074f4f59577.zip
external_mesa3d-1cdb4da1d6ce94d947e41d4f0e568074f4f59577.tar.gz
external_mesa3d-1cdb4da1d6ce94d947e41d4f0e568074f4f59577.tar.bz2
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>
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r--src/gallium/auxiliary/vl/vl_video_buffer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/vl/vl_video_buffer.c b/src/gallium/auxiliary/vl/vl_video_buffer.c
index 4a68ac1..fdc9598 100644
--- a/src/gallium/auxiliary/vl/vl_video_buffer.c
+++ b/src/gallium/auxiliary/vl/vl_video_buffer.c
@@ -250,7 +250,7 @@ vl_video_buffer_template(struct pipe_resource *templ,
templ->height0 = tmpl->height;
templ->depth0 = depth;
templ->array_size = array_size;
- templ->bind = PIPE_BIND_SAMPLER_VIEW | PIPE_BIND_RENDER_TARGET;
+ templ->bind = PIPE_BIND_SAMPLER_VIEW | PIPE_BIND_RENDER_TARGET | tmpl->bind;
templ->usage = usage;
vl_video_buffer_adjust_size(&templ->width0, &templ->height0, plane,