Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stb_truetype 1.06 assertion #280

Closed
Pagghiu opened this issue Jul 20, 2015 · 3 comments
Closed

stb_truetype 1.06 assertion #280

Pagghiu opened this issue Jul 20, 2015 · 3 comments

Comments

@Pagghiu
Copy link
Contributor

Pagghiu commented Jul 20, 2015

@ocornut I'm sorry for the delayed answer to your questions in #133 but I've been on travel with limited internet access.

I think it's better to split this off the #133 discussion regarding assertions I've been hitting during latest update of imgui, as I don't think it's a great idea answering to closed issues 🙈

I get an assertion in stb_truetype 1.06 on latest IMGUI master featuring the updated stb_truetype 1.06 asserts when adding font awesome.

stb_truetype_assertion_1

![stb_truetype_assertion_2](https://cloud.githubusercontent.com/assets/5406873/8796405/ddf3ffce-2f94-11e5-9020-f553279119ab.jpg) ![stb_truetype_assertion_9](https://cloud.githubusercontent.com/assets/5406873/8796406/de15bd80-2f94-11e5-992a-f939c5d29a0f.jpg)

I have been able to recreate a small repro case:

  • Tested on the OpenGL Sample from today's master (60dce8b)
  • Needs the binarized/compressed font awesome
  • The assert is hit consistently when stb_truetype == 1.06 and it's not hit when stb_truetype == 1.05

I've created a small repro in a branch (OpenGL sample, not OpenGL3)
https://github.com/Pagghiu/imgui/tree/bug-stb-truetype

Regarding your question in #133

On updating to indexed rendering - did you run into any issue or confusing thing that you think could have been easier

It literally took me 10 minutes to update everything on multiple platforms. I'm lucky as I'm using a plain OpenGL backend, so updating was actually a copy/paste of the Rendering function in the OpenGL sample with the addition of small code changes to handle High-DPI displays.
I also have a function that "clones" the entire ImDrawData to let another thread do the rendering job, and it was just as easy to update. I need that to correctly handle rendering/vsync on OSX (runs on a special OS thread) and to avoid multithreading issues that's my only option, but this is probably a topic for another github issue someday 😄

@ocornut
Copy link
Owner

ocornut commented Jul 21, 2015

I can repro but I suppose we'll need to make a repro for stb_truetype,h
Note that it doesn't happen if you #define STBTT_RASTERIZER_VERSION 1

@ocornut
Copy link
Owner

ocornut commented Aug 1, 2015

Should be fixed now.

@Pagghiu
Copy link
Contributor Author

Pagghiu commented Aug 1, 2015

Yes, everything works correctly now! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants