CN-122023685-A - Terrain tile generation method, device and equipment
Abstract
The application provides a method, a device and equipment for generating a terrain tile, wherein the method comprises the steps of acquiring elevation data; generating elevation grids according to the elevation data, generating triangular grids and triangular skirts according to the elevation grids, and generating terrain tiles according to the triangular grids and the triangular skirts. The method of the embodiment of the application efficiently and accurately realizes the full-flow automatic processing from multi-source elevation data to standardized Quantized-Mesh terrain tiles.
Inventors
- LI MINGHUA
- WANG LEI
- ZHOU XIAOMING
- XIE YONGHU
- LI QIANG
- LI MENGWEI
- LI JIANCUN
Assignees
- 北京观微科技有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20251211
Claims (10)
- 1. A method of generating a terrain tile, comprising: Acquiring elevation data; Generating an elevation grid according to the elevation data; generating triangular grids and triangular skirts according to the elevation grids; and generating terrain tiles according to the triangular meshes and the triangular skirt edges.
- 2. The method of claim 1, wherein generating an elevation grid from the elevation data comprises: dividing the elevation data based on a quadtree pyramid structure to generate tile data sources of all levels; and generating elevation grids according to the tile data sources of each level, wherein each grid point in the elevation grids comprises longitude and latitude coordinates and altitude information.
- 3. The method of claim 1, wherein generating triangular meshes and triangular skirts from the elevation mesh comprises: Determining a plurality of rectangular units corresponding to the elevation grid, wherein the rectangular units are formed based on 4 adjacent grid points in the elevation grid; Generating a first triangle according to a first grid point, a second grid point and a third grid point in any rectangular unit; generating a second triangle according to the second grid point, the third grid point and the fourth grid point in the rectangular unit; generating triangular grids corresponding to the elevation grids according to the first triangles and the second triangles in the plurality of rectangular units; and generating the triangular skirt edges according to the triangular meshes.
- 4. The method for generating a terrain tile according to claim 3, wherein after generating a triangle mesh corresponding to the elevation mesh according to the first triangle and the second triangle in the plurality of rectangular units, the method further comprises: Determining elevation values of grid points of which the elevation data fall in the triangular projection range and elevation values of projection points of the grid points on a plane of the triangle aiming at any triangle in the triangular grids; And inserting the grid point serving as a target vertex into the triangle to generate a plurality of triangles when the difference value between the elevation value of the grid point and the elevation value of the projection point is larger than a preset threshold value.
- 5. A method of generating terrain tiles as claimed in claim 3, wherein said generating said triangular skirt from said triangular mesh comprises: determining a copy vertex corresponding to a vertex of a triangle in the triangle mesh; reducing the elevation value of the duplicated vertex by a preset fixed value; and generating a triangle skirt according to the vertexes of the triangle and the duplicated vertexes.
- 6. The method of generating a terrain tile according to claims 1-5, characterized in that the method further comprises: Determining the elevation value of each elevation point of the elevation data falling in the triangle projection range and the elevation value of the projection point of the elevation point on the plane of the triangle aiming at any triangle in the triangle mesh; determining the geometric error of the triangle according to the difference value between the elevation value of each elevation point and the elevation value of the projection point; And determining the geometric error of the tile hierarchy in switching according to the geometric error of each triangle in the triangle mesh.
- 7. A terrain tile generation apparatus, comprising: the acquisition module is used for acquiring elevation data; the processing module is used for generating an elevation grid according to the elevation data; The generating module is used for generating a triangular grid and a triangular skirt according to the elevation grid; And the packaging module is used for generating terrain tiles according to the triangular meshes and the triangular skirt edges.
- 8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method of generating a terrain tile as claimed in any of claims 1 to 6 when executing the computer program.
- 9. A non-transitory computer readable storage medium having stored thereon a computer program, which when executed by a processor implements a method of generating a terrain tile as claimed in any of claims 1 to 6.
- 10. A computer program product comprising a computer program which, when executed by a processor, implements a method of generating a terrain tile as claimed in any one of claims 1 to 6.
Description
Terrain tile generation method, device and equipment Technical Field The present invention relates to the field of geographic information systems and three-dimensional terrain rendering technologies, and in particular, to a method, an apparatus, and a device for generating a terrain tile. Background With the popularization of WebGL technology, realizing high-performance three-dimensional terrain visualization in a browser has become a key requirement in the fields of digital earth, smart city and the like. The traditional terrain service mostly adopts picture tiles or is Cheng Wapian high, but the problems of large data size or large decoding calculation cost exist in the modes. To solve the above problems, cesium open source virtual earth engines have introduced a Quantized-Mesh 1.0 format, which is designed specifically for streaming and efficient rendering, as the preferred format for current three-dimensional terrain tiles. Therefore, how to develop a terrain tile generating method which has high-efficiency data processing capability and is completely compatible with Quantized-Mesh 1.0 standard, so as to solve the problems of large data volume, low network transmission efficiency, poor three-dimensional rendering performance, poor compatibility and the like in the prior art, and the method is a technical problem to be solved by those skilled in the art. Disclosure of Invention The application provides a method, a device and equipment for generating a terrain tile, which are used for generating an elevation grid according to elevation data; according to the design of the triangular grids and the triangular skirt edges, namely, the application can effectively support vertex index compression, improve network transmission efficiency, improve three-dimensional rendering fluency of a browser end, effectively eliminate rendering cracks of adjacent tiles, balance terrain precision and three-dimensional rendering fluency of the browser end and effectively and accurately realize full-flow automatic processing from multi-source elevation data to standardized Quantized-Mesh terrain tiles on the premise of retaining the key features of the terrains such as mountains, canyons and the like. The invention provides a generation method of a terrain tile, which comprises the following steps of. Acquiring elevation data; Generating an elevation grid according to the elevation data; generating triangular grids and triangular skirts according to the elevation grids; and generating terrain tiles according to the triangular meshes and the triangular skirt edges. According to the method for generating the terrain tile provided by the invention, the generation of the elevation grid according to the elevation data comprises the following steps: dividing the elevation data based on a quadtree pyramid structure to generate tile data sources of all levels; and generating elevation grids according to the tile data sources of each level, wherein each grid point in the elevation grids comprises longitude and latitude coordinates and altitude information. According to the method for generating the terrain tiles, the triangular meshes and the triangular skirts are generated according to the elevation meshes, and the method comprises the following steps: Determining a plurality of rectangular units corresponding to the elevation grid, wherein the rectangular units are formed based on 4 adjacent grid points in the elevation grid; Generating a first triangle according to a first grid point, a second grid point and a third grid point in any rectangular unit; generating a second triangle according to the second grid point, the third grid point and the fourth grid point in the rectangular unit; generating triangular grids corresponding to the elevation grids according to the first triangles and the second triangles in the plurality of rectangular units; and generating the triangular skirt edges according to the triangular meshes. According to the method for generating the terrain tile provided by the invention, after generating the triangular grid corresponding to the elevation grid according to the first triangle and the second triangle in the plurality of rectangular units, the method further comprises: Determining elevation values of grid points of which the elevation data fall in the triangular projection range and elevation values of projection points of the grid points on a plane of the triangle aiming at any triangle in the triangular grids; And inserting the grid point serving as a target vertex into the triangle to generate a plurality of triangles when the difference value between the elevation value of the grid point and the elevation value of the projection point is larger than a preset threshold value. According to the method for generating the terrain tile provided by the invention, the triangular skirt edge is generated according to the triangular mesh, and the method comprises the following steps: determining a copy vertex cor