fix texture pool alloc..

This commit is contained in:
Bigfoot71 2025-05-17 18:17:29 +02:00
parent f7df285d69
commit 3913ffeac2

4
src/external/rlsw.h vendored
View File

@ -3787,10 +3787,10 @@ bool swInit(int w, int h)
swViewport(0, 0, w, h); swViewport(0, 0, w, h);
swScissor(0, 0, w, h); swScissor(0, 0, w, h);
RLSW.loadedTextures = SW_MALLOC(SW_MAX_TEXTURES); RLSW.loadedTextures = SW_MALLOC(SW_MAX_TEXTURES * sizeof(sw_texture_t));
if (RLSW.loadedTextures == NULL) { swClose(); return false; } if (RLSW.loadedTextures == NULL) { swClose(); return false; }
RLSW.freeTextureIds = SW_MALLOC(SW_MAX_TEXTURES); RLSW.freeTextureIds = SW_MALLOC(SW_MAX_TEXTURES * sizeof(uint32_t));
if (RLSW.loadedTextures == NULL) { swClose(); return false; } if (RLSW.loadedTextures == NULL) { swClose(); return false; }
RLSW.clearColor[0] = 0.0f; RLSW.clearColor[0] = 0.0f;