bugThe FreeType Project - Bugs: bug #51228, Functions missing to adjust...

 
 

bug #51228: Functions missing to adjust sidebearings based on HVAR/VVAR data

Submitted by:  Bob Taylor <monotype>
Submitted on:  Mon 12 Jun 2017 08:49:21 PM UTC  
 
Severity: 3 - NormalItem Group: None
Status: InvalidPrivacy: Public
Assigned to: Werner LEMBERG <wl>Open/Closed: Closed
Planned Release: None

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sat 17 Jun 2017 12:10:26 PM UTC, comment #5:

Yes, HVAR/VVAR sidebearing variations are just caches. They don't have any functional use.

Behdad Esfahbod <behdad>
Wed 14 Jun 2017 04:01:14 PM UTC, comment #4:

OK, closing.

Werner LEMBERG <wl>
Project AdministratorIn charge of this item.
Wed 14 Jun 2017 03:17:59 PM UTC, comment #3:

We were hoping to create a tracking functionality that works for both TTF and CFF2 OpenType fonts using the HVAR table. But it looks like that may not be feasible. The 1.8 spec says:

Take note that, in a variable font with TrueType outlines, the left side bearing for each glyph must equal xMin, and bit 1 in the flags field of the 'head' table must be set.

This would mean that most applications could ignore left side bearing variations, except perhaps using the gvar table to vary phantom points. Another approach might be to use the GPOS table data in conjunction with a tracking axis. We will explore those options.

This wishlist request can be closed from our point of view.

Bob Taylor <monotype>
Wed 14 Jun 2017 01:17:07 PM UTC, comment #2:

Behdad, Dave, if you disagree with my observations please comment!

Werner LEMBERG <wl>
Project AdministratorIn charge of this item.
Wed 14 Jun 2017 11:29:04 AM UTC, comment #1:

Right now, FreeType derives fields like `horiBearingX' in the `FT_Glyph_Metrics' always from the `glyf' table (+applied variations), not from `HVAR' or `VVAR'. In other words, the function pointers you are referring to are completely unused; it is not necessary to implement them at all.

Does your `HVAR/VVAR only' tracking solution work with other OpenType implementations? I interpret the OpenType specification that HVAR/VVAR are auxiliary tables for TTFs and essentially redundant, since the same data is provided with `glyf' + `gvar'. Consequently, making HVAR/VVAR do something different than glyf/gvar looks like incorrect behaviour not covered by the specification.

If you think differently please discuss this on the OpenType mailing list.

Werner LEMBERG <wl>
Project AdministratorIn charge of this item.
Mon 12 Jun 2017 08:49:21 PM UTC, original submission:

In release 2.8, in ttdriver.c, the functions for adjusting sidebearings based on HVAR or VVAR data are NULL, as in

(FT_LSB_Adjust_Func) NULL, /* lsb_adjust */
(FT_RSB_Adjust_Func) NULL, /* rsb_adjust */
and
(FT_TSB_Adjust_Func) NULL, /* tsb_adjust */
(FT_BSB_Adjust_Func) NULL, /* bsb_adjust */

In order to implement a tracking axis using only HVAR/VVAR data we also need to adjust the sidebearings along with the advance.

The attached test font has an HVAR table with advance and sidebearing adjustment data along with a tracking axis to exercise the adjustments.

Bob Taylor <monotype>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #40908:  LinotypeUnivers-Variable.ttf added by monotype (420KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by behdad (Posted a comment)
  • -unavailable- added by wl
  • -unavailable- added by wl (Posted a comment)
  • -unavailable- added by wl
  • -unavailable- added by monotype (Submitted the item)
  • -unavailable- added by monotype
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 8 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed 14 Jun 2017 04:01:14 PM UTCwlStatusNeed Info=>Invalid
      Open/ClosedOpen=>Closed
    Wed 14 Jun 2017 11:29:33 AM UTCwlCarbon-Copy-=>Added behdad
    Wed 14 Jun 2017 11:29:04 AM UTCwlStatusNone=>Need Info
      Assigned toNone=>wl
      Carbon-Copy-=>Added darnold
    Mon 12 Jun 2017 08:49:21 PM UTCmonotypeAttached File-=>Added LinotypeUnivers-Variable.ttf, #40908
      Carbon-Copy-=>Added monotype

    Back to the top


    Powered by Savane 3.1-cleanup1