summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/intel_screen.c
diff options
context:
space:
mode:
authorTopi Pohjolainen <[email protected]>2013-04-25 14:33:09 +0300
committerTopi Pohjolainen <[email protected]>2013-08-02 08:56:02 +0300
commite8568a08030e0d79bd75dde57e65d01805eefe2a (patch)
treef16fdf2b1c8d36b271faf6e6ff87b607e643b520 /src/mesa/drivers/dri/i965/intel_screen.c
parent34c55b59251a9c6e9979c1c0094c5158ce3503cb (diff)
intel: allow packed prime buffers to be treated normally
v2: - fix earlier rebase error breaking bisect (loaderPriv -> loaderPrivate) Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/intel_screen.c')
-rw-r--r--src/mesa/drivers/dri/i965/intel_screen.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
index f913c429db5..ce7a51e5512 100644
--- a/src/mesa/drivers/dri/i965/intel_screen.c
+++ b/src/mesa/drivers/dri/i965/intel_screen.c
@@ -651,7 +651,11 @@ intel_create_image_from_fds(__DRIscreen *screen,
if (f == NULL)
return NULL;
- image = intel_allocate_image(__DRI_IMAGE_FORMAT_NONE, loaderPrivate);
+ if (f->nplanes == 1)
+ image = intel_allocate_image(f->planes[0].dri_format, loaderPrivate);
+ else
+ image = intel_allocate_image(__DRI_IMAGE_FORMAT_NONE, loaderPrivate);
+
if (image == NULL)
return NULL;