@shapediver/viewer.features.drawing-tools 3.4.3 → 3.5.0

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.
Files changed (148) hide show
  1. package/dist/api/implementation/DrawingToolsApi.d.ts +1 -2
  2. package/dist/api/implementation/DrawingToolsApi.d.ts.map +1 -1
  3. package/dist/api/implementation/DrawingToolsApi.js +21 -12
  4. package/dist/api/implementation/DrawingToolsApi.js.map +1 -1
  5. package/dist/api/interfaces/IDrawingToolsApi.d.ts +2 -6
  6. package/dist/api/interfaces/IDrawingToolsApi.d.ts.map +1 -1
  7. package/dist/business/implementation/DrawingToolsManager.d.ts +6 -8
  8. package/dist/business/implementation/DrawingToolsManager.d.ts.map +1 -1
  9. package/dist/business/implementation/DrawingToolsManager.js +14 -14
  10. package/dist/business/implementation/DrawingToolsManager.js.map +1 -1
  11. package/dist/business/implementation/managers/HistoryManager.d.ts +1 -2
  12. package/dist/business/implementation/managers/HistoryManager.d.ts.map +1 -1
  13. package/dist/business/implementation/managers/HistoryManager.js.map +1 -1
  14. package/dist/business/implementation/managers/TextVisualizationManager.d.ts +1 -2
  15. package/dist/business/implementation/managers/TextVisualizationManager.d.ts.map +1 -1
  16. package/dist/business/implementation/managers/TextVisualizationManager.js +8 -8
  17. package/dist/business/implementation/managers/TextVisualizationManager.js.map +1 -1
  18. package/dist/business/implementation/managers/geometry/GeometryManager.d.ts +3 -4
  19. package/dist/business/implementation/managers/geometry/GeometryManager.d.ts.map +1 -1
  20. package/dist/business/implementation/managers/geometry/GeometryManager.js +2 -2
  21. package/dist/business/implementation/managers/geometry/GeometryManager.js.map +1 -1
  22. package/dist/business/implementation/managers/geometry/helpers/GeometryManagerHelper.d.ts +2 -2
  23. package/dist/business/implementation/managers/geometry/helpers/GeometryManagerHelper.d.ts.map +1 -1
  24. package/dist/business/implementation/managers/geometry/helpers/GeometryManagerHelper.js +4 -0
  25. package/dist/business/implementation/managers/geometry/helpers/GeometryManagerHelper.js.map +1 -1
  26. package/dist/business/implementation/managers/interaction/InteractionManager.d.ts +3 -4
  27. package/dist/business/implementation/managers/interaction/InteractionManager.d.ts.map +1 -1
  28. package/dist/business/implementation/managers/interaction/InteractionManager.js +23 -7
  29. package/dist/business/implementation/managers/interaction/InteractionManager.js.map +1 -1
  30. package/dist/business/implementation/managers/interaction/handlers/DeletionInteractionHandler.js +1 -1
  31. package/dist/business/implementation/managers/interaction/handlers/DeletionInteractionHandler.js.map +1 -1
  32. package/dist/business/implementation/managers/interaction/handlers/InsertionInteractionHandler.d.ts +2 -0
  33. package/dist/business/implementation/managers/interaction/handlers/InsertionInteractionHandler.d.ts.map +1 -1
  34. package/dist/business/implementation/managers/interaction/handlers/InsertionInteractionHandler.js +30 -7
  35. package/dist/business/implementation/managers/interaction/handlers/InsertionInteractionHandler.js.map +1 -1
  36. package/dist/business/implementation/managers/interaction/handlers/MidPointInteractionHandler.js +1 -1
  37. package/dist/business/implementation/managers/interaction/handlers/MidPointInteractionHandler.js.map +1 -1
  38. package/dist/business/implementation/managers/interaction/helpers/InteractionManagerHelper.d.ts.map +1 -1
  39. package/dist/business/implementation/managers/interaction/helpers/InteractionManagerHelper.js +6 -3
  40. package/dist/business/implementation/managers/interaction/helpers/InteractionManagerHelper.js.map +1 -1
  41. package/dist/business/interfaces/IDrawingToolsManager.d.ts +6 -38
  42. package/dist/business/interfaces/IDrawingToolsManager.d.ts.map +1 -1
  43. package/dist/business/interfaces/IDrawingToolsManager.js.map +1 -1
  44. package/dist/index.d.ts +6 -15
  45. package/dist/index.d.ts.map +1 -1
  46. package/dist/index.js +11 -13
  47. package/dist/index.js.map +1 -1
  48. package/package.json +11 -10
  49. package/dist/api/implementation/restrictions/AbstractRestrictionApi.d.ts +0 -10
  50. package/dist/api/implementation/restrictions/AbstractRestrictionApi.d.ts.map +0 -1
  51. package/dist/api/implementation/restrictions/AbstractRestrictionApi.js +0 -38
  52. package/dist/api/implementation/restrictions/AbstractRestrictionApi.js.map +0 -1
  53. package/dist/api/implementation/restrictions/AbstractSnapRestrictionApi.d.ts +0 -11
  54. package/dist/api/implementation/restrictions/AbstractSnapRestrictionApi.d.ts.map +0 -1
  55. package/dist/api/implementation/restrictions/AbstractSnapRestrictionApi.js +0 -40
  56. package/dist/api/implementation/restrictions/AbstractSnapRestrictionApi.js.map +0 -1
  57. package/dist/api/implementation/restrictions/geometry/GeometryRestrictionApi.d.ts +0 -15
  58. package/dist/api/implementation/restrictions/geometry/GeometryRestrictionApi.d.ts.map +0 -1
  59. package/dist/api/implementation/restrictions/geometry/GeometryRestrictionApi.js +0 -54
  60. package/dist/api/implementation/restrictions/geometry/GeometryRestrictionApi.js.map +0 -1
  61. package/dist/api/implementation/restrictions/plane/PlaneRestrictionApi.d.ts +0 -20
  62. package/dist/api/implementation/restrictions/plane/PlaneRestrictionApi.d.ts.map +0 -1
  63. package/dist/api/implementation/restrictions/plane/PlaneRestrictionApi.js +0 -67
  64. package/dist/api/implementation/restrictions/plane/PlaneRestrictionApi.js.map +0 -1
  65. package/dist/api/implementation/restrictions/plane/snap/AngularRestrictionApi.d.ts +0 -10
  66. package/dist/api/implementation/restrictions/plane/snap/AngularRestrictionApi.d.ts.map +0 -1
  67. package/dist/api/implementation/restrictions/plane/snap/AngularRestrictionApi.js +0 -40
  68. package/dist/api/implementation/restrictions/plane/snap/AngularRestrictionApi.js.map +0 -1
  69. package/dist/api/implementation/restrictions/plane/snap/AxisRestrictionApi.d.ts +0 -7
  70. package/dist/api/implementation/restrictions/plane/snap/AxisRestrictionApi.d.ts.map +0 -1
  71. package/dist/api/implementation/restrictions/plane/snap/AxisRestrictionApi.js +0 -24
  72. package/dist/api/implementation/restrictions/plane/snap/AxisRestrictionApi.js.map +0 -1
  73. package/dist/api/implementation/restrictions/plane/snap/GridRestrictionApi.d.ts +0 -10
  74. package/dist/api/implementation/restrictions/plane/snap/GridRestrictionApi.d.ts.map +0 -1
  75. package/dist/api/implementation/restrictions/plane/snap/GridRestrictionApi.js +0 -40
  76. package/dist/api/implementation/restrictions/plane/snap/GridRestrictionApi.js.map +0 -1
  77. package/dist/api/interfaces/IRestrictionApi.d.ts +0 -11
  78. package/dist/api/interfaces/IRestrictionApi.d.ts.map +0 -1
  79. package/dist/api/interfaces/IRestrictionApi.js +0 -3
  80. package/dist/api/interfaces/IRestrictionApi.js.map +0 -1
  81. package/dist/api/interfaces/ISnapRestrictionApi.d.ts +0 -13
  82. package/dist/api/interfaces/ISnapRestrictionApi.d.ts.map +0 -1
  83. package/dist/api/interfaces/ISnapRestrictionApi.js +0 -3
  84. package/dist/api/interfaces/ISnapRestrictionApi.js.map +0 -1
  85. package/dist/business/implementation/managers/geometry/GeometryMathManager.d.ts +0 -82
  86. package/dist/business/implementation/managers/geometry/GeometryMathManager.d.ts.map +0 -1
  87. package/dist/business/implementation/managers/geometry/GeometryMathManager.js +0 -245
  88. package/dist/business/implementation/managers/geometry/GeometryMathManager.js.map +0 -1
  89. package/dist/business/implementation/managers/interaction/EventManager.d.ts +0 -26
  90. package/dist/business/implementation/managers/interaction/EventManager.d.ts.map +0 -1
  91. package/dist/business/implementation/managers/interaction/EventManager.js +0 -63
  92. package/dist/business/implementation/managers/interaction/EventManager.js.map +0 -1
  93. package/dist/business/implementation/managers/interaction/RestrictionManager.d.ts +0 -19
  94. package/dist/business/implementation/managers/interaction/RestrictionManager.d.ts.map +0 -1
  95. package/dist/business/implementation/managers/interaction/RestrictionManager.js +0 -113
  96. package/dist/business/implementation/managers/interaction/RestrictionManager.js.map +0 -1
  97. package/dist/business/implementation/managers/interaction/restrictions/AbstractRestriction.d.ts +0 -19
  98. package/dist/business/implementation/managers/interaction/restrictions/AbstractRestriction.d.ts.map +0 -1
  99. package/dist/business/implementation/managers/interaction/restrictions/AbstractRestriction.js +0 -105
  100. package/dist/business/implementation/managers/interaction/restrictions/AbstractRestriction.js.map +0 -1
  101. package/dist/business/implementation/managers/interaction/restrictions/AbstractSnapRestriction.d.ts +0 -31
  102. package/dist/business/implementation/managers/interaction/restrictions/AbstractSnapRestriction.d.ts.map +0 -1
  103. package/dist/business/implementation/managers/interaction/restrictions/AbstractSnapRestriction.js +0 -125
  104. package/dist/business/implementation/managers/interaction/restrictions/AbstractSnapRestriction.js.map +0 -1
  105. package/dist/business/implementation/managers/interaction/restrictions/geometry/GeometryRestriction.d.ts +0 -40
  106. package/dist/business/implementation/managers/interaction/restrictions/geometry/GeometryRestriction.d.ts.map +0 -1
  107. package/dist/business/implementation/managers/interaction/restrictions/geometry/GeometryRestriction.js +0 -257
  108. package/dist/business/implementation/managers/interaction/restrictions/geometry/GeometryRestriction.js.map +0 -1
  109. package/dist/business/implementation/managers/interaction/restrictions/plane/PlaneRestriction.d.ts +0 -66
  110. package/dist/business/implementation/managers/interaction/restrictions/plane/PlaneRestriction.d.ts.map +0 -1
  111. package/dist/business/implementation/managers/interaction/restrictions/plane/PlaneRestriction.js +0 -244
  112. package/dist/business/implementation/managers/interaction/restrictions/plane/PlaneRestriction.js.map +0 -1
  113. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AngularRestriction.d.ts +0 -39
  114. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AngularRestriction.d.ts.map +0 -1
  115. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AngularRestriction.js +0 -317
  116. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AngularRestriction.js.map +0 -1
  117. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AxisRestriction.d.ts +0 -27
  118. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AxisRestriction.d.ts.map +0 -1
  119. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AxisRestriction.js +0 -165
  120. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/AxisRestriction.js.map +0 -1
  121. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/GridRestriction.d.ts +0 -39
  122. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/GridRestriction.d.ts.map +0 -1
  123. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/GridRestriction.js +0 -212
  124. package/dist/business/implementation/managers/interaction/restrictions/plane/snap/GridRestriction.js.map +0 -1
  125. package/dist/business/implementation/utils/numberCleaner.d.ts +0 -2
  126. package/dist/business/implementation/utils/numberCleaner.d.ts.map +0 -1
  127. package/dist/business/implementation/utils/numberCleaner.js +0 -9
  128. package/dist/business/implementation/utils/numberCleaner.js.map +0 -1
  129. package/dist/business/interfaces/IManager.d.ts +0 -4
  130. package/dist/business/interfaces/IManager.d.ts.map +0 -1
  131. package/dist/business/interfaces/IManager.js +0 -3
  132. package/dist/business/interfaces/IManager.js.map +0 -1
  133. package/dist/business/interfaces/IRestriction.d.ts +0 -40
  134. package/dist/business/interfaces/IRestriction.d.ts.map +0 -1
  135. package/dist/business/interfaces/IRestriction.js +0 -12
  136. package/dist/business/interfaces/IRestriction.js.map +0 -1
  137. package/dist/business/interfaces/IRestrictionBase.d.ts +0 -19
  138. package/dist/business/interfaces/IRestrictionBase.d.ts.map +0 -1
  139. package/dist/business/interfaces/IRestrictionBase.js +0 -5
  140. package/dist/business/interfaces/IRestrictionBase.js.map +0 -1
  141. package/dist/business/interfaces/ISnapRestriction.d.ts +0 -52
  142. package/dist/business/interfaces/ISnapRestriction.d.ts.map +0 -1
  143. package/dist/business/interfaces/ISnapRestriction.js +0 -4
  144. package/dist/business/interfaces/ISnapRestriction.js.map +0 -1
  145. package/dist/three/CSS2DRenderer.d.ts +0 -32
  146. package/dist/three/CSS2DRenderer.d.ts.map +0 -1
  147. package/dist/three/CSS2DRenderer.js +0 -137
  148. package/dist/three/CSS2DRenderer.js.map +0 -1
