I need to build an algorithm that will automatically interpolate a variable font in the layout based on the positions of the characters in space. It doesn't matter in which software it will be implemented, it can be anything from InDesign to Processing. Is it even possible?
I tried to implement this via JavaScript in InDesign, but I didn't find a suitable function to determine the position of the symbol in the layout space. I also made attempts to implement the algorithm through After Effects, but it (Still!) does not have native support for variable fonts. Third-party scripts either convert the font into shapes, which does not allow working with existing font axes, or they do not have the functionality to create the necessary logic.
The idea itself sounds extremely simple: to bind the values of the axes of a variable font with coordinates in space. As a result, I expect to get a character-by-character interpolation of the axis values. Below is a diagram of how it should work. I will be glad of any ideas.