mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-02-22 11:51:41 +00:00
Fix HWR_ClearLightTables being called too late
extracolormaps own the OpenGL-specific light table data, so that has to be freed earlier.
This commit is contained in:
parent
baec79e01d
commit
98aed03f15
2 changed files with 3 additions and 3 deletions
|
@ -8002,6 +8002,9 @@ boolean P_LoadLevel(boolean fromnetsave, boolean reloadinggamestate)
|
||||||
// Free GPU textures before freeing patches.
|
// Free GPU textures before freeing patches.
|
||||||
if (rendermode == render_opengl && (vid.glstate == VID_GL_LIBRARY_LOADED))
|
if (rendermode == render_opengl && (vid.glstate == VID_GL_LIBRARY_LOADED))
|
||||||
HWR_ClearAllTextures();
|
HWR_ClearAllTextures();
|
||||||
|
|
||||||
|
// Delete light table textures
|
||||||
|
HWR_ClearLightTables();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
Patch_FreeTag(PU_PATCH_LOWPRIORITY);
|
Patch_FreeTag(PU_PATCH_LOWPRIORITY);
|
||||||
|
|
|
@ -426,9 +426,6 @@ void R_ClearColormaps(void)
|
||||||
{
|
{
|
||||||
// Purged by PU_LEVEL, just overwrite the pointer
|
// Purged by PU_LEVEL, just overwrite the pointer
|
||||||
extra_colormaps = R_CreateDefaultColormap(true);
|
extra_colormaps = R_CreateDefaultColormap(true);
|
||||||
#ifdef HWRENDER
|
|
||||||
HWR_ClearLightTables();
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in a new issue