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

Add Javascript testbed for parameter fitting #29

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Conversation

raphlinus
Copy link
Contributor

This is a hacky Javascript implementation of the core hyperbez math (the new one, linear over quadratic to the 1.5). It also contains a rough draft of parameter fitting.

As of this commit, the draft does a good job at small angles, and moderate and high tension. It also shows off the potential for squarish hyperellipses, when the control points are moved close together.

The blue curve represents the hyperbezier, and the gray curve is an ordinary cubic Bézier for comparison.

Some things are in very rough form, as this is for experimentation only. For example, moving the endpoints yields unexpected results.

This is a hacky Javascript implementation of the core hyperbez math (the new one, linear over quadratic to the 1.5). It also contains a rough draft of parameter fitting.

As of this commit, the draft does a good job at small angles, and moderate and high tension. It also shows off the potential for squarish hyperellipses, when the control points are moved close together.

The blue curve represents the hyperbezier, and the gray curve is an ordinary cubic Bézier for comparison.

Some things are in very rough form, as this is for experimentation only. For example, moving the endpoints yields unexpected results.
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

Successfully merging this pull request may close these issues.

1 participant