projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
31fe1d1
)
svga: fixed surface size to include array size
author
Charmaine Lee
<charmainel@vmware.com>
Tue, 6 Jun 2017 18:52:50 +0000
(11:52 -0700)
committer
Brian Paul
<brianp@vmware.com>
Fri, 30 Jun 2017 14:24:27 +0000
(08:24 -0600)
This patch fixes the total surface size in surface cache
to include array size as well.
Tested with MTT glretrace.
Reviewed-by: Brian Paul <brianp@vmware.com>
src/gallium/drivers/svga/svga_screen_cache.c
patch
|
blob
|
history
diff --git
a/src/gallium/drivers/svga/svga_screen_cache.c
b/src/gallium/drivers/svga/svga_screen_cache.c
index 0816ff68c8acce4608809503b5955fe0f33066b1..5cec435830a37a37bf2334ecec9d2d4c0c7bf7fb 100644
(file)
--- a/
src/gallium/drivers/svga/svga_screen_cache.c
+++ b/
src/gallium/drivers/svga/svga_screen_cache.c
@@
-48,6
+48,7
@@
surface_size(const struct svga_host_surface_cache_key *key)
assert(key->numMipLevels > 0);
assert(key->numFaces > 0);
+ assert(key->arraySize > 0);
if (key->format == SVGA3D_BUFFER) {
/* Special case: we don't want to count vertex/index buffers
@@
-68,7
+69,7
@@
surface_size(const struct svga_host_surface_cache_key *key)
total_size += img_size;
}
- total_size *= key->numFaces;
+ total_size *= key->numFaces
* key->arraySize
;
return total_size;
}