rm-graphical-computing-node 1.0.121 → 1.0.122

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 (2) hide show
  1. package/dist/index.mjs +19 -3
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -9645,12 +9645,14 @@ var getMergeMeaning = (allProjectionResults, wallLines, wallVerifyType, averageP
9645
9645
  if (word === "wall" || word === "stair guardrail")
9646
9646
  continue;
9647
9647
  let threePoints = [];
9648
+ let ptIndex = [];
9648
9649
  for (let u4 = 0; u4 < allProjectionResults[i].points.length; u4++) {
9649
9650
  threePoints.push(new THREE8.Vector3(
9650
9651
  allProjectionResults[i].points[u4].x,
9651
9652
  allProjectionResults[i].points[u4].y,
9652
9653
  allProjectionResults[i].points[u4].z
9653
9654
  ));
9655
+ ptIndex.push(u4);
9654
9656
  }
9655
9657
  if (wallLines && wallLines.length && wallVerifyType && wallVerifyType.length && wallVerifyType.includes(word)) {
9656
9658
  threePoints = checkNearObjects(wallLines, threePoints);
@@ -9682,6 +9684,11 @@ var getMergeMeaning = (allProjectionResults, wallLines, wallVerifyType, averageP
9682
9684
  if (threePoints.length === 0)
9683
9685
  continue;
9684
9686
  const centerData = getCenterAndPointHeight(threePoints);
9687
+ let mapPosition = /* @__PURE__ */ new Map();
9688
+ mapPosition.set(
9689
+ `${allProjectionResults[i].position.x},${allProjectionResults[i].position.y},${allProjectionResults[i].position.z}`,
9690
+ threePoints
9691
+ );
9685
9692
  const data = {
9686
9693
  points: threePoints,
9687
9694
  path: computeContour(points),
@@ -9696,7 +9703,8 @@ var getMergeMeaning = (allProjectionResults, wallLines, wallVerifyType, averageP
9696
9703
  isDel: false,
9697
9704
  obj_id,
9698
9705
  positionArr: [allProjectionResults[i].position],
9699
- isStaircaseBalconyRailing: false
9706
+ isStaircaseBalconyRailing: false,
9707
+ mapPosition
9700
9708
  // isObliqueCeiling,
9701
9709
  // pointPercent,
9702
9710
  // pointsNormal
@@ -9861,9 +9869,16 @@ var getMergeMeaning = (allProjectionResults, wallLines, wallVerifyType, averageP
9861
9869
  }
9862
9870
  if (isMerge) {
9863
9871
  delData.add(k);
9872
+ let nowIndex = cloneData.points.length;
9873
+ let threePoints = [];
9864
9874
  for (let m = 0; m < array[k].points.length; m++) {
9865
- if (array[k].points[m].z > averagePz2 && array[k].points[m].z - averagePz2 > 0.1 || cloneData.type == "floor" || cloneData.type == "Staircase")
9875
+ if (array[k].points[m].z > averagePz2 && array[k].points[m].z - averagePz2 > 0.1 || cloneData.type == "floor" || cloneData.type == "Staircase") {
9866
9876
  cloneData.points.push(array[k].points[m]);
9877
+ threePoints.push(array[k].points[m]);
9878
+ }
9879
+ }
9880
+ if (cloneData.type != "floor") {
9881
+ cloneData.mapPosition.set(`${array[k].positionArr[0].x},${array[k].positionArr[0].y},${array[k].positionArr[0].z}`, threePoints);
9867
9882
  }
9868
9883
  let tmpPoints = cloneData.points.map((p) => [p.x, p.y]);
9869
9884
  if (cloneData.type == "floor") {
@@ -10323,7 +10338,8 @@ var getMergeMeaning = (allProjectionResults, wallLines, wallVerifyType, averageP
10323
10338
  obj_id: array[j].obj_id,
10324
10339
  pcdPoints: array[j].points,
10325
10340
  positionArr: array[j].positionArr,
10326
- isStaircaseBalconyRailing: array[j].isStaircaseBalconyRailing
10341
+ isStaircaseBalconyRailing: array[j].isStaircaseBalconyRailing,
10342
+ mapPosition: array[j].mapPosition
10327
10343
  });
10328
10344
  }
10329
10345
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "rm-graphical-computing-node",
3
- "version": "1.0.121",
3
+ "version": "1.0.122",
4
4
  "description": "墙体/梁线/点云语义计算库(依赖 Python 与 three.js)",
5
5
  "type": "module",
6
6
  "main": "dist/index.mjs",