svga: include sample count in surface_size() computation
Use MAX2() because sampleCount will be zero for non-MSAA surfaces. No Piglit regressions. Reviewed-by: Charmaine Lee <charmainel@vmware.com>
This commit is contained in:
@@ -69,7 +69,7 @@ surface_size(const struct svga_host_surface_cache_key *key)
|
||||
total_size += img_size;
|
||||
}
|
||||
|
||||
total_size *= key->numFaces * key->arraySize;
|
||||
total_size *= key->numFaces * key->arraySize * MAX2(1, key->sampleCount);
|
||||
|
||||
return total_size;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user