mirror of
https://git.code.sf.net/p/quake/newtree
synced 2024-11-22 12:11:34 +00:00
Fix for memory waste noticed by LordHavoc: 4*sizeof(unsigned int) (4* needed size!) to GL_4_BYTES (nice portable GL types, we should use them everywhere!)
This commit is contained in:
parent
dae1954eaf
commit
1c235242f9
1 changed files with 2 additions and 2 deletions
|
@ -1177,8 +1177,8 @@ GL_Upload32 (unsigned int *data, int width, int height, qboolean mipmap,
|
|||
|
||||
if (!
|
||||
(scaled =
|
||||
malloc (scaled_width * scaled_height * 4 *
|
||||
sizeof (unsigned int)))) Sys_Error ("GL_LoadTexture: too big");
|
||||
malloc (scaled_width * scaled_height *
|
||||
sizeof (GL_4_BYTES)))) Sys_Error ("GL_LoadTexture: too big");
|
||||
|
||||
samples = alpha ? gl_alpha_format : gl_solid_format;
|
||||
|
||||
|
|
Loading…
Reference in a new issue