Open rsms opened 4 years ago
I tried disabling everything I could think of with otfccbuild and still the same issue:
./bin/release-x64/otfccbuild -O0 --keep-unicode-ranges --keep-modified-time \
--dont-merge-features --dont-merge-lookups --keep-average-char-width \
-o Inter-Regular-otfccbuild.otf Inter-Regular.json
I ran OTS 7.1.7 on the font files and no combinations of options yields a readable font file. E.g.
ots-validator-checker Inter-Regular-otfccbuild.otf
→ font renderer couldn't open the transcoded font
(whereas with the original input file ots-validator-checker Inter-Regular.otf
→ font renderer didn't crash
which is OTS’s way of saying that it succeeded. OTS is used in Chrome to validate fonts.)
Strange. I do not have dev environment for otfcc
now since it has been stalled for pretty a while.
Note that if you want to fix https://github.com/rsms/inter/issues/228 by round-tripping with otfcc then it won't. otfcc's bounding box definition is also wrong.
Thanks for chiming in @be5invis. I’m working on a project unrelated to Inter where I’d like to use otfcc. I used its code in a C project and kept getting invalid font files as an output; thought it was my code that somehow used the otfcc functions incorrectly, so I tried just compiling with master and latest stable release. Turned out there’s an issue in otfcc :–)
repro:
The input file Inter-Regular.otf is from the Inter v3.11 release and is verified to work correctly in a variety of font parsers (also it passes the macOS Font Book validator)
However the output file is not only MUCH larger in size but also does not work on macOS. Font Book validation fails with “System Validation” error:
Attached here is the input font file, resulting output font file and the JSON dump, to save you some time: otfs-and-json.zip
Here are TTX dumps with a diff: ttx-with-diff.zip
I also tried building the latest master from git which yields the exact same results.
Env: