@wemap/maths 10.0.0-alpha.10 → 10.0.0-alpha.11

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/index.d.ts CHANGED
@@ -30,6 +30,10 @@ declare module '@wemap/maths' {
30
30
  export function std(arr: number[]): number;
31
31
  export function wrap(n: number, min: number, max: number): number;
32
32
 
33
+ export class EulerAngles {
34
+ static toString(eulerAngles: EulerAngles_t | EulerAnglesDegrees_t): string;
35
+ }
36
+
33
37
  export class Quaternion {
34
38
  static ROTX_PI2: Quaternion_t;
35
39
  static ROTX_PI: Quaternion_t;
package/index.js CHANGED
@@ -1,3 +1,4 @@
1
+ export { default as EulerAngles } from './src/EulerAngles.js';
1
2
  export { default as Matrix } from './src/Matrix.js';
2
3
  export { default as Matrix3 } from './src/Matrix3.js';
3
4
  export { default as Matrix4 } from './src/Matrix4.js';
package/package.json CHANGED
@@ -13,7 +13,7 @@
13
13
  "directory": "packages/maths"
14
14
  },
15
15
  "name": "@wemap/maths",
16
- "version": "10.0.0-alpha.10",
16
+ "version": "10.0.0-alpha.11",
17
17
  "bugs": {
18
18
  "url": "https://github.com/wemap/wemap-modules-js/issues"
19
19
  },
@@ -26,5 +26,5 @@
26
26
  "wemap"
27
27
  ],
28
28
  "license": "ISC",
29
- "gitHead": "5970289ef2b1f06f9df382878f72bf48f57c4c00"
29
+ "gitHead": "51207f18c96fb4693c7719c6dcb0d73642d6ebb2"
30
30
  }
@@ -0,0 +1,8 @@
1
+ class EulerAngles {
2
+
3
+ static toString([yaw, pitch, roll]) {
4
+ return `[${yaw.toFixed(2)}, ${pitch.toFixed(2)}, ${roll.toFixed(2)}]`;
5
+ }
6
+
7
+ }
8
+ export default EulerAngles;