bugThe FreeType Project - Bugs: bug #59413, Big fat glitch in TrueType...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #59413: Big fat glitch in TrueType interpreter v40

Submitter:  Alexei Podtelezhnikov <podtelez>
Submitted:  Wed 04 Nov 2020 03:18:31 AM UTC
   
 
Severity:  3 - Normal Item Group:  None
Status:  Confirmed Privacy:  Public
Assigned to:  morksig Open/Closed:  Open
Planned Release:  None

Wed 04 Nov 2020 05:15:13 PM UTC, comment #3: 

Yes, the x component is unreliable, since it usually varies by ±1 pixels in comparison to the hinted outlines.  However, in almost all cases it works quite nicely – you are the first who shows an example where the current v40 algorithm fails miserably, because the distance used for setting up the freedom vector is so ridiculously short.

I'm not sure whether your suggestion works: The difference in direction between (0,47) and (-11,47) is quite large...

Werner LEMBERG <wl>
Group administrator
Wed 04 Nov 2020 02:19:24 PM UTC, comment #2: 

Are you saying that x-component of the freedom vector is unreliable, given that we x-moves might be quite different? We can try to ignore small Δx altogether and use (0, 47).

Alexei Podtelezhnikov <podtelez>
Group Member
Wed 04 Nov 2020 01:46:14 PM UTC, comment #1: 

This is a hard one, AFAICS.  The problem seems to be opcode SFVTL, which eventually resolves to a call to `Ins_SxVTL`.  The points used for it are 128 and 127, respectively.

In v35 mode the 26.6 coordinates are

  127: {x = 1195, y = 77}
  128: {x = 1206, y = 30}

while in v40 mode we have

  127 = {x = 1166, y = 77}
  128 = {x = 1206, y = 30}

The deltas are (-11, 47) for v35 and (-40, 47) for v40.  As can be seen, those distances are less than a pixel(!), and it is very problematic to use such small values for setting up the freedom and projection vectors.  Of course they vary by a factor three, causing the ugly artifact.

Any suggestions how to fix that?  What comes to my mind is to carry another, fourth array of point vectors that holds fully hinted coordinates (in addition to the unscaled, scaled, and v40 hinted ones).  On the other hand, this would slow down hinting by a factor of almost two...

Werner LEMBERG <wl>
Group administrator
Wed 04 Nov 2020 03:18:31 AM UTC, original submission:  

$ ftgrid -f628 20 Windows/Fonts/pala.ttf

Only v40 exhibits this glitch only in this glyph in Palatino Linotype Regular, see attached. The preceding glyph is almost the same but does not have it. Nikolaus, please take a look.

Alexei Podtelezhnikov <podtelez>
Group Member

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attached Files
file #50203:  ftgrid.png added by podtelez (24KiB - image/png - big fat glitch)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by wl (Posted a comment)
  • -email is unavailable- added by podtelez (Submitted the item)
  • -email is unavailable- added by podtelez
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-11-04 wl StatusNone Confirmed
    2020-11-04 podtelez Attached File- Added ftgrid.png, #50203
        Carbon-Copy- Added morksig

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code