openframeworks / openFrameworks

openFrameworks is a community-developed cross platform toolkit for creative coding in C++.
http://openframeworks.cc
Other
9.96k stars 2.55k forks source link

bug with making contours from fonts #6592

Closed ofZach closed 2 years ago

ofZach commented 4 years ago

one of my students was experimenting with this font and this code

https://www.dropbox.com/s/p02qyulbud26fqb/lato.ttf?dl=0 https://github.com/ofZach/RTP_SFPC_SUMMER20/tree/master/typeExample3

and found that the parsing looks a little weird, some screenshots when you zoom in

Screen Shot 2020-06-07 at 7 04 09 AM Screen Shot 2020-06-07 at 7 04 01 AM

it seems that when you change the makeContoursForCharacter and make all the 64 to 64.0 instead it fixes things, so perhaps it's just a resolution issue?

Screen Shot 2020-06-07 at 7 04 43 AM Screen Shot 2020-06-07 at 7 04 37 AM

happy to submit a PR just wanted to mention it as an issue in case anyone has ideas.

dimitre commented 2 years ago

I think this is related to the fact assumes as a default parameter for simplifyAmt the value of 0.3 so maybe every loaded font is simplified?

dimitre commented 2 years ago

I've checked out the code and confirm simplifyAmt = 0.0 fixes this This PR closes this issue https://github.com/openframeworks/openFrameworks/pull/7065

Screen Shot 2022-09-27 at 21 05 26

ofTheo commented 2 years ago

closed by #7065