nodi-modular 0.0.7 → 0.0.9

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
@@ -1,16 +1,30 @@
1
1
  /* tslint:disable */
2
2
  /* eslint-disable */
3
3
  export function do_nothing_just_tell_wasm_bindgen_to_generate_types(): void;
4
- /**
5
- * Interop struct for transform
6
- * Represents a 4x4 matrix as a 16-element array
7
- */
8
- export type TransformInterop = number[];
4
+ export type GeometryInteropVec = GeometryInterop[];
9
5
 
10
- export interface CurveInteropHandle {
6
+ export type NodeConnectionInteropVec = NodeConnectionInterop[];
7
+
8
+ export type NodePropertyInteropVec = NodePropertyInterop[];
9
+
10
+ export type NodeInteropVec = NodeInterop[];
11
+
12
+ export type EdgeInteropVec = EdgeInterop[];
13
+
14
+ export interface IndicesInteropHandle {
11
15
  count: number;
12
- vertices: number;
13
- transform: TransformInterop | undefined;
16
+ indices: number;
17
+ }
18
+
19
+ export interface EdgeInterop {
20
+ source: EdgeUnitInterop<OutputId>;
21
+ destination: EdgeUnitInterop<InputId>;
22
+ empty: boolean;
23
+ }
24
+
25
+ export interface EdgeUnitInterop<IO> {
26
+ node: NodeId;
27
+ io: IO;
14
28
  }
15
29
 
16
30
  export interface GeometrySpreadsheet {
@@ -20,75 +34,86 @@ export interface GeometrySpreadsheet {
20
34
  meshes: MeshInterop[];
21
35
  }
22
36
 
23
- export interface GroupInteropHandle {
24
- objects: GeometryInteropHandleProxy[];
25
- }
26
-
27
37
  /**
28
- * Interop struct for node
38
+ * Interop struct for evaluation results
29
39
  */
30
- export interface NodeInterop {
31
- /**
32
- * Node variant
33
- */
34
- variant: string;
35
- /**
36
- * Node identifier
37
- */
38
- id: string;
39
- name: string;
40
- label: string | undefined;
41
- description: string;
42
- /**
43
- * Input parameters
44
- */
45
- inputs: IOInterop[];
46
- /**
47
- * Input variables
48
- */
49
- inputVariables: IOVariables | undefined;
50
- /**
51
- * Output parameters
52
- */
53
- outputs: IOInterop[];
40
+ export interface EvaluationInterop {
54
41
  /**
55
- * Output variables
42
+ * Processed nodes in the latest evaluation
56
43
  */
57
- outputVariables: IOVariables | undefined;
44
+ processedNodes: GraphNodeSet[];
58
45
  /**
59
- * Node properties
46
+ * Geometry identifiers in the latest evaluation
60
47
  */
61
- properties: NodePropertyInterop[];
62
- enabled: boolean;
63
- visible: boolean;
64
- meta: NodeMetaInterop;
48
+ geometryIdentifiers: GeometryIdentifier[];
65
49
  }
66
50
 
67
- export interface NodeEntityInterop {
68
- variant: string;
69
- id: string;
70
- name: string;
71
- label: string | undefined;
72
- inputs: string[];
73
- outputs: string[];
74
- enabled: boolean;
75
- visible: boolean;
51
+
52
+ /// Manually added types due to limitations in the `wasm-bindgen` & `tsify` crates.
53
+ export type ID<T = any> = string;
54
+ export type NodeId = ID;
55
+ export type InputId = ID;
56
+ export type OutputId = ID;
57
+ export type SubGraphId = ID;
58
+ export type SubGraphInstanceId = ID;
59
+
60
+ export type IndexMap<K, V> = Map<K, V>;
61
+
62
+ export type U1 = 1;
63
+ export type U2 = 2;
64
+ export type U3 = 3;
65
+
66
+ /// Define vector & point types with FixedLengthArray
67
+ type BuildTuple<L extends number, T, R extends any[] = []> = R['length'] extends L ? R : BuildTuple<L, T, [T, ...R]>;
68
+ type FixedLengthArray<T, L extends number> = BuildTuple<L, T>;
69
+ export type OPoint<T, D extends number> = FixedLengthArray<T, D>;
70
+ export type OVector<T, D extends number> = FixedLengthArray<T, D>;
71
+ export type Point<T, D extends number> = OPoint<T, D>;
72
+ export type SVector<T, D extends number> = OVector<T, D>;
73
+ export type Point2<T = number> = Point<T, 2>;
74
+ export type Vector2<T = number> = SVector<T, 2>;
75
+ export type Point3<T = number> = Point<T, 3>;
76
+ export type Vector3<T = number> = SVector<T, 3>;
77
+ export type Point4<T = number> = Point<T, 4>;
78
+ export type Vector4<T = number> = SVector<T, 4>;
79
+ export type Transform3<T = number> = FixedLengthArray<T, 16>;
80
+
81
+
82
+ export interface DataTreeInterop {
83
+ branches: IndexMap<string, string[]>;
84
+ }
85
+
86
+ export interface DataTreeFormatInterop {
87
+ outputs: IndexMap<string, string>;
76
88
  }
77
89
 
78
90
  /**
79
- * Interop struct for node meta
91
+ * Interop struct for transform
92
+ * Represents a 4x4 matrix as a 16-element array
80
93
  */
81
- export interface NodeMetaInterop {
82
- /**
83
- * Error message
84
- */
85
- error: string | undefined;
86
- /**
87
- * Node\' output has geometry or not
88
- */
89
- hasGeometry: boolean;
94
+ export type TransformInterop = number[];
95
+
96
+ export interface MeshInteropHandle {
97
+ count: number;
98
+ vertices: number;
99
+ normals: number;
100
+ indices: IndicesInteropHandle | undefined;
101
+ transform: TransformInterop | undefined;
90
102
  }
91
103
 
104
+ /**
105
+ * Vector display handle for wasm interop
106
+ * stride = 6 (3 for point, 3 for vector)
107
+ */
108
+ export interface VectorDisplayHandle {
109
+ count: number;
110
+ vertices: number;
111
+ }
112
+
113
+ export type DisplayProxyHandle = { variant: "Vector"; data: VectorDisplayHandle };
114
+
115
+ export type GeometryInteropHandleProxy = { variant: "Mesh"; data: MeshInteropHandle } | { variant: "Curve"; data: CurveInteropHandle } | { variant: "Group"; data: GroupInteropHandle };
116
+
92
117
  export type NodeSectionInterop = { type: "section"; content: NodeFolderInterop } | { type: "item"; content: NodeItemInterop };
93
118
 
94
119
  export interface NodeItemInterop {
@@ -102,31 +127,8 @@ export interface NodeMapInterop {
102
127
  folder: NodeFolderInterop;
103
128
  }
104
129
 
105
- export interface IndicesInteropHandle {
106
- count: number;
107
- indices: number;
108
- }
109
-
110
- /**
111
- * Geometry identifier
112
- */
113
- export interface GeometryIdentifier {
114
- /**
115
- * Parent node ID
116
- */
117
- nodeId?: NodeId;
118
- /**
119
- * Output ID that the geometry is belonged to
120
- */
121
- outputId: OutputId;
122
- /**
123
- * Geometry ID
124
- */
125
- geometryId: ID<GeometryProxy>;
126
- /**
127
- * Transform matrix in interop format
128
- */
129
- transform: TransformInterop;
130
+ export interface GroupInteropHandle {
131
+ objects: GeometryInteropHandleProxy[];
130
132
  }
131
133
 
132
134
  export interface NodeCreationSetting {
@@ -141,14 +143,6 @@ export interface NodeCreationSetting {
141
143
  visible?: boolean;
142
144
  }
143
145
 
144
- export interface MeshInteropHandle {
145
- count: number;
146
- vertices: number;
147
- normals: number;
148
- indices: IndicesInteropHandle | undefined;
149
- transform: TransformInterop | undefined;
150
- }
151
-
152
146
  /**
153
147
  * Interop struct for node property
154
148
  */
@@ -201,76 +195,71 @@ export interface AdaptiveTessellationOptions {
201
195
  maxDepth: number;
202
196
  }
203
197
 
204
- export interface DataTreeInterop {
205
- branches: IndexMap<string, string[]>;
206
- }
207
-
208
- export interface DataTreeFormatInterop {
209
- outputs: IndexMap<string, string>;
198
+ /**
199
+ * Interop struct for node
200
+ */
201
+ export interface NodeInterop {
202
+ /**
203
+ * Node variant
204
+ */
205
+ variant: string;
206
+ /**
207
+ * Node identifier
208
+ */
209
+ id: string;
210
+ name: string;
211
+ label: string | undefined;
212
+ description: string;
213
+ /**
214
+ * Input parameters
215
+ */
216
+ inputs: IOInterop[];
217
+ /**
218
+ * Input variables
219
+ */
220
+ inputVariables: IOVariables | undefined;
221
+ /**
222
+ * Output parameters
223
+ */
224
+ outputs: IOInterop[];
225
+ /**
226
+ * Output variables
227
+ */
228
+ outputVariables: IOVariables | undefined;
229
+ /**
230
+ * Node properties
231
+ */
232
+ properties: NodePropertyInterop[];
233
+ enabled: boolean;
234
+ visible: boolean;
235
+ meta: NodeMetaInterop;
210
236
  }
211
237
 
212
- export type GeometryInteropVec = GeometryInterop[];
213
-
214
- export type NodeConnectionInteropVec = NodeConnectionInterop[];
215
-
216
- export type NodePropertyInteropVec = NodePropertyInterop[];
217
-
218
- export type NodeInteropVec = NodeInterop[];
219
-
220
- export type EdgeInteropVec = EdgeInterop[];
221
-
222
- export interface IOInterop {
238
+ export interface NodeEntityInterop {
239
+ variant: string;
223
240
  id: string;
224
241
  name: string;
225
- accessType: string;
226
- connections: string[];
242
+ label: string | undefined;
243
+ inputs: string[];
244
+ outputs: string[];
245
+ enabled: boolean;
246
+ visible: boolean;
227
247
  }
228
248
 
229
- export type GeometryInteropHandleProxy = { variant: "Mesh"; data: MeshInteropHandle } | { variant: "Curve"; data: CurveInteropHandle } | { variant: "Group"; data: GroupInteropHandle };
230
-
231
249
  /**
232
- * Interop struct for evaluation results
250
+ * Interop struct for node meta
233
251
  */
234
- export interface EvaluationInterop {
252
+ export interface NodeMetaInterop {
235
253
  /**
236
- * Processed nodes in the latest evaluation
254
+ * Error message
237
255
  */
238
- processedNodes: NodeId[];
256
+ error: string | undefined;
239
257
  /**
240
- * Geometry identifiers in the latest evaluation
258
+ * Node\' output has geometry or not
241
259
  */
242
- geometryIdentifiers: GeometryIdentifier[];
260
+ hasGeometry: boolean;
243
261
  }
244
262
 
245
-
246
- /// Manually added types due to limitations in the `wasm-bindgen` & `tsify` crates.
247
- export type ID<T = any> = string;
248
- export type NodeId = ID;
249
- export type InputId = ID;
250
- export type OutputId = ID;
251
-
252
- export type IndexMap<K, V> = Map<K, V>;
253
-
254
- export type U1 = 1;
255
- export type U2 = 2;
256
- export type U3 = 3;
257
-
258
- /// Define vector & point types with FixedLengthArray
259
- type BuildTuple<L extends number, T, R extends any[] = []> = R['length'] extends L ? R : BuildTuple<L, T, [T, ...R]>;
260
- type FixedLengthArray<T, L extends number> = BuildTuple<L, T>;
261
- export type OPoint<T, D extends number> = FixedLengthArray<T, D>;
262
- export type OVector<T, D extends number> = FixedLengthArray<T, D>;
263
- export type Point<T, D extends number> = OPoint<T, D>;
264
- export type SVector<T, D extends number> = OVector<T, D>;
265
- export type Point2<T = number> = Point<T, 2>;
266
- export type Vector2<T = number> = SVector<T, 2>;
267
- export type Point3<T = number> = Point<T, 3>;
268
- export type Vector3<T = number> = SVector<T, 3>;
269
- export type Point4<T = number> = Point<T, 4>;
270
- export type Vector4<T = number> = SVector<T, 4>;
271
- export type Transform3<T = number> = FixedLengthArray<T, 16>;
272
-
273
-
274
263
  export interface NodeConnectionInterop {
275
264
  outputNodeId: string;
276
265
  outputIndex: number;
@@ -279,30 +268,43 @@ export interface NodeConnectionInterop {
279
268
  inputConnectionIndex: number | undefined;
280
269
  }
281
270
 
282
- export interface EdgeInterop {
283
- source: EdgeUnitInterop<OutputId>;
284
- destination: EdgeUnitInterop<InputId>;
285
- empty: boolean;
286
- }
287
-
288
- export interface EdgeUnitInterop<IO> {
289
- node: NodeId;
290
- io: IO;
271
+ export interface IOInterop {
272
+ id: string;
273
+ name: string;
274
+ accessType: AccessTypes;
275
+ connections: string[];
291
276
  }
292
277
 
293
278
  /**
294
- * Defines the dynamics of an IO parameter.
279
+ * Geometry identifier
295
280
  */
296
- export interface IOVariables {
297
- minCount: number;
298
- maxCount: number;
299
- defaultCount: number;
300
- offset: number;
281
+ export interface GeometryIdentifier {
282
+ /**
283
+ * Parent node ID
284
+ */
285
+ graphNodeSet?: GraphNodeSet;
286
+ /**
287
+ * Output ID that the geometry is belonged to
288
+ */
289
+ outputId: OutputId;
290
+ /**
291
+ * Geometry ID
292
+ */
293
+ geometryId: ID<GeometryProxy>;
294
+ /**
295
+ * Transform matrix in interop format
296
+ */
297
+ transform: TransformInterop;
301
298
  }
302
299
 
303
- export interface Prune<T, U> {
304
- connectedComponents: SubGraph<T, U>[];
305
- bypass: Connection[] | undefined;
300
+ /**
301
+ * Curve interop handle for wasm interop
302
+ * stride = 3 (x, y, z)
303
+ */
304
+ export interface CurveInteropHandle {
305
+ count: number;
306
+ vertices: number;
307
+ transform: TransformInterop | undefined;
306
308
  }
307
309
 
308
310
  export interface NodePropertyCategoryValue {
@@ -319,6 +321,29 @@ export interface NodePropertyRangeValue {
319
321
 
320
322
  export type NodePropertyValue = { type: "Number"; content: number } | { type: "Range"; content: NodePropertyRangeValue } | { type: "Range2d"; content: [NodePropertyRangeValue, NodePropertyRangeValue] } | { type: "String"; content: string } | { type: "Bool"; content: boolean } | { type: "NumberVector"; content: number[] } | { type: "Category"; content: NodePropertyCategoryValue } | { type: "Vector2d"; content: [number, number] } | { type: "Vector3d"; content: [number, number, number] } | { type: "Point2d"; content: [number, number] } | { type: "Point3d"; content: [number, number, number] } | { type: "Points2d"; content: [number, number][] } | { type: "Buffer"; content: number[] };
321
323
 
324
+ /**
325
+ * A set of node id and instance id
326
+ */
327
+ export interface GraphNodeSet {
328
+ subGraphIdSet: SubGraphIdSet | undefined;
329
+ nodeId: NodeId;
330
+ }
331
+
332
+ export type AccessTypes = "Item" | "List" | "Tree";
333
+
334
+ export type GraphMappingTypes = "None" | "Bezier" | "Linear" | "Sine";
335
+
336
+ /**
337
+ * Defines the dynamics of an IO parameter.
338
+ */
339
+ export interface IOVariables {
340
+ minCount: number;
341
+ maxCount: number;
342
+ defaultCount: number;
343
+ offset: number;
344
+ editable: boolean;
345
+ }
346
+
322
347
  /**
323
348
  * Graph structure
324
349
  */
@@ -327,22 +352,61 @@ export interface Graph<T, U> {
327
352
  * Nodes in the graph
328
353
  */
329
354
  nodes: IndexMap<NodeId, Node<T, U>>;
355
+ /**
356
+ * nested graphs
357
+ */
358
+ sub_graphs?: IndexMap<SubGraphId, SubGraph<T, U>>;
330
359
  }
331
360
 
332
- export interface SubGraphNode {
333
- sources: NodeId[];
334
- destinations: NodeId[];
361
+ export type GraphVariant = "Root" | { SubGraph: SubGraphId };
362
+
363
+ export interface Prune<T, U> {
364
+ connectedComponents: ConnectedComponents<T, U>[];
365
+ bypass: Connection[] | undefined;
335
366
  }
336
367
 
368
+ /**
369
+ * A sub graph is a graph that is a part of a larger graph
370
+ */
337
371
  export interface SubGraph<T, U> {
338
- nodes: IndexMap<NodeId, SubGraphNode<T, U>>;
372
+ /**
373
+ * The id of the sub graph
374
+ */
375
+ id: SubGraphId;
376
+ /**
377
+ * The graph of the sub graph
378
+ */
379
+ graph: Graph<T, U>;
380
+ /**
381
+ * The instances of the sub graph
382
+ */
383
+ instances: SubGraphInstanceId[];
339
384
  }
340
385
 
341
- export interface IOManager<T, U> {
342
- parameters: IOParameter<T, U>[];
386
+ export interface Connection {
387
+ source: NodeParameter<OutputId>;
388
+ destination: NodeParameter<InputId>;
343
389
  }
344
390
 
345
- export type GraphMappingTypes = "None" | "Bezier" | "Linear" | "Sine";
391
+ export interface NodeParameter<T> {
392
+ nodeId: NodeId;
393
+ parameterId: T;
394
+ parameterIndex: number;
395
+ }
396
+
397
+ export interface ConnectedComponentNode {
398
+ sources: NodeId[];
399
+ destinations: NodeId[];
400
+ }
401
+
402
+ export interface ConnectedComponents<T, U> {
403
+ nodes: IndexMap<NodeId, ConnectedComponentNode<T, U>>;
404
+ }
405
+
406
+ export interface SubGraphIdSet {
407
+ subGraphId: SubGraphId;
408
+ instanceId: SubGraphInstanceId;
409
+ }
346
410
 
347
411
  export interface Node<T> {
348
412
  id: NodeId;
@@ -359,109 +423,59 @@ export type OutputIOManager = IOManager<OutputId, InputId>;
359
423
 
360
424
  export type InputIOManager = IOManager<InputId, OutputId>;
361
425
 
362
- export interface Connection {
363
- source: NodeParameter<OutputId>;
364
- destination: NodeParameter<InputId>;
365
- }
366
-
367
- export interface NodeParameter<T> {
368
- nodeId: NodeId;
369
- parameterId: T;
370
- parameterIndex: number;
371
- }
372
-
373
- /**
374
- * Plane representation with origin, normal, x axis, and y axis
375
- */
376
- export interface Plane {
377
- /**
378
- * Origin coordinate of the plane
379
- */
380
- origin: Point3<number>;
381
- /**
382
- * Normal vector of the plane
383
- */
384
- normal: Vector3<number>;
385
- /**
386
- * X axis of the plane
387
- */
388
- xAxis: Vector3<number>;
389
- /**
390
- * Y axis of the plane
391
- */
392
- yAxis: Vector3<number>;
426
+ export interface IOManager<T, U> {
427
+ parameters: IOParameter<T, U>[];
393
428
  }
394
429
 
395
- /**
396
- * Geometry proxy for various geometry types
397
- */
398
- export type GeometryProxy = { variant: "Curve"; data: CurveProxy } | { variant: "Surface"; data: SurfaceProxy } | { variant: "Brep"; data: Brep } | { variant: "Mesh"; data: Mesh } | { variant: "BBox"; data: OrientedBox } | { variant: "Group"; data: Group };
399
-
400
430
 
401
- export type BoundingBox3D = {
402
- min: Vector3;
403
- max: Vector3;
431
+ export type Triangle3D = {
432
+ a: Point3;
433
+ b: Point3;
434
+ c: Point3;
404
435
  };
405
436
 
406
437
  /**
407
- * Mesh representation with vertices, normals, uv, and index
438
+ * A circular surface
408
439
  */
409
- export interface Mesh {
410
- /**
411
- * Vertices of the mesh
412
- */
413
- vertices: Point3<number>[];
414
- /**
415
- * Normals of the mesh
416
- */
417
- normals: Vector3<number>[] | undefined;
440
+ export interface CircularSurface {
418
441
  /**
419
- * UV coordinates of the mesh
442
+ * The base plane of the circle
420
443
  */
421
- uv: Vector2<number>[] | undefined;
444
+ plane: Plane;
422
445
  /**
423
- * Index of the mesh
446
+ * The radius of the circle
424
447
  */
425
- index: [number, number, number][];
448
+ radius: number;
426
449
  }
427
450
 
428
451
  /**
429
- * Proxy for various curve types
430
- */
431
- export type CurveProxy = { variant: "Line"; data: LineCurve3D } | { variant: "Arc"; data: ArcCurve } | { variant: "Circle"; data: CircleCurve } | { variant: "Ellipse"; data: EllipseCurve } | { variant: "Rectangle"; data: RectangleCurve } | { variant: "Polyline"; data: PolylineCurve3D } | { variant: "NURBS"; data: NurbsCurve };
432
-
433
- /**
434
- * An arc curve in 3D space
452
+ * Interop struct for point cloud data
435
453
  */
436
- export interface ArcCurve {
437
- /**
438
- * The base plane of the arc
439
- */
440
- plane: Plane;
441
- /**
442
- * The start angle of the arc
443
- */
444
- startAngle: number;
454
+ export interface PointCloudInterop {
445
455
  /**
446
- * The end angle of the arc
456
+ * Vertices of the point cloud
447
457
  */
448
- endAngle: number;
458
+ vertices: [number, number, number][];
449
459
  /**
450
- * The radius of the arc
460
+ * Transform matrix of the point cloud
451
461
  */
452
- radius: number;
462
+ transform: Transform3<number>;
453
463
  }
454
464
 
465
+ /**
466
+ * A surface defined by three points
467
+ */
468
+ export type TriangleSurface = Triangle3D;
455
469
 
456
- export type LineCurve3D = {
457
- a: Point3;
458
- b: Point3;
459
- };
470
+ /**
471
+ * Proxy for various surface types
472
+ */
473
+ export type SurfaceProxy = { variant: "Circular"; data: CircularSurface } | { variant: "Triangle"; data: TriangleSurface } | { variant: "Plane"; data: PlaneSurface } | { variant: "NURBS"; data: NurbsSurface } | { variant: "Trimmed"; data: TrimmedSurface };
460
474
 
461
- export interface Domain {
462
- min: number;
463
- max: number;
464
- }
475
+ /**
476
+ * Proxy for various curve types
477
+ */
478
+ export type CurveProxy = { variant: "Line"; data: LineCurve3D } | { variant: "Arc"; data: ArcCurve } | { variant: "Circle"; data: CircleCurve } | { variant: "Ellipse"; data: EllipseCurve } | { variant: "Rectangle"; data: RectangleCurve } | { variant: "Polyline"; data: PolylineCurve3D } | { variant: "NURBS"; data: NurbsCurve };
465
479
 
466
480
  /**
467
481
  * A surface defined by a plane and two domains in x and y directions
@@ -482,26 +496,48 @@ export interface PlaneSurface {
482
496
  }
483
497
 
484
498
 
485
- export type NurbsCurve3D<T = number> = {
486
- control_points: Point4<T>[];
487
- knots: T[];
488
- degree: T;
499
+ export type NurbsSurface3D<T = number> = {
500
+ control_points: Point4<T>[][];
501
+ u_knots: T[];
502
+ v_knots: T[];
503
+ u_degree: T;
504
+ v_degree: T;
489
505
  };
490
506
 
491
507
  /**
492
- * Interop struct for point cloud data
508
+ * Plane representation with origin, normal, x axis, and y axis
493
509
  */
494
- export interface PointCloudInterop {
510
+ export interface Plane {
495
511
  /**
496
- * Vertices of the point cloud
512
+ * Origin coordinate of the plane
497
513
  */
498
- vertices: [number, number, number][];
514
+ origin: Point3<number>;
499
515
  /**
500
- * Transform matrix of the point cloud
516
+ * Normal vector of the plane
501
517
  */
502
- transform: Transform3<number>;
518
+ normal: Vector3<number>;
519
+ /**
520
+ * X axis of the plane
521
+ */
522
+ xAxis: Vector3<number>;
523
+ /**
524
+ * Y axis of the plane
525
+ */
526
+ yAxis: Vector3<number>;
503
527
  }
504
528
 
529
+ /**
530
+ * A NURBS surface
531
+ */
532
+ export type NurbsSurface = NurbsSurface3D<number>;
533
+
534
+
535
+ export type NurbsCurve3D<T = number> = {
536
+ control_points: Point4<T>[];
537
+ knots: T[];
538
+ degree: T;
539
+ };
540
+
505
541
  /**
506
542
  * Interop struct for mesh data
507
543
  */
@@ -529,33 +565,44 @@ export interface MeshInterop {
529
565
  }
530
566
 
531
567
  /**
532
- * Proxy for various surface types
533
- */
534
- export type SurfaceProxy = { variant: "Circular"; data: CircularSurface } | { variant: "Triangle"; data: TriangleSurface } | { variant: "Plane"; data: PlaneSurface } | { variant: "NURBS"; data: NurbsSurface } | { variant: "Trimmed"; data: TrimmedSurface<SurfaceProxy, CurveProxy> };
535
-
536
- export type NurbsCurve = NurbsCurve3D<number>;
537
-
538
- /**
539
- * Interop struct for curve data
568
+ * A rectangle curve in 3D space
540
569
  */
541
- export interface CurveInterop {
570
+ export interface RectangleCurve {
542
571
  /**
543
- * Vertices of the curve
572
+ * The base plane of the rectangle
544
573
  */
545
- vertices: [number, number, number][];
574
+ plane: Plane;
546
575
  /**
547
- * Transform matrix of the curve
576
+ * The domain of the rectangle in the plane x axis
548
577
  */
549
- transform: Transform3<number> | undefined;
578
+ x: Domain;
579
+ /**
580
+ * The domain of the rectangle in the plane y axis
581
+ */
582
+ y: Domain;
550
583
  }
551
584
 
585
+ export type NurbsCurve = NurbsCurve3D<number>;
586
+
552
587
 
553
- export type Triangle3D = {
554
- a: Point3;
555
- b: Point3;
556
- c: Point3;
588
+ export type PolylineCurve2D = {
589
+ points: Point2[];
590
+ };
591
+ export type PolylineCurve3D = {
592
+ points: Point3[];
557
593
  };
558
594
 
595
+
596
+ export type BoundingBox3D = {
597
+ min: Vector3;
598
+ max: Vector3;
599
+ };
600
+
601
+ export interface Domain {
602
+ min: number;
603
+ max: number;
604
+ }
605
+
559
606
  /**
560
607
  * A ellipse curve in 3D space
561
608
  */
@@ -575,37 +622,40 @@ export interface EllipseCurve {
575
622
  }
576
623
 
577
624
  /**
578
- * An oriented box in 3D space
625
+ * A circle curve in 3D space
579
626
  */
580
- export interface OrientedBox {
627
+ export interface CircleCurve {
581
628
  /**
582
- * The plane that the box is aligned to
629
+ * The base plane of the circle
583
630
  */
584
631
  plane: Plane;
585
632
  /**
586
- * The bounding box in the local coordinate system
633
+ * The radius of the circle
587
634
  */
588
- bounds: BoundingBox3D;
635
+ radius: number;
589
636
  }
590
637
 
591
-
592
- export type PolylineCurve3D = {
593
- points: Point3[];
594
- };
595
-
596
638
  /**
597
- * A surface defined by three points
639
+ * An arc curve in 3D space
598
640
  */
599
- export type TriangleSurface = Triangle3D;
600
-
601
-
602
- export type NurbsSurface3D<T = number> = {
603
- control_points: Point4<T>[][];
604
- u_knots: T[];
605
- v_knots: T[];
606
- u_degree: T;
607
- v_degree: T;
608
- };
641
+ export interface ArcCurve {
642
+ /**
643
+ * The base plane of the arc
644
+ */
645
+ plane: Plane;
646
+ /**
647
+ * The start angle of the arc
648
+ */
649
+ startAngle: number;
650
+ /**
651
+ * The end angle of the arc
652
+ */
653
+ endAngle: number;
654
+ /**
655
+ * The radius of the arc
656
+ */
657
+ radius: number;
658
+ }
609
659
 
610
660
  /**
611
661
  * Interop proxy for various geometry types
@@ -613,54 +663,64 @@ export type NurbsSurface3D<T = number> = {
613
663
  export type GeometryInterop = { variant: "Mesh"; data: MeshInterop } | { variant: "Curve"; data: CurveInterop } | { variant: "Point"; data: PointCloudInterop } | { variant: "Plane"; data: Plane } | { variant: "Group"; data: GeometryInterop[] };
614
664
 
615
665
  /**
616
- * A NURBS surface
666
+ * Geometry proxy for various geometry types
617
667
  */
618
- export type NurbsSurface = NurbsSurface3D<number>;
668
+ export type GeometryProxy = { variant: "Curve"; data: CurveProxy } | { variant: "Surface"; data: SurfaceProxy } | { variant: "Brep"; data: Brep } | { variant: "Mesh"; data: Mesh } | { variant: "BBox"; data: OrientedBox } | { variant: "Group"; data: Group };
669
+
670
+
671
+ export type LineCurve3D = {
672
+ a: Point3;
673
+ b: Point3;
674
+ };
619
675
 
620
676
  /**
621
- * A circular surface
677
+ * Interop struct for curve data
622
678
  */
623
- export interface CircularSurface {
679
+ export interface CurveInterop {
624
680
  /**
625
- * The base plane of the circle
681
+ * Vertices of the curve
626
682
  */
627
- plane: Plane;
683
+ vertices: [number, number, number][];
628
684
  /**
629
- * The radius of the circle
685
+ * Transform matrix of the curve
630
686
  */
631
- radius: number;
687
+ transform: Transform3<number> | undefined;
632
688
  }
633
689
 
634
690
  /**
635
- * A rectangle curve in 3D space
691
+ * An oriented box in 3D space
636
692
  */
637
- export interface RectangleCurve {
693
+ export interface OrientedBox {
638
694
  /**
639
- * The base plane of the rectangle
695
+ * The plane that the box is aligned to
640
696
  */
641
697
  plane: Plane;
642
698
  /**
643
- * The domain of the rectangle in the plane x axis
644
- */
645
- x: Domain;
646
- /**
647
- * The domain of the rectangle in the plane y axis
699
+ * The bounding box in the local coordinate system
648
700
  */
649
- y: Domain;
701
+ bounds: BoundingBox3D;
650
702
  }
651
703
 
652
704
  /**
653
- * A circle curve in 3D space
705
+ * Mesh representation with vertices, normals, uv, and index
654
706
  */
655
- export interface CircleCurve {
707
+ export interface Mesh {
656
708
  /**
657
- * The base plane of the circle
709
+ * Vertices of the mesh
658
710
  */
659
- plane: Plane;
711
+ vertices: Point3<number>[];
660
712
  /**
661
- * The radius of the circle
713
+ * Normals of the mesh
662
714
  */
663
- radius: number;
715
+ normals: Vector3<number>[] | undefined;
716
+ /**
717
+ * UV coordinates of the mesh
718
+ */
719
+ uv: Vector2<number>[] | undefined;
720
+ /**
721
+ * Index of the mesh
722
+ */
723
+ index: [number, number, number][];
664
724
  }
665
725
 
666
726
  /**
@@ -692,11 +752,11 @@ export class Modular {
692
752
  /**
693
753
  * Get all nodes in the graph
694
754
  */
695
- getNodes(): (NodeInterop)[];
755
+ getNodes(): NodeInterop[];
696
756
  /**
697
757
  * Change a node property with node id and property
698
758
  */
699
- changeNodeProperty(node_id: string, prop: NodePropertyInterop): boolean;
759
+ changeNodeProperty(node_id: string, prop: NodePropertyInterop, graph_id?: string | null): boolean;
700
760
  /**
701
761
  * Find a geometry by its identifier
702
762
  */
@@ -708,7 +768,7 @@ export class Modular {
708
768
  /**
709
769
  * Update the tessellation options to modify the tessellation quality for geometry interoperability
710
770
  */
711
- updateTessellationOptions(options?: AdaptiveTessellationOptions): void;
771
+ updateTessellationOptions(options?: AdaptiveTessellationOptions | null): void;
712
772
  }
713
773
 
714
774
  export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
@@ -722,7 +782,7 @@ export interface InitOutput {
722
782
  readonly modular_clearGraph: (a: number) => void;
723
783
  readonly modular_evaluate: (a: number) => any;
724
784
  readonly modular_getNodes: (a: number) => [number, number];
725
- readonly modular_changeNodeProperty: (a: number, b: number, c: number, d: any) => number;
785
+ readonly modular_changeNodeProperty: (a: number, b: number, c: number, d: any, e: number, f: number) => number;
726
786
  readonly modular_findGeometryById: (a: number, b: any) => any;
727
787
  readonly modular_findGeometryInteropById: (a: number, b: any) => any;
728
788
  readonly modular_updateTessellationOptions: (a: number, b: number) => void;
@@ -736,8 +796,8 @@ export interface InitOutput {
736
796
  readonly __externref_table_dealloc: (a: number) => void;
737
797
  readonly __externref_drop_slice: (a: number, b: number) => void;
738
798
  readonly __wbindgen_free: (a: number, b: number, c: number) => void;
739
- readonly closure730_externref_shim: (a: number, b: number, c: any) => void;
740
- readonly closure3354_externref_shim: (a: number, b: number, c: any, d: any) => void;
799
+ readonly closure774_externref_shim: (a: number, b: number, c: any) => void;
800
+ readonly closure3434_externref_shim: (a: number, b: number, c: any, d: any) => void;
741
801
  readonly __wbindgen_start: () => void;
742
802
  }
743
803
 
package/index.js CHANGED
@@ -220,11 +220,11 @@ export function do_nothing_just_tell_wasm_bindgen_to_generate_types() {
220
220
  }
221
221
 
222
222
  function __wbg_adapter_52(arg0, arg1, arg2) {
223
- wasm.closure730_externref_shim(arg0, arg1, arg2);
223
+ wasm.closure774_externref_shim(arg0, arg1, arg2);
224
224
  }
225
225
 
226
226
  function __wbg_adapter_142(arg0, arg1, arg2, arg3) {
227
- wasm.closure3354_externref_shim(arg0, arg1, arg2, arg3);
227
+ wasm.closure3434_externref_shim(arg0, arg1, arg2, arg3);
228
228
  }
229
229
 
230
230
  const ModularFinalization = (typeof FinalizationRegistry === 'undefined')
@@ -298,7 +298,7 @@ export class Modular {
298
298
  }
299
299
  /**
300
300
  * Get all nodes in the graph
301
- * @returns {(NodeInterop)[]}
301
+ * @returns {NodeInterop[]}
302
302
  */
303
303
  getNodes() {
304
304
  const ret = wasm.modular_getNodes(this.__wbg_ptr);
@@ -310,12 +310,15 @@ export class Modular {
310
310
  * Change a node property with node id and property
311
311
  * @param {string} node_id
312
312
  * @param {NodePropertyInterop} prop
313
+ * @param {string | null} [graph_id]
313
314
  * @returns {boolean}
314
315
  */
315
- changeNodeProperty(node_id, prop) {
316
+ changeNodeProperty(node_id, prop, graph_id) {
316
317
  const ptr0 = passStringToWasm0(node_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
317
318
  const len0 = WASM_VECTOR_LEN;
318
- const ret = wasm.modular_changeNodeProperty(this.__wbg_ptr, ptr0, len0, prop);
319
+ var ptr1 = isLikeNone(graph_id) ? 0 : passStringToWasm0(graph_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
320
+ var len1 = WASM_VECTOR_LEN;
321
+ const ret = wasm.modular_changeNodeProperty(this.__wbg_ptr, ptr0, len0, prop, ptr1, len1);
319
322
  return ret !== 0;
320
323
  }
321
324
  /**
@@ -338,7 +341,7 @@ export class Modular {
338
341
  }
339
342
  /**
340
343
  * Update the tessellation options to modify the tessellation quality for geometry interoperability
341
- * @param {AdaptiveTessellationOptions | undefined} [options]
344
+ * @param {AdaptiveTessellationOptions | null} [options]
342
345
  */
343
346
  updateTessellationOptions(options) {
344
347
  wasm.modular_updateTessellationOptions(this.__wbg_ptr, isLikeNone(options) ? 0 : addToExternrefTable0(options));
@@ -386,62 +389,54 @@ function __wbg_get_imports() {
386
389
  getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
387
390
  getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
388
391
  };
389
- imports.wbg.__wbg_buffer_6e1d53ff183194fc = function(arg0) {
392
+ imports.wbg.__wbg_buffer_609cc3eee51ed158 = function(arg0) {
390
393
  const ret = arg0.buffer;
391
394
  return ret;
392
395
  };
393
- imports.wbg.__wbg_call_0411c0c3c424db9a = function() { return handleError(function (arg0, arg1, arg2) {
394
- const ret = arg0.call(arg1, arg2);
396
+ imports.wbg.__wbg_call_672a4d21634d4a24 = function() { return handleError(function (arg0, arg1) {
397
+ const ret = arg0.call(arg1);
395
398
  return ret;
396
399
  }, arguments) };
397
- imports.wbg.__wbg_call_3114932863209ca6 = function() { return handleError(function (arg0, arg1) {
398
- const ret = arg0.call(arg1);
400
+ imports.wbg.__wbg_call_7cccdd69e0791ae2 = function() { return handleError(function (arg0, arg1, arg2) {
401
+ const ret = arg0.call(arg1, arg2);
399
402
  return ret;
400
403
  }, arguments) };
401
404
  imports.wbg.__wbg_crypto_ed58b8e10a292839 = function(arg0) {
402
405
  const ret = arg0.crypto;
403
406
  return ret;
404
407
  };
405
- imports.wbg.__wbg_done_adfd3f40364def50 = function(arg0) {
408
+ imports.wbg.__wbg_done_769e5ede4b31c67b = function(arg0) {
406
409
  const ret = arg0.done;
407
410
  return ret;
408
411
  };
409
- imports.wbg.__wbg_entries_ce82e236f8300a53 = function(arg0) {
412
+ imports.wbg.__wbg_entries_3265d4158b33e5dc = function(arg0) {
410
413
  const ret = Object.entries(arg0);
411
414
  return ret;
412
415
  };
413
416
  imports.wbg.__wbg_getRandomValues_bcb4912f16000dc4 = function() { return handleError(function (arg0, arg1) {
414
417
  arg0.getRandomValues(arg1);
415
418
  }, arguments) };
416
- imports.wbg.__wbg_getTime_701326a7a826723f = function(arg0) {
419
+ imports.wbg.__wbg_getTime_46267b1c24877e30 = function(arg0) {
417
420
  const ret = arg0.getTime();
418
421
  return ret;
419
422
  };
420
- imports.wbg.__wbg_getTimezoneOffset_e564c972d25502d1 = function(arg0) {
423
+ imports.wbg.__wbg_getTimezoneOffset_6b5752021c499c47 = function(arg0) {
421
424
  const ret = arg0.getTimezoneOffset();
422
425
  return ret;
423
426
  };
424
- imports.wbg.__wbg_get_68aa371864aa301a = function(arg0, arg1) {
425
- const ret = arg0[arg1 >>> 0];
426
- return ret;
427
- };
428
- imports.wbg.__wbg_get_92a4780a3beb5fe9 = function() { return handleError(function (arg0, arg1) {
427
+ imports.wbg.__wbg_get_67b2ba62fc30de12 = function() { return handleError(function (arg0, arg1) {
429
428
  const ret = Reflect.get(arg0, arg1);
430
429
  return ret;
431
430
  }, arguments) };
431
+ imports.wbg.__wbg_get_b9b93047fe3cf45b = function(arg0, arg1) {
432
+ const ret = arg0[arg1 >>> 0];
433
+ return ret;
434
+ };
432
435
  imports.wbg.__wbg_getwithrefkey_1dc361bd10053bfe = function(arg0, arg1) {
433
436
  const ret = arg0[arg1];
434
437
  return ret;
435
438
  };
436
- imports.wbg.__wbg_globalThis_1e2ac1d6eee845b3 = function() { return handleError(function () {
437
- const ret = globalThis.globalThis;
438
- return ret;
439
- }, arguments) };
440
- imports.wbg.__wbg_global_f25a574ae080367c = function() { return handleError(function () {
441
- const ret = global.global;
442
- return ret;
443
- }, arguments) };
444
- imports.wbg.__wbg_instanceof_ArrayBuffer_435fcead703e2827 = function(arg0) {
439
+ imports.wbg.__wbg_instanceof_ArrayBuffer_e14585432e3737fc = function(arg0) {
445
440
  let result;
446
441
  try {
447
442
  result = arg0 instanceof ArrayBuffer;
@@ -451,7 +446,7 @@ function __wbg_get_imports() {
451
446
  const ret = result;
452
447
  return ret;
453
448
  };
454
- imports.wbg.__wbg_instanceof_Map_77fd223783fe0068 = function(arg0) {
449
+ imports.wbg.__wbg_instanceof_Map_f3469ce2244d2430 = function(arg0) {
455
450
  let result;
456
451
  try {
457
452
  result = arg0 instanceof Map;
@@ -461,7 +456,7 @@ function __wbg_get_imports() {
461
456
  const ret = result;
462
457
  return ret;
463
458
  };
464
- imports.wbg.__wbg_instanceof_Uint8Array_9b67296cab48238f = function(arg0) {
459
+ imports.wbg.__wbg_instanceof_Uint8Array_17156bcf118086a9 = function(arg0) {
465
460
  let result;
466
461
  try {
467
462
  result = arg0 instanceof Uint8Array;
@@ -471,23 +466,23 @@ function __wbg_get_imports() {
471
466
  const ret = result;
472
467
  return ret;
473
468
  };
474
- imports.wbg.__wbg_isArray_fcd559a3bcfde1e9 = function(arg0) {
469
+ imports.wbg.__wbg_isArray_a1eab7e0d067391b = function(arg0) {
475
470
  const ret = Array.isArray(arg0);
476
471
  return ret;
477
472
  };
478
- imports.wbg.__wbg_isSafeInteger_4de146aa53f6e470 = function(arg0) {
473
+ imports.wbg.__wbg_isSafeInteger_343e2beeeece1bb0 = function(arg0) {
479
474
  const ret = Number.isSafeInteger(arg0);
480
475
  return ret;
481
476
  };
482
- imports.wbg.__wbg_iterator_7a20c20ce22add0f = function() {
477
+ imports.wbg.__wbg_iterator_9a24c88df860dc65 = function() {
483
478
  const ret = Symbol.iterator;
484
479
  return ret;
485
480
  };
486
- imports.wbg.__wbg_length_2e63ba34c4121df5 = function(arg0) {
481
+ imports.wbg.__wbg_length_a446193dc22c12f8 = function(arg0) {
487
482
  const ret = arg0.length;
488
483
  return ret;
489
484
  };
490
- imports.wbg.__wbg_length_e74df4881604f1d9 = function(arg0) {
485
+ imports.wbg.__wbg_length_e2d2a49132c1b256 = function(arg0) {
491
486
  const ret = arg0.length;
492
487
  return ret;
493
488
  };
@@ -495,19 +490,11 @@ function __wbg_get_imports() {
495
490
  const ret = arg0.msCrypto;
496
491
  return ret;
497
492
  };
498
- imports.wbg.__wbg_new0_207938728f108bf6 = function() {
493
+ imports.wbg.__wbg_new0_f788a2397c7ca929 = function() {
499
494
  const ret = new Date();
500
495
  return ret;
501
496
  };
502
- imports.wbg.__wbg_new_076cac58bb698dd4 = function() {
503
- const ret = new Object();
504
- return ret;
505
- };
506
- imports.wbg.__wbg_new_0c28e72025e00594 = function() {
507
- const ret = new Array();
508
- return ret;
509
- };
510
- imports.wbg.__wbg_new_1e8ca58d170d6ad0 = function(arg0, arg1) {
497
+ imports.wbg.__wbg_new_23a2665fac83c611 = function(arg0, arg1) {
511
498
  try {
512
499
  var state0 = {a: arg0, b: arg1};
513
500
  var cb0 = (arg0, arg1) => {
@@ -525,47 +512,55 @@ function __wbg_get_imports() {
525
512
  state0.a = state0.b = 0;
526
513
  }
527
514
  };
528
- imports.wbg.__wbg_new_23362fa370a0a372 = function(arg0) {
529
- const ret = new Uint8Array(arg0);
515
+ imports.wbg.__wbg_new_31a97dac4f10fab7 = function(arg0) {
516
+ const ret = new Date(arg0);
530
517
  return ret;
531
518
  };
532
- imports.wbg.__wbg_new_2f2bde6bba4a5707 = function(arg0) {
533
- const ret = new Date(arg0);
519
+ imports.wbg.__wbg_new_405e22f390576ce2 = function() {
520
+ const ret = new Object();
534
521
  return ret;
535
522
  };
536
- imports.wbg.__wbg_new_3f616ed16821b4c5 = function() {
523
+ imports.wbg.__wbg_new_5e0be73521bc8c17 = function() {
537
524
  const ret = new Map();
538
525
  return ret;
539
526
  };
540
- imports.wbg.__wbg_newnoargs_19a249f4eceaaac3 = function(arg0, arg1) {
527
+ imports.wbg.__wbg_new_78feb108b6472713 = function() {
528
+ const ret = new Array();
529
+ return ret;
530
+ };
531
+ imports.wbg.__wbg_new_a12002a7f91c75be = function(arg0) {
532
+ const ret = new Uint8Array(arg0);
533
+ return ret;
534
+ };
535
+ imports.wbg.__wbg_newnoargs_105ed471475aaf50 = function(arg0, arg1) {
541
536
  const ret = new Function(getStringFromWasm0(arg0, arg1));
542
537
  return ret;
543
538
  };
544
- imports.wbg.__wbg_newwithbyteoffsetandlength_ee8def7000b7b2be = function(arg0, arg1, arg2) {
539
+ imports.wbg.__wbg_newwithbyteoffsetandlength_d97e637ebe145a9a = function(arg0, arg1, arg2) {
545
540
  const ret = new Uint8Array(arg0, arg1 >>> 0, arg2 >>> 0);
546
541
  return ret;
547
542
  };
548
- imports.wbg.__wbg_newwithlength_91de49dea5643c87 = function(arg0) {
543
+ imports.wbg.__wbg_newwithlength_a381634e90c276d4 = function(arg0) {
549
544
  const ret = new Uint8Array(arg0 >>> 0);
550
545
  return ret;
551
546
  };
552
- imports.wbg.__wbg_newwithyearmonthdayhrminsec_31d5cba1a2e85b57 = function(arg0, arg1, arg2, arg3, arg4, arg5) {
547
+ imports.wbg.__wbg_newwithyearmonthdayhrminsec_72c204d952ef4426 = function(arg0, arg1, arg2, arg3, arg4, arg5) {
553
548
  const ret = new Date(arg0 >>> 0, arg1, arg2, arg3, arg4, arg5);
554
549
  return ret;
555
550
  };
556
- imports.wbg.__wbg_next_c591766a7286b02a = function() { return handleError(function (arg0) {
557
- const ret = arg0.next();
558
- return ret;
559
- }, arguments) };
560
- imports.wbg.__wbg_next_f387ecc56a94ba00 = function(arg0) {
551
+ imports.wbg.__wbg_next_25feadfc0913fea9 = function(arg0) {
561
552
  const ret = arg0.next;
562
553
  return ret;
563
554
  };
555
+ imports.wbg.__wbg_next_6574e1a8a62d1055 = function() { return handleError(function (arg0) {
556
+ const ret = arg0.next();
557
+ return ret;
558
+ }, arguments) };
564
559
  imports.wbg.__wbg_node_02999533c4ea02e3 = function(arg0) {
565
560
  const ret = arg0.node;
566
561
  return ret;
567
562
  };
568
- imports.wbg.__wbg_now_5b0cbad8de553ec4 = function(arg0) {
563
+ imports.wbg.__wbg_now_d18023d54d4e5500 = function(arg0) {
569
564
  const ret = arg0.now();
570
565
  return ret;
571
566
  };
@@ -573,13 +568,13 @@ function __wbg_get_imports() {
573
568
  const ret = arg0.process;
574
569
  return ret;
575
570
  };
576
- imports.wbg.__wbg_queueMicrotask_3d422e1ba49c2500 = function(arg0) {
571
+ imports.wbg.__wbg_queueMicrotask_97d92b4fcc8a61c5 = function(arg0) {
572
+ queueMicrotask(arg0);
573
+ };
574
+ imports.wbg.__wbg_queueMicrotask_d3219def82552485 = function(arg0) {
577
575
  const ret = arg0.queueMicrotask;
578
576
  return ret;
579
577
  };
580
- imports.wbg.__wbg_queueMicrotask_f301663ccadbb7d0 = function(arg0) {
581
- queueMicrotask(arg0);
582
- };
583
578
  imports.wbg.__wbg_randomFillSync_ab2cfe79ebbf2740 = function() { return handleError(function (arg0, arg1) {
584
579
  arg0.randomFillSync(arg1);
585
580
  }, arguments) };
@@ -587,36 +582,48 @@ function __wbg_get_imports() {
587
582
  const ret = module.require;
588
583
  return ret;
589
584
  }, arguments) };
590
- imports.wbg.__wbg_resolve_6a311e8bb26423ab = function(arg0) {
585
+ imports.wbg.__wbg_resolve_4851785c9c5f573d = function(arg0) {
591
586
  const ret = Promise.resolve(arg0);
592
587
  return ret;
593
588
  };
594
- imports.wbg.__wbg_self_ac4343e4047b83cc = function() { return handleError(function () {
595
- const ret = self.self;
596
- return ret;
597
- }, arguments) };
598
- imports.wbg.__wbg_set_1d975b42d95fd6c6 = function(arg0, arg1, arg2) {
599
- const ret = arg0.set(arg1, arg2);
600
- return ret;
589
+ imports.wbg.__wbg_set_37837023f3d740e8 = function(arg0, arg1, arg2) {
590
+ arg0[arg1 >>> 0] = arg2;
601
591
  };
602
592
  imports.wbg.__wbg_set_3f1d0b984ed272ed = function(arg0, arg1, arg2) {
603
593
  arg0[arg1] = arg2;
604
594
  };
605
- imports.wbg.__wbg_set_7b70226104a82921 = function(arg0, arg1, arg2) {
595
+ imports.wbg.__wbg_set_65595bdd868b3009 = function(arg0, arg1, arg2) {
606
596
  arg0.set(arg1, arg2 >>> 0);
607
597
  };
608
- imports.wbg.__wbg_set_a1fb6291729caffb = function(arg0, arg1, arg2) {
609
- arg0[arg1 >>> 0] = arg2;
598
+ imports.wbg.__wbg_set_8fc6bf8a5b1071d1 = function(arg0, arg1, arg2) {
599
+ const ret = arg0.set(arg1, arg2);
600
+ return ret;
610
601
  };
611
- imports.wbg.__wbg_subarray_b4e9772c34a7f5ba = function(arg0, arg1, arg2) {
602
+ imports.wbg.__wbg_static_accessor_GLOBAL_88a902d13a557d07 = function() {
603
+ const ret = typeof global === 'undefined' ? null : global;
604
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
605
+ };
606
+ imports.wbg.__wbg_static_accessor_GLOBAL_THIS_56578be7e9f832b0 = function() {
607
+ const ret = typeof globalThis === 'undefined' ? null : globalThis;
608
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
609
+ };
610
+ imports.wbg.__wbg_static_accessor_SELF_37c5d418e4bf5819 = function() {
611
+ const ret = typeof self === 'undefined' ? null : self;
612
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
613
+ };
614
+ imports.wbg.__wbg_static_accessor_WINDOW_5de37043a91a9c40 = function() {
615
+ const ret = typeof window === 'undefined' ? null : window;
616
+ return isLikeNone(ret) ? 0 : addToExternrefTable0(ret);
617
+ };
618
+ imports.wbg.__wbg_subarray_aa9065fa9dc5df96 = function(arg0, arg1, arg2) {
612
619
  const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
613
620
  return ret;
614
621
  };
615
- imports.wbg.__wbg_then_5c6469c1e1da9e59 = function(arg0, arg1) {
622
+ imports.wbg.__wbg_then_44b73946d2fb3e7d = function(arg0, arg1) {
616
623
  const ret = arg0.then(arg1);
617
624
  return ret;
618
625
  };
619
- imports.wbg.__wbg_value_30db1d77772f3236 = function(arg0) {
626
+ imports.wbg.__wbg_value_cd1ffa7b1ab794f1 = function(arg0) {
620
627
  const ret = arg0.value;
621
628
  return ret;
622
629
  };
@@ -624,10 +631,6 @@ function __wbg_get_imports() {
624
631
  const ret = arg0.versions;
625
632
  return ret;
626
633
  };
627
- imports.wbg.__wbg_window_1a23defd102c72f4 = function() { return handleError(function () {
628
- const ret = window.window;
629
- return ret;
630
- }, arguments) };
631
634
  imports.wbg.__wbindgen_as_number = function(arg0) {
632
635
  const ret = +arg0;
633
636
  return ret;
@@ -660,8 +663,8 @@ function __wbg_get_imports() {
660
663
  const ret = false;
661
664
  return ret;
662
665
  };
663
- imports.wbg.__wbindgen_closure_wrapper3166 = function(arg0, arg1, arg2) {
664
- const ret = makeMutClosure(arg0, arg1, 731, __wbg_adapter_52);
666
+ imports.wbg.__wbindgen_closure_wrapper3355 = function(arg0, arg1, arg2) {
667
+ const ret = makeMutClosure(arg0, arg1, 775, __wbg_adapter_52);
665
668
  return ret;
666
669
  };
667
670
  imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
package/index_bg.wasm CHANGED
Binary file
package/package.json CHANGED
@@ -5,7 +5,7 @@
5
5
  "Masatatsu Nakamura <masatatsu.nakamura@gmail.com"
6
6
  ],
7
7
  "description": "Modular is a module project designed to import node graphs created in Nodi in JSON format, enabling the extraction of geometric data generated based on the node graph structure.",
8
- "version": "0.0.7",
8
+ "version": "0.0.9",
9
9
  "license": "MIT",
10
10
  "repository": {
11
11
  "type": "git",