CN113066148A - Map data processing method, device, equipment and storage medium - Google Patents

Map data processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN113066148A
CN113066148A CN202010002142.7A CN202010002142A CN113066148A CN 113066148 A CN113066148 A CN 113066148A CN 202010002142 A CN202010002142 A CN 202010002142A CN 113066148 A CN113066148 A CN 113066148A
Authority
CN
China
Prior art keywords
road
vector
end point
determining
segment
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.)
Granted
Application number
CN202010002142.7A
Other languages
Chinese (zh)
Other versions
CN113066148B (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.)
Shenyang Mxnavi Co Ltd
Original Assignee
Shenyang Mxnavi Co Ltd
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 Shenyang Mxnavi Co Ltd filed Critical Shenyang Mxnavi Co Ltd
Priority to CN202010002142.7A priority Critical patent/CN113066148B/en
Publication of CN113066148A publication Critical patent/CN113066148A/en
Application granted granted Critical
Publication of CN113066148B publication Critical patent/CN113066148B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • G06T11/206Drawing of charts or graphs

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Processing Or Creating Images (AREA)

Abstract

The embodiment of the invention discloses a map data processing method, a map data processing device, map data processing equipment and a storage medium. The method comprises the following steps: in the DTM model, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of a road line segment according to the first endpoint coordinates and the second endpoint coordinates of the road line segment in the 2D vector map; controlling a first end point of the road segment, approaching a second end point of the road segment by a long axis step length in a long axis direction, and approaching a second end point by a short axis step length in a short axis direction to obtain a target square intersected with the road segment; intersection points of the road segments and the target tiles are determined for integrating the 2D data of the road segments into the DTM model. The method can solve the problem that the height of a road segment in the 2D electronic map needs to be determined in the process of integrating the 2D electronic map data and the DTM model data. The accuracy of the corresponding height of the road line segment is improved, and the road line segment can change along the terrain in the DTM model.

Description

Map data processing method, device, equipment and storage medium
Technical Field
The present invention relates to data processing technologies, and in particular, to a method, an apparatus, a device, and a storage medium for processing map data.
Background
The core data in the current geographic information system, for example, data of points, lines (roads, rivers, and the like), and planes (greenbelts, water systems, and the like) on an electronic map are mainly 2D data.
A Digital terrestrial Model (DTM Model) models the surface of the earth and stores altitude information, but lacks accurate road data, and thus requires introduction of road data into the DTM Model through integration of a 2D electronic map and the DTM Model.
Due to different data collection modes, track points in the 2D electronic map only have x and y coordinate data, but do not have elevation data z, and cannot be directly integrated with DTM model data. Therefore, in the process of integrating the 2D electronic map data and the DTM model data, the heights of the segments of the geographic elements in the 2D electronic map, especially the heights of the segments of the roads in the 2D electronic map, need to be determined. The more accurate the height of the road segment, the higher the degree of fit between the road segment and the terrain in the DTM model, enabling the road segment to vary along the terrain in the DTM model.
Disclosure of Invention
The embodiment of the invention provides a map data processing method, a map data processing device, map data processing equipment and a storage medium, which are used for improving the accuracy of obtaining the height of a road segment in the process of integrating 2D electronic map data and DTM model data and enabling the road segment to change along the terrain in a DTM model.
In a first aspect, an embodiment of the present invention provides a map data processing method, where the method includes:
in a DTM model, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of a road line segment according to the first endpoint coordinates and the second endpoint coordinates of the road line segment in a 2D vector map;
controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment;
determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model.
In a second aspect, an embodiment of the present invention further provides a map data processing apparatus, where the apparatus includes:
the road segment determining module is used for determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of the road segment in the DTM model according to the first endpoint coordinates and the second endpoint coordinates of the road segment in the 2D vector map;
a target square acquiring module, configured to control a first end point of the road segment, approach a second end point of the road segment in the long axis direction by the long axis step length, and approach the second end point in the short axis direction by the short axis step length, so as to obtain a target square intersecting the road segment;
and the intersection point determining module is used for determining the intersection point of the road line segment and the target square grid and integrating the 2D data of the road line segment into the DTM model.
In a third aspect, an embodiment of the present invention further provides an apparatus, where the apparatus includes:
one or more processors;
a storage device for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the map data processing method as described above.
In a fourth aspect, the embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, which when executed by a processor implements the map data processing method as described above.
According to the embodiment of the invention, in a DTM model, according to a first endpoint coordinate and a second endpoint coordinate of a road segment in a 2D vector map, a major axis direction, a minor axis direction, a major axis step length and a minor axis step length of the road segment are determined; controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment; determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model. The problem that the height of a road segment in a 2D electronic map needs to be determined in the process of integrating 2D electronic map data and DTM model data is solved. The accuracy of the corresponding height of the road line segment is improved, and the road line segment can change along the terrain in the DTM model.
Drawings
Fig. 1 is a flowchart of a map data processing method according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a relationship between a road segment and a square grid according to an embodiment of the present invention;
fig. 3 is a flowchart of a map data processing method according to a second embodiment of the present invention;
fig. 4 is a schematic diagram illustrating a method for determining a road endpoint auxiliary point according to a second embodiment of the present invention;
fig. 5 is a schematic structural diagram of a map data processing apparatus according to a third embodiment of the present invention;
fig. 6 is a schematic structural diagram of an apparatus according to a fourth embodiment of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are merely illustrative of the invention and are not limiting of the invention. It should be further noted that, for the convenience of description, only some of the structures related to the present invention are shown in the drawings, not all of the structures.
Example one
Fig. 1 is a flowchart of a map data processing method according to an embodiment of the present invention, where the present embodiment is applicable to a case where 2D vector data of a road segment is integrated into a DTM model, and the method can be executed by a map data processing apparatus according to an embodiment of the present invention, and the apparatus can be implemented by software and/or hardware. Referring to fig. 1, the map data processing method provided in this embodiment includes:
and step 110, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of the road line segment in the DTM model according to the first endpoint coordinates and the second endpoint coordinates of the road line segment in the 2D vector map.
The first end point and the second end point are end points at two ends of the road line segment, the first end point and the second end point are connected to form the road line segment, and the plurality of road line segments form the whole road. The major axis direction, the minor axis direction, the major axis step size, and the minor axis step size are used to approximate the first endpoint to the second endpoint in the DTM model.
In this embodiment, optionally, determining the major axis direction, the minor axis direction, the major axis step length, and the minor axis step length of the road segment according to the first endpoint coordinate and the second endpoint coordinate of the road segment in the 2D vector map includes:
according to a first endpoint coordinate and a second endpoint coordinate of a road line segment in a 2D vector map, determining the number of grids spanned by the road line segment in the direction of a transverse axis and the direction of a longitudinal axis respectively;
taking an axial direction with a large number of crossed squares as the long axis direction, taking the other axial direction as the short axis direction, and projecting the road line segment in the long axis direction as a long axis length, and projecting the road line segment in the short axis direction as a short axis length;
taking the grid size in the DTM model as the long axis step length;
and taking the product of the proportional value between the length of the short axis and the length of the long axis and the grid size as the short axis step length.
Determining the number of the grids spanned by the road line segment in the direction of the horizontal axis according to the horizontal coordinates of the first end point and the second end point; and determining the number of the squares crossed by the road line segment in the longitudinal axis direction according to the vertical coordinates of the first end point and the second end point. The axial direction with a large number of crossing squares is taken as the long axis direction, and the other axial direction is taken as the short axis direction, that is, if the number of crossing squares in the horizontal axis direction is larger than that in the vertical axis direction, the horizontal axis is the direction long axis direction, and the vertical axis direction is the short axis direction.
Wherein the major axis step is a square lattice dimension cellsize, and the minor axis step is (dminor/dmajor) × cellsize, wherein dminor is the minor axis length and dmajor is the major axis length.
Fig. 2 is a schematic diagram of a relationship between a road segment and a square grid according to an embodiment of the present invention.
As shown in fig. 2, taking a line segment NO of the broken line segment NOPQ as an example, N is a first end point, O is a second end point, the number of squares spanned by NO on the horizontal axis is 3, and the number of squares spanned on the vertical axis is 2, the horizontal axis is the major axis, and the vertical axis is the minor axis. Projecting the road line segment in the direction of the transverse axis as the length of the long axis; the road segment is projected in the longitudinal axis direction as a minor axis length.
If the grid size in the DTM model is 1, the long axis length is 2, and the short axis length is 1, then the long axis step is 1, and the short axis step is (1/2) × 1 ═ 0.5. The method has the advantages that the direction of the first end point approaching the second end point and the accuracy of step length obtaining are improved, so that the target squares of the road line segments are determined, and the road line segments can change along the terrain in the DTM model in the process of integrating the 2D electronic map data and the DTM model data.
In this embodiment, optionally, before determining the long axis direction, the short axis direction, the long axis step length, and the short axis step length of the road segment, the method further includes:
in the DTM model, the midpoint of a connecting line of central points of two adjacent grids is taken as a new sampling point, and the height average value of the central points of the two adjacent grids is taken as the height value of the new sampling point;
dividing each square grid into four square grids by adopting the new sampling points;
and aiming at each grid obtained by dividing, dividing the grid into two triangular meshes by adopting the diagonal line of the grid.
The grid is formed by dividing a DTM model coverage area, and the size of each grid is the same. For example, the DTM model data is originally 32 × 32 square grid data, and the coordinates of the center point of each square grid are known; and taking the middle point of the connecting line of the central points of the two adjacent grids as a new sampling point, and adding the original central point to obtain 64 sampling points by 64. And if the corresponding heights of the central points of the two adjacent squares are 10m and 20m, the corresponding height of the new sampling point is 15 m.
Every four sampling points form a square, and each square grid is divided into four square grids, so that 64 × 64 square grid data is obtained. And aiming at each grid obtained by dividing, dividing the grid into two triangular meshes by adopting the diagonal line of the grid. The method has the advantages that the data are divided into regular triangular meshes, so that the data can be conveniently and uniformly processed subsequently, and the map data processing efficiency is improved.
And step 120, controlling a first end point of the road segment, approaching a second end point of the road segment by the long-axis step length in the long-axis direction, and approaching the second end point by the short-axis step length in the short-axis direction to obtain a target square intersected with the road segment.
The method comprises the steps of taking a first end point of a road line segment as a starting point, approaching a second end point of the road line segment by a long axis step length in the long axis direction and a short axis step length in the short axis direction to obtain a target square intersected with the road line segment.
In this embodiment, optionally, controlling a first end point of the road segment, approaching a second end point of the road segment with the long axis step length in the long axis direction, and approaching the second end point with the short axis step length in the short axis direction to obtain a target square intersected with the road segment includes:
determining the coordinate value Xi of the left boundary of the ith target square as
Figure BDA0002353875370000071
Determining the coordinate value Xi' of the right boundary of the ith target square as
Figure BDA0002353875370000072
Figure BDA0002353875370000073
Determining the coordinate value Yi of the lower boundary of the ith target square as
Figure BDA0002353875370000074
Determining the upper boundary coordinate value Yi' of the ith target square as
Figure BDA0002353875370000075
Figure BDA0002353875370000076
Obtaining a target square grid intersected with the road line segment according to the left boundary coordinate, the right boundary coordinate, the lower boundary coordinate and the upper boundary coordinate of the target square grid;
wherein i is a positive integer; nx and Ny are respectively a horizontal axis coordinate and a vertical axis coordinate of the first endpoint, and cellsize is the size of the square grid; in the long axis direction, the step length is the long axis step length cellsize; in the short axis direction, the step size is the short axis step size k, and k is a proportional value between the short axis length and the long axis length.
For example, if the coordinates of the first end point are (0.5,2.5), the grid size is 1, the minor axis length is 1, and the major axis length is 2, k is 0.5. The x-axis direction is the major axis direction, and the y-axis direction is the minor axis direction. The left boundary coordinate X2 of the second target square is now rounded down to
Figure BDA0002353875370000077
Wherein the step length is a long-axis step length cellsize; similarly, the right boundary coordinate X2' of the second target square is
Figure BDA0002353875370000078
The lower boundary coordinate Y2' of the second target square is
Figure BDA0002353875370000079
Figure BDA00023538753700000710
Wherein the step length is a minor axis step length cellsize k; similarly, the upper boundary coordinate Y2' of the second target square is
Figure BDA00023538753700000711
Obtaining a second target square grid according to the left boundary coordinate, the right boundary coordinate, the lower boundary coordinate and the upper boundary coordinate of the second target square grid; all the target squares intersected with the road line segment can be obtained in the same way. The advantage of setting up like this is that, improves the target check accuracy that road line section intersects and obtains, makes 2D electronic map data and DTM model data integration in-process, and road line section can change along the topography in the DTM model.
Step 130, determining the intersection point of the road segment and the target grid, and integrating the 2D data of the road segment into the DTM model.
After the intersection points of the road line segments and all the target squares are determined, all the associated points of the road line segments in the DTM model are obtained. In the DTM model, all the intersections are connected in sequence to obtain road data having a height, thereby integrating 2D vector data of road segments into the DTM model.
In this embodiment, optionally, determining an intersection point of the road segment and the intersection target square includes:
determining a first type of intersection point between the road line segment and each target square;
and determining a second type of intersection point between the road line segment and the diagonal line in the target square.
The first type of intersection point between the road segment and the target grid is determined by using a Cohen-Sutherland clipping algorithm, which is not limited in this embodiment. Establishing a nine-square grid by taking the target grid as a center, wherein each area in the nine-square grid corresponds to one code; judging the position relation between the road line segment and the Sudoku center square according to the code of the area where the end point of the road line segment is located, and cutting the road line segment by the Sudoku center square when the road line segment passes through the Sudoku center square so as to obtain the crossed edge of the road line segment and the current target square; and then acquiring an intersection point according to the linear equation of the intersected edge and the linear equation of the road segment. And determining all the first type intersections of the road line segments and the target squares by adopting the same mode for each target square.
The second type intersection point of the road line segment and the diagonal line in the target grid can be obtained by calculation through a linear equation of the road line segment and a linear equation of the diagonal line; wherein the diagonal line in the target square may be the hypotenuse of the triangular mesh. The advantage of setting up like this is that, improves the road line section and the accuracy that target check intersect acquireed, makes 2D electronic map data and DTM model data integration in-process, and the road line section can change along the topography in the DTM model.
According to the technical scheme provided by the embodiment, the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of a road segment are determined in a DTM model according to a first endpoint coordinate and a second endpoint coordinate of the road segment in a 2D vector map; controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment; determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model. The problem that the height of a road segment in a 2D electronic map needs to be determined in the process of integrating 2D electronic map data and DTM model data is solved. The accuracy of the corresponding height of the road line segment is improved, and the road line segment can change along the terrain in the DTM model.
Example two
Fig. 3 is a flowchart of a map data processing method according to a second embodiment of the present invention. The technical solution is supplementary explanation of the process after integrating the 2D data of the road segment into the DTM model. The aspects of the embodiments of the invention may be combined with any of the embodiments described above. Compared with the scheme, the scheme is specifically optimized, and the method further comprises the following steps:
for each end point in the road line segments, if the end point is a break point between two adjacent road line segments, determining two auxiliary points for the end point according to the two adjacent road line segments;
otherwise, determining four auxiliary points for the end point according to the road segment to which the end point belongs;
and drawing the road surface according to the end points in the road line segment and the determined auxiliary points.
Specifically, a flowchart of the map data processing method is shown in fig. 3:
and 310, in the DTM model, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of the road segment according to the first endpoint coordinates and the second endpoint coordinates of the road segment in the 2D vector map.
And step 320, controlling a first end point of the road segment, approaching a second end point of the road segment by the long-axis step length in the long-axis direction, and approaching the second end point by the short-axis step length in the short-axis direction to obtain a target square intersected with the road segment.
Step 330, determining the intersection of the road segment and the target grid for integrating the 2D data of the road segment into the DTM model.
Step 340, for each end point in the road line segments, if the end point is a break point between two adjacent road line segments, determining two auxiliary points for the end point according to the two adjacent road line segments.
When the line segment end points are break points connecting two adjacent line segments, two auxiliary points are determined for the end points according to two adjacent road line segments.
In this embodiment, optionally, determining two auxiliary points for the endpoint according to the two adjacent road segments includes:
taking the angular bisector vector of the two adjacent road segments as a first vector;
taking a vector in the direction opposite to the first vector as a second vector;
two auxiliary points are determined for the end point according to the road width, the first vector, the second vector and the end point.
Fig. 4 is a schematic diagram of determining a road endpoint auxiliary point according to a second embodiment of the present invention.
As shown in fig. 4, point N is a break point between two adjacent road segments MN and NP, a vector w1 of an angle bisector of the two adjacent road segments is taken as a first vector, a second vector v1 is a vector opposite to the first vector, and the size of the first vector and the second vector may be half of the actual road width. Then the end point is taken as a starting point, and the points J and L obtained from the magnitude and direction of the first vector and the magnitude and direction of the second vector are two auxiliary points of the end point. This has the advantage that no gaps are created at the turning points when describing a road with a width.
And 350, otherwise, determining four auxiliary points for the end point according to the road line segment to which the end point belongs.
And when the end point is the starting point or the end point of the road line segment, determining four auxiliary points for the end point according to the road line segment to which the end point belongs.
In this embodiment, optionally, determining four auxiliary points for the endpoint according to the road segment to which the endpoint belongs includes:
taking a vector from the end point to the other end point of the road segment along the direction of the road segment as a third vector;
determining a fourth vector and a fifth vector that are perpendicular to the third vector;
taking the sum of the third vector and the fourth vector as a sixth vector;
taking the sum of the third vector and the fifth vector as a seventh vector;
and determining four auxiliary points for the endpoint according to the road width, the fourth vector, the fifth vector, the sixth vector and the seventh vector and the endpoint.
As shown in fig. 4, the point M is an end point not connected to other road segments, and the direction of the third vector M1 is the road direction, and the size is the road segment length. The fourth vector u1 and the fifth vector w are perpendicular to the third vector, are in the same straight line and have opposite directions, and the magnitude of the fourth vector u1 and the fifth vector w can be half of the width of a road, so that an auxiliary point H and a point T are obtained. Adding the third vector m1 and the fourth vector u1 as a sixth vector u, thereby obtaining an auxiliary point R point; the third vector m1 and the fifth vector w are added as a seventh vector v, thereby acquiring the auxiliary point S point.
That is, with the end point as a starting point, four points obtained according to the magnitude and direction of the fourth vector, the magnitude and direction of the fifth vector, the magnitude and direction of the sixth vector and the magnitude and direction of the seventh vector are four auxiliary points of the end point. The benefit of this is that polygons of the outer contour at the end points of the road are obtained, from which the wide road is drawn more accurately in the DTM model.
And step 360, drawing the road surface according to the end points in the road line segment and the determined auxiliary points.
And after the auxiliary points are determined according to the end points in the road line segments, connecting all the auxiliary points according to the positions to form the road surface. The points can be connected by drawing z to obtain the road surface after triangulation.
On the basis of the embodiment, the technical scheme realizes that the road surface is drawn according to the road segment end points and the auxiliary points by determining the auxiliary points of the road segment end points, so that the road with the width is drawn more accurately in the DTM model.
EXAMPLE III
Fig. 5 is a schematic structural diagram of a map data processing apparatus according to a third embodiment of the present invention. The device can be realized in a hardware and/or software mode, can execute the map data processing method provided by any embodiment of the invention, and has corresponding functional modules and beneficial effects of the execution method. As shown in fig. 5, the apparatus includes:
a road segment determining module 510, configured to determine, in the DTM model, a major axis direction, a minor axis direction, a major axis step length, and a minor axis step length of a road segment according to a first endpoint coordinate and a second endpoint coordinate of the road segment in the 2D vector map.
A target square acquiring module 520, configured to control a first end point of the road segment, approach a second end point of the road segment with the long axis step length in the long axis direction, and approach the second end point with the short axis step length in the short axis direction, so as to obtain a target square intersected with the road segment.
An intersection determination module 530 for determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model.
According to the embodiment of the invention, in a DTM model, according to a first endpoint coordinate and a second endpoint coordinate of a road segment in a 2D vector map, a major axis direction, a minor axis direction, a major axis step length and a minor axis step length of the road segment are determined; controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment; determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model. The problem that the height of a road segment in a 2D electronic map needs to be determined in the process of integrating 2D electronic map data and DTM model data is solved. The accuracy of the corresponding height of the road line segment is improved, and the road line segment can change along the terrain in the DTM model.
On the basis of the above technical solutions, optionally, the road segment determining module 510 includes:
the grid number determining unit is used for respectively determining the number of grids spanned by the road line segment in the direction of the horizontal axis and the direction of the longitudinal axis according to the first endpoint coordinate and the second endpoint coordinate of the road line segment in the 2D vector map;
a road segment determination unit configured to determine an axial direction in which a large number of the squares are crossed as the long axis direction, determine another axial direction as the short axis direction, and determine a projection of the road segment in the long axis direction as a long axis length and a projection of the road segment in the short axis direction as a short axis length;
and the long axis step length determining unit is used for taking the grid size in the DTM model as the long axis step length.
A short axis step determining unit configured to determine a product of a proportional value between the short axis length and the long axis length and the square size as the short axis step.
On the basis of the above technical solutions, optionally, the target square acquisition module 520 includes:
a first coordinate value determination unit for determining a left boundary coordinate value Xi of the ith target cell as
Figure BDA0002353875370000131
A second coordinate value determination unit for determining a right boundary coordinate value Xi' of the ith target cell as
Figure BDA0002353875370000132
A third coordinate value determination unit for determining a lower boundary coordinate value Yi of the ith target cell as
Figure BDA0002353875370000141
A fourth coordinate value determination unit for determining an upper boundary coordinate value Yi' of the ith target cell as
Figure BDA0002353875370000142
And the target square grid acquisition unit is used for acquiring a target square grid intersected with the road line segment according to the left boundary coordinate, the right boundary coordinate, the lower boundary coordinate and the upper boundary coordinate of the target square grid.
Wherein i is a positive integer; nx and Ny are respectively a horizontal axis coordinate and a vertical axis coordinate of the first endpoint, and cellsize is the size of the square grid; in the long axis direction, the step length is the long axis step length cellsize; in the short axis direction, the step size is the short axis step size k, and k is a proportional value between the short axis length and the long axis length.
On the basis of the above technical solutions, optionally, the intersection determining module 530 includes:
and the first type intersection point determining module is used for determining the first type intersection points between the road line segments and each target square.
And the second type intersection point determining module is used for determining a second type intersection point between the road line segment and the diagonal line in the target square.
On the basis of the above technical solutions, optionally, the apparatus further includes:
and the first auxiliary point determining module is used for determining two auxiliary points for each end point in the road line segment according to the two adjacent road line segments if the end point is a break point between the two adjacent road line segments.
And the second auxiliary point determining module is used for determining four auxiliary points for each end point in the road line segment according to the road line segment to which the end point belongs if the end point is not a break point between two adjacent road line segments.
And the road surface drawing module is used for drawing the road surface according to the end points in the road line segment and the determined auxiliary points.
On the basis of the foregoing technical solutions, optionally, the first auxiliary point determining module includes:
the first vector acquisition unit is used for taking the angular bisector vector of the two adjacent road line segments as a first vector;
a second vector acquisition unit configured to take a vector having a direction opposite to that of the first vector as a second vector;
a first auxiliary point determining unit for determining two auxiliary points for the end point according to the road width, the first vector, the second vector and the end point.
On the basis of the foregoing technical solutions, optionally, the second auxiliary point determining module includes:
a third vector acquisition unit configured to take a vector from the end point to another end point of the road segment in the direction of the road segment as a third vector;
a fourth-fifth vector obtaining unit for determining a fourth vector and a fifth vector perpendicular to the third vector;
a sixth vector acquisition unit configured to take a sum of the third vector and the fourth vector as a sixth vector;
a seventh vector acquisition unit configured to take a sum of the third vector and the fifth vector as a seventh vector;
and the second auxiliary point determining unit is used for determining four auxiliary points for the endpoint according to the road width, the fourth vector, the fifth vector, the sixth vector, the seventh vector and the endpoint.
Example four
Fig. 6 is a schematic structural diagram of an apparatus according to a fourth embodiment of the present invention, as shown in fig. 6, the apparatus includes a processor 60, a memory 61, an input device 62, and an output device 63; the number of processors 60 in the device may be one or more, and one processor 60 is taken as an example in fig. 6; the processor 60, the memory 61, the input device 62 and the output device 63 in the apparatus may be connected by a bus or other means, as exemplified by the bus connection in fig. 6.
The memory 61, which is a computer-readable storage medium, may be used to store software programs, computer-executable programs, and modules, such as program instructions/modules corresponding to the map data processing method in the embodiment of the present invention. The processor 60 executes various functional applications of the device and data processing, i.e., implements the above-described map data processing method, by executing software programs, instructions, and modules stored in the memory 61.
The memory 61 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application program required for at least one function; the storage data area may store data created according to the use of the terminal, and the like. Further, the memory 61 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some examples, the memory 61 may further include memory located remotely from the processor 60, which may be connected to the device over a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
EXAMPLE five
An embodiment of the present invention further provides a storage medium containing computer-executable instructions, which when executed by a computer processor, are configured to perform a method for processing map data, the method including:
in a DTM model, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of a road line segment according to the first endpoint coordinates and the second endpoint coordinates of the road line segment in a 2D vector map;
controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment;
determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model.
Of course, the storage medium containing the computer-executable instructions provided by the embodiments of the present invention is not limited to the method operations described above, and may also perform related operations in the map data processing method provided by any embodiment of the present invention.
From the above description of the embodiments, it is obvious for those skilled in the art that the present invention can be implemented by software and necessary general hardware, and certainly, can also be implemented by hardware, but the former is a better embodiment in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which can be stored in a computer-readable storage medium, such as a floppy disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a FLASH Memory (FLASH), a hard disk or an optical disk of a computer, and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device) to execute the methods according to the embodiments of the present invention.
It should be noted that, in the embodiment of the map data processing apparatus, the units and modules included in the map data processing apparatus are only divided according to the functional logic, but are not limited to the above division as long as the corresponding functions can be realized; in addition, specific names of the functional units are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present invention.
It is to be noted that the foregoing is only illustrative of the preferred embodiments of the present invention and the technical principles employed. It will be understood by those skilled in the art that the present invention is not limited to the particular embodiments described herein, but is capable of various obvious changes, rearrangements and substitutions as will now become apparent to those skilled in the art without departing from the scope of the invention. Therefore, although the present invention has been described in greater detail by the above embodiments, the present invention is not limited to the above embodiments, and may include other equivalent embodiments without departing from the spirit of the present invention, and the scope of the present invention is determined by the scope of the appended claims.

Claims (10)

1. A map data processing method, comprising:
in a DTM model, determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of a road line segment according to the first endpoint coordinates and the second endpoint coordinates of the road line segment in a 2D vector map;
controlling a first end point of the road segment, approaching a second end point of the road segment in the long axis direction by the long axis step length, and approaching the second end point in the short axis direction by the short axis step length to obtain a target square intersected with the road segment;
determining intersections of the road segments with the target tiles for integrating 2D data of the road segments into the DTM model.
2. The method of claim 1, wherein determining the major axis direction, the minor axis direction, the major axis step size, and the minor axis step size of a road segment from first endpoint coordinates and second endpoint coordinates of the road segment in a 2D vector map comprises:
according to a first endpoint coordinate and a second endpoint coordinate of a road line segment in a 2D vector map, determining the number of grids spanned by the road line segment in the direction of a transverse axis and the direction of a longitudinal axis respectively;
taking an axial direction with a large number of crossed squares as the long axis direction, taking the other axial direction as the short axis direction, and projecting the road line segment in the long axis direction as a long axis length, and projecting the road line segment in the short axis direction as a short axis length;
taking the grid size in the DTM model as the long axis step length;
and taking the product of the proportional value between the length of the short axis and the length of the long axis and the grid size as the short axis step length.
3. The method of claim 1, wherein controlling a first end point of the road segment, approximating a second end point of the road segment with the major axis step in the major axis direction, and approximating the second end point with the minor axis step in the minor axis direction to obtain a target pane that intersects the road segment comprises:
determining the coordinate value Xi of the left boundary of the ith target square as
Figure FDA0002353875360000021
Determining the coordinate value Xi' of the right boundary of the ith target square as (
Figure FDA0002353875360000022
Figure FDA0002353875360000023
Determining the coordinate value Yi of the lower boundary of the ith target square as
Figure FDA0002353875360000024
Determining the upper boundary coordinate value Yi' of the ith target square as (
Figure FDA0002353875360000025
Figure FDA0002353875360000026
Obtaining a target square grid intersected with the road line segment according to the left boundary coordinate, the right boundary coordinate, the lower boundary coordinate and the upper boundary coordinate of the target square grid;
wherein i is a positive integer; nx and Ny are respectively a horizontal axis coordinate and a vertical axis coordinate of the first endpoint, and cellsize is the size of the square grid; in the long axis direction, the step length is the long axis step length cellsize; in the short axis direction, the step size is the short axis step size k, and k is a proportional value between the short axis length and the long axis length.
4. The method of claim 1, wherein determining an intersection of the road segment with the intersecting target square comprises:
determining a first type of intersection point between the road line segment and each target square;
and determining a second type of intersection point between the road line segment and the diagonal line in the target square.
5. The method of claim 1, further comprising:
for each end point in the road line segments, if the end point is a break point between two adjacent road line segments, determining two auxiliary points for the end point according to the two adjacent road line segments;
otherwise, determining four auxiliary points for the end point according to the road segment to which the end point belongs;
and drawing the road surface according to the end points in the road line segment and the determined auxiliary points.
6. The method of claim 5, wherein determining two auxiliary points for the end point based on the two adjacent road segments comprises:
taking the angular bisector vector of the two adjacent road segments as a first vector;
taking a vector in the direction opposite to the first vector as a second vector;
two auxiliary points are determined for the end point according to the road width, the first vector, the second vector and the end point.
7. The method of claim 5, wherein determining four auxiliary points for the endpoint based on the road segment to which the endpoint belongs comprises:
taking a vector from the end point to the other end point of the road segment along the direction of the road segment as a third vector;
determining a fourth vector and a fifth vector that are perpendicular to the third vector;
taking the sum of the third vector and the fourth vector as a sixth vector;
taking the sum of the third vector and the fifth vector as a seventh vector;
and determining four auxiliary points for the endpoint according to the road width, the fourth vector, the fifth vector, the sixth vector and the seventh vector and the endpoint.
8. A map data processing apparatus, characterized by comprising:
the road segment determining module is used for determining the major axis direction, the minor axis direction, the major axis step length and the minor axis step length of the road segment in the DTM model according to the first endpoint coordinates and the second endpoint coordinates of the road segment in the 2D vector map;
a target square acquiring module, configured to control a first end point of the road segment, approach a second end point of the road segment in the long axis direction by the long axis step length, and approach the second end point in the short axis direction by the short axis step length, so as to obtain a target square intersecting the road segment;
and the intersection point determining module is used for determining the intersection point of the road line segment and the target square grid and integrating the 2D data of the road line segment into the DTM model.
9. An apparatus, characterized in that the apparatus comprises:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the map data processing method of any one of claims 1-7.
10. A computer-readable storage medium, on which a computer program is stored, characterized in that the program, when executed by a processor, implements the map data processing method according to any one of claims 1 to 7.
CN202010002142.7A 2020-01-02 2020-01-02 Map data processing method, device, equipment and storage medium Active CN113066148B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010002142.7A CN113066148B (en) 2020-01-02 2020-01-02 Map data processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010002142.7A CN113066148B (en) 2020-01-02 2020-01-02 Map data processing method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113066148A true CN113066148A (en) 2021-07-02
CN113066148B CN113066148B (en) 2023-07-18

Family

ID=76558178

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010002142.7A Active CN113066148B (en) 2020-01-02 2020-01-02 Map data processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113066148B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20120042539A (en) * 2010-10-25 2012-05-03 현대엠엔소프트 주식회사 Method and navigation for displaying three-dimension road
CN105444735A (en) * 2014-08-22 2016-03-30 北京协进科技发展有限公司 Road grade determining method and device
CN108981734A (en) * 2018-05-17 2018-12-11 北京三快在线科技有限公司 Electronic map road expanding method, device, electronic equipment and storage medium
CN109360272A (en) * 2018-09-21 2019-02-19 浙江理工大学 A kind of grid surface curve design method based on distance restraint
CN110487279A (en) * 2019-08-27 2019-11-22 东南大学 A kind of paths planning method based on improvement A* algorithm

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20120042539A (en) * 2010-10-25 2012-05-03 현대엠엔소프트 주식회사 Method and navigation for displaying three-dimension road
CN105444735A (en) * 2014-08-22 2016-03-30 北京协进科技发展有限公司 Road grade determining method and device
CN108981734A (en) * 2018-05-17 2018-12-11 北京三快在线科技有限公司 Electronic map road expanding method, device, electronic equipment and storage medium
CN109360272A (en) * 2018-09-21 2019-02-19 浙江理工大学 A kind of grid surface curve design method based on distance restraint
CN110487279A (en) * 2019-08-27 2019-11-22 东南大学 A kind of paths planning method based on improvement A* algorithm

Also Published As

Publication number Publication date
CN113066148B (en) 2023-07-18

Similar Documents

Publication Publication Date Title
CN109541634B (en) Path planning method and device and mobile device
CN110633262B (en) Spark-based map intersection area calculation method and system
CN111860880B (en) Path determination method and device, electronic equipment and storage medium
CN114332291A (en) Oblique photography model building outer contour rule extraction method
CN111986326B (en) Construction method and device of pavement three-dimensional model, computer equipment and storage medium
CN115270500A (en) Boolean difference calculation method and device and electronic equipment
CN115082699A (en) Contour shape extraction method and device, electronic equipment and storage medium
CN113066176A (en) Map data processing method, device, equipment and storage medium
CN113066148B (en) Map data processing method, device, equipment and storage medium
CN115830255B (en) Simulation scene generation method and device, electronic equipment and storage medium
CN116664793A (en) Three-dimensional modeling method and device for hydraulic building excavation slope release and electronic equipment
CN113066151B (en) Map data processing method, device, equipment and storage medium
CN111221934A (en) Method and device for determining operation boundary of unmanned aerial vehicle
CN113066179B (en) Map data processing method, device, equipment and storage medium
CN114240976B (en) Map iterative segmentation method, device, equipment and storage medium
CN111426329B (en) Road generation method and device, computer equipment and storage medium
CN110917624B (en) Path determination method, device and equipment
CN114647681A (en) Intersection matching method, equipment and storage medium
CN113066150A (en) Map data processing method, device, equipment and storage medium
CN113128122A (en) BIM-based municipal road detection method
CN113066149A (en) Map data processing method, device, equipment and storage medium
CN113064954A (en) Map data processing method, device, equipment and storage medium
CN112632208B (en) Traffic flow trajectory deformation method and device
Liu et al. Line simplification algorithm implementation and error analysis
CN114155508B (en) Road change detection method, device, equipment and storage medium

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
CB02 Change of applicant information

Address after: 110000 No. 861-6, shangshengou village, Hunnan District, Shenyang City, Liaoning Province

Applicant after: Shenyang Meihang Technology Co.,Ltd.

Address before: 110179 12th and 13th floors of Debao building, No.1 Jinhui street, Hunnan New District, Shenyang City, Liaoning Province

Applicant before: SHENYANG MXNAVI Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant