Jürg Lehni
2d166a3189
Remove accidental coma.
2015-01-05 16:00:14 +01:00
Jürg Lehni
cb75908dd6
Include @iconexperience in the contributors list.
...
Relates to #611
2015-01-05 15:59:41 +01:00
Jürg Lehni
d74d9274a1
Merge pull request #612 from iconexperience/master
...
Improve Line.getSignedDistance()
2015-01-05 15:43:26 +01:00
Jan
60ddc68e56
Improve Line.getSignedDistance()
...
Improved code is shorter, faster, and should product results with higher precision.
2015-01-05 15:16:45 +01:00
Jürg Lehni
1803cd216a
Handle empty paths in Path#join()
...
Closes #516
2015-01-05 00:42:00 +01:00
Jürg Lehni
6562f861ab
More code clean-up.
2015-01-05 00:13:30 +01:00
Jürg Lehni
9977b6ab68
Some code clean-up.
2015-01-05 00:09:34 +01:00
Jürg Lehni
6ea81e5651
Merge remote-tracking branch 'origin/boolean-operations'
...
Conflicts:
src/path/PathItem.Boolean.js
2015-01-05 00:04:01 +01:00
Jürg Lehni
72bd150a34
Fix the rest of the failing tests that 6c6ad76c94
had caused.
...
Also closes #610 .
2015-01-04 23:59:25 +01:00
Jürg Lehni
5f3df1f5a1
Fix some failing tests with PathItem#contains(), introduced by commit 6c6ad76c94
2015-01-04 23:28:39 +01:00
Jürg Lehni
18c5c3b7c4
Use the right parameter in the previous curve to determine slope change.
2015-01-04 23:02:43 +01:00
Jürg Lehni
5d875f2d83
Clean up code formatting.
2015-01-04 22:37:27 +01:00
Jürg Lehni
c20b32f748
Implement unit test for #610
2015-01-04 22:10:30 +01:00
Jürg Lehni
8928eaffd0
Merge branch 'refs/heads/master' into boolean-operations
2015-01-04 22:00:55 +01:00
Jürg Lehni
da53bfe5a0
Simplify boolean operations example code a bit.
2015-01-04 22:00:40 +01:00
Jürg Lehni
7e80e19e32
Insert results of boolean operations above the first path.
2015-01-04 21:59:31 +01:00
Jürg Lehni
d522e4aec2
Merge remote-tracking branch 'origin/master' into boolean-operations
...
Conflicts:
src/path/PathItem.Boolean.js
2015-01-04 21:29:50 +01:00
Jürg Lehni
9f0a774fd0
Fix newly introduced error in clean-up.
2015-01-04 18:07:02 +01:00
Jürg Lehni
1239eb55ec
Minor clean up in Curve.filterIntersections().
2015-01-04 17:47:41 +01:00
Jürg Lehni
f0d28d7529
Implement unit test for #609
2015-01-04 17:46:59 +01:00
Jürg Lehni
77193e1465
Clean-up new splitPath() code.
2015-01-04 17:37:15 +01:00
hkrish
718af4527f
Boolean: handle linear segments correctly.
...
Earlier implementation was unfinished and did not reset some handles to
linear, this caused the winding to be miscalculated.
Conflicts:
src/path/PathItem.Boolean.js
2015-01-04 17:30:19 +01:00
Jürg Lehni
afc14b9634
Reduce Numerical.TOLERANCE to 1e-6, and use the same value across the boolean code.
...
Yields very good results now, across all tests.
2015-01-04 15:54:50 +01:00
Jürg Lehni
ac0663bdd9
Hard-code numerical tolerance in unit tests as it's used in all hard-coded values.
2015-01-04 14:07:43 +01:00
Jürg Lehni
a683493e59
Implement unit tests for path intersection.
...
Related: #565 , #568 , #570 , #571
2015-01-04 14:01:32 +01:00
Jürg Lehni
3564dafa93
Do not keep iterating if the curve was reduced to a point.
2015-01-04 13:23:59 +01:00
Jürg Lehni
d33d65fcc2
Revert change in recursion threshold as the new code reaches the desired precision earlier.
2015-01-04 13:21:12 +01:00
Jürg Lehni
cca6606f72
Reduce the amount of path reversing required.
...
We don't need paths at clockwise / counter-clockwise orientation. We simply need them oriented the same way, or the opposite way.
2015-01-04 01:51:27 +01:00
Jürg Lehni
390ef324f2
Find a better implementation for exclude() boolean operations, requiring only one pass instead of two.
2015-01-04 01:50:24 +01:00
Jürg Lehni
f0f98daf69
Apply @hkrish's fix in 3781aedb22
to Line.getSignedDistance as well.
...
Relates to #554
2015-01-04 00:53:56 +01:00
hkrish
3781aedb22
Small but critical fix on getSignedDistance method
...
when the line is perfectly vertical, return the difference between x values depending on the side. The earlier "l1y" is a silly mistake.
2015-01-03 23:41:47 +01:00
Jürg Lehni
5c184e381b
Merge remote-tracking branch 'origin/master' into boolean-operations
...
Conflicts:
src/path/PathItem.Boolean.js
2015-01-03 21:09:31 +01:00
Jürg Lehni
4371e92191
Reduce EPSILON to 1e-13.
...
Reducing further to 1e-14 starts producing new issues in boolean operations code.
2015-01-03 21:03:13 +01:00
Jürg Lehni
b6a4815d03
Remove Curve#isHorizontal() as its implementation and precision is specific to boolean operations.
2015-01-03 21:02:12 +01:00
Jürg Lehni
46d7717812
Use standard values for tMin / tMax when calling getTangentAt() tracePaths()
2015-01-03 20:59:20 +01:00
Jürg Lehni
6bb6002d1a
No need to double tolerances here.
2015-01-03 20:35:51 +01:00
Jürg Lehni
68c53534d6
Use the same precision in PathItem#getIntersections() when handling curve time parameters as in the rest of the library.
...
TOLERANCE instead of EPSILON.
2015-01-03 20:25:57 +01:00
Jürg Lehni
3e67f72393
Some code clean-up.
2015-01-03 20:25:12 +01:00
Jürg Lehni
383bed4d05
Turn off invisible spaces in TextMate2.
2015-01-03 11:43:41 +01:00
Jürg Lehni
51ec3325e3
Remove the need to store winding samples in array and sort.
...
Calculating the average winding value instead yields the same results.
2015-01-03 11:25:10 +01:00
Jürg Lehni
26f209c835
Implement better strategy for handling edge cases in winding samples.
2015-01-03 11:24:27 +01:00
Jürg Lehni
a854c55914
Split off code from Path.Clockwise() into Curve.getEdgeSum()
2015-01-03 01:46:22 +01:00
Jürg Lehni
80e1a54171
Dirty temporary fix for new median winding code that struggles with circles.
2015-01-03 01:17:48 +01:00
Jürg Lehni
5da0ae5c3c
Better handle of edge values in Path#split().
...
Closes #515 & #538
2015-01-03 01:07:51 +01:00
Jürg Lehni
98686ef888
Fix endless recursion in CompoundPath#reduce()
2015-01-03 00:51:06 +01:00
Jürg Lehni
5e654ca64e
Reducing an empty CompoundPath should replace it with an empty Path.
2015-01-03 00:46:45 +01:00
Jürg Lehni
e195db2567
Handle empty paths in Path#reorient()
...
Closes #548
2015-01-03 00:46:24 +01:00
Jürg Lehni
001561decb
Remove the dependency of Math.random() from boolean operation code.
...
Closes #473
2015-01-03 00:32:06 +01:00
Jürg Lehni
bb2fece225
Restructure code that determines median winding contribution.
2015-01-03 00:26:13 +01:00
Jürg Lehni
5f0e545ba7
Use EPSILON instead of TOLERANCE in Point#isColinear() and #isOrthogonal()
2015-01-02 23:48:34 +01:00