Files
il/resources/public/js/cljs-runtime/module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$utils$getOrientationOfPoints.js
2026-07-01 22:38:29 -06:00

19 lines
641 B
JavaScript

shadow$provide.module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$utils$getOrientationOfPoints = function(global, require, module, exports) {
exports.getOrientationOfPoints = function(points) {
const m = points.length;
if (6 > m) {
return 1;
}
let area = 0;
for (let i = 0, x1 = points[m - 2], y1 = points[m - 1]; i < m; i += 2) {
const x2 = points[i], y2 = points[i + 1];
area += (x2 - x1) * (y2 + y1);
x1 = x2;
y1 = y2;
}
return 0 > area ? -1 : 1;
};
};
//# sourceMappingURL=module$node_modules$pixi_DOT_js$lib$scene$graphics$shared$utils$getOrientationOfPoints.js.map