mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-07 06:57:36 -06:00
FIX: init_font crash
Change-Id: I2d2fd9f297e2980e789b124d3e026d0db1fa1602
This commit is contained in:
parent
dfde6e518f
commit
1f0ce4ac47
5 changed files with 36 additions and 10 deletions
|
@ -1979,6 +1979,7 @@ void ImGuiWrapper::init_font(bool compress)
|
|||
unsigned char* pixels;
|
||||
int width, height;
|
||||
io.Fonts->GetTexDataAsRGBA32(&pixels, &width, &height); // Load as RGBA 32-bits (75% of the memory is wasted, but default font is so small) because it is more likely to be compatible with user's existing shaders. If your ImTextureId represent a higher-level concept than just a GL texture id, consider calling GetTexDataAsAlpha8() instead to save on GPU memory.
|
||||
BOOST_LOG_TRIVIAL(trace) << "Build texture done. width: " << width << ", height: " << height;
|
||||
|
||||
// Fill rectangles from the SVG-icons
|
||||
for (auto icon : font_icons) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue