[FIXED] Interpolation issue with close axis location

Post your bug reports here. Include information that helps us to understand and reproduce the bug.
Post Reply
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

[FIXED] Interpolation issue with close axis location

Post by File_xor »

When axis locations are very close, interpolation corrupts as shown the image attached.
Attachments
2021-07-05 155150.png
2021-07-05 155150.png (281.58 KiB) Viewed 3683 times
Erwin Denissen
Moderator
Moderator
Posts: 11108
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Interpolation issue with close axis location

Post by Erwin Denissen »

It doesn't look right, but we can't determine the cause without inspecting the font, so please send it to us.
Erwin Denissen
High-Logic
Proven Font Technology
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

Re: Interpolation issue with close axis location

Post by File_xor »

Here it is.
Attachments
Xor7Seg_Variable_V1.0.fcp
(10.44 KiB) Downloaded 159 times
Erwin Denissen
Moderator
Moderator
Posts: 11108
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Interpolation issue with close axis location

Post by Erwin Denissen »

Thank you for providing the font. I assume you made it with another font editor?

Anyway I think I have a fix for it, but please verify if it now works as expected.

https://www.high-logic.com/tmp/fontcrea ... 97-x64.exe
Erwin Denissen
High-Logic
Proven Font Technology
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

Re: Interpolation issue with close axis location

Post by File_xor »

Now works as expected. Thank you.
I assume you made it with another font editor?
I use Blender as design tool because it accepts formula as input and I think working with edges is better for me,and then convert coordinates via calculator to FontCreator.
I guess I'll need conversion tool soon as converting curve will be tedious though.
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

Re: Interpolation issue with close axis location

Post by File_xor »

Sorry for raising the issue again, but I found this problem is not solved entirely yet.
Attachments
Xor7Seg_Variable_V1.0.fcp
(14.28 KiB) Downloaded 159 times
2021-07-12 232119.png
2021-07-12 232119.png (306.29 KiB) Viewed 3598 times
Erwin Denissen
Moderator
Moderator
Posts: 11108
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Interpolation issue with close axis location

Post by Erwin Denissen »

I suspect those are all bugs in your font. Can you show a glyph that you think should interpolate correctly, but fails to do so?
Erwin Denissen
High-Logic
Proven Font Technology
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

Re: Interpolation issue with close axis location

Post by File_xor »

In certain range, all glyphs are interpolated with default master instead of two masters that covering the range.
Maybe my font has too close masters but I don't know how far the value to be to hide intermediate state.
Is 1/65536 between masters too close?
Erwin Denissen
Moderator
Moderator
Posts: 11108
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Interpolation issue with close axis location

Post by Erwin Denissen »

File_xor wrote: Mon Jul 12, 2021 2:57 pm In certain range, all glyphs are interpolated with default master instead of two masters that covering the range.
If it is an issue on our side, please provide a way for us to reproduce it.
File_xor wrote: Mon Jul 12, 2021 2:57 pm Maybe my font has too close masters but I don't know how far the value to be to hide intermediate state.
Is 1/65536 between masters too close?
Such small difference can not be stored in the internal font format. For each axis, the master location is stored in a 16-bit signed fixed number with the low 14 bits of fraction (F2DOT14).
Erwin Denissen
High-Logic
Proven Font Technology
File_xor
Posts: 9
Joined: Fri Jun 25, 2021 9:13 am

Re: Interpolation issue with close axis location

Post by File_xor »

Sorry, I didn't notice there is normalization for the coordinate values which causes a lot of precision loss.
I modified the gap to 1/8192 and now problem is gone.

By the way, you wrote:
For each axis, the master location is stored in a 16-bit signed fixed number with the low 14 bits of fraction (F2DOT14).
I assume you are talking about normalized coordinate system used in avar table, however, I'm talking about coordinates in fvar table which stores the coordinates as Fixed (16.16) data type and that's why I used 1/65536 as gap previously.
Erwin Denissen
Moderator
Moderator
Posts: 11108
Joined: Fri Oct 04, 2002 12:41 am
Location: Bilthoven, The Netherlands
Contact:

Re: Interpolation issue with close axis location

Post by Erwin Denissen »

File_xor wrote: Tue Jul 13, 2021 5:39 am Sorry, I didn't notice there is normalization for the coordinate values which causes a lot of precision loss.
I modified the gap to 1/8192 and now problem is gone.
Perfect.
File_xor wrote: Tue Jul 13, 2021 5:39 am By the way, you wrote:
For each axis, the master location is stored in a 16-bit signed fixed number with the low 14 bits of fraction (F2DOT14).
I assume you are talking about normalized coordinate system used in avar table, however, I'm talking about coordinates in fvar table which stores the coordinates as Fixed (16.16) data type and that's why I used 1/65536 as gap previously.
Tuples are stored as F2DOT14.
Erwin Denissen
High-Logic
Proven Font Technology
Post Reply