@@ -1,10 +0,0 @@
1
- import { AbstractSnapRestrictionApi } from '../../AbstractSnapRestrictionApi';
2
- import { AngularRestriction } from '../../../../../business/implementation/managers/interaction/restrictions/plane/snap/AngularRestriction';
3
- export declare class AngularRestrictionApi extends AbstractSnapRestrictionApi {
4
- #private;
5
- constructor(restriction: AngularRestriction);
6
- get angleStep(): number;
7
- set angleStep(value: number);
8
- get angleStepEditable(): boolean;
9
- }
10
- //# sourceMappingURL=AngularRestrictionApi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AngularRestrictionApi.d.ts","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/AngularRestrictionApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAC;AAC9E,OAAO,EAAE,kBAAkB,EAAE,MAAM,wGAAwG,CAAC;AAE5I,qBAAa,qBAAsB,SAAQ,0BAA0B;;gBASrD,WAAW,EAAE,kBAAkB;IAS3C,IAAW,SAAS,IAAI,MAAM,CAE7B;IAED,IAAW,SAAS,CAAC,KAAK,EAAE,MAAM,EAEjC;IAED,IAAW,iBAAiB,IAAI,OAAO,CAEtC;CAGJ"}
@@ -1,40 +0,0 @@
1
- "use strict";
2
- var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
- if (kind === "m") throw new TypeError("Private method is not writable");
4
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
- };
8
- var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
- };
13
- var _AngularRestrictionApi_angularRestriction;
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.AngularRestrictionApi = void 0;
16
- const AbstractSnapRestrictionApi_1 = require("../../AbstractSnapRestrictionApi");
17
- class AngularRestrictionApi extends AbstractSnapRestrictionApi_1.AbstractSnapRestrictionApi {
18
- // #endregion Properties (1)
19
- // #region Constructors (1)
20
- constructor(restriction) {
21
- super(restriction);
22
- // #region Properties (1)
23
- _AngularRestrictionApi_angularRestriction.set(this, void 0);
24
- __classPrivateFieldSet(this, _AngularRestrictionApi_angularRestriction, restriction, "f");
25
- }
26
- // #endregion Constructors (1)
27
- // #region Public Getters And Setters (2)
28
- get angleStep() {
29
- return __classPrivateFieldGet(this, _AngularRestrictionApi_angularRestriction, "f").angleStep;
30
- }
31
- set angleStep(value) {
32
- __classPrivateFieldGet(this, _AngularRestrictionApi_angularRestriction, "f").angleStep = value;
33
- }
34
- get angleStepEditable() {
35
- return __classPrivateFieldGet(this, _AngularRestrictionApi_angularRestriction, "f").angleStepEditable;
36
- }
37
- }
38
- exports.AngularRestrictionApi = AngularRestrictionApi;
39
- _AngularRestrictionApi_angularRestriction = new WeakMap();
40
- //# sourceMappingURL=AngularRestrictionApi.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AngularRestrictionApi.js","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/AngularRestrictionApi.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,iFAA8E;AAG9E,MAAa,qBAAsB,SAAQ,uDAA0B;IAKjE,4BAA4B;IAE5B,2BAA2B;IAE3B,YAAY,WAA+B;QACvC,KAAK,CAAC,WAAW,CAAC,CAAC;QATvB,yBAAyB;QAEzB,4DAAiD;QAQ7C,uBAAA,IAAI,6CAAuB,WAAW,MAAA,CAAC;IAC3C,CAAC;IAED,8BAA8B;IAE9B,yCAAyC;IAEzC,IAAW,SAAS;QAChB,OAAO,uBAAA,IAAI,iDAAoB,CAAC,SAAS,CAAC;IAC9C,CAAC;IAED,IAAW,SAAS,CAAC,KAAa;QAC9B,uBAAA,IAAI,iDAAoB,CAAC,SAAS,GAAG,KAAK,CAAC;IAC/C,CAAC;IAED,IAAW,iBAAiB;QACxB,OAAO,uBAAA,IAAI,iDAAoB,CAAC,iBAAiB,CAAC;IACtD,CAAC;CAGJ;AA/BD,sDA+BC"}
@@ -1,7 +0,0 @@
1
- import { AbstractSnapRestrictionApi } from '../../AbstractSnapRestrictionApi';
2
- import { AxisRestriction } from '../../../../../business/implementation/managers/interaction/restrictions/plane/snap/AxisRestriction';
3
- export declare class AxisRestrictionApi extends AbstractSnapRestrictionApi {
4
- #private;
5
- constructor(restriction: AxisRestriction);
6
- }
7
- //# sourceMappingURL=AxisRestrictionApi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AxisRestrictionApi.d.ts","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/AxisRestrictionApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAC;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,qGAAqG,CAAC;AAEtI,qBAAa,kBAAmB,SAAQ,0BAA0B;;gBASlD,WAAW,EAAE,eAAe;CAM3C"}
@@ -1,24 +0,0 @@
1
- "use strict";
2
- var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
- if (kind === "m") throw new TypeError("Private method is not writable");
4
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
- };
8
- var _AxisRestrictionApi_axisRestriction;
9
- Object.defineProperty(exports, "__esModule", { value: true });
10
- exports.AxisRestrictionApi = void 0;
11
- const AbstractSnapRestrictionApi_1 = require("../../AbstractSnapRestrictionApi");
12
- class AxisRestrictionApi extends AbstractSnapRestrictionApi_1.AbstractSnapRestrictionApi {
13
- // #endregion Properties (1)
14
- // #region Constructors (1)
15
- constructor(restriction) {
16
- super(restriction);
17
- // #region Properties (1)
18
- _AxisRestrictionApi_axisRestriction.set(this, void 0);
19
- __classPrivateFieldSet(this, _AxisRestrictionApi_axisRestriction, restriction, "f");
20
- }
21
- }
22
- exports.AxisRestrictionApi = AxisRestrictionApi;
23
- _AxisRestrictionApi_axisRestriction = new WeakMap();
24
- //# sourceMappingURL=AxisRestrictionApi.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"AxisRestrictionApi.js","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/AxisRestrictionApi.ts"],"names":[],"mappings":";;;;;;;;;;AAAA,iFAA8E;AAG9E,MAAa,kBAAmB,SAAQ,uDAA0B;IAK9D,4BAA4B;IAE5B,2BAA2B;IAE3B,YAAY,WAA4B;QACpC,KAAK,CAAC,WAAW,CAAC,CAAC;QATvB,yBAAyB;QAEzB,sDAA2C;QAQvC,uBAAA,IAAI,uCAAoB,WAAW,MAAA,CAAC;IACxC,CAAC;CAGJ;AAfD,gDAeC"}
@@ -1,10 +0,0 @@
1
- import { AbstractSnapRestrictionApi } from '../../AbstractSnapRestrictionApi';
2
- import { GridRestriction } from '../../../../../business/implementation/managers/interaction/restrictions/plane/snap/GridRestriction';
3
- export declare class GridRestrictionApi extends AbstractSnapRestrictionApi {
4
- #private;
5
- constructor(restriction: GridRestriction);
6
- get gridUnit(): number;
7
- set gridUnit(value: number);
8
- get gridUnitEditable(): boolean;
9
- }
10
- //# sourceMappingURL=GridRestrictionApi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GridRestrictionApi.d.ts","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/GridRestrictionApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAC;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,qGAAqG,CAAC;AAEtI,qBAAa,kBAAmB,SAAQ,0BAA0B;;gBASlD,WAAW,EAAE,eAAe;IASxC,IAAW,QAAQ,IAAI,MAAM,CAE5B;IAED,IAAW,QAAQ,CAAC,KAAK,EAAE,MAAM,EAEhC;IAED,IAAW,gBAAgB,IAAI,OAAO,CAErC;CAGJ"}
@@ -1,40 +0,0 @@
1
- "use strict";
2
- var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
- if (kind === "m") throw new TypeError("Private method is not writable");
4
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
- };
8
- var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
- };
13
- var _GridRestrictionApi_gridRestriction;
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.GridRestrictionApi = void 0;
16
- const AbstractSnapRestrictionApi_1 = require("../../AbstractSnapRestrictionApi");
17
- class GridRestrictionApi extends AbstractSnapRestrictionApi_1.AbstractSnapRestrictionApi {
18
- // #endregion Properties (1)
19
- // #region Constructors (1)
20
- constructor(restriction) {
21
- super(restriction);
22
- // #region Properties (1)
23
- _GridRestrictionApi_gridRestriction.set(this, void 0);
24
- __classPrivateFieldSet(this, _GridRestrictionApi_gridRestriction, restriction, "f");
25
- }
26
- // #endregion Constructors (1)
27
- // #region Public Getters And Setters (2)
28
- get gridUnit() {
29
- return __classPrivateFieldGet(this, _GridRestrictionApi_gridRestriction, "f").gridUnit;
30
- }
31
- set gridUnit(value) {
32
- __classPrivateFieldGet(this, _GridRestrictionApi_gridRestriction, "f").gridUnit = value;
33
- }
34
- get gridUnitEditable() {
35
- return __classPrivateFieldGet(this, _GridRestrictionApi_gridRestriction, "f").gridUnitEditable;
36
- }
37
- }
38
- exports.GridRestrictionApi = GridRestrictionApi;
39
- _GridRestrictionApi_gridRestriction = new WeakMap();
40
- //# sourceMappingURL=GridRestrictionApi.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GridRestrictionApi.js","sourceRoot":"","sources":["../../../../../../src/api/implementation/restrictions/plane/snap/GridRestrictionApi.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,iFAA8E;AAG9E,MAAa,kBAAmB,SAAQ,uDAA0B;IAK9D,4BAA4B;IAE5B,2BAA2B;IAE3B,YAAY,WAA4B;QACpC,KAAK,CAAC,WAAW,CAAC,CAAC;QATvB,yBAAyB;QAEzB,sDAA2C;QAQvC,uBAAA,IAAI,uCAAoB,WAAW,MAAA,CAAC;IACxC,CAAC;IAED,8BAA8B;IAE9B,yCAAyC;IAEzC,IAAW,QAAQ;QACf,OAAO,uBAAA,IAAI,2CAAiB,CAAC,QAAQ,CAAC;IAC1C,CAAC;IAED,IAAW,QAAQ,CAAC,KAAa;QAC7B,uBAAA,IAAI,2CAAiB,CAAC,QAAQ,GAAG,KAAK,CAAC;IAC3C,CAAC;IAED,IAAW,gBAAgB;QACvB,OAAO,uBAAA,IAAI,2CAAiB,CAAC,gBAAgB,CAAC;IAClD,CAAC;CAGJ;AA/BD,gDA+BC"}
@@ -1,11 +0,0 @@
1
- export interface IRestrictionApi {
2
- /**
3
- * The unique identifier of the restriction.
4
- */
5
- readonly id: string;
6
- /**
7
- * Whether the restriction is enabled or not.
8
- */
9
- enabled: boolean;
10
- }
11
- //# sourceMappingURL=IRestrictionApi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"IRestrictionApi.d.ts","sourceRoot":"","sources":["../../../src/api/interfaces/IRestrictionApi.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAG5B;;OAEG;IACH,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,OAAO,EAAE,OAAO,CAAC;CAGpB"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=IRestrictionApi.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"IRestrictionApi.js","sourceRoot":"","sources":["../../../src/api/interfaces/IRestrictionApi.ts"],"names":[],"mappings":""}
@@ -1,13 +0,0 @@
1
- import { IRestrictionApi } from './IRestrictionApi';
2
- export interface ISnapRestrictionApi extends IRestrictionApi {
3
- /**
4
- * If the enabling or disabling of the restriction is allowed to the end user.
5
- * If it is not editable, the default value for enabling or disabling the restriction is used.
6
- */
7
- readonly enabledEditable: boolean;
8
- /**
9
- * The priority of the restriction.
10
- */
11
- priority: number;
12
- }
13
- //# sourceMappingURL=ISnapRestrictionApi.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ISnapRestrictionApi.d.ts","sourceRoot":"","sources":["../../../src/api/interfaces/ISnapRestrictionApi.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAEpD,MAAM,WAAW,mBAAoB,SAAQ,eAAe;IAGxD;;;OAGG;IACH,QAAQ,CAAC,eAAe,EAAE,OAAO,CAAC;IAElC;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAGpB"}
@@ -1,3 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- //# sourceMappingURL=ISnapRestrictionApi.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ISnapRestrictionApi.js","sourceRoot":"","sources":["../../../src/api/interfaces/ISnapRestrictionApi.ts"],"names":[],"mappings":""}
@@ -1,82 +0,0 @@
1
- import { DrawingToolsManager } from '../../DrawingToolsManager';
2
- import { IManager } from '../../../interfaces/IManager';
3
- import { IRay } from '@shapediver/viewer.features.interaction';
4
- import { vec3 } from 'gl-matrix';
5
- export declare class GeometryMathManager implements IManager {
6
- #private;
7
- constructor(drawingToolsManager: DrawingToolsManager);
8
- /**
9
- * Check which distances of lines to ray
10
- *
11
- * @param ray
12
- * @returns
13
- */
14
- checkLineDistances(ray: IRay): {
15
- index: number[];
16
- distance: number;
17
- }[] | undefined;
18
- /**
19
- * Check which distances of points to ray
20
- *
21
- * @param ray
22
- * @returns
23
- */
24
- checkPointDistances(ray: IRay): {
25
- index: number;
26
- distance: number;
27
- }[] | undefined;
28
- close(): void;
29
- /**
30
- * Calculate the closest point on a ray to a point
31
- *
32
- * @param ray
33
- * @param point
34
- * @returns
35
- */
36
- closestPoint(ray: IRay, point: vec3): vec3;
37
- /**
38
- * Calculate the closest point on a line to a point
39
- *
40
- * @param start
41
- * @param end
42
- * @param point
43
- */
44
- closestPointOnLine(start: vec3, end: vec3, point: vec3): vec3;
45
- /**
46
- * Calculate the closest point on a plane to a point
47
- *
48
- * @param point
49
- * @param planeNormal
50
- * @param planeOrigin
51
- * @returns
52
- */
53
- closestPointOnPlane(planeOrigin: vec3, planeNormal: vec3, point: vec3): vec3;
54
- /**
55
- * Calculate the distance between a ray and a line segment
56
- *
57
- * @param ray
58
- * @param lineStart
59
- * @param lineEnd
60
- * @returns
61
- */
62
- closestPointsRayLine(ray: IRay, lineStart: vec3, lineEnd: vec3): {
63
- closestPointOnRay: vec3;
64
- closestPointOnLine: vec3;
65
- };
66
- /**
67
- * Calculate the distance between two rays
68
- *
69
- * @param ray1
70
- * @param ray2
71
- * @returns
72
- */
73
- closestPointsRayRay(ray1: IRay, ray2: IRay): {
74
- closestPointOnRay1: vec3;
75
- closestPointOnRay2: vec3;
76
- };
77
- screenSpaceDistanceCheck(point1: vec3, point2: vec3, threshold: number): {
78
- distanceSquared: number;
79
- check: boolean;
80
- };
81
- }
82
- //# sourceMappingURL=GeometryMathManager.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeometryMathManager.d.ts","sourceRoot":"","sources":["../../../../../src/business/implementation/managers/geometry/GeometryMathManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,E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;KAAE;IA+BnG,wBAAwB,CAAC,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM;;;;CAkChF"}
@@ -1,245 +0,0 @@
1
- "use strict";
2
- var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
3
- if (kind === "m") throw new TypeError("Private method is not writable");
4
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
5
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
6
- return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
7
- };
8
- var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
9
- if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
10
- if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
11
- return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
12
- };
13
- var _GeometryMathManager_drawingToolsManager, _GeometryMathManager_settings, _GeometryMathManager_viewport;
14
- Object.defineProperty(exports, "__esModule", { value: true });
15
- exports.GeometryMathManager = void 0;
16
- const gl_matrix_1 = require("gl-matrix");
17
- class GeometryMathManager {
18
- // #endregion Properties (3)
19
- // #region Constructors (1)
20
- constructor(drawingToolsManager) {
21
- // #region Properties (3)
22
- _GeometryMathManager_drawingToolsManager.set(this, void 0);
23
- _GeometryMathManager_settings.set(this, void 0);
24
- _GeometryMathManager_viewport.set(this, void 0);
25
- __classPrivateFieldSet(this, _GeometryMathManager_drawingToolsManager, drawingToolsManager, "f");
26
- __classPrivateFieldSet(this, _GeometryMathManager_viewport, drawingToolsManager.viewport, "f");
27
- __classPrivateFieldSet(this, _GeometryMathManager_settings, drawingToolsManager.settings, "f");
28
- }
29
- // #endregion Constructors (1)
30
- // #region Public Methods (9)
31
- /**
32
- * Check which distances of lines to ray
33
- *
34
- * @param ray
35
- * @returns
36
- */
37
- checkLineDistances(ray) {
38
- const positionArray = __classPrivateFieldGet(this, _GeometryMathManager_drawingToolsManager, "f").positionArray;
39
- const indicesArrayLines = __classPrivateFieldGet(this, _GeometryMathManager_drawingToolsManager, "f").indicesArrayLines;
40
- // if there are no line array indices, return
41
- if (!indicesArrayLines)
42
- return;
43
- /**
44
- * Calculate line distances to ray
45
- */
46
- const distances = [];
47
- for (let i = 0; i < indicesArrayLines.length; i += 2) {
48
- const firstIndex = indicesArrayLines.at(i);
49
- const secondIndex = indicesArrayLines.at(i + 1);
50
- const lineStart = gl_matrix_1.vec3.fromValues(positionArray.at(firstIndex * 3), positionArray.at(firstIndex * 3 + 1), positionArray.at(firstIndex * 3 + 2));
51
- const lineEnd = gl_matrix_1.vec3.fromValues(positionArray.at(secondIndex * 3), positionArray.at(secondIndex * 3 + 1), positionArray.at(secondIndex * 3 + 2));
52
- const { closestPointOnRay, closestPointOnLine } = this.closestPointsRayLine(ray, lineStart, lineEnd);
53
- if (this.screenSpaceDistanceCheck(closestPointOnRay, closestPointOnLine, __classPrivateFieldGet(this, _GeometryMathManager_settings, "f").visualization.points.size_0 * __classPrivateFieldGet(this, _GeometryMathManager_settings, "f").visualization.distanceMultiplicationFactor).check === false)
54
- continue;
55
- distances.push({ index: [firstIndex, secondIndex], distance: gl_matrix_1.vec3.distance(closestPointOnRay, closestPointOnLine) });
56
- }
57
- // if there are no distances, return
58
- if (distances.length === 0)
59
- return;
60
- return distances.sort((a, b) => a.distance - b.distance);
61
- }
62
- /**
63
- * Check which distances of points to ray
64
- *
65
- * @param ray
66
- * @returns
67
- */
68
- checkPointDistances(ray) {
69
- const positionArray = __classPrivateFieldGet(this, _GeometryMathManager_drawingToolsManager, "f").positionArray;
70
- /**
71
- * Calculate point distances to ray
72
- */
73
- const distances = [];
74
- for (let i = 0; i < positionArray.length; i += 3) {
75
- const point = gl_matrix_1.vec3.fromValues(positionArray.at(i), positionArray.at(i + 1), positionArray.at(i + 2));
76
- // distance from point to ray
77
- const closestPoint = this.closestPoint(ray, point);
78
- if (this.screenSpaceDistanceCheck(point, closestPoint, __classPrivateFieldGet(this, _GeometryMathManager_settings, "f").visualization.points.size_0 * __classPrivateFieldGet(this, _GeometryMathManager_settings, "f").visualization.distanceMultiplicationFactor).check === false)
79
- continue;
80
- distances.push({ index: i / 3, distance: gl_matrix_1.vec3.distance(point, closestPoint) });
81
- }
82
- // if there are no distances, return
83
- if (distances.length === 0)
84
- return;
85
- // sort distances
86
- return distances.sort((a, b) => a.distance - b.distance);
87
- }
88
- close() { }
89
- /**
90
- * Calculate the closest point on a ray to a point
91
- *
92
- * @param ray
93
- * @param point
94
- * @returns
95
- */
96
- closestPoint(ray, point) {
97
- // distance from point to ray
98
- const dot = gl_matrix_1.vec3.dot(ray.direction, gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), point, ray.origin));
99
- // closest point on ray to point
100
- return gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), ray.origin, gl_matrix_1.vec3.multiply(gl_matrix_1.vec3.create(), ray.direction, gl_matrix_1.vec3.fromValues(dot, dot, dot)));
101
- }
102
- /**
103
- * Calculate the closest point on a line to a point
104
- *
105
- * @param start
106
- * @param end
107
- * @param point
108
- */
109
- closestPointOnLine(start, end, point) {
110
- const lineDir = gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), end, start);
111
- // Vector from linePoint to point
112
- const v = gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), point, start);
113
- // Line direction dot product with itself
114
- const dirDotDir = gl_matrix_1.vec3.dot(lineDir, lineDir);
115
- // If the direction vector is a zero vector, return the line point as closest point
116
- if (dirDotDir === 0)
117
- return start;
118
- // Projection factor t
119
- const t = gl_matrix_1.vec3.dot(v, lineDir) / dirDotDir;
120
- // Closest point on the line
121
- const closestPoint = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), start, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), lineDir, t));
122
- return closestPoint;
123
- }
124
- /**
125
- * Calculate the closest point on a plane to a point
126
- *
127
- * @param point
128
- * @param planeNormal
129
- * @param planeOrigin
130
- * @returns
131
- */
132
- closestPointOnPlane(planeOrigin, planeNormal, point) {
133
- // Calculate the vector from the plane origin to the point
134
- const toPoint = gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), point, planeOrigin);
135
- // Project the vector onto the plane normal
136
- const projectionLength = gl_matrix_1.vec3.dot(toPoint, planeNormal);
137
- const projectionVector = gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), planeNormal, projectionLength);
138
- // Subtract the projection vector from the original point to get the projected point
139
- return gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), point, projectionVector);
140
- }
141
- /**
142
- * Calculate the distance between a ray and a line segment
143
- *
144
- * @param ray
145
- * @param lineStart
146
- * @param lineEnd
147
- * @returns
148
- */
149
- closestPointsRayLine(ray, lineStart, lineEnd) {
150
- // direction of line
151
- const lineDirection = gl_matrix_1.vec3.normalize(gl_matrix_1.vec3.create(), gl_matrix_1.vec3.subtract(gl_matrix_1.vec3.create(), lineEnd, lineStart));
152
- // cross product of ray direction and line direction
153
- const crossProduct = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), ray.direction, lineDirection);
154
- // length of cross product
155
- const crossProductLength = gl_matrix_1.vec3.length(crossProduct);
156
- if (crossProductLength < 0.0001) {
157
- // ray and line are parallel, calculate the distance differently
158
- const closestPointOnRay = ray.origin;
159
- const closestPointOnLine = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), lineStart, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), lineDirection, gl_matrix_1.vec3.dot(gl_matrix_1.vec3.subtract(gl_matrix_1.vec3.create(), ray.origin, lineStart), lineDirection)));
160
- return {
161
- closestPointOnRay, closestPointOnLine
162
- };
163
- }
164
- const t = gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), lineStart, ray.origin);
165
- const u = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), t, lineDirection);
166
- const v = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), t, ray.direction);
167
- const tValue = gl_matrix_1.vec3.dot(u, crossProduct) / Math.pow(crossProductLength, 2);
168
- const uValue = gl_matrix_1.vec3.dot(v, crossProduct) / Math.pow(crossProductLength, 2);
169
- const closestPointOnRay = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), ray.origin, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), ray.direction, tValue));
170
- // restrict the closest point on line to the line segment
171
- let closestPointOnLine;
172
- if (uValue < 0) {
173
- closestPointOnLine = lineStart;
174
- }
175
- else if (uValue > gl_matrix_1.vec3.distance(lineStart, lineEnd)) {
176
- closestPointOnLine = lineEnd;
177
- }
178
- else {
179
- closestPointOnLine = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), lineStart, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), lineDirection, uValue));
180
- }
181
- return {
182
- closestPointOnRay, closestPointOnLine
183
- };
184
- }
185
- /**
186
- * Calculate the distance between two rays
187
- *
188
- * @param ray1
189
- * @param ray2
190
- * @returns
191
- */
192
- closestPointsRayRay(ray1, ray2) {
193
- // cross product of ray1 direction and ray2 direction
194
- const crossProduct = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), ray1.direction, ray2.direction);
195
- // length of cross product
196
- const crossProductLength = gl_matrix_1.vec3.length(crossProduct);
197
- if (crossProductLength < 0.0001) {
198
- // ray1 and ray2 are parallel, calculate the distance differently
199
- const closestPointOnRay1 = ray1.origin;
200
- const closestPointOnRay2 = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), ray2.origin, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), ray2.direction, gl_matrix_1.vec3.dot(gl_matrix_1.vec3.subtract(gl_matrix_1.vec3.create(), ray1.origin, ray2.origin), ray2.direction)));
201
- return {
202
- closestPointOnRay1, closestPointOnRay2
203
- };
204
- }
205
- const t = gl_matrix_1.vec3.sub(gl_matrix_1.vec3.create(), ray2.origin, ray1.origin);
206
- const u = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), t, ray2.direction);
207
- const v = gl_matrix_1.vec3.cross(gl_matrix_1.vec3.create(), t, ray1.direction);
208
- const tValue = gl_matrix_1.vec3.dot(u, crossProduct) / Math.pow(crossProductLength, 2);
209
- const uValue = gl_matrix_1.vec3.dot(v, crossProduct) / Math.pow(crossProductLength, 2);
210
- const closestPointOnRay1 = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), ray1.origin, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), ray1.direction, tValue));
211
- const closestPointOnRay2 = gl_matrix_1.vec3.add(gl_matrix_1.vec3.create(), ray2.origin, gl_matrix_1.vec3.scale(gl_matrix_1.vec3.create(), ray2.direction, uValue));
212
- return {
213
- closestPointOnRay1, closestPointOnRay2
214
- };
215
- }
216
- screenSpaceDistanceCheck(point1, point2, threshold) {
217
- const camera = __classPrivateFieldGet(this, _GeometryMathManager_viewport, "f").camera;
218
- // Project points to NDC
219
- const screenPos1 = camera.project(gl_matrix_1.vec3.clone(point1));
220
- const screenPos2 = camera.project(gl_matrix_1.vec3.clone(point2));
221
- const width = __classPrivateFieldGet(this, _GeometryMathManager_viewport, "f").canvas.width;
222
- const height = __classPrivateFieldGet(this, _GeometryMathManager_viewport, "f").canvas.height;
223
- const x1 = ((screenPos1[0] * (width / 2)) + (width / 2));
224
- const y1 = -((screenPos1[1] * (height / 2)) + (height / 2));
225
- const x2 = ((screenPos2[0] * (width / 2)) + (width / 2));
226
- const y2 = -((screenPos2[1] * (height / 2)) + (height / 2));
227
- const distanceSquared = Math.pow((x2 - x1), 2) + Math.pow((y2 - y1), 2);
228
- /**
229
- * Logic: The actual calculation would be
230
- * distance * 2 < threshold
231
- * the multiplication by 2 is to account for the fact that the distance is from the center of the point
232
- *
233
- * However, we work with the squared distance to avoid the sqrt operation
234
- * Therefore we square all values:
235
- * distanceSquared * 4 < threshold ** 2
236
- */
237
- return {
238
- distanceSquared: distanceSquared,
239
- check: distanceSquared * 4 < Math.pow(threshold, 2)
240
- };
241
- }
242
- }
243
- exports.GeometryMathManager = GeometryMathManager;
244
- _GeometryMathManager_drawingToolsManager = new WeakMap(), _GeometryMathManager_settings = new WeakMap(), _GeometryMathManager_viewport = new WeakMap();
245
- //# sourceMappingURL=GeometryMathManager.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeometryMathManager.js","sourceRoot":"","sources":["../../../../../src/business/implementation/managers/geometry/GeometryMathManager.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAIA,yCAAiC;AAEjC,MAAa,mBAAmB;IAO5B,4BAA4B;IAE5B,2BAA2B;IAE3B,YAAY,mBAAwC;QAVpD,yBAAyB;QAEzB,2DAAmD;QACnD,gDAA6B;QAC7B,gDAAiC;QAO7B,uBAAA,IAAI,4CAAwB,mBAAmB,MAAA,CAAC;QAChD,uBAAA,IAAI,iCAAa,mBAAmB,CAAC,QAAQ,MAAA,CAAC;QAC9C,uBAAA,IAAI,iCAAa,mBAAmB,CAAC,QAAQ,MAAA,CAAC;IAClD,CAAC;IAED,8BAA8B;IAE9B,6BAA6B;IAE7B;;;;;OAKG;IACI,kBAAkB,CAAC,GAAS;QAC/B,MAAM,aAAa,GAAG,uBAAA,IAAI,gDAAqB,CAAC,aAAa,CAAC;QAC9D,MAAM,iBAAiB,GAAG,uBAAA,IAAI,gDAAqB,CAAC,iBAAiB,CAAC;QAEtE,6CAA6C;QAC7C,IAAI,CAAC,iBAAiB;YAAE,OAAO;QAE/B;;WAEG;QACH,MAAM,SAAS,GAGT,EAAE,CAAC;QAET,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,iBAAiB,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE;YAClD,MAAM,UAAU,GAAG,iBAAiB,CAAC,EAAE,CAAC,CAAC,CAAE,CAAC;YAC5C,MAAM,WAAW,GAAG,iBAA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C,GAAG,SAAA,SAAS,EAAI,CAAC,CAAA;SAC9C,CAAC;IACN,CAAC;CAGJ;AA1RD,kDA0RC"}
@@ -1,26 +0,0 @@
1
- import { IDomEventListener } from '@shapediver/viewer.shared.services';
2
- import { IManager } from '../../../interfaces/IManager';
3
- import { IRay, IViewportApi } from '@shapediver/viewer.features.interaction';
4
- declare type Callbacks = {
5
- onDown: (event: PointerEvent, ray: IRay) => void;
6
- onMove: (event: PointerEvent, ray: IRay) => void;
7
- onUp: (event: PointerEvent, ray: IRay) => void;
8
- onOut: (event: PointerEvent, ray: IRay) => void;
9
- onKeyDown: (event: KeyboardEvent) => void;
10
- onKeyUp: (event: KeyboardEvent) => void;
11
- };
12
- export declare class EventManager implements IDomEventListener, IManager {
13
- #private;
14
- constructor(viewport: IViewportApi, callbacks: Callbacks);
15
- close(): void;
16
- onKeyDown(event: KeyboardEvent): void;
17
- onKeyUp(event: KeyboardEvent): void;
18
- onMouseWheel(): void;
19
- onPointerDown(event: PointerEvent): void;
20
- onPointerEnd(): void;
21
- onPointerMove(event: PointerEvent): void;
22
- onPointerOut(event: PointerEvent): void;
23
- onPointerUp(event: PointerEvent): void;
24
- }
25
- export {};
26
- //# sourceMappingURL=EventManager.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"EventManager.d.ts","sourceRoot":"","sources":["../../../../../src/business/implementation/managers/interaction/EventManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,oCAAoC,CAAC;AACvE,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,IAAI,EAAE,YAAY,EAAE,MAAM,yCAAyC,CAAC;AAI7E,aAAK,SAAS,GAAG;IACb,MAAM,EAAE,CAAC,KAAK,EAAE,YAAY,EAAE,GAAG,EAAE,IAAI,KAAK,IAAI,CAAC;IACjD,MAAM,EAAE,CAAC,KAAK,EAAE,YAAY,EAAE,GAAG,EAAE,IAAI,KAAK,IAAI,CAAC;IACjD,IAAI,EAAE,CAAC,KAAK,EAAE,YAAY,EAAE,GAAG,EAAE,IAAI,KAAK,IAAI,CAAC;IAC/C,KAAK,EAAE,CAAC,KAAK,EAAE,YAAY,EAAE,GAAG,EAAE,IAAI,KAAK,IAAI,CAAC;IAChD,SAAS,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IAC1C,OAAO,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAA;CAC1C,CAAA;AAMD,qBAAa,YAAa,YAAW,iBAAiB,EAAE,QAAQ;;gBAWhD,QAAQ,EAAE,YAAY,EAAE,SAAS,EAAE,SAAS;IAUjD,KAAK,IAAI,IAAI;IAIb,SAAS,CAAC,KAAK,EAAE,aAAa,GAAG,IAAI;IAIrC,OAAO,CAAC,KAAK,EAAE,aAAa,GAAG,IAAI;IAInC,YAAY,IAAI,IAAI;IAEpB,aAAa,CAAC,KAAK,EAAE,YAAY,GAAG,IAAI;IAKxC,YAAY,IAAI,IAAI;IAEpB,aAAa,CAAC,KAAK,EAAE,YAAY,GAAG,IAAI;IAKxC,YAAY,CAAC,KAAK,EAAE,YAAY,GAAG,IAAI;IAKvC,WAAW,CAAC,KAAK,EAAE,YAAY,GAAG,IAAI;CAMhD"}