mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-25 15:10:10 +01:00
mesa: handle numSamples=0 in _mesa_test_proxy_teximage()
Should fix the regressions reported in bug 96949. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96949 Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
parent
aa6f60f844
commit
b89d0df535
1 changed files with 1 additions and 3 deletions
|
|
@ -1271,8 +1271,6 @@ _mesa_test_proxy_teximage(struct gl_context *ctx, GLenum target,
|
|||
{
|
||||
uint64_t bytes, mbytes;
|
||||
|
||||
assert(numSamples > 0);
|
||||
|
||||
if (numLevels > 0) {
|
||||
/* Compute total memory for a whole mipmap. This is the path
|
||||
* taken for glTexStorage(GL_PROXY_TEXTURE_x).
|
||||
|
|
@ -1306,7 +1304,7 @@ _mesa_test_proxy_teximage(struct gl_context *ctx, GLenum target,
|
|||
}
|
||||
|
||||
bytes *= _mesa_num_tex_faces(target);
|
||||
bytes *= numSamples;
|
||||
bytes *= MAX2(1, numSamples);
|
||||
|
||||
mbytes = bytes / (1024 * 1024); /* convert to MB */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue