@itwin/core-geometry 4.4.0-dev.3 → 4.4.0-dev.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/topology/Graph.d.ts +19 -9
- package/lib/cjs/topology/Graph.d.ts.map +1 -1
- package/lib/cjs/topology/Graph.js +19 -9
- package/lib/cjs/topology/Graph.js.map +1 -1
- package/lib/cjs/topology/HalfEdgeGraphValidation.d.ts +23 -18
- package/lib/cjs/topology/HalfEdgeGraphValidation.d.ts.map +1 -1
- package/lib/cjs/topology/HalfEdgeGraphValidation.js +23 -18
- package/lib/cjs/topology/HalfEdgeGraphValidation.js.map +1 -1
- package/lib/cjs/topology/HalfEdgeNodeXYZUV.d.ts +17 -10
- package/lib/cjs/topology/HalfEdgeNodeXYZUV.d.ts.map +1 -1
- package/lib/cjs/topology/HalfEdgeNodeXYZUV.js +38 -17
- package/lib/cjs/topology/HalfEdgeNodeXYZUV.js.map +1 -1
- package/lib/esm/topology/Graph.d.ts +19 -9
- package/lib/esm/topology/Graph.d.ts.map +1 -1
- package/lib/esm/topology/Graph.js +19 -9
- package/lib/esm/topology/Graph.js.map +1 -1
- package/lib/esm/topology/HalfEdgeGraphValidation.d.ts +23 -18
- package/lib/esm/topology/HalfEdgeGraphValidation.d.ts.map +1 -1
- package/lib/esm/topology/HalfEdgeGraphValidation.js +23 -18
- package/lib/esm/topology/HalfEdgeGraphValidation.js.map +1 -1
- package/lib/esm/topology/HalfEdgeNodeXYZUV.d.ts +17 -10
- package/lib/esm/topology/HalfEdgeNodeXYZUV.d.ts.map +1 -1
- package/lib/esm/topology/HalfEdgeNodeXYZUV.js +38 -17
- package/lib/esm/topology/HalfEdgeNodeXYZUV.js.map +1 -1
- package/package.json +5 -5
|
@@ -6,8 +6,9 @@
|
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
7
|
exports.HalfEdgeMaskValidation = exports.HalfEdgePointerInspector = void 0;
|
|
8
8
|
// Search services for HalfEdgeGraph
|
|
9
|
-
/**
|
|
10
|
-
*
|
|
9
|
+
/**
|
|
10
|
+
* HalfEdgePointerInspector has methods to check HalfEdge objects for pointer errors.
|
|
11
|
+
* * For a one-step test of the whole graph.
|
|
11
12
|
*/
|
|
12
13
|
class HalfEdgePointerInspector {
|
|
13
14
|
constructor() {
|
|
@@ -19,7 +20,7 @@ class HalfEdgePointerInspector {
|
|
|
19
20
|
this.numTested = 0;
|
|
20
21
|
this.numWithMatchedEdgeMate = 0;
|
|
21
22
|
}
|
|
22
|
-
/** Clear all counts */
|
|
23
|
+
/** Clear all counts. */
|
|
23
24
|
clearCounts() {
|
|
24
25
|
this.numUndefinedEdgeMate = 0;
|
|
25
26
|
this.numUndefinedFP = 0;
|
|
@@ -29,7 +30,7 @@ class HalfEdgePointerInspector {
|
|
|
29
30
|
this.numWithMatchedEdgeMate = 0;
|
|
30
31
|
this.numTested = 0;
|
|
31
32
|
}
|
|
32
|
-
/** Inspect a single half edge.
|
|
33
|
+
/** Inspect a single half edge. Increment counters according to the half edge's pointers. */
|
|
33
34
|
inspectHalfEdge(he) {
|
|
34
35
|
this.numTested++;
|
|
35
36
|
if (he.facePredecessor === undefined)
|
|
@@ -47,10 +48,11 @@ class HalfEdgePointerInspector {
|
|
|
47
48
|
else
|
|
48
49
|
this.numMatePairError++;
|
|
49
50
|
}
|
|
50
|
-
/**
|
|
51
|
+
/**
|
|
52
|
+
* Return true if all pointer pairings are correct for a closed half edge graph (with no boundary):
|
|
51
53
|
* * For each he: `he.edgeMate.edgeMate === he`
|
|
52
|
-
* * For each he: `he.faceSuccessor.facePredecessor
|
|
53
|
-
* * For each he: `he.facePredecessor.faceSuccessor
|
|
54
|
+
* * For each he: `he.faceSuccessor.facePredecessor === he`
|
|
55
|
+
* * For each he: `he.facePredecessor.faceSuccessor === he`
|
|
54
56
|
*/
|
|
55
57
|
get isValidClosedHalfEdgeGraph() {
|
|
56
58
|
return this.numWithMatchedEdgeMate === this.numTested
|
|
@@ -59,10 +61,11 @@ class HalfEdgePointerInspector {
|
|
|
59
61
|
&& this.numFSFPError === 0
|
|
60
62
|
&& this.numMatePairError === 0;
|
|
61
63
|
}
|
|
62
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* Return true if all pointer pairings are correct for a half edge graph with possible boundary:
|
|
63
66
|
* * For each he: `he.edgeMate.edgeMate === he`
|
|
64
|
-
* * For each he: `he.faceSuccessor.facePredecessor
|
|
65
|
-
* * For each he: `he.facePredecessor.faceSuccessor
|
|
67
|
+
* * For each he: `he.faceSuccessor.facePredecessor === he`
|
|
68
|
+
* * For each he: `he.facePredecessor.faceSuccessor === he`
|
|
66
69
|
*/
|
|
67
70
|
get isValidHalfEdgeGraphAllowRaggedBoundary() {
|
|
68
71
|
return this.numWithMatchedEdgeMate + this.numUndefinedEdgeMate === this.numTested
|
|
@@ -71,17 +74,19 @@ class HalfEdgePointerInspector {
|
|
|
71
74
|
&& this.numFSFPError === 0
|
|
72
75
|
&& this.numMatePairError === 0;
|
|
73
76
|
}
|
|
74
|
-
/**
|
|
75
|
-
*
|
|
77
|
+
/**
|
|
78
|
+
* Inspect all half edges of graph.
|
|
79
|
+
* * All pointer counts are left in member vars for later inspection.
|
|
76
80
|
*/
|
|
77
81
|
inspectHalfEdges(graph) {
|
|
78
82
|
this.clearCounts();
|
|
79
83
|
for (const he of graph.allHalfEdges)
|
|
80
84
|
this.inspectHalfEdge(he);
|
|
81
85
|
}
|
|
82
|
-
/**
|
|
83
|
-
*
|
|
84
|
-
* @
|
|
86
|
+
/**
|
|
87
|
+
* Inspect a graph's pointer properties.
|
|
88
|
+
* @param expectAllMates true for "complete" graph.
|
|
89
|
+
* @returns true if all pointers are valid.
|
|
85
90
|
*/
|
|
86
91
|
static inspectGraph(graph, expectAllMates) {
|
|
87
92
|
const inspector = new HalfEdgePointerInspector();
|
|
@@ -92,13 +97,13 @@ class HalfEdgePointerInspector {
|
|
|
92
97
|
}
|
|
93
98
|
}
|
|
94
99
|
exports.HalfEdgePointerInspector = HalfEdgePointerInspector;
|
|
95
|
-
/**
|
|
100
|
+
/** Static methods to inspect mask consistency properties in HalfEdgeGraph. */
|
|
96
101
|
class HalfEdgeMaskValidation {
|
|
97
102
|
/**
|
|
98
103
|
* Test if a mask is used consistently around faces.
|
|
99
|
-
* * At the low level, there is no actual traversal around faces.
|
|
104
|
+
* * At the low level, there is no actual traversal around faces. It is only necessary to verify that the mask
|
|
105
|
+
* matches for each HalfEdge and its faceSuccessor.
|
|
100
106
|
* @returns Return true if mask is "all or nothing around all faces"
|
|
101
|
-
*
|
|
102
107
|
*/
|
|
103
108
|
static isMaskConsistentAroundAllFaces(graph, mask) {
|
|
104
109
|
for (const he of graph.allHalfEdges) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HalfEdgeGraphValidation.js","sourceRoot":"","sources":["../../../src/topology/HalfEdgeGraphValidation.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;;;AAQ/F,oCAAoC;AACpC
|
|
1
|
+
{"version":3,"file":"HalfEdgeGraphValidation.js","sourceRoot":"","sources":["../../../src/topology/HalfEdgeGraphValidation.ts"],"names":[],"mappings":";AAAA;;;+FAG+F;;;AAQ/F,oCAAoC;AACpC;;;GAGG;AACH,MAAa,wBAAwB;IAArC;QACS,yBAAoB,GAAW,CAAC,CAAC;QACjC,mBAAc,GAAW,CAAC,CAAC;QAC3B,mBAAc,GAAW,CAAC,CAAC;QAC3B,iBAAY,GAAW,CAAC,CAAC;QACzB,qBAAgB,GAAW,CAAC,CAAC;QAC7B,cAAS,GAAW,CAAC,CAAC;QACtB,2BAAsB,GAAW,CAAC,CAAC;IA8E5C,CAAC;IA7EC,wBAAwB;IACjB,WAAW;QAChB,IAAI,CAAC,oBAAoB,GAAG,CAAC,CAAC;QAC9B,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC;QACxB,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC;QACxB,IAAI,CAAC,YAAY,GAAG,C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cAAc,KAAK,CAAC;eACzB,IAAI,CAAC,YAAY,KAAK,CAAC;eACvB,IAAI,CAAC,gBAAgB,KAAK,CAAC,CAAC;IACnC,CAAC;IACD;;;OAGG;IACI,gBAAgB,CAAC,KAAoB;QAC1C,IAAI,CAAC,WAAW,EAAE,CAAC;QACnB,KAAK,MAAM,EAAE,IAAI,KAAK,CAAC,YAAY;YACjC,IAAI,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC;IAC7B,CAAC;IACD;;;;OAIG;IACI,MAAM,CAAC,YAAY,CAAC,KAAoB,EAAE,cAAuB;QACtE,MAAM,SAAS,GAAG,IAAI,wBAAwB,EAAE,CAAC;QACjD,SAAS,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;QAClC,IAAI,cAAc;YAChB,OAAO,SAAS,CAAC,0BAA0B,CAAC;QAC9C,OAAO,SAAS,CAAC,uCAAuC,CAAC;IAC3D,CAAC;CACF;AArFD,4DAqFC;AACD,8EAA8E;AAC9E,MAAa,sBAAsB;IACjC;;;;;OAKG;IACI,MAAM,CAAC,8BAA8B,CAAC,KAAoB,EAAE,IAAkB;QACnF,KAAK,MAAM,EAAE,IAAI,KAAK,CAAC,YAAY,EAAE;YACnC,IAAI,EAAE,CAAC,aAAa,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;gBACrD,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AAdD,wDAcC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\n\r\n/** @packageDocumentation\r\n * @module Topology\r\n */\r\n// cspell:word FSFP\r\nimport { HalfEdge, HalfEdgeGraph, HalfEdgeMask } from \"./Graph\";\r\n\r\n// Search services for HalfEdgeGraph\r\n/**\r\n * HalfEdgePointerInspector has methods to check HalfEdge objects for pointer errors.\r\n * * For a one-step test of the whole graph.\r\n */\r\nexport class HalfEdgePointerInspector {\r\n public numUndefinedEdgeMate: number = 0;\r\n public numUndefinedFS: number = 0;\r\n public numUndefinedFP: number = 0;\r\n public numFSFPError: number = 0;\r\n public numMatePairError: number = 0;\r\n public numTested: number = 0;\r\n public numWithMatchedEdgeMate: number = 0;\r\n /** Clear all counts. */\r\n public clearCounts() {\r\n this.numUndefinedEdgeMate = 0;\r\n this.numUndefinedFP = 0;\r\n this.numUndefinedFS = 0;\r\n this.numFSFPError = 0;\r\n this.numMatePairError = 0;\r\n this.numWithMatchedEdgeMate = 0;\r\n this.numTested = 0;\r\n }\r\n /** Inspect a single half edge. Increment counters according to the half edge's pointers. */\r\n public inspectHalfEdge(he: HalfEdge) {\r\n this.numTested++;\r\n if (he.facePredecessor === undefined)\r\n this.numUndefinedFP++;\r\n else if (he.facePredecessor.faceSuccessor !== he)\r\n this.numFSFPError++;\r\n\r\n if (he.faceSuccessor === undefined)\r\n this.numUndefinedFS++;\r\n else if (he.faceSuccessor.facePredecessor !== he)\r\n this.numFSFPError++;\r\n\r\n if (he.edgeMate === undefined)\r\n this.numUndefinedEdgeMate++;\r\n else if (he.edgeMate.edgeMate === he)\r\n this.numWithMatchedEdgeMate++;\r\n else\r\n this.numMatePairError++;\r\n }\r\n /**\r\n * Return true if all pointer pairings are correct for a closed half edge graph (with no boundary):\r\n * * For each he: `he.edgeMate.edgeMate === he`\r\n * * For each he: `he.faceSuccessor.facePredecessor === he`\r\n * * For each he: `he.facePredecessor.faceSuccessor === he`\r\n */\r\n public get isValidClosedHalfEdgeGraph(): boolean {\r\n return this.numWithMatchedEdgeMate === this.numTested\r\n && this.numUndefinedFS === 0\r\n && this.numUndefinedFP === 0\r\n && this.numFSFPError === 0\r\n && this.numMatePairError === 0;\r\n }\r\n /**\r\n * Return true if all pointer pairings are correct for a half edge graph with possible boundary:\r\n * * For each he: `he.edgeMate.edgeMate === he`\r\n * * For each he: `he.faceSuccessor.facePredecessor === he`\r\n * * For each he: `he.facePredecessor.faceSuccessor === he`\r\n */\r\n public get isValidHalfEdgeGraphAllowRaggedBoundary(): boolean {\r\n return this.numWithMatchedEdgeMate + this.numUndefinedEdgeMate === this.numTested\r\n && this.numUndefinedFS === 0\r\n && this.numUndefinedFP === 0\r\n && this.numFSFPError === 0\r\n && this.numMatePairError === 0;\r\n }\r\n /**\r\n * Inspect all half edges of graph.\r\n * * All pointer counts are left in member vars for later inspection.\r\n */\r\n public inspectHalfEdges(graph: HalfEdgeGraph) {\r\n this.clearCounts();\r\n for (const he of graph.allHalfEdges)\r\n this.inspectHalfEdge(he);\r\n }\r\n /**\r\n * Inspect a graph's pointer properties.\r\n * @param expectAllMates true for \"complete\" graph.\r\n * @returns true if all pointers are valid.\r\n */\r\n public static inspectGraph(graph: HalfEdgeGraph, expectAllMates: boolean): boolean {\r\n const inspector = new HalfEdgePointerInspector();\r\n inspector.inspectHalfEdges(graph);\r\n if (expectAllMates)\r\n return inspector.isValidClosedHalfEdgeGraph;\r\n return inspector.isValidHalfEdgeGraphAllowRaggedBoundary;\r\n }\r\n}\r\n/** Static methods to inspect mask consistency properties in HalfEdgeGraph. */\r\nexport class HalfEdgeMaskValidation {\r\n /**\r\n * Test if a mask is used consistently around faces.\r\n * * At the low level, there is no actual traversal around faces. It is only necessary to verify that the mask\r\n * matches for each HalfEdge and its faceSuccessor.\r\n * @returns Return true if mask is \"all or nothing around all faces\"\r\n */\r\n public static isMaskConsistentAroundAllFaces(graph: HalfEdgeGraph, mask: HalfEdgeMask): boolean {\r\n for (const he of graph.allHalfEdges) {\r\n if (he.faceSuccessor.getMask(mask) !== he.getMask(mask))\r\n return false;\r\n }\r\n return true;\r\n }\r\n}\r\n"]}
|
|
@@ -16,30 +16,37 @@ export declare class NodeXYZUV {
|
|
|
16
16
|
private _z;
|
|
17
17
|
private _u;
|
|
18
18
|
private _v;
|
|
19
|
+
/** Constructor */
|
|
19
20
|
private constructor();
|
|
20
|
-
/**
|
|
21
|
+
/**
|
|
22
|
+
* Set all content directly from args.
|
|
21
23
|
* @returns `this` reference
|
|
22
24
|
*/
|
|
23
25
|
set(node: HalfEdge, x: number, y: number, z: number, u: number, v: number): NodeXYZUV;
|
|
26
|
+
/** Set from `other` */
|
|
24
27
|
setFrom(other: NodeXYZUV): void;
|
|
25
|
-
/**
|
|
26
|
-
*
|
|
27
|
-
* *
|
|
28
|
+
/**
|
|
29
|
+
* Create a `NodeXYZUV` with:
|
|
30
|
+
* * node from the given HalfEdge.
|
|
31
|
+
* * x,y,z as the coordinates of `node`.
|
|
32
|
+
* * u as the xy dot product of vectorA with `ray.direction`, where vectorA is the vector from ray origin to
|
|
33
|
+
* `node` coordinates.
|
|
34
|
+
* * v as the xy cross product of `ray.direction` with vectorA.
|
|
28
35
|
*/
|
|
29
36
|
static createNodeAndRayOrigin(node: HalfEdge, ray: Ray3d, result?: NodeXYZUV): NodeXYZUV;
|
|
30
|
-
/** Create a `NodeXYZUV` with explicit node
|
|
37
|
+
/** Create a `NodeXYZUV` with explicit `node`, xyz, uv. */
|
|
31
38
|
static create(node: HalfEdge, x?: number, y?: number, z?: number, u?: number, v?: number): NodeXYZUV;
|
|
32
39
|
/** Access the node. */
|
|
33
40
|
get node(): HalfEdge;
|
|
34
|
-
/** Access the x coordinate */
|
|
41
|
+
/** Access the x coordinate. */
|
|
35
42
|
get x(): number;
|
|
36
|
-
/** Access the y coordinate */
|
|
43
|
+
/** Access the y coordinate. */
|
|
37
44
|
get y(): number;
|
|
38
|
-
/** Access the z coordinate */
|
|
45
|
+
/** Access the z coordinate. */
|
|
39
46
|
get z(): number;
|
|
40
|
-
/** Access the u coordinate */
|
|
47
|
+
/** Access the u coordinate. */
|
|
41
48
|
get u(): number;
|
|
42
|
-
/** Access the v coordinate */
|
|
49
|
+
/** Access the v coordinate. */
|
|
43
50
|
get v(): number;
|
|
44
51
|
/** Access the x,y,z coordinates as Point3d with optional caller-supplied result. */
|
|
45
52
|
getXYZAsPoint3d(result?: Point3d): Point3d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HalfEdgeNodeXYZUV.d.ts","sourceRoot":"","sources":["../../../src/topology/HalfEdgeNodeXYZUV.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAEnC;;GAEG;AACH;;;GAGG;AACH,qBAAa,SAAS;IACpB,OAAO,CAAC,KAAK,CAAW;IACxB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;
|
|
1
|
+
{"version":3,"file":"HalfEdgeNodeXYZUV.d.ts","sourceRoot":"","sources":["../../../src/topology/HalfEdgeNodeXYZUV.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAEnC;;GAEG;AACH;;;GAGG;AACH,qBAAa,SAAS;IACpB,OAAO,CAAC,KAAK,CAAW;IACxB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,OAAO,CAAC,EAAE,CAAS;IACnB,kBAAkB;IAClB,OAAO;IAQP;;;OAGG;IACI,GAAG,CAAC,IAAI,EAAE,QAAQ,EAAE,CAAC,EAAE,M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
class NodeXYZUV {
|
|
19
|
+
/** Constructor */
|
|
19
20
|
constructor(node, x, y, z, u, v) {
|
|
20
21
|
this._x = x;
|
|
21
22
|
this._y = y;
|
|
@@ -24,7 +25,8 @@ class NodeXYZUV {
|
|
|
24
25
|
this._v = v;
|
|
25
26
|
this._node = node;
|
|
26
27
|
}
|
|
27
|
-
/**
|
|
28
|
+
/**
|
|
29
|
+
* Set all content directly from args.
|
|
28
30
|
* @returns `this` reference
|
|
29
31
|
*/
|
|
30
32
|
set(node, x, y, z, u, v) {
|
|
@@ -36,6 +38,7 @@ class NodeXYZUV {
|
|
|
36
38
|
this._node = node;
|
|
37
39
|
return this;
|
|
38
40
|
}
|
|
41
|
+
/** Set from `other` */
|
|
39
42
|
setFrom(other) {
|
|
40
43
|
this._x = other.x;
|
|
41
44
|
this._y = other.y;
|
|
@@ -44,9 +47,13 @@ class NodeXYZUV {
|
|
|
44
47
|
this._v = other.v;
|
|
45
48
|
this._node = other.node;
|
|
46
49
|
}
|
|
47
|
-
/**
|
|
48
|
-
*
|
|
49
|
-
* *
|
|
50
|
+
/**
|
|
51
|
+
* Create a `NodeXYZUV` with:
|
|
52
|
+
* * node from the given HalfEdge.
|
|
53
|
+
* * x,y,z as the coordinates of `node`.
|
|
54
|
+
* * u as the xy dot product of vectorA with `ray.direction`, where vectorA is the vector from ray origin to
|
|
55
|
+
* `node` coordinates.
|
|
56
|
+
* * v as the xy cross product of `ray.direction` with vectorA.
|
|
50
57
|
*/
|
|
51
58
|
static createNodeAndRayOrigin(node, ray, result) {
|
|
52
59
|
const x = node.x;
|
|
@@ -60,28 +67,42 @@ class NodeXYZUV {
|
|
|
60
67
|
return result.set(node, x, y, z, u, v);
|
|
61
68
|
return new NodeXYZUV(node, x, y, z, u, v);
|
|
62
69
|
}
|
|
63
|
-
/** Create a `NodeXYZUV` with explicit node
|
|
70
|
+
/** Create a `NodeXYZUV` with explicit `node`, xyz, uv. */
|
|
64
71
|
static create(node, x = 0, y = 0, z = 0, u = 0, v = 0) {
|
|
65
72
|
return new NodeXYZUV(node, x, y, z, u, v);
|
|
66
73
|
}
|
|
67
74
|
/** Access the node. */
|
|
68
|
-
get node() {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
/** Access the
|
|
72
|
-
get
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
/** Access the
|
|
76
|
-
get
|
|
77
|
-
|
|
78
|
-
|
|
75
|
+
get node() {
|
|
76
|
+
return this._node;
|
|
77
|
+
}
|
|
78
|
+
/** Access the x coordinate. */
|
|
79
|
+
get x() {
|
|
80
|
+
return this._x;
|
|
81
|
+
}
|
|
82
|
+
/** Access the y coordinate. */
|
|
83
|
+
get y() {
|
|
84
|
+
return this._y;
|
|
85
|
+
}
|
|
86
|
+
/** Access the z coordinate. */
|
|
87
|
+
get z() {
|
|
88
|
+
return this._z;
|
|
89
|
+
}
|
|
90
|
+
/** Access the u coordinate. */
|
|
91
|
+
get u() {
|
|
92
|
+
return this._u;
|
|
93
|
+
}
|
|
94
|
+
/** Access the v coordinate. */
|
|
95
|
+
get v() {
|
|
96
|
+
return this._v;
|
|
97
|
+
}
|
|
79
98
|
/** Access the x,y,z coordinates as Point3d with optional caller-supplied result. */
|
|
80
99
|
getXYZAsPoint3d(result) {
|
|
81
100
|
return Point3dVector3d_1.Point3d.create(this._x, this._y, this._z, result);
|
|
82
101
|
}
|
|
83
102
|
/** Access the uv coordinates as Point2d with optional caller-supplied result. */
|
|
84
|
-
getUVAsPoint2d(result) {
|
|
103
|
+
getUVAsPoint2d(result) {
|
|
104
|
+
return Point2dVector2d_1.Point2d.create(this._u, this._v, result);
|
|
105
|
+
}
|
|
85
106
|
/** Toleranced comparison function for u coordinate */
|
|
86
107
|
classifyU(target, tol) {
|
|
87
108
|
const delta = this.u - target;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HalfEdgeNodeXYZUV.js","sourceRoot":"","sources":["../../../src/topology/HalfEdgeNodeXYZUV.ts"],"names":[],"mappings":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CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAC7B,CAAC;IACD,sDAAsD;IAC/C,SAAS,CAAC,MAAc,EAAE,GAAW;QAC1C,MAAM,KAAK,GAAG,MAAM,GAAG,IAAI,CAAC,EAAE,CAAC;QAC/B,IAAI,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,IAAI,GAAG;YACxB,OAAO,CAAC,CAAC;QACX,OAAO,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;IAC7B,CAAC;CACF;AA9GD,8BA8GC","sourcesContent":["/*---------------------------------------------------------------------------------------------\r\n* Copyright (c) Bentley Systems, Incorporated. All rights reserved.\r\n* See LICENSE.md in the project root for license terms and full copyright notice.\r\n*--------------------------------------------------------------------------------------------*/\r\nimport { Geometry } from \"../Geometry\";\r\nimport { Point2d } from \"../geometry3d/Point2dVector2d\";\r\nimport { Point3d } from \"../geometry3d/Point3dVector3d\";\r\nimport { Ray3d } from \"../geometry3d/Ray3d\";\r\nimport { HalfEdge } from \"./Graph\";\r\n\r\n/** @packageDocumentation\r\n * @module Topology\r\n */\r\n/**\r\n * Reference to a HalfEdge node with extra XYZ and UV data.\r\n * @internal\r\n */\r\nexport class NodeXYZUV {\r\n private _node: HalfEdge;\r\n private _x: number;\r\n private _y: number;\r\n private _z: number;\r\n private _u: number;\r\n private _v: number;\r\n /** Constructor */\r\n private constructor(node: HalfEdge, x: number, y: number, z: number, u: number, v: number) {\r\n this._x = x;\r\n this._y = y;\r\n this._z = z;\r\n this._u = u;\r\n this._v = v;\r\n this._node = node;\r\n }\r\n /**\r\n * Set all content directly from args.\r\n * @returns `this` reference\r\n */\r\n public set(node: HalfEdge, x: number, y: number, z: number, u: number, v: number): NodeXYZUV {\r\n this._x = x;\r\n this._y = y;\r\n this._z = z;\r\n this._u = u;\r\n this._v = v;\r\n this._node = node;\r\n return this;\r\n }\r\n /** Set from `other` */\r\n public setFrom(other: NodeXYZUV): void {\r\n this._x = other.x;\r\n this._y = other.y;\r\n this._z = other.z;\r\n this._u = other.u;\r\n this._v = other.v;\r\n this._node = other.node;\r\n }\r\n /**\r\n * Create a `NodeXYZUV` with:\r\n * * node from the given HalfEdge.\r\n * * x,y,z as the coordinates of `node`.\r\n * * u as the xy dot product of vectorA with `ray.direction`, where vectorA is the vector from ray origin to\r\n * `node` coordinates.\r\n * * v as the xy cross product of `ray.direction` with vectorA.\r\n */\r\n public static createNodeAndRayOrigin(node: HalfEdge, ray: Ray3d, result?: NodeXYZUV): NodeXYZUV {\r\n const x = node.x;\r\n const y = node.y;\r\n const z = node.z;\r\n const dx = x - ray.origin.x;\r\n const dy = y - ray.origin.y;\r\n const u = Geometry.dotProductXYXY(dx, dy, ray.direction.x, ray.direction.y);\r\n const v = Geometry.crossProductXYXY(ray.direction.x, ray.direction.y, dx, dy);\r\n if (result)\r\n return result.set(node, x, y, z, u, v);\r\n return new NodeXYZUV(node, x, y, z, u, v);\r\n }\r\n /** Create a `NodeXYZUV` with explicit `node`, xyz, uv. */\r\n public static create(\r\n node: HalfEdge, x: number = 0, y: number = 0, z: number = 0, u: number = 0, v: number = 0,\r\n ): NodeXYZUV {\r\n return new NodeXYZUV(node, x, y, z, u, v);\r\n }\r\n /** Access the node. */\r\n public get node(): HalfEdge {\r\n return this._node;\r\n }\r\n /** Access the x coordinate. */\r\n public get x(): number {\r\n return this._x;\r\n }\r\n /** Access the y coordinate. */\r\n public get y(): number {\r\n return this._y;\r\n }\r\n /** Access the z coordinate. */\r\n public get z(): number {\r\n return this._z;\r\n }\r\n /** Access the u coordinate. */\r\n public get u(): number {\r\n return this._u;\r\n }\r\n /** Access the v coordinate. */\r\n public get v(): number {\r\n return this._v;\r\n }\r\n /** Access the x,y,z coordinates as Point3d with optional caller-supplied result. */\r\n public getXYZAsPoint3d(result?: Point3d): Point3d {\r\n return Point3d.create(this._x, this._y, this._z, result);\r\n }\r\n /** Access the uv coordinates as Point2d with optional caller-supplied result. */\r\n public getUVAsPoint2d(result?: Point2d): Point2d {\r\n return Point2d.create(this._u, this._v, result);\r\n }\r\n /** Toleranced comparison function for u coordinate */\r\n public classifyU(target: number, tol: number): number {\r\n const delta = this.u - target;\r\n if (Math.abs(delta) <= tol)\r\n return 0;\r\n return delta >= 0 ? 1 : -1;\r\n }\r\n /** Toleranced comparison function for v coordinate */\r\n public classifyV(target: number, tol: number): number {\r\n const delta = target - this._v;\r\n if (Math.abs(delta) <= tol)\r\n return 0;\r\n return delta >= 0 ? 1 : -1;\r\n }\r\n}\r\n"]}
|
|
@@ -22,14 +22,16 @@ export declare enum HalfEdgeMask {
|
|
|
22
22
|
/**
|
|
23
23
|
* Mask commonly set consistently around exterior faces.
|
|
24
24
|
* * A boundary edge with interior to one side, exterior to the other, will have EXTERIOR only on the outside.
|
|
25
|
-
* * An
|
|
25
|
+
* * An edge inserted "within a purely exterior face" can have EXTERIOR on both sides.
|
|
26
26
|
* * An interior edge (such as added during triangulation) will have no EXTERIOR bits.
|
|
27
|
+
* * Visualization can be found at geometry/internaldocs/Graph.md
|
|
27
28
|
*/
|
|
28
29
|
EXTERIOR = 1,
|
|
29
30
|
/**
|
|
30
|
-
* Mask commonly set (on both sides) of original geometry edges that are transition from outside
|
|
31
|
+
* Mask commonly set (on both sides) of original geometry edges that are transition from outside to inside.
|
|
31
32
|
* * At the moment of creating an edge from primary user boundary loop coordinates, the fact that an edge is BOUNDARY
|
|
32
33
|
* is often clear even though there is uncertainty about which side should be EXTERIOR.
|
|
34
|
+
* * Visualization can be found at geometry/internaldocs/Graph.md
|
|
33
35
|
*/
|
|
34
36
|
BOUNDARY_EDGE = 2,
|
|
35
37
|
/**
|
|
@@ -199,7 +201,7 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
199
201
|
/**
|
|
200
202
|
* Create a new vertex within the edge beginning at `baseA`.
|
|
201
203
|
* * This creates two new nodes in their own vertex loop.
|
|
202
|
-
* * If the base is undefined
|
|
204
|
+
* * If the base is `undefined`, create a single-edge loop.
|
|
203
205
|
* * Existing nodes stay in their face and vertex loops and retain xyz and i values.
|
|
204
206
|
* * Unlike [[pinch]], this breaks the edgeMate pairing of the input edge:
|
|
205
207
|
* each node of the input edge gets a new node as its edge mate.
|
|
@@ -412,7 +414,15 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
412
414
|
vectorToFaceSuccessor(result?: Vector3d): Vector3d;
|
|
413
415
|
/** Return Vector3d from `this` to face successor. */
|
|
414
416
|
vectorToFacePredecessor(result?: Vector3d): Vector3d;
|
|
415
|
-
/**
|
|
417
|
+
/**
|
|
418
|
+
* Test if `spaceNode` is in the sector of `sectorNode`.
|
|
419
|
+
* * The sector at `sectorNode` is defined by two rays starting at `sectorNode` and extending along the edges
|
|
420
|
+
* owned by `sectorNode` and its face predecessor.
|
|
421
|
+
* * In general, this method returns `true` if the coordinates of `spaceNode` are _strictly_ inside this sector
|
|
422
|
+
* (not on the rays).
|
|
423
|
+
* * Interpretation is whether a viewer at `sectorNode` can see `spaceNode` between the two rays.
|
|
424
|
+
* * Degenerate sectors of 180 or 360 degrees have special handling.
|
|
425
|
+
*/
|
|
416
426
|
static isNodeVisibleInSector(spaceNode: HalfEdge, sectorNode: HalfEdge): boolean;
|
|
417
427
|
/** Returns 2D cross product of vectors from `base` to `targetA` and from `base` to `targetB`. */
|
|
418
428
|
static crossProductXYToTargets(base: HalfEdge, targetA: HalfEdge, targetB: HalfEdge): number;
|
|
@@ -430,7 +440,7 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
430
440
|
* @param nodeB the second node in the chain; the node at the sector vertex.
|
|
431
441
|
* @param nodeC the third node in the chain, nominally the face successor of nodeB.
|
|
432
442
|
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. Typically this is a
|
|
433
|
-
* fraction of the sector's face's signed area. We can't compute area here, so if undefined
|
|
443
|
+
* fraction of the sector's face's signed area. We can't compute area here, so if `undefined`, zero tolerance is used.
|
|
434
444
|
* @returns true iff the sector is convex. A degenerate sector, where the incident edges overlap, returns false.
|
|
435
445
|
*/
|
|
436
446
|
static isSectorConvex(nodeA: HalfEdge, nodeB: HalfEdge, nodeC: HalfEdge, signedAreaTol?: number): boolean;
|
|
@@ -440,7 +450,7 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
440
450
|
* (convex) or a right turn (not-convex). Note that if we have a convex face, then to traverse it in ccw orientation,
|
|
441
451
|
* we always do left turns. However, if the face is not convex, we make both left and right turns.
|
|
442
452
|
* * This computation ignores z-coordinates.
|
|
443
|
-
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. If undefined
|
|
453
|
+
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. If `undefined`, a fraction
|
|
444
454
|
* (`Geometry.smallMetricDistanceSquared`) of the computed signed area is used. Pass 0 to skip toleranced computation.
|
|
445
455
|
* @returns true iff the sector is convex. A degenerate sector, where the incident edges overlap, returns false.
|
|
446
456
|
*/
|
|
@@ -567,7 +577,7 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
567
577
|
fractionToZ(fraction: number): number;
|
|
568
578
|
/**
|
|
569
579
|
* Compute fractional coordinates of the intersection of edges from given base nodes.
|
|
570
|
-
* * If parallel or colinear, return undefined
|
|
580
|
+
* * If parallel or colinear, return `undefined`.
|
|
571
581
|
* * If (possibly extended) lines intersect, return the fractions of intersection as x,y in the result.
|
|
572
582
|
* @param nodeA0 base node of edge A.
|
|
573
583
|
* @param nodeB0 base node of edge B.
|
|
@@ -576,7 +586,7 @@ export declare class HalfEdge implements HalfEdgeUserData {
|
|
|
576
586
|
static transverseIntersectionFractions(nodeA0: HalfEdge, nodeB0: HalfEdge, result?: Vector2d): Vector2d | undefined;
|
|
577
587
|
/**
|
|
578
588
|
* Compute fractional position (possibly outside 0..1) of the intersection of a horizontal line with an edge.
|
|
579
|
-
* * If the edge is horizontal with (approximate) identical y, return the node.
|
|
589
|
+
* * If the edge is horizontal with (approximate) identical y, return the base node.
|
|
580
590
|
* * If the edge is horizontal with different y, return `undefined`.
|
|
581
591
|
* @param node0 base node of edge.
|
|
582
592
|
* @param y y coordinate of the horizontal line.
|
|
@@ -658,7 +668,7 @@ export declare class HalfEdgeGraph {
|
|
|
658
668
|
/**
|
|
659
669
|
* Create a new vertex within the edge beginning at `base`.
|
|
660
670
|
* * This creates two new nodes in their own vertex loop.
|
|
661
|
-
* * If the base is undefined
|
|
671
|
+
* * If the base is `undefined`, create a single-edge loop.
|
|
662
672
|
* * Existing nodes stay in their face and vertex loops and retain xyz and i values.
|
|
663
673
|
* * Unlike [[pinch]], this breaks the edgeMate pairing of the input edge:
|
|
664
674
|
* each node of the input edge gets a new node as its edge mate.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Graph.d.ts","sourceRoot":"","sources":["../../../src/topology/Graph.ts"],"names":[],"mappings":"AAKA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAGvD,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AACpD,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAQvD;;;;;;;;;;;GAWG;AACH,oBAAY,YAAY;IAStB;;;;;OAKG;IACH,QAAQ,IAAa;IACrB;;;;OAIG;IACH,aAAa,IAAa;IAC1B;;;;;OAKG;IACH,YAAY,IAAa;IACzB,6EAA6E;IAC7E,OAAO,KAAY;IACnB,wDAAwD;IACxD,iBAAiB,MAAa;IAC9B,2CAA2C;IAC3C,SAAS,MAAa;IACtB,oBAAoB;IACpB,SAAS,IAAa;IACtB,oEAAoE;IACpE,mBAAmB,aAAa;IAChC,oBAAoB;IACpB,QAAQ,aAAa;CAKtB;AAED;;;GAGG;AACH,MAAM,MAAM,YAAY,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Mask commonly set consistently around exterior faces.
|
|
42
42
|
* * A boundary edge with interior to one side, exterior to the other, will have EXTERIOR only on the outside.
|
|
43
|
-
* * An
|
|
43
|
+
* * An edge inserted "within a purely exterior face" can have EXTERIOR on both sides.
|
|
44
44
|
* * An interior edge (such as added during triangulation) will have no EXTERIOR bits.
|
|
45
|
+
* * Visualization can be found at geometry/internaldocs/Graph.md
|
|
45
46
|
*/
|
|
46
47
|
HalfEdgeMask[HalfEdgeMask["EXTERIOR"] = 1] = "EXTERIOR";
|
|
47
48
|
/**
|
|
48
|
-
* Mask commonly set (on both sides) of original geometry edges that are transition from outside
|
|
49
|
+
* Mask commonly set (on both sides) of original geometry edges that are transition from outside to inside.
|
|
49
50
|
* * At the moment of creating an edge from primary user boundary loop coordinates, the fact that an edge is BOUNDARY
|
|
50
51
|
* is often clear even though there is uncertainty about which side should be EXTERIOR.
|
|
52
|
+
* * Visualization can be found at geometry/internaldocs/Graph.md
|
|
51
53
|
*/
|
|
52
54
|
HalfEdgeMask[HalfEdgeMask["BOUNDARY_EDGE"] = 2] = "BOUNDARY_EDGE";
|
|
53
55
|
/**
|
|
@@ -198,7 +200,7 @@ class HalfEdge {
|
|
|
198
200
|
/**
|
|
199
201
|
* Create a new vertex within the edge beginning at `baseA`.
|
|
200
202
|
* * This creates two new nodes in their own vertex loop.
|
|
201
|
-
* * If the base is undefined
|
|
203
|
+
* * If the base is `undefined`, create a single-edge loop.
|
|
202
204
|
* * Existing nodes stay in their face and vertex loops and retain xyz and i values.
|
|
203
205
|
* * Unlike [[pinch]], this breaks the edgeMate pairing of the input edge:
|
|
204
206
|
* each node of the input edge gets a new node as its edge mate.
|
|
@@ -695,7 +697,15 @@ class HalfEdge {
|
|
|
695
697
|
const other = this.facePredecessor;
|
|
696
698
|
return Vector3d.create(other.x - this.x, other.y - this.y, other.z - this.z, result);
|
|
697
699
|
}
|
|
698
|
-
/**
|
|
700
|
+
/**
|
|
701
|
+
* Test if `spaceNode` is in the sector of `sectorNode`.
|
|
702
|
+
* * The sector at `sectorNode` is defined by two rays starting at `sectorNode` and extending along the edges
|
|
703
|
+
* owned by `sectorNode` and its face predecessor.
|
|
704
|
+
* * In general, this method returns `true` if the coordinates of `spaceNode` are _strictly_ inside this sector
|
|
705
|
+
* (not on the rays).
|
|
706
|
+
* * Interpretation is whether a viewer at `sectorNode` can see `spaceNode` between the two rays.
|
|
707
|
+
* * Degenerate sectors of 180 or 360 degrees have special handling.
|
|
708
|
+
*/
|
|
699
709
|
static isNodeVisibleInSector(spaceNode, sectorNode) {
|
|
700
710
|
// remark: fussy details ported from native code. The obscure cases seemed "unlikely" at first. But pre-existing
|
|
701
711
|
// unit tests for triangulation pinged just about everything. So it really matters to do the "0" cases this way
|
|
@@ -756,7 +766,7 @@ class HalfEdge {
|
|
|
756
766
|
* @param nodeB the second node in the chain; the node at the sector vertex.
|
|
757
767
|
* @param nodeC the third node in the chain, nominally the face successor of nodeB.
|
|
758
768
|
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. Typically this is a
|
|
759
|
-
* fraction of the sector's face's signed area. We can't compute area here, so if undefined
|
|
769
|
+
* fraction of the sector's face's signed area. We can't compute area here, so if `undefined`, zero tolerance is used.
|
|
760
770
|
* @returns true iff the sector is convex. A degenerate sector, where the incident edges overlap, returns false.
|
|
761
771
|
*/
|
|
762
772
|
static isSectorConvex(nodeA, nodeB, nodeC, signedAreaTol = 0) {
|
|
@@ -775,7 +785,7 @@ class HalfEdge {
|
|
|
775
785
|
* (convex) or a right turn (not-convex). Note that if we have a convex face, then to traverse it in ccw orientation,
|
|
776
786
|
* we always do left turns. However, if the face is not convex, we make both left and right turns.
|
|
777
787
|
* * This computation ignores z-coordinates.
|
|
778
|
-
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. If undefined
|
|
788
|
+
* @param signedAreaTol optional signed area tolerance to use in test for parallel vectors. If `undefined`, a fraction
|
|
779
789
|
* (`Geometry.smallMetricDistanceSquared`) of the computed signed area is used. Pass 0 to skip toleranced computation.
|
|
780
790
|
* @returns true iff the sector is convex. A degenerate sector, where the incident edges overlap, returns false.
|
|
781
791
|
*/
|
|
@@ -1064,7 +1074,7 @@ class HalfEdge {
|
|
|
1064
1074
|
}
|
|
1065
1075
|
/**
|
|
1066
1076
|
* Compute fractional coordinates of the intersection of edges from given base nodes.
|
|
1067
|
-
* * If parallel or colinear, return undefined
|
|
1077
|
+
* * If parallel or colinear, return `undefined`.
|
|
1068
1078
|
* * If (possibly extended) lines intersect, return the fractions of intersection as x,y in the result.
|
|
1069
1079
|
* @param nodeA0 base node of edge A.
|
|
1070
1080
|
* @param nodeB0 base node of edge B.
|
|
@@ -1085,7 +1095,7 @@ class HalfEdge {
|
|
|
1085
1095
|
}
|
|
1086
1096
|
/**
|
|
1087
1097
|
* Compute fractional position (possibly outside 0..1) of the intersection of a horizontal line with an edge.
|
|
1088
|
-
* * If the edge is horizontal with (approximate) identical y, return the node.
|
|
1098
|
+
* * If the edge is horizontal with (approximate) identical y, return the base node.
|
|
1089
1099
|
* * If the edge is horizontal with different y, return `undefined`.
|
|
1090
1100
|
* @param node0 base node of edge.
|
|
1091
1101
|
* @param y y coordinate of the horizontal line.
|
|
@@ -1237,7 +1247,7 @@ export class HalfEdgeGraph {
|
|
|
1237
1247
|
/**
|
|
1238
1248
|
* Create a new vertex within the edge beginning at `base`.
|
|
1239
1249
|
* * This creates two new nodes in their own vertex loop.
|
|
1240
|
-
* * If the base is undefined
|
|
1250
|
+
* * If the base is `undefined`, create a single-edge loop.
|
|
1241
1251
|
* * Existing nodes stay in their face and vertex loops and retain xyz and i values.
|
|
1242
1252
|
* * Unlike [[pinch]], this breaks the edgeMate pairing of the input edge:
|
|
1243
1253
|
* each node of the input edge gets a new node as its edge mate.
|