CN116401332B - Large-scale three-dimensional model display optimization method and system and electronic equipment - Google Patents

Large-scale three-dimensional model display optimization method and system and electronic equipment Download PDF

Info

Publication number
CN116401332B
CN116401332B CN202310664180.2A CN202310664180A CN116401332B CN 116401332 B CN116401332 B CN 116401332B CN 202310664180 A CN202310664180 A CN 202310664180A CN 116401332 B CN116401332 B CN 116401332B
Authority
CN
China
Prior art keywords
data
dimensional model
data block
osgb
format
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202310664180.2A
Other languages
Chinese (zh)
Other versions
CN116401332A (en
Inventor
王海泉
孙磊磊
任心怡
林嘉芊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beihang University
Original Assignee
Beihang University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beihang University filed Critical Beihang University
Priority to CN202310664180.2A priority Critical patent/CN116401332B/en
Publication of CN116401332A publication Critical patent/CN116401332A/en
Application granted granted Critical
Publication of CN116401332B publication Critical patent/CN116401332B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/29Geographical information databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/174Redundancy elimination performed by the file system
    • G06F16/1744Redundancy elimination performed by the file system using compression, e.g. sparse files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/22Indexing; Data structures therefor; Storage structures
    • G06F16/2228Indexing structures
    • G06F16/2246Trees, e.g. B+trees
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/25Integrating or interfacing systems involving database management systems
    • G06F16/258Data format conversion from or to a database
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/04Texture mapping
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/005Tree description, e.g. octree, quadtree
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/05Geographic models
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T17/00Three dimensional [3D] modelling, e.g. data description of 3D objects
    • G06T17/20Finite element generation, e.g. wire-frame surface description, tesselation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T19/00Manipulating 3D models or images for computer graphics
    • G06T19/20Editing of 3D images, e.g. changing shapes or colours, aligning objects or positioning parts
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02TCLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO TRANSPORTATION
    • Y02T10/00Road transport of goods or passengers
    • Y02T10/10Internal combustion engine [ICE] based vehicles
    • Y02T10/40Engine management systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Databases & Information Systems (AREA)
  • Software Systems (AREA)
  • Computer Graphics (AREA)
  • General Engineering & Computer Science (AREA)
  • Geometry (AREA)
  • Data Mining & Analysis (AREA)
  • Remote Sensing (AREA)
  • Architecture (AREA)
  • Computer Hardware Design (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The invention discloses a large-scale three-dimensional model display optimization method, a system and electronic equipment, and relates to the technical field of three-dimensional model display, wherein the method comprises the following steps: performing recursion reconstruction on data blocks in osgb format original data describing geospatial information to generate an index tree; simplifying the triangle network file information in the original data of the osgb format, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain the simplified and compressed osgb format data; and according to the index tree and the simplified compressed osgb format data, the corresponding osgb format data is called according to the user requirement, and the corresponding osgb format data is converted into 3DTiles format data for transmission and display. The invention can process and optimize the large-scale oblique photography model data, and improve the loading and rendering efficiency.

Description

Large-scale three-dimensional model display optimization method and system and electronic equipment
Technical Field
The invention relates to the technical field of three-dimensional model display, in particular to a large-scale three-dimensional model display optimization method, a system and electronic equipment.
Background
In recent years, internet technology has been vigorously developed, and a new living machine is brought to a geographic information system based on Web. Text descriptions or images were used earlier for presentation of geographic information. Because the common manual modeling takes a long time and has huge workload, the time duration is less than one month, and the timeliness of the oblique photogrammetry technology is greatly improved under the support of high-performance hardware from the acquisition of two-dimensional image data to the completion of three-dimensional modeling. Therefore, the three-dimensional model mainly uses an oblique photography technology, acquires object images from five different angles such as vertical angles and oblique angles through the unmanned aerial vehicle, and then inputs the object images into ContextCapture software for data processing to form three-dimensional model data in a common osgb format.
The large-scale oblique photography model data (namely the three-dimensional model data in the osgb format) has the problems of huge data volume, complex data structure, large number of folders, serious file fragmentation, large pyramid level and the like, and is difficult to be completely loaded into a memory at one time. The large-scale oblique photography model data visualization can cause large-scale delay of client rendering, or collapse is caused by insufficient memory of a browser and can not be rendered, so that the efficiency of loading and rendering the large-scale oblique photography model data is low, the requirement of people on the real-time property of the large-scale oblique photography model data can not be met, and a large amount of I/O operations exist during data scheduling, so that computer resources are occupied.
Currently, for large-scale oblique photography model data, a common solution is to process by closed source software. For example, the processing is performed through commercial software such as CesiumLab or SuperMap, but the tools have certain data requirements before simplification, are only supported to be displayed in specific software after simplification, have no universality, have low data conversion speed aiming at a large-scale oblique photography model, have low loading efficiency, cannot autonomously set optimization parameters, and are difficult to meet the purpose of being used on different platforms.
In addition, some open source tools, such as the 3DTiles tool of the fanvanzh invention, can realize conversion from osgb format to 3DTiles format, but cannot process and optimize data, so that the problems of low loading efficiency, missing data after conversion and the like still exist.
Disclosure of Invention
The invention aims to provide a large-scale three-dimensional model display optimization method, a system and electronic equipment, which can perform data processing and optimization on large-scale oblique photography model data and improve loading and rendering efficiency.
In order to achieve the above object, the present invention provides the following solutions:
in a first aspect, the present invention provides a method for optimizing the display of a large-scale three-dimensional model, including:
acquiring osgb format raw data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks; each of the data blocks is stored as a tile; each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, and the three-dimensional models of each level are stored as an osgb file; the three-dimensional model is a model composed of triangle net file information; the triangle file information comprises triangle information and texture information;
performing recursion reconstruction on the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf node is used for storing the address of the triangle network file information;
simplifying the triangle network file information in the original osgb format data, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain simplified and compressed osgb format data;
and according to the index tree and the simplified compressed osgb format data, corresponding osgb format data are called according to the user requirement, and the corresponding osgb format data are converted into 3DTiles format data and then transmitted and displayed.
In a second aspect, the present invention provides a large-scale three-dimensional model display optimization system, comprising:
the data acquisition module is used for acquiring osgb format original data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks; each of the data blocks is stored as a tile; each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, and the three-dimensional models of each level are stored as an osgb file; the three-dimensional model is a model composed of triangle net file information; the triangle file information comprises triangle information and texture information;
the index tree generation module is used for recursively reconstructing the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf node is used for storing the address of the triangle network file information;
the simplified compression module is used for simplifying the triangle network file information in the original data in the osgb format, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain the simplified compressed osgb format data;
and the transmission display module is used for calling the corresponding osgb format data according to the index tree and the simplified compressed osgb format data and user requirements, converting the corresponding osgb format data into 3DTiles format data, and then transmitting and displaying the data.
In a third aspect, the present invention provides an electronic device comprising a memory for storing a computer program and a processor that runs the computer program to cause the electronic device to perform the method of large-scale three-dimensional model exhibition optimization according to the first aspect.
According to the specific embodiment provided by the invention, the invention discloses the following technical effects:
the invention provides a large-scale three-dimensional model display optimization method, a system and electronic equipment, which are used for solving the problems that computer resources are consumed greatly, display efficiency is low, visual effect is poor, instantaneity cannot be guaranteed and the like during large-scale three-dimensional model rendering. Under the condition of ensuring that the fineness of the data is acceptable, the osgb file is simplified and compressed, the triangle network information quantity and the texture information fineness of the data are reduced, format conversion is carried out, the universal data format 3DTiles is generated, the problems of large data quantity, file fragmentation and low loading rendering efficiency of a large-scale three-dimensional model file are solved, and the processing and rendering of the large-scale three-dimensional model are realized.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions of the prior art, the drawings that are needed in the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of a large-scale three-dimensional model display optimization method provided by an embodiment of the invention;
FIG. 2 is a flow chart of a recursively reconstructing a new index provided in an embodiment of the present invention;
FIG. 3 is a schematic diagram of osgb repartitioning and merging according to an embodiment of the present invention;
fig. 4 is a simplified effect diagram of triangle network information provided by the embodiment of the invention; fig. 4 (a) is a simplified effect diagram of triangle mesh information provided by the embodiment of the present invention, and fig. 4 (b) is a simplified effect diagram of triangle mesh information provided by the embodiment of the present invention;
FIG. 5 shows a bounding box diagram and successfully scheduled three-dimensional models after reconstruction according to the embodiment of the present invention at different viewpoint distances; fig. 5 (a) shows that the reconstructed three-dimensional model is successfully scheduled at the first viewpoint distance and the bounding box diagram is displayed, and fig. 5 (b) shows that the reconstructed three-dimensional model is successfully scheduled at the second viewpoint distance and the bounding box diagram is displayed; fig. 5 (c) is successfully scheduled at the third viewpoint distance of the reconstructed three-dimensional model and displays the bounding box graph.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
In order that the above-recited objects, features and advantages of the present invention will become more readily apparent, a more particular description of the invention will be rendered by reference to the appended drawings and appended detailed description.
Example 1
Cesium is an open source JavaScript graphics library for the display of three-dimensional models in a browser. Cesium is built based on an open structure 3DTiles, hardware acceleration is performed by using WebGL, and three-dimensional data can be displayed across platforms and browsers. Because its 3DTiles format supports streaming, a relatively efficient standard web distribution can be formed, facilitating the display of large-scale oblique photography model data. Cesium is a very promising digital earth platform for displaying geospatial data.
In view of this, the present embodiment provides a large-scale three-dimensional model display optimization method, which includes the following three steps: the data in the osgb format is recursively reconstructed into a new index, the data in the osgb format is iteratively and simply compressed, and the osgb format is converted into a 3DTiles format.
As shown in fig. 1 and fig. 2, the method for optimizing the large-scale three-dimensional model display provided in this embodiment specifically includes:
step 100: acquiring osgb format raw data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks, each data block stored as a Tile (Tile); each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, the fineness of the three-dimensional models of the top level gradually increases from the three-dimensional model of the top level to the three-dimensional model of the bottom level, wherein the fineness of the three-dimensional model of the top level only can show the rough outline of the three-dimensional model, and the three-dimensional model of each level is stored as an osgb file. Each tile node mainly stores a bounding volume, a geometry error, a content (a three-dimensional model corresponding to a tile), and a child tile information of the tile. The three-dimensional model is a model composed of triangle net file information; the triangle mesh file information includes triangle mesh information and texture information.
Step 200: performing recursion reconstruction on the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf nodes are used for storing addresses of the triangle network file information.
The original data in the osgb format is provided with multi-detail-level LOD data, and different LOD data can be selected for display according to the viewpoint distance. And performing recursion reconstruction on the data blocks in the original data in the osgb format to obtain a new index, a new bounding box, a new screen error and the like, thereby solving the problem of fragmentation of the original large-scale oblique photography model data file.
As shown in fig. 2, the specific implementation is as follows:
and 2.1, traversing model nodes in original data in an osgb format, and acquiring model top node data of each three-dimensional model under a total folder, wherein the model top node data comprises information such as X-axis maximum value Xmax, X-axis minimum value Xmin, Y-axis maximum value Ymax, Y-axis minimum value Ymin, Z-axis maximum value Zmax, Z-axis minimum value Zmin, root node number, total bounding boxes, multi-detail LOD data and the like of each partial maximum AABB bounding box. And meanwhile, a set threshold value, such as the maximum number of sub-Tile nodes, the maximum number of root nodes, the maximum number of model top-level nodes and the like, needs to be determined.
Step 2.2, according to the model top node data in step 2.1, calculating the spatial position relationship of each three-dimensional model on the XOY plane, for example: and obtaining an XY row mark according to the information such as the X is a foundation block, the Y is a foundation block and the like.
And 2.3, carrying out recursion splitting and merging operation on each data block based on the spatial position relation of each three-dimensional model on the XOY plane to obtain the reconstructed data block.
The following operations are performed for any one of the data blocks to obtain a reconstructed data block.
Step 1: and judging whether the number of model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold value, and obtaining a first judging result.
Step 2: and if the first judgment result shows that the number of the model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold, performing partitioning operation on the data block to obtain a data block after the partitioning operation, and returning to the step 1.
Step 3: if the first judgment result indicates that the number of model top nodes of the three-dimensional model at the top layer of the data block does not exceed the set threshold, merging the data block with surrounding data blocks according to the spatial position relation of each three-dimensional model on the XOY plane to obtain the data block after merging operation, returning to the step 1 as shown in fig. 3 until the merging operation is not performed and the number of model top nodes of the three-dimensional model at the top layer of the data block after merging operation does not exceed the set threshold.
Step 4: and (3) processing the data block sub-top three-dimensional model and the data of each level below according to the operations from the step (1) to the step (3) to obtain a reconstructed data block.
One example is: and newly creating osg, namely storing linked list nodes of the repartitioned osgb file by a Group node split Group. Traversing the access subtree downwards from the root node root, judging whether the subtree is a pagedLod node, and if yes, directly adding the split group.
The pagedLod node is a node in osg, the paging detail level node (osg:: pagedLOD) inherits from osg:: LOD node, and is also a detail level node used for realizing dynamic paging loading, and the paging detail level node can also contain the LOD node according to the requirement of the loading according to the viewpoint. The difference between the system and the osg:LOD node is that the osg:LOD node exists in one file, each node of the osg:pagedLOD is a file in a disk, the files can be loaded according to the needs, and a separate thread is responsible for real-time scheduling and loading in the loading process.
Step 2.4, determining a new three-dimensional model according to the reconstructed data block, and determining a new bounding box according to the new three-dimensional model; the calculation formulas of the length w and the width h of the new bounding box are as follows:
the calculation formula of the length w is as follows: w=box.xmax () -box.xmin ().
The calculation formula of the width h is: h=box.ymax () -box.ymin ().
Wherein box.xmax () represents the maximum value of the bounding box on the X-axis, box.xmin () represents the minimum value of the bounding box on the X-axis, box.ymax () represents the maximum value of the bounding box on the Y-axis, and box.ymin () represents the minimum value of the bounding box on the Y-axis.
If w < h, the new bounding box nodes box1, box2, box3 and box4 are larger bounding boxes.
box1.xMax() = box2.xMax() = box.xMin() + w * 0.5;
box1.yMax() = box2.yMin() = box.yMin() + h * 0.5;
box3.xMin() = box4.xMin() = box.xMin() + w * 0.5;
box3.yMax() = box4.yMin() = box.yMin() + h * 0.5;
And 2.5, generating an index by the new three-dimensional model and the new bounding box to obtain an index tree, and obtaining the index tree.
Further, the method provided in this embodiment further includes: and determining a new screen error according to the reconstructed data block and the new three-dimensional model.
Step 300: and simplifying the triangle network file information in the original data of the osgb format, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain the simplified and compressed osgb format data.
The three-dimensional models with different levels are models formed by the triangular network file information, and the data volume can be reduced by simplifying and compressing the triangular network file information, but meanwhile, the accuracy can be influenced after the triangular network file information is compressed, so that a certain choice is needed to achieve the purpose of better effect of transmission and rendering. Obviously, the simplified compression of the triangle network file information is a key for solving the problem of large single data volume in network transmission.
In this embodiment, the improved QEM algorithm is first adopted to iterate and simplify the triangle mesh file information in the osgb format original data until the model features can be reserved and a better simplifying effect is achieved. Secondly, compressing triangle network information in the triangle network file information after iteration simplification by adopting a drago algorithm or an edgebreak algorithm of a google open source, and compressing texture information in the triangle network file information after iteration simplification by adopting a ktx2 algorithm to obtain the osgb format data after the simplification.
In this embodiment, the step 300 is specifically implemented as follows:
step 3.1, reading the original data in the osgb format, and traversing geometric nodes (namely nodes of triangle mesh file information) in the original data in the osgb format, wherein the triangle mesh file information comprises triangle mesh information and texture information; the triangle mesh information comprises vertex information, side information, normal vector information and plane information of the triangle mesh.
And 3.2, calculating the weight of all the vertexes of the triangular network information according to the obvious degree of influence on the model characteristics and the connection information among the vertexes. The importance measure of the edge to be collapsed is calculated from the cosine value of the dihedral angle (the inner product of the two surface normals), which reflects whether the local area around a certain point is flat.
And 3.3, performing simplified collapse on the two vertexes with the minimum weight values in each two planes. For example, a set of two vertices v1 and v2 with the smallest weight values are collapsed into a single pointThe calculation formula is as follows:
wherein argmin is a mathematical term that indicates the value of an argument (or parameter) that a certain function takes to a minimum value; "arg" stands for "image", i.e., an argument; "min" represents "minimum", i.e., the minimum taken by the function. plane means plane;representing the vertices v1, v2 … … that make up plane p. distance represents distance.
The above formula represents a simplification of the edge connecting the two vertices v1 and v2, finding an optimized pointThe error between the vertex v and the plane p is minimized, thereby simplifying.
The specific process of the step 3.3 is as follows:
(1) The equation for the plane p is set as: ax+by+cz+d=0 and+/>+/>=1, hold parameters a, b, c, d.
(2) Any point outside plane pThe distance to plane p is expressed as:
wherein abcd can refer to step (1), representing a plane equation, dis (v) representing the distance from a point v outside the plane to a plane p, the meaning of p being followed by a bracket, denoted by a matrix, T being the sign of the matrix in discrete math.
(3) kp is referred to as the basic secondary matrix of plane p.
(4) The domain plane set of mesh vertices V is: set_p (V) = { plane1, plane2 … … plane },represented as the sum of all squares of vertex V and plane Set _ p (V).
Let the secondary error corresponding to vertex V be Q:
(5) Optimum apex for collapse formationI.e. error function->Error function->Is a quadratic function, and the problem of finding its minimum is a linear problem; />As a linear function.
For the followingMatrixIs empty because of +.>Is a homogeneous vector, which +.>The component is always 1. Assuming this matrix is reversible, it can be derived:
(6) The RGB values are added into the QEM so that different model parts can be distinguished more quickly, and more accurate collapse cost is obtained.
And 3.4, if the minimum collapse cost is within the allowable range, determining a new vertex, deleting the original edge and connecting the new edge, repeating the operation until simplification is completed, and finally regenerating osgb format data, namely iterating the simplified data. The triangle mesh information simplifying effect is shown in fig. 4.
And 3.5, re-reading the simplified triangle mesh file information, including vertex information, side information, normal vector information, surface information and texture information. And the drago algorithm or the edgebreak algorithm compresses the triangle network information in the triangle network file information after the iteration is simplified, and the topological relation between the triangle network file information and the current triangle is recorded through five codes of C, L, E, R and S.
By using the coding mode, the vertex information can represent all vertexes by only using a small part of vertex information and character coding, and meanwhile, the device is provided with a decoder, and the original triangle mesh information can be completely restored according to the coding rule.
And 3.6, re-reading the simplified texture information for extraction, wherein most of the texture information is jpg format pictures. The method uses ktx algorithm to compress the data, processes the data into ktx format files which can be efficiently rendered, reduces the data volume, and simultaneously has a rendering speed faster than jpg and adapts to various platforms.
Step 400: and according to the index tree and the simplified compressed osgb format data, the corresponding osgb format data is called according to the requirement of a user, and is converted into 3D (data transmission) files format data for transmission and display, wherein the effect is shown in figure 5.
In this embodiment, step 400 specifically includes:
firstly, converting the simplified and compressed osgb format data according to a 3DTiles format to generate b3dm format data; secondly, generating a tileset.json file according to the index tree; the tileset.json file is an index file for reading b3dm format data, and when scheduling is performed, the data of which layer of fine hierarchy can be known through tileset.json. Then, according to the tileset.json file and the user requirement, corresponding b3dm format data is called; and finally, carrying out GZip compression, transmission and display on the corresponding b3dm format data. The data volume can be reduced but the integrity of the data is not problematic due to lossless compression in the process of GZip, and the transmission speed of 3DTiles can be improved.
Example two
In order to execute the corresponding method of the above embodiment to achieve the corresponding functions and technical effects, a large-scale three-dimensional model display optimization system is provided below.
The large-scale three-dimensional model display optimization system provided by the embodiment comprises:
the data acquisition module is used for acquiring osgb format original data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks; each of the data blocks is stored as a tile; each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, and the three-dimensional models of each level are stored as an osgb file; the three-dimensional model is a model composed of triangle net file information; the triangle mesh file information includes triangle mesh information and texture information.
The index tree generation module is used for recursively reconstructing the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf nodes are used for storing addresses of the triangle network file information.
The simplified compression module is used for simplifying the triangle network file information in the original data of the osgb format, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain the simplified compressed osgb format data.
And the transmission display module is used for calling the corresponding osgb format data according to the index tree and the simplified compressed osgb format data and user requirements, converting the corresponding osgb format data into 3DTiles format data, and then transmitting and displaying the data.
Example III
An embodiment of the present invention provides an electronic device including a memory for storing a computer program and a processor that runs the computer program to cause the electronic device to execute the large-scale three-dimensional model exhibition optimization method of the first embodiment.
Alternatively, the electronic device may be a server.
In addition, the embodiment of the invention further provides a computer readable storage medium, which stores a computer program, and the computer program realizes the large-scale three-dimensional model exhibition optimization method of the first embodiment when being executed by a processor.
By combining all the technical schemes, the invention has the following advantages:
the invention designs and realizes a method, a system and electronic equipment for optimizing the display of a large-scale three-dimensional model based on a process on the basis of researching the lack of ignition of the large-scale three-dimensional model by using the currently used commercial software.
The final generated files of the osgb format files input by the invention are 3DTiles format files, are all file formats with strong applicability, can be displayed in a cross-platform manner, have forced requirements on file folder naming when no data is input, and generate universal data format 3DTiles rather than specific format files after processing, thereby enhancing the applicability of the files.
The invention can realize the reconstruction of the large-scale three-dimensional model, newly build indexes, simplify compression and display, effectively reduce the problems of broken large-scale three-dimensional model files, large data volume and the like, improve the loading and rendering speeds of the large-scale three-dimensional model and reduce the resource consumption of a computer.
In the present specification, each embodiment is described in a progressive manner, and each embodiment is mainly described in a different point from other embodiments, and identical and similar parts between the embodiments are all enough to refer to each other. For the system disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section.
The principles and embodiments of the present invention have been described herein with reference to specific examples, the description of which is intended only to assist in understanding the methods of the present invention and the core ideas thereof; also, it is within the scope of the present invention to be modified by those of ordinary skill in the art in light of the present teachings. In view of the foregoing, this description should not be construed as limiting the invention.

Claims (6)

1. A method for optimizing the display of a large-scale three-dimensional model, comprising the steps of:
acquiring osgb format raw data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks; each of the data blocks is stored as a tile; each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, and the three-dimensional models of each level are stored as an osgb file; the three-dimensional model is a model composed of triangle net file information; the triangle file information comprises triangle information and texture information;
performing recursion reconstruction on the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf node is used for storing the address of the triangle network file information;
simplifying the triangle network file information in the original osgb format data, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain simplified and compressed osgb format data;
according to the index tree and the simplified compressed osgb format data, corresponding osgb format data are called according to user requirements, and are converted into 3DTiles format data for transmission and display;
the method specifically comprises the steps of performing recursion reconstruction on a data block in the osgb format original data to generate an index tree, wherein the method specifically comprises the following steps:
traversing model nodes in original data in osgb format to obtain model top node data of each three-dimensional model;
according to the model top node data, the spatial position relation of each three-dimensional model on the XOY plane is counted;
based on the spatial position relation of each three-dimensional model on the XOY plane, carrying out recursion splitting and merging operation on each data block to obtain a reconstructed data block;
determining a new three-dimensional model according to the reconstructed data block, and determining a new bounding box according to the new three-dimensional model;
generating an index by the new three-dimensional model and the new bounding box to obtain an index tree;
based on the spatial position relation of each three-dimensional model on the XOY plane, carrying out recursion splitting and merging operation on each data block to obtain a reconstructed data block, wherein the method specifically comprises the following steps:
the following operations are executed on any data block to obtain a reconstructed data block;
step 1: judging whether the number of model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold value or not, and obtaining a first judging result;
step 2: if the first judgment result shows that the number of model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold, performing partitioning operation on the data block to obtain a data block after the partitioning operation, and returning to the step 1;
step 3: if the first judgment result shows that the number of model top nodes of the three-dimensional model at the top layer of the data block does not exceed the set threshold, merging the data block with surrounding data blocks according to the spatial position relation of each three-dimensional model on the XOY plane to obtain a data block after merging operation, and returning to the step 1 until the merging operation is not performed and the number of model top nodes of the three-dimensional model at the top layer of the data block after merging operation does not exceed the set threshold;
step 4: and (3) processing the data block sub-top three-dimensional model and the data of each level below according to the operations from the step (1) to the step (3) to obtain a reconstructed data block.
2. The method of optimizing the presentation of a large-scale three-dimensional model according to claim 1, further comprising: and determining a new screen error according to the reconstructed data block and the new three-dimensional model.
3. The method for optimizing large-scale three-dimensional model display according to claim 1, wherein the method for optimizing large-scale three-dimensional model display is characterized by simplifying the triangle mesh file information in the osgb format original data, and compressing the triangle mesh information and the texture information in the simplified triangle mesh file information respectively to obtain simplified compressed osgb format data, and specifically comprises the steps of:
adopting an improved QEM algorithm to iterate and simplify the triangle net file information in the osgb format original data;
compressing triangle mesh information in the triangle mesh file information after the simplification by adopting a draco algorithm or an edgebreak algorithm, and compressing texture information in the triangle mesh file information after the simplification by adopting a ktx algorithm to obtain the osgb format data after the simplification.
4. The method for optimizing the display of a large-scale three-dimensional model according to claim 1, wherein the method for optimizing the display of the large-scale three-dimensional model is characterized by calling corresponding osgb format data according to user requirements according to the index tree and the simplified compressed osgb format data, and converting the corresponding osgb format data into 3DTiles format data for transmission and display, and specifically comprises the following steps:
converting the simplified compressed osgb format data according to a 3DTiles format to generate b3dm format data;
generating a tileset.json file according to the index tree; the tileset.json file is an index file for reading b3dm format data;
according to the tileset.json file and the user requirement, corresponding b3dm format data are called;
and carrying out GZip compression, transmission and display on the corresponding b3dm format data.
5. A large-scale three-dimensional model display optimization system, comprising:
the data acquisition module is used for acquiring osgb format original data describing geospatial information; the osgb format raw data are large-scale oblique photography model data describing geospatial information; the osgb format raw data includes a plurality of data blocks; each of the data blocks is stored as a tile; each tile stores a plurality of levels of three-dimensional models, the fineness of the three-dimensional models of each level is different, and the three-dimensional models of each level are stored as an osgb file; the three-dimensional model is a model composed of triangle net file information; the triangle file information comprises triangle information and texture information;
the index tree generation module is used for recursively reconstructing the data blocks in the osgb format original data to generate an index tree; the index tree comprises a plurality of root nodes, subtree nodes hung under each root node and leaf nodes hung under each subtree node; the root node is used for storing the address of the reconstructed data block; the subtree nodes are used for storing the addresses of the new bounding boxes; the leaf node is used for storing the address of the triangle network file information;
the simplified compression module is used for simplifying the triangle network file information in the original data in the osgb format, and respectively compressing the triangle network information and the texture information in the simplified triangle network file information to obtain the simplified compressed osgb format data;
the transmission display module is used for calling corresponding osgb format data according to the index tree and the simplified compressed osgb format data and user requirements, converting the corresponding osgb format data into 3DTiles format data and then transmitting and displaying the data;
the method specifically comprises the steps of performing recursion reconstruction on a data block in the osgb format original data to generate an index tree, wherein the method specifically comprises the following steps:
traversing model nodes in original data in osgb format to obtain model top node data of each three-dimensional model;
according to the model top node data, the spatial position relation of each three-dimensional model on the XOY plane is counted;
based on the spatial position relation of each three-dimensional model on the XOY plane, carrying out recursion splitting and merging operation on each data block to obtain a reconstructed data block;
determining a new three-dimensional model according to the reconstructed data block, and determining a new bounding box according to the new three-dimensional model;
generating an index by the new three-dimensional model and the new bounding box to obtain an index tree;
based on the spatial position relation of each three-dimensional model on the XOY plane, carrying out recursion splitting and merging operation on each data block to obtain a reconstructed data block, wherein the method specifically comprises the following steps:
the following operations are executed on any data block to obtain a reconstructed data block;
step 1: judging whether the number of model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold value or not, and obtaining a first judging result;
step 2: if the first judgment result shows that the number of model top nodes of the three-dimensional model at the top layer of the data block exceeds a set threshold, performing partitioning operation on the data block to obtain a data block after the partitioning operation, and returning to the step 1;
step 3: if the first judgment result shows that the number of model top nodes of the three-dimensional model at the top layer of the data block does not exceed the set threshold, merging the data block with surrounding data blocks according to the spatial position relation of each three-dimensional model on the XOY plane to obtain a data block after merging operation, and returning to the step 1 until the merging operation is not performed and the number of model top nodes of the three-dimensional model at the top layer of the data block after merging operation does not exceed the set threshold;
step 4: and (3) processing the data block sub-top three-dimensional model and the data of each level below according to the operations from the step (1) to the step (3) to obtain a reconstructed data block.
6. An electronic device comprising a memory for storing a computer program and a processor that runs the computer program to cause the electronic device to perform the large-scale three-dimensional model presentation optimization method according to any one of claims 1 to 4.
CN202310664180.2A 2023-06-07 2023-06-07 Large-scale three-dimensional model display optimization method and system and electronic equipment Active CN116401332B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310664180.2A CN116401332B (en) 2023-06-07 2023-06-07 Large-scale three-dimensional model display optimization method and system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310664180.2A CN116401332B (en) 2023-06-07 2023-06-07 Large-scale three-dimensional model display optimization method and system and electronic equipment

Publications (2)

Publication Number Publication Date
CN116401332A CN116401332A (en) 2023-07-07
CN116401332B true CN116401332B (en) 2023-09-29

Family

ID=87012689

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310664180.2A Active CN116401332B (en) 2023-06-07 2023-06-07 Large-scale three-dimensional model display optimization method and system and electronic equipment

Country Status (1)

Country Link
CN (1) CN116401332B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116721218B (en) * 2023-07-08 2024-01-26 南京信息工程大学 Three-dimensional real estate model light-weight method, system and equipment
CN116630552B (en) * 2023-07-26 2023-11-07 北京中科辅龙智能技术有限公司 Optimized rendering method for large-scale three-dimensional process factory model

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111858828A (en) * 2020-09-24 2020-10-30 北京数字政通科技股份有限公司 Three-dimensional geographic data oriented transmission and rendering method and system
CN112365598A (en) * 2020-10-29 2021-02-12 深圳大学 Method, device and terminal for converting oblique photography data into three-dimensional data
CN114170394A (en) * 2021-12-03 2022-03-11 北京数字政通科技股份有限公司 Display optimization method and device of mass oblique data on Web end

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109934914B (en) * 2019-03-28 2023-05-16 东南大学 Embedded city design scene simulation method and system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111858828A (en) * 2020-09-24 2020-10-30 北京数字政通科技股份有限公司 Three-dimensional geographic data oriented transmission and rendering method and system
CN112365598A (en) * 2020-10-29 2021-02-12 深圳大学 Method, device and terminal for converting oblique photography data into three-dimensional data
CN114170394A (en) * 2021-12-03 2022-03-11 北京数字政通科技股份有限公司 Display optimization method and device of mass oblique data on Web end

Also Published As

Publication number Publication date
CN116401332A (en) 2023-07-07

Similar Documents

Publication Publication Date Title
CN116401332B (en) Large-scale three-dimensional model display optimization method and system and electronic equipment
CN110070613B (en) Large three-dimensional scene webpage display method based on model compression and asynchronous loading
KR101546703B1 (en) System for processing massive bim data of building
Gobbetti et al. C‐BDAM–compressed batched dynamic adaptive meshes for terrain rendering
CN103093499B (en) A kind of city three-dimensional model data method for organizing being applicable to Internet Transmission
KR101546705B1 (en) Method for visualizing building-inside bim data by bim data process terminal
CN113870437A (en) Digital twin BIM model conversion and lightweight method and device
Ruzinoor et al. A review on 3D terrain visualization of GIS data: techniques and software
CN101119485A (en) Characteristic reservation based three-dimensional model progressive transmission method
US20080012853A1 (en) Generating mesh from implicit surface
CN116051759B (en) Method for generating oblique photography LOD simplified model
CN113593051A (en) Live-action visualization method, dam visualization method and computer equipment
Novák et al. Rasterized bounding volume hierarchies
EP4287134A1 (en) Method and system for generating polygon meshes approximating surfaces using root-finding and iteration for mesh vertex positions
CN112102486A (en) Merging root node-based oblique photography data LOD reconstruction method
CN113470172B (en) Method for converting OBJ three-dimensional model into 3DTiles
CN108228723A (en) WEB three-dimensional modeling datas construction method and computer readable storage medium
CN114461959A (en) WEB side online display method and device of BIM data and electronic equipment
El Haje et al. 3D cities rendering and visualisation: a web-based solution
Scholz et al. Level of Detail for Real-Time Volumetric Terrain Rendering.
Platings et al. Compression of Large‐Scale Terrain Data for Real‐Time Visualization Using a Tiled Quad Tree
Tariq et al. Instanced model simplification using combined geometric and appearance-related metric
Jiang et al. A large-scale scene display system based on webgl
US11954802B2 (en) Method and system for generating polygon meshes approximating surfaces using iteration for mesh vertex positions
CN116168188B (en) Fusion method, system and equipment for large-range inclined three-dimensional data

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant