mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-15 01:17:00 +00:00
ImFontAtlas: doesn't clear input data, left to the application. (#224)
This commit is contained in:
parent
4b088ec7e8
commit
5df542c3c0
@ -230,6 +230,10 @@ static void ImGui_ImplDX11_CreateFontsTexture()
|
|||||||
samplerDesc.MaxLOD = 0.f;
|
samplerDesc.MaxLOD = 0.f;
|
||||||
g_pd3dDevice->CreateSamplerState(&samplerDesc, &g_pFontSampler);
|
g_pd3dDevice->CreateSamplerState(&samplerDesc, &g_pFontSampler);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Cleanup (don't clear the input data if you want to append new fonts later)
|
||||||
|
io.Fonts->ClearInputData();
|
||||||
|
io.Fonts->ClearTexData();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ImGui_ImplDX11_CreateDeviceObjects()
|
bool ImGui_ImplDX11_CreateDeviceObjects()
|
||||||
|
@ -224,6 +224,10 @@ static void ImGui_ImplDX9_CreateFontsTexture()
|
|||||||
|
|
||||||
// Store our identifier
|
// Store our identifier
|
||||||
io.Fonts->TexID = (void *)pTexture;
|
io.Fonts->TexID = (void *)pTexture;
|
||||||
|
|
||||||
|
// Cleanup (don't clear the input data if you want to append new fonts later)
|
||||||
|
io.Fonts->ClearInputData();
|
||||||
|
io.Fonts->ClearTexData();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ImGui_ImplDX9_CreateDeviceObjects()
|
bool ImGui_ImplDX9_CreateDeviceObjects()
|
||||||
|
@ -174,6 +174,10 @@ void ImGui_ImplGlfwGL3_CreateFontsTexture()
|
|||||||
|
|
||||||
// Store our identifier
|
// Store our identifier
|
||||||
io.Fonts->TexID = (void *)(intptr_t)g_FontTexture;
|
io.Fonts->TexID = (void *)(intptr_t)g_FontTexture;
|
||||||
|
|
||||||
|
// Cleanup (don't clear the input data if you want to append new fonts later)
|
||||||
|
io.Fonts->ClearInputData();
|
||||||
|
io.Fonts->ClearTexData();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool ImGui_ImplGlfwGL3_CreateDeviceObjects()
|
bool ImGui_ImplGlfwGL3_CreateDeviceObjects()
|
||||||
|
@ -156,6 +156,10 @@ bool ImGui_ImplGlfw_CreateDeviceObjects()
|
|||||||
// Store our identifier
|
// Store our identifier
|
||||||
io.Fonts->TexID = (void *)(intptr_t)g_FontTexture;
|
io.Fonts->TexID = (void *)(intptr_t)g_FontTexture;
|
||||||
|
|
||||||
|
// Cleanup (don't clear the input data if you want to append new fonts later)
|
||||||
|
io.Fonts->ClearInputData();
|
||||||
|
io.Fonts->ClearTexData();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -8683,7 +8683,6 @@ bool ImFontAtlas::Build()
|
|||||||
ImGui::MemFree(buf_ranges);
|
ImGui::MemFree(buf_ranges);
|
||||||
buf_packedchars = NULL;
|
buf_packedchars = NULL;
|
||||||
buf_ranges = NULL;
|
buf_ranges = NULL;
|
||||||
ClearInputData();
|
|
||||||
|
|
||||||
// Render into our custom data block
|
// Render into our custom data block
|
||||||
RenderCustomTexData(1, &extra_rects);
|
RenderCustomTexData(1, &extra_rects);
|
||||||
|
Loading…
Reference in New Issue
Block a user