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

Support MSDF/MTSDF fonts #1107

Open
soywiz opened this issue Nov 13, 2022 · 2 comments
Open

Support MSDF/MTSDF fonts #1107

soywiz opened this issue Nov 13, 2022 · 2 comments

Comments

@soywiz
Copy link
Member

soywiz commented Nov 13, 2022

Would be nice to be able to generate them on the fly from TTFs/OTFs with a mutable atlas to add glyphs on the fly, so people can just use a normal TTF but render without intermediate textures for specific texts. While still being able to support normal TTF fonts normally rendered for static texts to have as much quality as possible.

References MSDF:

SDF:

Later we should have also emojis in mind. Maybe emojis can be rendered alone in separate bitmaps/textures at a fixed size, and alternatively for COLRv1 fonts we can render vector chunks, and colorize them later.

@soywiz soywiz added this to Korlibs Nov 13, 2022
@soywiz soywiz moved this to Backlog in Korlibs Nov 13, 2022
@soywiz
Copy link
Member Author

soywiz commented Nov 13, 2022

We can start implementing a SDF autoatlas as a proof of concept, since it should be easier and faster to implement, and there is already code in the codebase for that IIRC, then implement the MSDF later.

soywiz added a commit that referenced this issue Nov 13, 2022
soywiz added a commit that referenced this issue Nov 13, 2022
soywiz added a commit that referenced this issue Nov 13, 2022
…g and ellipsis, fixes bounds with filters, add fast material-like circle+rounded rect with shadow rendering based on SDF [Part 1] (#1105)

* Initial work on new UIButton material-like

* Improve UIButton behaviour

* More work

* Added ShadedView for custom shaders supporting paddings

* Fix UIVerticalList zIndex

* Cleanup Animator when working in parallel mode

* Added FastMaterialBackground supporting background, rounded corners, highlight circle + shadow

* Small Graphics fix

* Simplify Shader function creation to be DRY with arguments

* Updated UIButton to use FastMaterialBackground

* More work on window an combobox

* More work supporting rendering material layers with RenderContext2D directly

* More work supporting rendering material layers with RenderContext2D directly

* More work

* Fixes long-standing issue with UIWindow resizing

* Fix debug fps overlay scale to be an integer and avoid rendering issues

* Fixes mouse overlay debug scale too

* Optimize setting UIView size

* Some fixes and improvements

* More work

* Improve RichTextData

* Make RichTextData support word wrapping, limiting by height and ellipsis

* Make RichTextData potentially support other nodes in addition to text

* Support constructing deques from other collections

* Improve headless testing to make it simpler for devs

* Support rendering RichTextData into Context2D

* Put new text engine at work!

* Fix XML attributes without quotes

* Added RichTextData HTML support

* Fix RichTextData.toHTML()

* Support rich text color

* More work

* Some work on #1107

* Some work on #1107
@soywiz
Copy link
Member Author

soywiz commented Mar 14, 2023

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

No branches or pull requests

1 participant