Wii U: Don't forget to reset pointer to NULL

This commit is contained in:
UnknownShadow200 2025-03-09 07:30:16 +11:00
parent 199be2f489
commit 698a461fdd
2 changed files with 3 additions and 3 deletions

View File

@ -294,8 +294,6 @@ static void CreateFragmentPrograms(int index, const SceGxmProgram* fragProgram,
FragmentProgram* FP = &FP_list[index + i];
sceGxmShaderPatcherRegisterProgram(gxm_shader_patcher, fragProgram, &programID);
const SceGxmProgram* prog = sceGxmShaderPatcherGetProgramFromId(programID); // TODO just use original program directly?
sceGxmShaderPatcherCreateFragmentProgram(gxm_shader_patcher,
programID, SCE_GXM_OUTPUT_REGISTER_FORMAT_UCHAR4,
SCE_GXM_MULTISAMPLE_NONE, blend_modes[i], vertexProgram,

View File

@ -184,8 +184,10 @@ static void BindPendingTexture(void) {
}
void Gfx_DeleteTexture(GfxResourceID* texId) {
if (*texId == pendingTex) pendingTex = NULL;
GX2Texture* tex = (GX2Texture*)texId;
if (tex == pendingTex) pendingTex = NULL;
// TODO free memory ???
*texId = NULL;
}
void Gfx_EnableMipmaps(void) { } // TODO