Search

CN-116521916-B - Point cloud space attribute joint parallel query method based on octree forest

CN116521916BCN 116521916 BCN116521916 BCN 116521916BCN-116521916-B

Abstract

The invention provides a point cloud space attribute joint parallel query method based on octree forests, which is characterized in that an external cube of a query main body is calculated, target octree intersected with the external cube in the point cloud octree is filtered, meanwhile, space query is carried out on the target octree to obtain a target node array and a target point index array, finally, attribute filtering is carried out on points in the target node array and the target point index array to obtain target points, point cloud data corresponding to the target points are obtained as target data, joint processing of space query and attribute filtering can be realized, the attribute filtering is not needed to be queried again, and the query processing flow is greatly simplified directly based on space query results.

Inventors

  • XIANG ZEJUN
  • RAO MING
  • TANG HAO
  • TENG DEGUI
  • LONG CHUAN
  • LI CHAO
  • Yuan changzheng
  • LI CHUANG
  • GOU YONGGANG
  • LI SHURONG
  • ZHANG HENG

Assignees

  • 重庆市测绘科学技术研究院(重庆市地图编制中心)
  • 重庆市勘测院

Dates

Publication Date
20260512
Application Date
20230410

Claims (8)

  1. 1. The point cloud space attribute joint parallel query method based on the octree forest is characterized by comprising the following steps of: calculating an circumscribed cube of a query body, filtering a target octree intersecting the circumscribed cube in a point cloud octree, comprising: constructing an octree according to point cloud data to obtain a point cloud octree, wherein the point cloud data comprises three-dimensional coordinates of point clouds and point cloud attributes, and the point cloud octree comprises root nodes, intermediate nodes and leaf nodes; Judging a point cloud query mode, wherein the point cloud query mode comprises screen query; calculating an external cube of a query body from point cloud data, comprising: When the point cloud query mode is screen query, calculating projection coordinates of a query entity on a far and near clipping surface according to the projection type, the screen viewpoint coordinates, the sight line direction and the far and near clipping distance; calculating an external cube of the projection coordinate according to the projection coordinate; Acquiring a point cloud octree intersected with the external cube as a target octree; performing space query on the target octree to obtain a target node array and a target point index array; And performing attribute filtering on points in the target node array and the target point index array to obtain a target point, and acquiring point cloud data corresponding to the target point as target data.
  2. 2. The method of claim 1, wherein the point cloud query further comprises a three-dimensional space query.
  3. 3. The method of claim 2, wherein the step of computing an bounding cube of the query body from the point cloud data comprises: and when the point cloud query mode is three-dimensional space query, directly calculating an external cube of the query main body.
  4. 4. The method of claim 2, wherein the step of spatially querying the target octree to obtain a target node array and a target point index array comprises: calculating an external bounding box and an internal bounding box of the query entity; sequentially screening out nodes intersecting with the external bounding box from the nodes of the target octree as nodes to be processed; And sequentially screening out the nodes to be processed, which are intersected with the inscribed bounding box, as target nodes, and taking the point index array of the target nodes as a target point index array.
  5. 5. The method according to claim 4, wherein after the step of sequentially screening out nodes intersecting the circumscribed bounding box from the nodes of the target octree as the nodes to be processed, further comprising: screening leaf nodes in the nodes to be processed, which are not intersected with the inscribed bounding box, from the nodes to be processed, and taking the leaf nodes as target leaf nodes; judging whether each point coordinate in the target leaf node is positioned in the query entity; if yes, the target leaf node is taken as a target node, and the point index array of the target node is taken as a target point index array.
  6. 6. The method of claim 4, wherein the step of computing the circumscribed bounding box and the inscribed bounding box of the querying entity comprises: And when the point cloud query mode is three-dimensional space query, calculating an external bounding box and an internal bounding box of the query entity.
  7. 7. The method of claim 4, wherein the step of computing the circumscribed bounding box and the inscribed bounding box of the querying entity comprises: when the point cloud query mode is screen query, acquiring screen coordinates of an external bounding box and an internal bounding box of a query entity; and calculating an external bounding box and an internal bounding box of the query entity according to the screen coordinates.
  8. 8. The method according to claim 1, wherein the step of performing attribute filtering on points in the target node array and the target point index array to obtain target points and acquiring point cloud data corresponding to the target points as target data includes: judging whether the attributes of points in the target node array and the target point index array accord with preset values or not; If yes, taking the point which accords with the preset value as a target point; And acquiring point cloud data corresponding to the target point as target data, and finishing the space and attribute inquiry of the point cloud data.

Description

Point cloud space attribute joint parallel query method based on octree forest Technical Field The invention relates to the technical field of point cloud query, in particular to a point cloud space attribute joint parallel query method based on an octree forest. Background Point cloud data is a data form that expresses geometric features of a space object with a huge number of discrete point coordinates. It is characterized by large data volume. The method comprises the steps of inquiring a point cloud space, namely inquiring the point cloud in a given geometrical figure on a screen or a geometrical figure in the space, inquiring the attribute of the point cloud, namely inquiring the attribute inquiring condition of the point cloud, namely inquiring the point cloud meeting the condition, and inquiring the spatial attribute joint inquiry of the point cloud, namely inquiring the point cloud meeting the attribute inquiring condition in the geometrical figure. With the continuous development of large-scale three-dimensional data acquisition technology, three-dimensional laser scanning equipment is widely applied. The method can be used for carrying out complete point cloud coordinate acquisition on the target scene, carrying out automatic high-precision scanning in a three-dimensional space, truly describing the overall structure and morphological characteristics of the target scene and rapidly acquiring the point cloud data of the target scene. In the application of searching, analyzing and processing and rendering the point cloud, the joint inquiry of the space and the attribute of the point cloud is required, however, the existing inquiry is only carried out on the space or the attribute singly. Disclosure of Invention Aiming at the defects existing in the prior art, the invention provides a point cloud space attribute joint parallel query method based on an octree forest, which aims to solve the technical problem that only a space or attribute is queried independently in the prior art. A point cloud space attribute joint parallel query method based on octree forests comprises the steps of calculating an external cube of a query main body, filtering target octree intersected with the external cube in a point cloud octree, performing space query on the target octree to obtain a target node array and a target point index array, performing attribute filtering on points in the target node array and the target point index array to obtain target points, and obtaining point cloud data corresponding to the target points as target data. In one embodiment, the step of calculating an external cube of the query body and filtering target octree intersecting the external cube in the point cloud octree comprises the steps of constructing the octree according to point cloud data, obtaining the point cloud octree, wherein the point cloud data comprises three-dimensional coordinates of point clouds and point cloud attributes, the point cloud octree comprises root nodes, intermediate nodes and leaf nodes, calculating the external cube of the query body according to the point cloud data, and obtaining the point cloud octree intersecting the external cube as the target octree. In one embodiment, before the step of calculating the external cube of the query body according to the point cloud data, the method further comprises a step of judging a point cloud query mode, wherein the point cloud query mode comprises three-dimensional space query and screen query. In one embodiment, the step of calculating the external cube of the query body according to the point cloud data comprises directly calculating the external cube of the query body when the point cloud query mode is three-dimensional space query. In one embodiment, the step of calculating the external cube of the query body according to the point cloud data further comprises the steps of calculating projection coordinates of the query entity on a far-near clipping surface according to the projection type, the screen viewpoint coordinates, the sight line direction and the far-near clipping distance when the point cloud query mode is screen query, and calculating the external cube of the projection coordinates according to the projection coordinates. In one embodiment, the step of carrying out space query on the target octree to obtain a target node array and a target point index array comprises the steps of calculating an external bounding box and an internal bounding box of a query entity, sequentially screening out nodes intersecting with the external bounding box from nodes of the target octree as nodes to be processed, sequentially screening out nodes to be processed intersecting with the internal bounding box from the nodes to be processed as target nodes, and taking the point index array of the target node as the target point index array. In one embodiment, after the step of sequentially screening out nodes intersecting with the circumscribed bounding box from the nodes