Open sourcing VTT

2»

Comments

  • I also believe there's the case, Khaled.

    I also understood that macO and iOS sorta interpret, rather than faithfully execute, hints, but with the latest "blurry fonts" user outrage I guess maybe something changed. 
  • John HudsonJohn Hudson Posts: 2,955
    FreeType has different rendering modes, some of them ignore font hinting completely (with or without auto-hinting) and I think that is what Android is using.

    Does anyone have stats on ppi resolution of Android devices reckoned to be in current use? I'm presuming they're mostly high resolution phones?
  • John HudsonJohn Hudson Posts: 2,955
    Hinting only matters for Windows users...
    What about varieties of Unix users? It's still possible to walk into an electronics store and buy a low resolution desktop monitor like the HP W2082a model (92ppi), and plug it into a PC running any chip compatible operating system.

    Then there's the whole world of embedded display systems...
  • … which, as we know, are just a tiny minority. :#
    From the market share, no.
    For me, hinting would become something more like a semantic marking of shape parts.
  • I actually think releasing vtt may not be as high impact as making a Python hinting engine, so we can have hinting extensions to all editors.
  • I was under the impression that python was too slow or CPU-intensive to make a hinting engine in it...or at least that's what people said several years ago.
  • I actually think releasing vtt may not be as high impact as making a Python hinting engine, so we can have hinting extensions to all editors.
    What exactly do you mean by "hinting engine"?
  • Autohinter, I believe @Dave Crossland means.
  • No, I believe a general purpose version of the truetype byte code interpreter, with support for  high level representations, such as vttalk and the one in Fontlab 5, and/or an autohi
  • You would need several components to build a full hinting system that can be plugged into editors:
    • Compiler from high-level instructions (glyf and CVT program) to assembly
    • Compiler from assembly to bytecode
    • Autohinter that generates high-level instructions
    • Instruction processor (applies instructions to deform a given glyph outline)
    • Rasterizer (translates the hinted outline into pixels)
    • UI for visual instruction editing
    • Storage format for high-level instructions in font source files
    The Font Programs (fpgm table) of VTT and FontLab fall most certainly under copyright as computer programs, so to do any practical hinting you would either need to have someone write new font programs, or convince FontLab and MS to release theirs under a libre licence.

    As for the instruction processor, it’s surely possible to write one in Python following the TrueType instruction manual (I have done so in a limited way), but it may differ from real-world processors which selectively ignore some instructions or interpret them differently (ClearType subpixel sampling for example).

    For rasterizers, the same applies. The big advantage of VTT is that it uses the same rasterizer(s) that will be used on the biggest target platform that displays the font.
  • Yes, there is interest. Having an open source version would be more than great.

    The UI has its issues (which would be easier to fix if open sourced) but I guess some crucial parts cannot be open sourced. If there was a way to plug in freetype instead that would be great as well.
    Oh god no. The eternal struggle of all off-brand renderers being inaccurate to the Microsoft bilevel renderer. Not again.
  • Thomas PhinneyThomas Phinney Posts: 2,732
    belatedly!

    Jens: FontLab VI and up also use a real Microsoft ClearType rasterizer (on any OS). Run it on MacOS and you also get real Apple rendering as well as real Microsoft rendering.
  • Fredrick BrennanFredrick Brennan Posts: 3
    edited April 2022
    @Eli Heuer suggested I reply here about MFEK Grant №6, Series of 2022. I am sorry if that's against the rules.

    Whereas, OpenType fonts are the main type of font used in computing today;

    Whereas, despite the increasing acceptance of high DPI screens, such screens have not totally overtaken the market as was once predicted;

    Whereas, even high DPI screens still require hinting for best display;

    Whereas, TrueType hinting remains the best way to hint OpenType fonts in the sense that it gives the most control to the font developer;

    Whereas, Microsoft developed in the 1990’s a programming language known as VTTTalk;

    Whereas, VTTTalk instructions are written as UTF-8 into the OpenType font table marked TSI3;

    Whereas, Microsoft has open sourced the compiler which converts VTTTalk into TrueType instructions;

    Whereas, despite this act, however generous it may be on the surface, Microsoft refuses to provide to the community a way of generating VTTTalk instructions (the VTT GUI);

    Whereas, the Modular Font Editor K Foundation, Inc., opposes in principle the necessity of proprietary software to create fonts in open file formats,

    Then, therefore, The Modular Font Editor K Foundation, Inc. opens for bids from the public the following signed grant proposal dated this 22nd of April, 2022, entitled “Visual TrueType GUI Rewrite” and with the reference code MFEK Foundation Grant № 6, Series of 2022.

    The Foundation estimates this grant will take two months to complete.

    This is document revision 0.


    My Foundation is currently offering the aforementioned grant to anyone who can create an open source GUI that creates the necessary VTTTalk code that can be compiled with the free software compiler MS released. It says on the page our bottom bid is $7,000, however we've heard community feedback and even if your offer is significantly higher please get in contact, we'll consider it, especially if you're super experienced.

    I'm also rewriting our Standard Terms to be more favorable to awardees who want to accept multiple grants, something I had not considered until @Thomas Phinney brought up the possibility. I'm still new at this—the Foundation was only officially incorporated on 22nd April 2022!

    How to bid on MFEK Foundation Grants, and their terms: https://mfek.org/foundation/terms.html



  • @Fredrick Brennan I don’t know how familiar you are with VTT (As it only runs on Windows, probably not very much so ;))

    Also not sure where the best place for discussion is, so I’m just adding my thoughts here.

    One of the general workflow problems with VTT is that it works on the final product, i.e. the binary font file. This makes it very hard to quickly generate or update the hinted font from the design source. You can add or replace single glyphs into the hinted font, but there is no assistance in finding differences between the old and new glyph other than manually checking that the hinting code still does what it is supposed to do (if point indices or positions change, the code may have become completely invalid, or just produce an unwanted result, depending on the nature of the changes).

    Any effort to modernize VTT should IMHO try to move the hinting further up the font production process. For example, Glyphs allows applying instructions to the PostScript contours and will assign the instructions to the corresponding points after TrueType contour conversion when the font is exported.

    In my own experiments in this field, I chose a designspace + UFOs as the source format for TT hinting. This differs from VTT insofar as the generated or manually written hinting code would not need to be stored in TSI* tables in a binary font, but in the UFO lib/UFO glyph libs.

    This, of course brings another complication.

    As VTT stores the CVT source program, CVT table, VTTTalk, VTT assembly, and final bytecode at the appropriate locations in the binary font, the font is "ready" after each compilation run and can be previewed in real-time using the builtin MS TrueType rasterizer.

    Experts are probably able to apply VTTTalk without instant visual feedback of the effect on the hinted outline, but other people not so much. That means, for the hints-in-UFO approach, you would need to either build a minimal binary font each time the hints are compiled, and extract the hinted outlines for previewing in the hint editor, or to implement your own scaler/rasterizer engine that can take a UFO glyph as input, then draw the deformed outlines of this glyph into the preview. For neither option the original MS TT rasterizer is available.

    Furthermore, I think my comments from nearly four years ago still are valid.
  • jeremy tribbyjeremy tribby Posts: 212
    edited April 2022

    I actually think releasing vtt may not be as high impact as making a Python hinting engine, so we can have hinting extensions to all editors.

    This comment is a few years old now but I agree
    the visual hints in Glyphs are nice
    a similar abstraction on top of TT instructions, that can be used with any editor, would be better than further work on VTT, imo
  • Dave CrosslandDave Crossland Posts: 1,389
    edited April 2022
    A modest proposal: maybe source is bad, and not having abstractions other than those that directly integrate with raw sfnt data is better. 
  • the visual hints in Glyphs are nice
    a similar abstraction on top of TT instructions, that can be used with any editor, would be better than further work on VTT, imo
    I’d written down my thoughts on such an abstraction, which I called “constraints”, in the UFO spec in 2016 already. I think it still has merit, but standardizing it in UFO before having a working implementation was probably the wrong way.
  • Hin-Tak LeungHin-Tak Leung Posts: 359
    Most of my thoughts in this venture already captured by my comments at

    https://github.com/microsoft/VisualTrueType/issues/30

    So I'll only add two points:

    (1) how about fund-raising enough money to persuade Georg to open-source Glyphs, or part of it, if the visual hints in Glyphs is considered nice? I am pretty sure it is much more than $7000 US he would ask for though - in my comment on github, I estimate effort to port the existing VTT GUI (ie not open-source, see item 2 below) to be no less than $40,000, and possibly much more, based on past experience with FontVal.

    (2) I believe that part of Visual Truetype was licensed to Microsoft by Apple. So one major obstacle of open-sourcing the GUI fully is finding suitable Apple person to talk to, as well as their past sub-contractors from some 30 years ago.

    My 2 cents.
Sign In or Register to comment.