Original Post
Lesson 36: In the EmptyTexture function, the following line is used to allocate space for an empty texture of size 128*128 width 4 color components:
data = (unsigned int*)new GLuint[((128*128) * 4 * sizeof(unsigned int))];
Can someone tell me why "4*sizeof(unsigned int)" is used?
Shouldn''t the new operator automatically allocate "4*sizeof(unsigned int)" bytes of memory per pixel when GLuint is specified?
Or is it an error?