Method for restoring Internet map vector tile data to construct real geographic position three-dimensional scene, computer equipment and computer program product
By receiving and processing internet map vector tile data, a life-size 3D model is generated, solving the problems of lost and scattered geographic information, and realizing low-cost and efficient 3D scene construction, supporting professional applications.
Patent Information
- Application Number
- CN202510999568.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-18
- Publication Date
- 2025-11-25
AI Technical Summary
Existing technologies struggle to efficiently and cost-effectively utilize internet map vector tile data to construct 3D scenes with realistic geographic coordinates and detailed features, and existing methods suffer from the loss or dispersion of geographic information.
By receiving dynamic geographic range data input by the user, converting it into a standard geographic coordinate system, calculating the coordinate range of the tile matrix, downloading and parsing vector tile data, stitching features across tiles, classifying them based on attribute semantics and determining 3D parameters, generating a 3D model of real size, and binding it to the target geographic coordinate system.
It enables low-cost, automated construction of high-fidelity 3D geographic scenes, restoring the original topological integrity and geographic information, ensuring strict alignment between the 3D scene and the real-world location, and supporting professional applications such as digital twins and urban planning.
Smart Images

Figure CN121010713A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of modeling technology, and in particular to a method, computer device, and computer program product for restoring Internet map vector tile data to construct a three-dimensional scene of a real geographical location. Background Technology
[0002] With the development of virtual reality (VR), augmented reality (AR), and digital twin technologies, the demand for constructing 3D scenes of real geographical environments is increasing. Traditional 3D modeling methods rely on data such as aerial photogrammetry and laser point clouds, which suffer from high costs and long update cycles.
[0003] The vector tile data provided by Internet maps (such as OpenStreetMap vector tiles and Mapbox VectorTiles) contains rich geographic features (roads, buildings, water bodies, etc.). However, most of these features have undergone vector thinning simplification, coordinate offsetting, slicing, and other processing, resulting in the loss or dispersion of the original geographic information. Therefore, existing technologies cannot directly use such vector tile data to construct 3D scenes with real geographic coordinates and detailed features. Summary of the Invention
[0004] This application provides a method, computer device, and computer program product for reconstructing vector tile data from internet maps to build a three-dimensional scene with a real geographical location, solving the technical problem mentioned in the background art of how to efficiently, cost-effectively, and accurately reverse-engineer vector tile data provided by internet maps to build a three-dimensional model.
[0005] In a first aspect, embodiments of this application provide a method for restoring internet map vector tile data to construct a three-dimensional scene of a real geographical location, the method comprising:
[0006] Receive dynamic geographic range data input by the user and convert the dynamic geographic range data into a geographic range in a standard geographic coordinate system;
[0007] Based on the geographical range and preset tile levels, the matrix coordinate range of each tile within the geographical range is calculated using a preset reverse projection method, and a vector tile request address is generated.
[0008] Download the binary vector tile data corresponding to the vector tile request address;
[0009] The binary vector tile data is parsed, and vector features containing geometric types, attribute semantics, and block coordinates are extracted from the binary vector tile data;
[0010] Based on the attribute semantics of the vector elements, the same geometric elements scattered across different tiles are topologically merged to generate complete geographic elements;
[0011] The complete geographic elements are uniformly converted to the target geographic coordinate system;
[0012] The complete geographic features are classified according to their attribute semantic types to obtain different types of vector features;
[0013] Each type of vector element has a preset three-dimensional parameter. Based on the preset three-dimensional parameter of each type of building vector element, the complete geographic element is converted into a three-dimensional model with real size and bound to the target geographic coordinate system.
[0014] Based on the target geographic coordinate system, a 3D model of the actual size is generated and output.
[0015] In some embodiments, calculating the matrix coordinate range of each tile within the geographical range using a preset inverse projection method based on the geographical range and preset tile levels includes:
[0016] The range of latitude and longitude coordinates of the geographical area is converted into Mercator plane coordinates;
[0017] Based on the preset tile levels and the range of Mercator plane coordinates, the minimum and maximum tile indices are calculated using an inverse formula to determine the range of the tile matrix to be downloaded.
[0018] In some embodiments, the type of the vector element includes architectural vector elements;
[0019] The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include:
[0020] Architectural vector elements are obtained from various different types of vector elements. For the architectural vector elements, a roof and exterior wall model is generated based on the height attribute field or the default value.
[0021] In some embodiments, the type of the vector element includes a road vector line element;
[0022] The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include:
[0023] Road vector elements are obtained from various types of vector elements, and a preset width is matched according to the semantic classification corresponding to the road vector line elements to generate a three-dimensional road model.
[0024] In some embodiments, the type of the vector feature includes a water body vector feature;
[0025] The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include:
[0026] Water body vector elements are obtained from various types of vector elements. The geometric surfaces of the water body vector elements are processed by a triangulation algorithm to eliminate texture deformation caused by irregular shapes. A preset water body texture is bound and a repeat mapping mode is set to generate a 3D water body model with real geographic coordinates.
[0027] In some embodiments, the type of the vector feature includes a green space vector surface feature;
[0028] The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include:
[0029] Green space vector surface features are obtained from various types of vector features. These green space vector surface features are raised to a preset base height to distinguish them from adjacent features. The geometric surfaces of the green space vector surface features are processed using a triangulation algorithm. The green space vector surface features are then bound to a preset green space texture and a repeat mapping mode is set to generate a 3D green space model with real geographic coordinates.
[0030] In some embodiments, the three-dimensional model of the actual size is generated and output based on the target geographic coordinate system:
[0031] The three-dimensional models of different types of vector elements at their actual dimensions are overlaid according to the target geographic coordinate system to generate a unified three-dimensional scene;
[0032] Each real-size 3D model is exported as a 3D format that supports geographic coordinate embedding, so that the vertex coordinates of each real-size 3D model are directly associated with latitude and longitude or projected coordinates, achieving seamless overlay with geographic information systems.
[0033] In some embodiments, the step of topologically merging the same geometric features scattered across different tiles to generate complete geographic features based on the attribute semantics of the vector features includes:
[0034] For linear or planar features, segments in adjacent tiles are matched using the attribute semantic fields; the geometric dissolution algorithm is used to merge the matched segments, eliminating the breaks caused by segmentation and forming a continuous geometry.
[0035] In a second aspect, this application also proposes a computer device, comprising: a memory, a processor, and a computer executable program stored in the memory and executable on the processor, the computer executable program being configured to implement the steps of the method described in the first aspect above for restoring Internet map vector tile data to construct a three-dimensional scene of real geographic location.
[0036] Thirdly, this application also proposes a computer program product that stores a computer executable program, which, when executed by a processor, implements the steps of the method described in the first aspect for restoring Internet map vector tile data to construct a three-dimensional scene of a real geographical location.
[0037] The beneficial effects of this application are as follows: by inversely calculating the matrix coordinate range of the tiles, the true geographic coordinates are restored, eliminating the offset error caused by the encryption of map service providers; broken vector elements across tiles are stitched together to restore their original topological integrity; real parameters are inversely mapped based on semantic tags to drive high-precision 3D modeling; and a 3D model of the true size is generated and output based on the target geographic coordinate system, ensuring that the 3D scene is strictly aligned with the real-world location. This solves the problem of geographic information distortion caused by slicing, offsetting, and simplification of internet vector tile data. Ultimately, it enables low-cost, automated construction of high-fidelity 3D geographic scenes to support professional applications. Attached Figure Description
[0038] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0039] Figure 1 This is a flowchart illustrating the method for reconstructing a three-dimensional scene of a real geographical location by restoring vector tile data from an internet map, as provided in an embodiment of the present invention.
[0040] Figure 2 This is a schematic diagram of the geometric structure of two vector tile elements involved in an embodiment of the present invention;
[0041] Figure 3 This is a schematic diagram of FME vector tile to gpkg conversion according to an embodiment of the present invention;
[0042] Figure 4This is a schematic diagram illustrating the semantic classification of vector tile elements using FME software, as described in an embodiment of the present invention.
[0043] Figure 5 A schematic diagram illustrating the architectural modeling process using FME software, provided in an embodiment of the present invention.
[0044] Figure 6 A schematic diagram illustrating the road modeling process using FME software, provided in an embodiment of the present invention.
[0045] Figure 7 A schematic diagram illustrating the process of water body modeling using FME software as provided in an embodiment of the present invention;
[0046] Figure 8 A schematic diagram illustrating the process of using FME software for green space modeling as provided in an embodiment of the present invention;
[0047] Figure 9 A schematic diagram illustrating the use of FME software for model merging in an embodiment of the present invention;
[0048] Figure 10 This is a simplified structural diagram of the computer device provided in the embodiments of this application. Detailed Implementation
[0049] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein is for the purpose of describing particular embodiments only and is not intended to limit the application; the terms “comprising” and “having”, and any variations thereof, in the specification, claims, and foregoing description of the drawings are intended to cover non-exclusive inclusion.
[0050] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0051] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.
[0052] In the description of the embodiments of this application, the term "multiple" refers to two or more (including two), unless otherwise expressly and specifically defined.
[0053] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0054] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0055] The inventors of this application have noticed that vector tile data provided by internet maps (such as OpenStreetMap vector tiles and Mapbox Vector Tiles) contains rich geographic features (roads, buildings, water bodies, etc.). However, most of these features have undergone vector thinning simplification, coordinate offsetting, and tiling, resulting in the loss or dispersion of original geographic information. Therefore, existing technologies cannot directly utilize such vector tile data to construct 3D scenes with realistic geographic coordinates and detailed features. How to efficiently, cost-effectively, and accurately convert vector tile data into 3D models has become an urgent technical problem to be solved.
[0056] To address the aforementioned technical problems, this application proposes a method, computer equipment, and computer product for restoring Internet map vector tile data to construct a three-dimensional scene of a real geographical location. To illustrate the technical solution proposed in the embodiments of this application, specific embodiments are described below.
[0057] It should be noted that all existing map applications on the Internet include vector tile map services. These vector tiles are not all the same. The most commonly used and relatively easy-to-obtain vector tile map formats are MVT and PBF. Moreover, most of these map services are derived from OSM data and are mostly open source and free. This embodiment can select one of the above-mentioned vector tile map services to ensure the consistency and stability of the data structure.
[0058] Please see Figure 1 This is a flowchart illustrating a method for reconstructing internet map vector tile data to construct a three-dimensional scene of a real geographical location, as provided in the first embodiment of this application. The method mainly includes steps S1 to S5:
[0059] Step S1. Dynamic Range Resolution and Tile Request Generation :
[0060] S1a: Receive dynamic geographic range data input by the user and convert the dynamic geographic range data into a geographic range in a standard geographic coordinate system (such as WGS84).
[0061] Understandably, the dynamic geographic extent data input by the user can be target area boundary data (such as vector surfaces like shapefiles or geojson, or rectangular ranges of latitude and longitude), its purpose being to clarify the real geographic area that needs to be restored (e.g., the area within the fifth ring road of a city). Using the user-input dynamic geographic extent data as the starting point for the entire method, its coordinates must be uniformly converted to a standard geographic coordinate system (such as WGS84) to ensure the consistency of the benchmark for subsequent calculations.
[0062] S1b: Based on the geographical range and the preset tile level (e.g., z=14), calculate the matrix coordinate range (tileX, tileY) of each tile within the geographical range using a preset reverse projection method (e.g., Mercator projection reverse method), and generate a vector tile request address;
[0063] Understandably, the preset tile level represents the resolution level of the data. Its function is that the higher the level (the larger the z value), the higher the tile resolution and the richer the geometric details contained (e.g., z=14 can cover all elements of OSM vector tiles).
[0064] For example, the latitude and longitude coordinates of the geographic area are converted into Mercator plane coordinates. Based on the preset tile level and the Mercator coordinate range, the minimum and maximum tile indices (tileX_min, tileY_min to tileX_max, tileY_max) are calculated using a reverse formula to determine the range of the tile matrix to be downloaded. That is, based on the latitude and longitude boundaries of the geographic area, combined with the preset tile level (z-value), the indices (tileX, tileY) of all tiles within that range are calculated in reverse using the Mercator projection formula, thereby determining the range of the tile matrix to be downloaded (corresponding to the vector tile request address). Furthermore, the actual geographic area covered by the tiles can be reconstructed through mathematical inverse calculation.
[0065] In practical implementation, the received dynamic geographic range data generally refers to vector polygon data such as shapefiles and geojson, or a rectangular range. For unified processing, this embodiment can use Python's geopandas library to convert them into the WGS84 geographic coordinate system. The vector tile map services selected above all follow the Web Mercator standard map tile tiling rules. Requesting tiles requires dynamically constructing the {z}, {x}, and {y} parameters, where {z} is the map tile pyramid level. Python is used to first parse and obtain the latitude and longitude ranges minx, miny, maxx, and maxy of the dynamic vector, and then convert them into Mercator ranges. For example, by searching relevant information, it can be found that the maximum map level of OSM vector tiles is 14, that is, when the map level is 14, map features in all vector tiles can be requested. Correspondingly, the above reverse formula can be the following formula for converting known Web Mercator coordinates into map tiles:
[0066] tileX=int((WebMercatorX+20037508.3427892) / (2*20037508.3427892)*z)
[0067] tileY=int((20037508.3427892-WebMercatorY) / (2*20037508.3427892)*z)
[0068] By adding the calculated dynamic range with two sets of parameters, z = 14, x = minx_3857, y = miny_3857 and z = 14, x = maxx_3857, y = maxy_3857, the range of the vector tile matrix corresponding to the dynamic range can be calculated. Then, these steps can be written into Python functions.
[0069] In summary, step S1 of this embodiment calculates the tile index in reverse from the user scope, which can restore the original data coverage.
[0070] Step S2. Vector Tile Download and Parsing:
[0071] S2a: Download the binary vector tile data corresponding to the vector tile request address;
[0072] In the specific implementation, a Python program can be pre-written to implement the batch download function of vector map tiles, mainly considering the following key points:
[0073] A. Use aiohttp to implement high-performance asynchronous HTTP requests;
[0074] B. Control the number of concurrent connections using semaphores;
[0075] C. Automatically create a directory tree structure, storing tiles in z / x / y.pbf format to maintain consistency with the vector map tile request address structure;
[0076] D. Add a mechanism to recognize request failure with a 30-second timeout and allow 3 retries on request failure, and set settings to ensure the robustness and stability of the program;
[0077] S2b: Parse the binary vector tile data and extract vector features containing geometric types, attribute semantics, and block coordinates from the binary vector tile data;
[0078] In summary, step S2 of this embodiment can parse the binary serialized tile data and restore it to processable geometric elements.
[0079] Step S3. Joining geometric elements across tiles:
[0080] S3a: Based on the attribute semantics (e.g., class field) of the vector features, topologically merge the same geometric features scattered across different tiles to generate complete geographic features, thereby restoring the complete geometric shape of the same geometric feature;
[0081] Understandably, the "same geometric element" refers to fragments scattered across different tiles, matched based on attribute semantics (e.g., class=highway or building=yes). For example, in the case of a road spanning multiple tiles (divided into multiple line segments), "the same geometric element" refers to the complete geometric shape of this road. Similarly, in the case of a building facade divided into multiple polygons by tile boundaries, "the same geometric element" refers to the complete outline of the building.
[0082] S3b: Transform the complete geographic elements into the target geographic coordinate system;
[0083] Understandably, the "target geographic coordinate system" in S3 is the coordinate system that the 3D scene will ultimately be bound to. In some embodiments, the "target geographic coordinate system" can be the same standard geographic coordinate system as in S1 (such as WGS84) to directly match the real geographic location; in other embodiments, the "target geographic coordinate system" can also be other projected coordinate systems (such as Web Mercator EPSG:3857) to optimize 3D rendering performance. The role of the "target geographic coordinate system" in S3 is to ensure that the coordinate system of the stitched vector elements is consistent with the coordinate system of the subsequent 3D modeling, avoiding positional misalignment.
[0084] In some embodiments, the splicing of cross-tile geometric features in S3 can restore the integrity of features through semantic matching and geometric operations, including: for linear or planar features, matching segments in adjacent tiles through the attribute semantic field; merging the matched segments using a geometric dissolution algorithm to eliminate the breaks caused by segmentation and form a continuous geometry.
[0085] For example, since vector tiles are generally based on the Mapbox Vector Tile (MVT) standard and are serialized into binary using Protocol Buffers (Protobuf), conventional GIS software cannot directly read and use them. They need to be converted into commonly used GIS vector data such as shapefiles (shp) and geojson using GIS tools such as FME before they can be used. In this embodiment, FME's Workbench can be used to build a vector tile to gpkg converter.
[0086] Conversion process ( Figure 3 The following key steps can be designed:
[0087] A. Map tiles are created by cutting vector data from a single layer into blocks of 256*256 or 512*512 size (e.g., ...). Figure 2 Therefore, it is possible to cut a complete surface or line feature into multiple parts. In this embodiment, the "GeometryFilter" tool of FME can be used to classify vector tiles according to geometric types such as points, lines, and surfaces.
[0088] B. Vector tile data stitching of linear and planar elements such as roads, water bodies, and green spaces ensures the integrity of individual features. In this embodiment, the "Dissolver" tool in FME can be used to merge vector features of the same semantic type from two adjacent vector tiles by selecting the "class" field in PBF.
[0089] C. The downloaded vector tile data coordinate system can be geographic coordinates or encrypted offset (domestic vector tile map services such as Bing and ArcGIS). In this embodiment, the "Reprojector" tool of FME can be used to convert the vector tile data coordinate system into the web Mercator coordinate system.
[0090] In summary, step S3 of this embodiment can reverse the splicing of the cut elements to restore the original topological structure.
[0091] Step S4. 3D modeling based on complete geographic features:
[0092] S4a: Classify the complete geographic features according to their attribute semantic types (such as buildings, roads, and water bodies) to obtain different types of vector features;
[0093] This embodiment classifies features using attribute semantics (e.g., building = yes, highway = motorway). In practice, the AttributeFilter tool in FME software can be used to filter features such as buildings, roads, green spaces, and water bodies by the "class" field (corresponding to...). Figure 4 ).
[0094] S4b: Determine the preset three-dimensional parameters (such as building height and road width) corresponding to each type of vector element, convert the complete geographic element into a three-dimensional model with real size based on the preset three-dimensional parameters corresponding to each type of building vector element, and bind the target geographic coordinate system;
[0095] Understandably, in this embodiment, the spatial vertex coordinates of the three-dimensional models of different types of vector elements are bound to the target geographic coordinate system (such as WGS84 or Web Mercator) to ensure that the relative positional relationship of each model in the three-dimensional scene is consistent with the real world.
[0096] In some embodiments, different types of vector features may further include building vector features, road vector line features, water body vector features, and green space vector surface features;
[0097] Step S4b can be further divided into the following sub-steps S4b-1, S4b-2, S4b-3, and S4b-4:
[0098] S4b-1: Obtain building vector elements from various different types of vector elements, and generate roof and exterior wall models for the building vector elements based on the height attribute field or default value;
[0099] In the specific implementation, refer to Figure 5 In the FME Workbench project, you can select the building vector features filtered by S4a to generate two workflows: one to generate the building roof model and the other to generate the building exterior model. The specific methods are as follows:
[0100] A. To generate the roof, you can use the "3DForcer" converter to raise the building surface vector to the basic height (set the default value of 3 for elements with missing height) using the "high" field value. Add a read module and select the JPG format to import the roof texture (select a 256*256 JPG image). You can use the "AppearanceStyler" converter to set the roof texture mode to "Repeat in U and V" to prevent texture distortion caused by irregular building shapes. Then, use the "AppearanceSetter" converter to set it as the roof texture.
[0101] B. To generate the building's exterior walls, use the "GeometryCoercer" converter to convert the building surfaces into lines, and the "Orientor" converter to unify the direction of the edges, ensuring uniformity between the inside and outside of each building's normal. Then, use the "Extruder" tool with the "high" field value to extrude the building outline into a wall (set the default value to 3 for missing height elements). Add a read module, selecting JPG format, and import the wall texture. Use the "AppearanceStyler" converter to set the wall texture mode to "Repeat in U and V," and then use the "AppearanceSetter" converter to set it as a roof texture. Finally, merge the roof model and wall model into a building model.
[0102] S4b-2: Obtain road vector elements from various different types of vector elements, and match a preset width according to the semantic classification corresponding to the road vector line elements to generate a three-dimensional road model.
[0103] In the specific implementation, refer to Figure 6 In the FME software's Workbench project, the road vector line features filtered by S4a can be categorized according to the OSM semantics corresponding to the "class" field in this embodiment as follows (see Table 1 below):
[0104] Table 1 OSM road semantic classification
[0105]
[0106]
[0107] The width of the corresponding road category can be assigned using the “AttributeValueMapper” converter and stored in the “buffer” field. Then, the “Bufferer” tool is used to buffer the road lines into a road surface. The “Extruder” tool is used to set a default thickness of 0.1 meters for the road surface. The “Orientor” converter is used to unify the normal direction of the road surface. The “AppearanceStyler” converter is used to set the road surface color to gray, thus forming a 3D road model.
[0108] S4b-3: Obtain water body vector elements from various types of vector elements, process the geometric surfaces of the water body vector elements through a triangulation algorithm to eliminate texture deformation caused by irregular shapes; bind a preset water body texture and set a repeat mapping mode to generate a 3D water body model with real geographic coordinates.
[0109] In the specific implementation, refer to Figure 7In the FME software's Workbench project, select the water body vector surface features filtered by S4a. In this embodiment, the "Triangulator" tool can be used to break down the water body vector "polygons" to prevent severe stretching and deformation of the texture. Add a read module and select the JPG format to import the water body texture (select a 256*256 JPG image). The "AppearanceStyler" converter can be used to set the water body texture mode to "repeated in U and V" to prevent irregular water body shapes from causing texture deformation. Then, the "AppearanceSetter" converter can be used to set it as a water body texture.
[0110] S4b-4: Obtain green space vector surface features from various types of vector features, raise the green space vector surface features to a preset base height to distinguish them from adjacent features; process the geometric surfaces of the green space vector surface features through a triangulation algorithm, bind the green space vector surface features to a preset green space texture and set a repeat mapping mode to generate a green space 3D model with real geographic coordinates.
[0111] In the specific implementation, refer to Figure 8 In the FME software's Workbench project, select the green space vector surface features filtered by S4a. In this embodiment, 3DForcer can be used to raise the green space vector to a basic height of 0.01 cm (to be higher than the water model). The "Triangulator" tool can be used to break down the "multifaceted" green space vector to prevent severe stretching and deformation of the texture. Add a reading module and select the JPG format to import the green space texture (select a 256*256 JPG image). The "AppearanceStyler" converter can be used to set the green space texture mode to "repeat in U and V" to prevent the irregular shape of the green space from causing texture deformation. Then, the "AppearanceSetter" converter can be used to set it as the green space texture.
[0112] Step S5. Based on the target geographic coordinate system, generate and output the 3D model of the actual dimensions:
[0113] S5a: Overlay the 3D models of different types of vector elements at their actual dimensions according to the target geographic coordinate system to generate a unified 3D scene;
[0114] Understandably, because the original vector tile data has been cut, offset, or projected, the generated independent 3D models (such as buildings and roads) will lead to misalignment between models (such as roads overlapping buildings) if they are not aligned with coordinates. This application's embodiments restore the true spatial relationships by uniformly converting the model vertex coordinates to the target geographic coordinate system (such as the WGS84 processed by S3); for example, the coordinates of the four corner points of a building model must strictly correspond to its latitude and longitude on the Earth's surface, otherwise it cannot match the surrounding roads.
[0115] In the specific implementation, you can refer to Figure 9 In the FME Workbench project, select the 3D models generated by sub-steps S4b-1, S4b-2, S4b-3, and S4b-4. You can use the "Aggregator" tool to overlay them in a 3D scene; ensure that the relative positions of each model in the 3D scene are consistent with the real world.
[0116] S5b (Geographic Reference Format Export): Exports each real-size 3D model as a 3D format that supports geographic coordinate embedding, allowing the vertex coordinates of each real-size 3D model to be directly associated with latitude and longitude or projected coordinates, achieving seamless overlay with the geographic information system.
[0117] The technical effect of this application's embodiments is that this patent utilizes "reverse restoration" technology, including:
[0118] Coordinate restoration (corresponding to step S1): By reversing the calculation of the matrix coordinate range of the tiles, the true geographic coordinates are restored, eliminating the offset error caused by the encryption of the map service provider;
[0119] Geometric restoration (corresponding to step S3): Connect broken vector elements (such as roads and buildings) across tiles to restore their original topological integrity;
[0120] Attribute restoration (corresponding to step S4): Based on semantic labels (such as OSM classification), reverse mapping of real parameters (such as road width and building height) drives high-precision 3D modeling;
[0121] Scene restoration (corresponding to step S5): Based on the target geographic coordinate system, generate and output a 3D model of the actual size to ensure that the 3D scene is strictly aligned with the real-world location.
[0122] This solves the problem of geographic information distortion caused by slicing, offsetting, and simplification of internet vector tile data. Ultimately, it enables low-cost, automated construction of high-fidelity 3D geographic scenes, supporting professional applications (such as digital twins and urban planning).
[0123] Furthermore, embodiments of the present invention provide a computer device, such as... Figure 10As shown, the computer device in this application embodiment can be, but is not limited to, various computers, laptops, smartphones, and tablets. In specific applications, drafters can operate the computer device to execute the method described in the above embodiments of this application for restoring internet map vector tile data to construct a three-dimensional scene with a real geographical location. The electronic device may include: a processor 01, a memory 02, and a computer executable program stored in the memory and executable on the processor. When the processor executes the computer executable program, it implements the steps in the method embodiments of this application for restoring internet map vector tile data to construct a three-dimensional scene with a real geographical location.
[0124] Those skilled in the art will understand that Figure 10 The examples of computer devices are merely examples and do not constitute a limitation on computer devices. They may include more or fewer components than shown, or combinations of certain components, or different components.
[0125] The processor can be a Central Processing Unit (CPU), but it can also be other general-purpose processors, graphics processing units (GPUs), digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.
[0126] In some embodiments, the memory may be an internal storage unit, such as a hard drive or memory of a computer device. In other embodiments, the memory may be an external storage device of the computer device, such as a plug-in hard drive, Smart Media Card (SMC), Secure Digital (SD) card, or Flash Card.
[0127] Furthermore, this application embodiment also provides a storage medium, which is a computer-readable storage medium storing a computer program. When the computer program is executed by a processor, it implements the steps in the above-described method embodiments.
[0128] Furthermore, this application also provides a computer program product that stores a computer executable program. When the computer executable program is executed by a processor, it implements the various steps of the above-described method for restoring Internet map vector tile data to construct a three-dimensional scene of real geographical location.
[0129] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0130] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A method for reconstructing internet map vector tile data to construct a three-dimensional scene of a real geographical location, characterized in that, The method includes: Receive dynamic geographic range data input by the user and convert the dynamic geographic range data into a geographic range in a standard geographic coordinate system; Based on the geographical range and preset tile levels, the matrix coordinate range of each tile within the geographical range is calculated using a preset reverse projection method, and a vector tile request address is generated. Download the binary vector tile data corresponding to the vector tile request address; The binary vector tile data is parsed, and vector features containing geometric types, attribute semantics, and block coordinates are extracted from the binary vector tile data; Based on the attribute semantics of the vector elements, the same geometric elements scattered across different tiles are topologically merged to generate complete geographic elements; The complete geographic elements are uniformly converted to the target geographic coordinate system; The complete geographic features are classified according to their attribute semantic types to obtain different types of vector features; Each type of vector element has a preset three-dimensional parameter. Based on the preset three-dimensional parameter of each type of building vector element, the complete geographic element is converted into a three-dimensional model with real size and bound to the target geographic coordinate system. Based on the target geographic coordinate system, a 3D model of the actual size is generated and output.
2. The method as described in claim 1, characterized in that, The step of calculating the matrix coordinate range of each tile within the geographical range based on the geographical range and the preset tile level using a preset reverse projection method includes: The range of latitude and longitude coordinates of the geographical area is converted into Mercator plane coordinates; Based on the preset tile levels and the range of Mercator plane coordinates, the minimum and maximum tile indices are calculated using an inverse formula to determine the range of the tile matrix to be downloaded.
3. The method as described in claim 1, characterized in that, The types of vector elements include architectural vector elements; The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include: Architectural vector elements are obtained from various different types of vector elements. For the architectural vector elements, a roof and exterior wall model is generated based on the height attribute field or the default value.
4. The method as described in claim 1, characterized in that, The types of vector elements include road vector line elements; The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include: Road vector elements are obtained from various types of vector elements, and a preset width is matched according to the semantic classification corresponding to the road vector line elements to generate a three-dimensional road model.
5. The method as described in claim 1, characterized in that, The types of vector features include water body vector features; The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include: Water body vector elements are obtained from various types of vector elements. The geometric surfaces of the water body vector elements are processed by a triangulation algorithm to eliminate texture distortion caused by irregular shapes. Bind a preset water body texture and set a repeat mapping mode to generate a 3D water body model with real geographic coordinates.
6. The method as described in claim 1, characterized in that, The types of vector features include green space vector surface features; The steps of determining the preset three-dimensional parameters corresponding to each type of vector element, converting the complete geographic elements into three-dimensional models with real dimensions based on the preset three-dimensional parameters corresponding to each type of building vector element, and binding them to the target geographic coordinate system include: Green space vector surface elements are obtained from various different types of vector elements, and the green space vector surface elements are raised to a preset base height to distinguish them from adjacent elements; The geometric surfaces of the green space vector surface elements are processed by a triangulation algorithm, and the green space vector surface elements are bound to a preset green space texture and a repeat mapping mode is set to generate a three-dimensional green space model with real geographic coordinates.
7. The method according to any one of claims 1 to 6, characterized in that, Based on the target geographic coordinate system, a 3D model of the actual size is generated and output: The three-dimensional models of different types of vector elements at their actual dimensions are overlaid according to the target geographic coordinate system to generate a unified three-dimensional scene; Each real-size 3D model is exported as a 3D format that supports geographic coordinate embedding, so that the vertex coordinates of each real-size 3D model are directly associated with latitude and longitude or projected coordinates, achieving seamless overlay with geographic information systems.
8. The method according to any one of claims 1 to 6, characterized in that, The step of topologically merging the same geometric features scattered across different tiles to generate complete geographic features based on the attribute semantics of the vector features includes: For linear or planar features, segments in adjacent tiles are matched using the attribute semantic fields. The geometric dissolution algorithm is used to merge the matched segments, eliminate the breaks caused by block division, and form a continuous geometry.
9. A computer device, characterized in that, include: The memory, the processor, and a computer-executable program stored on the memory and executable on the processor, the computer-executable program being configured to implement the steps of the method for reconstructing Internet map vector tile data to construct a three-dimensional scene of real geographic location as claimed in any one of claims 1 to 8.
10. A computer program product, characterized in that, The computer program product stores a computer executable program, which, when executed by a processor, implements the steps of the method for restoring Internet map vector tile data to construct a three-dimensional scene of real geographical location as described in any one of claims 1 to 8.