Prebuilt module for commit 41aca10112

This commit is contained in:
Paper.js Bot 2016-02-03 12:02:48 +00:00
parent 198d467e2b
commit a5354d6223
5 changed files with 31 additions and 28 deletions

View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Wed Feb 3 09:47:49 2016 +0100
* Date: Wed Feb 3 12:54:54 2016 +0100
*
***
*
@ -9408,6 +9408,7 @@ PathItem.inject(new function() {
py = point.y,
windLeft = 0,
windRight = 0,
isOnCurve = false,
length = curves.length,
roots = [],
abs = Math.abs;
@ -9457,16 +9458,16 @@ PathItem.inject(new function() {
? Curve.getPoint(values, roots[0]).x
: null;
if (x != null) {
var isWindingChange = winding === -prevWinding;
if (py !== yStart || isWindingChange
|| (x - px) * (prevXEnd - px) < 0) {
var isOnHorizontal =
py === yStart && (px - x) * (px - prevXEnd) < 0;
if ((x >= xBefore && x <= xAfter) || isOnHorizontal)
isOnCurve = true;
if (py != yEnd
&& (py != yStart || winding === prevWinding)) {
if (x < xBefore) {
windLeft += winding;
} else if (x > xAfter) {
windRight += winding;
} else if (py === yStart && isWindingChange) {
++windLeft;
++windRight;
}
}
}
@ -9475,7 +9476,7 @@ PathItem.inject(new function() {
}
}
}
return Math.max(abs(windLeft), abs(windRight));
return Math.max(abs(windLeft), abs(windRight)) | (isOnCurve ? 1 : 0 );
}
function propagateWinding(segment, path1, path2, monoCurves, operator) {

17
dist/paper-core.js vendored
View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Wed Feb 3 09:47:49 2016 +0100
* Date: Wed Feb 3 12:54:54 2016 +0100
*
***
*
@ -9408,6 +9408,7 @@ PathItem.inject(new function() {
py = point.y,
windLeft = 0,
windRight = 0,
isOnCurve = false,
length = curves.length,
roots = [],
abs = Math.abs;
@ -9457,16 +9458,16 @@ PathItem.inject(new function() {
? Curve.getPoint(values, roots[0]).x
: null;
if (x != null) {
var isWindingChange = winding === -prevWinding;
if (py !== yStart || isWindingChange
|| (x - px) * (prevXEnd - px) < 0) {
var isOnHorizontal =
py === yStart && (px - x) * (px - prevXEnd) < 0;
if ((x >= xBefore && x <= xAfter) || isOnHorizontal)
isOnCurve = true;
if (py != yEnd
&& (py != yStart || winding === prevWinding)) {
if (x < xBefore) {
windLeft += winding;
} else if (x > xAfter) {
windRight += winding;
} else if (py === yStart && isWindingChange) {
++windLeft;
++windRight;
}
}
}
@ -9475,7 +9476,7 @@ PathItem.inject(new function() {
}
}
}
return Math.max(abs(windLeft), abs(windRight));
return Math.max(abs(windLeft), abs(windRight)) | (isOnCurve ? 1 : 0 );
}
function propagateWinding(segment, path1, path2, monoCurves, operator) {

File diff suppressed because one or more lines are too long

17
dist/paper-full.js vendored
View file

@ -9,7 +9,7 @@
*
* All rights reserved.
*
* Date: Wed Feb 3 09:47:49 2016 +0100
* Date: Wed Feb 3 12:54:54 2016 +0100
*
***
*
@ -9408,6 +9408,7 @@ PathItem.inject(new function() {
py = point.y,
windLeft = 0,
windRight = 0,
isOnCurve = false,
length = curves.length,
roots = [],
abs = Math.abs;
@ -9457,16 +9458,16 @@ PathItem.inject(new function() {
? Curve.getPoint(values, roots[0]).x
: null;
if (x != null) {
var isWindingChange = winding === -prevWinding;
if (py !== yStart || isWindingChange
|| (x - px) * (prevXEnd - px) < 0) {
var isOnHorizontal =
py === yStart && (px - x) * (px - prevXEnd) < 0;
if ((x >= xBefore && x <= xAfter) || isOnHorizontal)
isOnCurve = true;
if (py != yEnd
&& (py != yStart || winding === prevWinding)) {
if (x < xBefore) {
windLeft += winding;
} else if (x > xAfter) {
windRight += winding;
} else if (py === yStart && isWindingChange) {
++windLeft;
++windRight;
}
}
}
@ -9475,7 +9476,7 @@ PathItem.inject(new function() {
}
}
}
return Math.max(abs(windLeft), abs(windRight));
return Math.max(abs(windLeft), abs(windRight)) | (isOnCurve ? 1 : 0 );
}
function propagateWinding(segment, path1, path2, monoCurves, operator) {

File diff suppressed because one or more lines are too long