Immediate-Mode-UI / Immediate-Mode-UI/Nuklear
Gamma correct fonts
- Dominant language
- C
- Stars
- 11.4k
- Forks
- 686
- Avg merge
- 4d 1h
- Merged PRs (30d)
- 3
Description
The fonts should be gamma correct, but they aren't.
I tried adding it myself, but the data that was provided in nk_tt__rasterize_sorted_edges isn't in the correct space.
https://chilliant.blogspot.com/2012/08/srgb-approximations-for-hlsl.html
After applying the formulas, the font is too bold, which could be because the data given through that function was modified so gamma incorrect rendering looks good too.
Contributor guide
Research direction
Start by tracing the font data passed through nk_tt__rasterize_sorted_edges and compare its space with the gamma formulas linked in the issue. Reproduce the current rendering and determine whether the gamma-correct result can avoid the reported overly bold appearance; done means the fonts render with the intended gamma correction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100