curvy 1.0.3 → 1.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/curve/cubic2d.d.mts +2 -2
- package/dist/curve/cubic2d.d.ts +2 -2
- package/dist/curve/cubic2d.mjs +5 -4
- package/dist/curve/linear2d.d.mts +2 -2
- package/dist/curve/linear2d.d.ts +2 -2
- package/dist/curve/linear2d.mjs +4 -3
- package/dist/curve/quadratic2d.d.mts +2 -2
- package/dist/curve/quadratic2d.d.ts +2 -2
- package/dist/curve/quadratic2d.mjs +5 -4
- package/dist/interval.d.mts +1 -1
- package/dist/interval.d.ts +1 -1
- package/dist/interval.mjs +2 -1
- package/dist/matrix/matrix2x2.d.mts +1 -1
- package/dist/matrix/matrix2x2.d.ts +1 -1
- package/dist/matrix/matrix2x2.mjs +4 -3
- package/dist/matrix/matrix3x3.d.mts +2 -2
- package/dist/matrix/matrix3x3.d.ts +2 -2
- package/dist/matrix/matrix3x3.mjs +6 -5
- package/dist/matrix/matrix4x4.d.mts +1 -1
- package/dist/matrix/matrix4x4.d.ts +1 -1
- package/dist/matrix/matrix4x4.mjs +7 -6
- package/dist/path/cubic2d.d.mts +2 -2
- package/dist/path/cubic2d.d.ts +2 -2
- package/dist/path/cubic2d.mjs +5 -4
- package/dist/path/linear2d.d.mts +2 -2
- package/dist/path/linear2d.d.ts +2 -2
- package/dist/path/linear2d.mjs +4 -3
- package/dist/path/quadratic2d.d.mts +2 -2
- package/dist/path/quadratic2d.d.ts +2 -2
- package/dist/path/quadratic2d.mjs +5 -4
- package/dist/{shared/curvy.BN-oFBsc.d.mts → pipe.d.mts} +33 -1
- package/dist/{shared/curvy.BN-oFBsc.d.ts → pipe.d.ts} +33 -1
- package/dist/{shared/curvy.DLOeble8.mjs → pipe.mjs} +1 -37
- package/dist/polynomial/cubic.d.mts +2 -2
- package/dist/polynomial/cubic.d.ts +2 -2
- package/dist/polynomial/cubic.mjs +4 -3
- package/dist/polynomial/linear.d.mts +2 -2
- package/dist/polynomial/linear.d.ts +2 -2
- package/dist/polynomial/linear.mjs +3 -2
- package/dist/polynomial/quadratic.d.mts +2 -2
- package/dist/polynomial/quadratic.d.ts +2 -2
- package/dist/polynomial/quadratic.mjs +4 -3
- package/dist/shared/{curvy.BPOevbwG.mjs → curvy.48SmIWxE.mjs} +13 -2
- package/dist/shared/{curvy.O57gIOmy.mjs → curvy.BDhiZ7He.mjs} +2 -1
- package/dist/shared/{curvy.CkJRVnqj.d.ts → curvy.BsHoYJNv.d.ts} +1 -1
- package/dist/shared/{curvy.ZjG-q57I.mjs → curvy.BzVmUIKm.mjs} +3 -2
- package/dist/shared/{curvy.B1zfBfvf.mjs → curvy.C2XGH0R0.mjs} +2 -1
- package/dist/shared/{curvy.BZXFCKQe.mjs → curvy.CE4X6_Is.mjs} +2 -1
- package/dist/shared/{curvy.DTco5vku.mjs → curvy.CREzSbNe.mjs} +4 -3
- package/dist/shared/{curvy.BrrC9QVB.mjs → curvy.Ct6KbNL5.mjs} +3 -2
- package/dist/shared/{curvy.DwHW5Fqt.d.mts → curvy.NsmY7zcr.d.mts} +1 -1
- package/dist/shared/{curvy.DV4S13Cq.mjs → curvy.Wcdc9gLh.mjs} +25 -2
- package/dist/splines/basis2d.d.mts +2 -2
- package/dist/splines/basis2d.d.ts +2 -2
- package/dist/splines/basis2d.mjs +10 -9
- package/dist/splines/bezier2d.d.mts +2 -2
- package/dist/splines/bezier2d.d.ts +2 -2
- package/dist/splines/bezier2d.mjs +10 -9
- package/dist/splines/cardinal2d.d.mts +2 -2
- package/dist/splines/cardinal2d.d.ts +2 -2
- package/dist/splines/cardinal2d.mjs +10 -9
- package/dist/splines/hermite2d.d.mts +2 -2
- package/dist/splines/hermite2d.d.ts +2 -2
- package/dist/splines/hermite2d.mjs +10 -9
- package/dist/utils.d.mts +27 -0
- package/dist/utils.d.ts +27 -0
- package/dist/utils.mjs +47 -0
- package/dist/vector/vector2.d.mts +22 -2
- package/dist/vector/vector2.d.ts +22 -2
- package/dist/vector/vector2.mjs +12 -3
- package/dist/vector/vector3.d.mts +32 -2
- package/dist/vector/vector3.d.ts +32 -2
- package/dist/vector/vector3.mjs +16 -3
- package/dist/vector/vector4.d.mts +1 -1
- package/dist/vector/vector4.d.ts +1 -1
- package/dist/vector/vector4.mjs +3 -2
- package/package.json +9 -1
package/dist/vector/vector2.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { i as isVector2$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as cross$1, b as components$1, s as softmax$1, e as add$1, f as subtract$1, h as hadamard$1, g as scale$1 } from '../shared/curvy.
|
|
2
|
-
import '../
|
|
1
|
+
import { i as isVector2$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as cross$1, b as components$1, s as softmax$1, e as add$1, f as subtract$1, h as hadamard$1, g as scale$1, j as getX$1, k as setX$1, l as getY$1, o as setY$1, p as setR$1, q as getTheta$1, r as setTheta$1 } from '../shared/curvy.48SmIWxE.mjs';
|
|
2
|
+
import '../pipe.mjs';
|
|
3
|
+
import '../utils.mjs';
|
|
3
4
|
|
|
4
5
|
const isVector2 = isVector2$1;
|
|
5
6
|
const make = make$1;
|
|
@@ -14,5 +15,13 @@ const add = add$1;
|
|
|
14
15
|
const subtract = subtract$1;
|
|
15
16
|
const hadamard = hadamard$1;
|
|
16
17
|
const scale = scale$1;
|
|
18
|
+
const getX = getX$1;
|
|
19
|
+
const setX = setX$1;
|
|
20
|
+
const getY = getY$1;
|
|
21
|
+
const setY = setY$1;
|
|
22
|
+
const getR = magnitude;
|
|
23
|
+
const setR = setR$1;
|
|
24
|
+
const getTheta = getTheta$1;
|
|
25
|
+
const setTheta = setTheta$1;
|
|
17
26
|
|
|
18
|
-
export { add, components, cross, dot, hadamard, isVector2, magnitude, make, normalize, scale, softmax, subtract, zero };
|
|
27
|
+
export { add, components, cross, dot, getR, getTheta, getX, getY, hadamard, isVector2, magnitude, make, normalize, scale, setR, setTheta, setX, setY, softmax, subtract, zero };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { g as ThreeDimensional } from '../shared/curvy.Bf5TIk31.mjs';
|
|
2
|
-
import {
|
|
2
|
+
import { Pipeable } from '../pipe.mjs';
|
|
3
3
|
|
|
4
4
|
declare const Vector3TypeId: unique symbol;
|
|
5
5
|
type Vector3TypeId = typeof Vector3TypeId;
|
|
@@ -38,5 +38,35 @@ declare const scale: {
|
|
|
38
38
|
(s: number): (v: Vector3) => Vector3;
|
|
39
39
|
(v: Vector3, s: number): Vector3;
|
|
40
40
|
};
|
|
41
|
+
declare const getX: (v: Vector3) => number;
|
|
42
|
+
declare const setX: {
|
|
43
|
+
(v: Vector3, x: number): Vector3;
|
|
44
|
+
(x: number): (v: Vector3) => Vector3;
|
|
45
|
+
};
|
|
46
|
+
declare const getY: (v: Vector3) => number;
|
|
47
|
+
declare const setY: {
|
|
48
|
+
(v: Vector3, y: number): Vector3;
|
|
49
|
+
(y: number): (v: Vector3) => Vector3;
|
|
50
|
+
};
|
|
51
|
+
declare const getZ: (v: Vector3) => number;
|
|
52
|
+
declare const setZ: {
|
|
53
|
+
(v: Vector3, z: number): Vector3;
|
|
54
|
+
(z: number): (v: Vector3) => Vector3;
|
|
55
|
+
};
|
|
56
|
+
declare const getR: (v: Vector3) => number;
|
|
57
|
+
declare const setR: {
|
|
58
|
+
(v: Vector3, r: number): Vector3;
|
|
59
|
+
(r: number): (v: Vector3) => Vector3;
|
|
60
|
+
};
|
|
61
|
+
declare const getTheta: (v: Vector3) => number;
|
|
62
|
+
declare const setTheta: {
|
|
63
|
+
(v: Vector3, theta: number): Vector3;
|
|
64
|
+
(theta: number): (v: Vector3) => Vector3;
|
|
65
|
+
};
|
|
66
|
+
declare const getPhi: (v: Vector3) => number;
|
|
67
|
+
declare const setPhi: {
|
|
68
|
+
(v: Vector3, phi: number): Vector3;
|
|
69
|
+
(phi: number): (v: Vector3) => Vector3;
|
|
70
|
+
};
|
|
41
71
|
|
|
42
|
-
export { type Vector3, add, components, dot, hadamard, isVector3, magnitude, make, normalize, scale, softmax, subtract, zero };
|
|
72
|
+
export { type Vector3, add, components, dot, getPhi, getR, getTheta, getX, getY, getZ, hadamard, isVector3, magnitude, make, normalize, scale, setPhi, setR, setTheta, setX, setY, setZ, softmax, subtract, zero };
|
package/dist/vector/vector3.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { g as ThreeDimensional } from '../shared/curvy.Bf5TIk31.js';
|
|
2
|
-
import {
|
|
2
|
+
import { Pipeable } from '../pipe.js';
|
|
3
3
|
|
|
4
4
|
declare const Vector3TypeId: unique symbol;
|
|
5
5
|
type Vector3TypeId = typeof Vector3TypeId;
|
|
@@ -38,5 +38,35 @@ declare const scale: {
|
|
|
38
38
|
(s: number): (v: Vector3) => Vector3;
|
|
39
39
|
(v: Vector3, s: number): Vector3;
|
|
40
40
|
};
|
|
41
|
+
declare const getX: (v: Vector3) => number;
|
|
42
|
+
declare const setX: {
|
|
43
|
+
(v: Vector3, x: number): Vector3;
|
|
44
|
+
(x: number): (v: Vector3) => Vector3;
|
|
45
|
+
};
|
|
46
|
+
declare const getY: (v: Vector3) => number;
|
|
47
|
+
declare const setY: {
|
|
48
|
+
(v: Vector3, y: number): Vector3;
|
|
49
|
+
(y: number): (v: Vector3) => Vector3;
|
|
50
|
+
};
|
|
51
|
+
declare const getZ: (v: Vector3) => number;
|
|
52
|
+
declare const setZ: {
|
|
53
|
+
(v: Vector3, z: number): Vector3;
|
|
54
|
+
(z: number): (v: Vector3) => Vector3;
|
|
55
|
+
};
|
|
56
|
+
declare const getR: (v: Vector3) => number;
|
|
57
|
+
declare const setR: {
|
|
58
|
+
(v: Vector3, r: number): Vector3;
|
|
59
|
+
(r: number): (v: Vector3) => Vector3;
|
|
60
|
+
};
|
|
61
|
+
declare const getTheta: (v: Vector3) => number;
|
|
62
|
+
declare const setTheta: {
|
|
63
|
+
(v: Vector3, theta: number): Vector3;
|
|
64
|
+
(theta: number): (v: Vector3) => Vector3;
|
|
65
|
+
};
|
|
66
|
+
declare const getPhi: (v: Vector3) => number;
|
|
67
|
+
declare const setPhi: {
|
|
68
|
+
(v: Vector3, phi: number): Vector3;
|
|
69
|
+
(phi: number): (v: Vector3) => Vector3;
|
|
70
|
+
};
|
|
41
71
|
|
|
42
|
-
export { type Vector3, add, components, dot, hadamard, isVector3, magnitude, make, normalize, scale, softmax, subtract, zero };
|
|
72
|
+
export { type Vector3, add, components, dot, getPhi, getR, getTheta, getX, getY, getZ, hadamard, isVector3, magnitude, make, normalize, scale, setPhi, setR, setTheta, setX, setY, setZ, softmax, subtract, zero };
|
package/dist/vector/vector3.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { i as isVector3$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as components$1, s as softmax$1, b as add$1, e as subtract$1, h as hadamard$1, f as scale$1 } from '../shared/curvy.
|
|
2
|
-
import '../
|
|
1
|
+
import { i as isVector3$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as components$1, s as softmax$1, b as add$1, e as subtract$1, h as hadamard$1, f as scale$1, g as getX$1, j as setX$1, k as getY$1, l as setY$1, o as getZ$1, p as setZ$1, q as setR$1, r as getTheta$1, t as setTheta$1, u as getPhi$1, v as setPhi$1 } from '../shared/curvy.Wcdc9gLh.mjs';
|
|
2
|
+
import '../pipe.mjs';
|
|
3
|
+
import '../utils.mjs';
|
|
3
4
|
|
|
4
5
|
const isVector3 = isVector3$1;
|
|
5
6
|
const make = make$1;
|
|
@@ -13,5 +14,17 @@ const add = add$1;
|
|
|
13
14
|
const subtract = subtract$1;
|
|
14
15
|
const hadamard = hadamard$1;
|
|
15
16
|
const scale = scale$1;
|
|
17
|
+
const getX = getX$1;
|
|
18
|
+
const setX = setX$1;
|
|
19
|
+
const getY = getY$1;
|
|
20
|
+
const setY = setY$1;
|
|
21
|
+
const getZ = getZ$1;
|
|
22
|
+
const setZ = setZ$1;
|
|
23
|
+
const getR = magnitude;
|
|
24
|
+
const setR = setR$1;
|
|
25
|
+
const getTheta = getTheta$1;
|
|
26
|
+
const setTheta = setTheta$1;
|
|
27
|
+
const getPhi = getPhi$1;
|
|
28
|
+
const setPhi = setPhi$1;
|
|
16
29
|
|
|
17
|
-
export { add, components, dot, hadamard, isVector3, magnitude, make, normalize, scale, softmax, subtract, zero };
|
|
30
|
+
export { add, components, dot, getPhi, getR, getTheta, getX, getY, getZ, hadamard, isVector3, magnitude, make, normalize, scale, setPhi, setR, setTheta, setX, setY, setZ, softmax, subtract, zero };
|
package/dist/vector/vector4.d.ts
CHANGED
package/dist/vector/vector4.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { i as isVector4$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as components$1, s as softmax$1, b as add$1, e as subtract$1, h as hadamard$1, f as scale$1 } from '../shared/curvy.
|
|
2
|
-
import '../
|
|
1
|
+
import { i as isVector4$1, m as make$1, a as magnitude$1, n as normalize$1, d as dot$1, c as components$1, s as softmax$1, b as add$1, e as subtract$1, h as hadamard$1, f as scale$1 } from '../shared/curvy.C2XGH0R0.mjs';
|
|
2
|
+
import '../pipe.mjs';
|
|
3
|
+
import '../utils.mjs';
|
|
3
4
|
|
|
4
5
|
const isVector4 = isVector4$1;
|
|
5
6
|
const make = make$1;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "curvy",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.5",
|
|
4
4
|
"description": "Spline and Curve utilities",
|
|
5
5
|
"author": "Tim Morris <timthewebguy@gmail.com>",
|
|
6
6
|
"homepage": "https://github.com/tkofh/curvy#readme",
|
|
@@ -87,6 +87,14 @@
|
|
|
87
87
|
"./splines/basis2d": {
|
|
88
88
|
"types": "./dist/splines/basis2d.d.ts",
|
|
89
89
|
"import": "./dist/splines/basis2d.mjs"
|
|
90
|
+
},
|
|
91
|
+
"./pipe": {
|
|
92
|
+
"types": "./dist/pipe.d.ts",
|
|
93
|
+
"import": "./dist/pipe.mjs"
|
|
94
|
+
},
|
|
95
|
+
"./utils": {
|
|
96
|
+
"types": "./dist/utils.d.ts",
|
|
97
|
+
"import": "./dist/utils.mjs"
|
|
90
98
|
}
|
|
91
99
|
},
|
|
92
100
|
"files": [
|