CsPaint questions
Posted: Mon Oct 21 2019 4:29 pm
Hi
I found many aspects of the CppCon 2019 graphics presentation interesting. I have played with sdf based text rendering and was interesting in testing it with the multi-channel sdf approach...so now you have done it for me!
You focused on the advantages of the multi-channel approach for sharp corners on large fonts. However, I had found in the past that sdf quality also had problems on smaller sizes. High DPI is certainly a concern...but we need/expect good quality for small/normal sizes/non-high-dpi as well. I wanted to play with this in CsPaint but I wasn't able to get a build working quickly on windows due to the dependencies. Can you post a screen shot? Similarly rotated text might be problematic at small/typical sizes.
Here are some other resources you might find interesting:
* Glyphy
** https://github.com/behdad/glyphy, which is by the same guy who does harfbuzz
* https://medium.com/@evanwallace/easy-scalable-text-rendering-on-the-gpu-c3f4d782c5ac
* https://wdobbie.com/post/gpu-text-rendering-with-vector-textures/
* http://jcgt.org/published/0006/02/02/
** This was commercialed into Slug, https://sluglibrary.com/
Regarding your plans to basically use a vulkan backend as the solution to high-dpi, i wonder how you will handle various design elements on scaling. For example, if you have a line which is 1 pixel wide, and then you scale to 1.5, the line will look blurry...so something more nuanced than a naive scaling may be required in some circumstances.
I found many aspects of the CppCon 2019 graphics presentation interesting. I have played with sdf based text rendering and was interesting in testing it with the multi-channel sdf approach...so now you have done it for me!
You focused on the advantages of the multi-channel approach for sharp corners on large fonts. However, I had found in the past that sdf quality also had problems on smaller sizes. High DPI is certainly a concern...but we need/expect good quality for small/normal sizes/non-high-dpi as well. I wanted to play with this in CsPaint but I wasn't able to get a build working quickly on windows due to the dependencies. Can you post a screen shot? Similarly rotated text might be problematic at small/typical sizes.
Here are some other resources you might find interesting:
* Glyphy
** https://github.com/behdad/glyphy, which is by the same guy who does harfbuzz
* https://medium.com/@evanwallace/easy-scalable-text-rendering-on-the-gpu-c3f4d782c5ac
* https://wdobbie.com/post/gpu-text-rendering-with-vector-textures/
* http://jcgt.org/published/0006/02/02/
** This was commercialed into Slug, https://sluglibrary.com/
Regarding your plans to basically use a vulkan backend as the solution to high-dpi, i wonder how you will handle various design elements on scaling. For example, if you have a line which is 1 pixel wide, and then you scale to 1.5, the line will look blurry...so something more nuanced than a naive scaling may be required in some circumstances.