i965: report bound buffer size not underlying buffer size for image size (v2)
authorDave Airlie <airlied@redhat.com>
Fri, 27 May 2016 05:00:57 +0000 (15:00 +1000)
committerDave Airlie <airlied@redhat.com>
Tue, 23 Aug 2016 03:39:15 +0000 (13:39 +1000)
commit96ea753d9eb802c95544c79035e89df38daf15f7
tree574d9e64895f5acb37599200de7f23d49c35d05c
parent34ff4fbba658dbdfb2b0c852b07a0ee2db549d2e
i965: report bound buffer size not underlying buffer size for image size (v2)

This seems to make sense, the image is bound to a subset of the buffer
so the image size should be from the bound size not the underlying
object.

This fixes:
GL44-CTS.shader_image_size.advanced-nonMS-fs-int

v2: get mininum of the two values, same as we write to the hw.

Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/mesa/drivers/dri/i965/brw_wm_surface_state.c