Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is Anisotropic interpolation a good thing to have? #2

Open
davelab6 opened this issue Mar 4, 2019 · 5 comments
Open

Is Anisotropic interpolation a good thing to have? #2

davelab6 opened this issue Mar 4, 2019 · 5 comments

Comments

@davelab6
Copy link

davelab6 commented Mar 4, 2019

In the original design doc, "OpenType GX" by @behdad, there is a "Further discussion" section which says,

Anisotropic interpolation

TODO:

  • Description of anisotropic interpolation.
  • Find out if this was possible in GXVar.
  • Make a case why it would be a good thing to have.

For (1), https://help.fontlab.com/fontlab-vi/Variations-panel/#anisotropic-interpolation (I believe by @twardoch) says it well:

Anisotropic interpolation can use different interpolation values for X and Y directions, unlike standard interpolation which uses the same values for both directions. This allows you to have an axis have more (up to double) or less (up to zero) effect in either the X or Y direction.

For (2), I wonder if @be5invis knows.

For (3), I wonder if a counter-case (that it would be a bad thing to have) was made, and that's why it never made it into OT1.8.

@behdad
Copy link
Member

behdad commented Mar 4, 2019

A better document will be Tim Ahrens MSc thesis / "Size-specific adjustments to type designs" book, which both explains powerful things that can e done with anisotropic interpolation as well as its problems / limitations.

@be5invis
Copy link

be5invis commented Mar 4, 2019

@davelab6

Yes you can. If you look into the delta-rect level you can see any variable "quantities" can be expressed into this form:

where are the variation rects of a given VQ.

So extending the rect set is pretty simple and safe: simply assign zero deltas to the new rects and it is solved.

VQs form a module so you can safely define addition or scale of VQs. Though I'd like to extend it a little so it can form a ring (allows you to define multiplication of VQs).

@davelab6
Copy link
Author

@dberlow @Lorp do you know if this was possible in GX?

@twardoch
Copy link

twardoch commented Jun 26, 2019 via email

@Lorp
Copy link

Lorp commented Jun 26, 2019

It’s easy to separate the x and y effects of all the delta sets, i.e. split them into two axes. This is fine in original GX. If you wanted to split wght, you’d create two new axes, wghX and wghY, and crunch the delta sets with fontTools or by editing TTX output. This would be 100% safe, I think. Moving the two new axes in sync would be identical to moving the old axis.

I wondered about this technique when writing a gvar parser. I liked the idea of making variations more like TrueType hinting, where x and y are always completely separate (except when you make non-orthogonal freedom & projection vectors).

It’s possible that on real data it would give better compression in itself, and also better IUP compression.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants