Comments (4)
Will this improve accuracy of curve-to-curve intersections? I am seeing accuracy to one decimal place when converting intersection results to points:
var a = new Bezier(71, 25, 44, 25, 19, 20, 0, 10);
var b = new Bezier(50, 35, 32, 26, 21, 13, 21, 0);
var i = a.intersects(b);
//alert(i.length); //btw - why is it 3?
var f = i[0].split('/').map(parseFloat);
var pa = a.get(f[0]);
var pb = b.get(f[1]);
console.log('point delta x:' + Math.abs(pa.x - pb.x) + ' y:' + Math.abs(pa.y - pb.y));
//result:
//point delta x:0.02300247966304525 y:0.05319080788130748
Ideally I'd like to get accuracy to 3 or four places.
from bezierjs.
it's three because at some point rounding starts yielding multiple bbox overlaps very close together. It could be 1 or 10 just as easily (okay, maybe not 10 =).
The intended improvement this issue is for should be to improve accuracy.
from bezierjs.
Cool, what will be your strategy once you are in the linear mode? Binary search?
from bezierjs.
yeah
from bezierjs.
Related Issues (20)
- _lut caching doesn't work: steps is off by one HOT 5
- Release v6.1.2 broken HOT 3
- Why get(t = 0.5) point is not the middle point of the curve? HOT 5
- Find optmal D1 - Bezier.cubicFromPoints HOT 1
- PolyBezier is not exported correct for ES Module. HOT 3
- Rational Bezier Curve Support HOT 1
- Example usage of `dist/bezier.js` HOT 4
- How to make a "strict" version of bezier.project(point)? HOT 2
- Should bezier.lineIntersects(line) work for line-line intersections? HOT 3
- intersects bug Bezier to Bezier HOT 3
- Suspicious line in `utils.compute()` HOT 2
- The intersection of the two bezier is empty HOT 10
- The intersection of two identical curves HOT 2
- Intersect line method does not always return existing intersections HOT 6
- Ability to get and estimate the centerline of a list of 3D points HOT 3
- PR for extending API to interpolate values along curve and find point on curve at distance?
- Artifact when offsetting an SVG path
- Split curves do not follow old curve. HOT 2
- Missing LICENSE file HOT 1
- How to Find Y-Coordinate for a Given X-Coordinate on a Bezier Curve HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bezierjs.