A three-dimensional space coordinate conversion method, storage medium and computing device

By establishing the correspondence between real mining areas and virtual mining areas in the Unity simulation environment, the conversion of latitude and longitude coordinates to three-dimensional virtual space coordinates is realized, solving the problem that the virtual mining area height value cannot be directly obtained in the existing technology, and the dynamic update and height query function of virtual mining area data is realized.

CN113870426BActive Publication Date: 2025-04-18XIAMEN HLWYMOBI TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111122991.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-09-24
Publication Date
2025-04-18
Estimated Expiration
2041-09-24

AI Technical Summary

Technical Problem

The prior art cannot directly convert the latitude and longitude information of the real mining area into the three-dimensional coordinates of the virtual mining area, resulting in the inability to obtain the height value of the corresponding coordinate points and perform height updates in the virtual mining area.

Method used

By establishing the correspondence between the real mining area and the virtual mining area, the Unity simulation environment is used to realize the conversion of latitude and longitude coordinates to three-dimensional virtual spatial coordinates. The specific steps include: establishing a virtual mining area based on the two-dimensional map and contour terrain map of the real mining area, determining the coordinate origin and reference point, obtaining the proportional relationship between the latitude and longitude coordinates and the three-dimensional virtual spatial coordinates, performing X-Z spatial coordinate projection transformation, and obtaining the height value in the Unity environment.

Benefits of technology

The synchronization of real mining area and virtual mining area data is realized, the virtual mining area data can be updated dynamically, and the corresponding height value is queried by inputting latitude and longitude coordinates, solving the problem of height update.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113870426B_ABST
    Figure CN113870426B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of map data processing, and in particular to a three-dimensional space coordinate conversion method, storage medium and computing device. The method comprises: establishing a virtual mining area identical to a two-dimensional map and a contour map of a real mining area according to the two-dimensional map and the contour map; establishing a corresponding relationship between the coordinate origin of the real mining area and the coordinate origin of the virtual mining area, and inputting the virtual mining area into a Unity simulation environment; taking another reference point at the same position in the real mining area and the virtual mining area, the reference point and the coordinate origin are independent of each other, and obtaining a proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area, thereby realizing the X-Z space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area; after the X-Z plane coordinates of the virtual mining area are determined, the y value of the geographical location point of the longitude and latitude coordinates in the virtual mining area, that is, the height value, is obtained in the Unity simulation environment.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of mining area terrain management, and in particular to a three-dimensional space coordinate conversion method, storage medium and computing device for a real mining area and a virtual mining area. Background Art

[0002] Due to the needs of production operations, the terrain structure of the mining area will undergo different degrees of changes in each operation cycle. In order to intuitively carry out visual management, the terrain of the real mining area needs to be converted into a three-dimensional virtual mining area. During the conversion process, the longitude and latitude information of the real mining area cannot be directly associated with the coordinate points of the virtual mining area, and it is impossible to directly obtain the height value of the corresponding coordinate point and update the height through the longitude and latitude information in the virtual mining area. Summary of the invention

[0003] In view of the above-mentioned defects of the prior art, the object of the present invention is to provide a three-dimensional space coordinate conversion method, storage medium and computing device to achieve synchronization of real mining area and virtual mining area data and obtain the height change of the mining area.

[0004] To this end, the first aspect of the present application provides a three-dimensional space coordinate conversion method, comprising:

[0005] Step S1: Based on the two-dimensional map and contour map of the real mining area, a virtual mining area that is completely identical to the real mining area is established;

[0006] Step S2: Establishing the correspondence between the coordinate origin of the real mining area and the coordinate origin of the virtual mining area, and inputting the virtual mining area into the Unity simulation environment;

[0007] Step S3: taking another reference point at the same position in the real mining area and the virtual mining area, the reference point is independent of the coordinate origin, and obtaining the proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area, so as to realize the XZ space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area;

[0008] Step S4: After the XZ plane coordinates of the virtual mining area are determined, the Y value of the three-dimensional virtual space coordinates of the longitude and latitude geographic location point in the virtual mining area, that is, the height value, is obtained in the Unity simulation environment.

[0009] Furthermore, the step S1 specifically includes:

[0010] (1) Based on the two-dimensional map and contour map of the actual mining area, select the map range where 3D terrain drawing is required;

[0011] (2) Convert the contour topographic map of the determined range into a height map;

[0012] (3) Importing the height map into 3D mapping software, and using a terrain editor provided in the 3D mapping software to automatically identify the location information of the height map and generate 3D terrain.

[0013] Furthermore, the 3D drawing software is one of 3Dmax and Sketchup.

[0014] Furthermore, step S2 specifically includes: selecting a geographical landmark point in the real mining area as the coordinate origin, recording the longitude and latitude coordinates of the point, selecting a virtual mining area coordinate origin corresponding to the coordinate origin of the real mining area in the virtual mining area, and inputting the virtual mining area into the Unity simulation environment.

[0015] Furthermore, in step S2, the lower left corner of the mining area is selected as the coordinate origin.

[0016] Furthermore, the step S3 specifically includes:

[0017] Step S31: taking another reference point at the same position in the real mining area and the virtual mining area, the reference point is independent of the coordinate origin, and recording the latitude and longitude coordinates of the reference point in the real mining area and the three-dimensional virtual coordinates in the virtual mining area respectively;

[0018] Step S32: According to the spatial coordinate correspondence between the coordinate origin and the reference point of the real mining area and the virtual mining area, the proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area is solved, thereby realizing the XZ space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area. The Y value of the three-dimensional virtual space coordinate is used to represent the height information of the virtual mining area.

[0019] Furthermore, the step S32 specifically includes:

[0020] (1) Select the coordinate origin Oo(0,y,0) of the three-dimensional virtual space coordinates, and record the longitude and latitude information J1 of the coordinate origin in the real mining area, where y is an arbitrary value;

[0021] (2) In the XZ plane space, select the coordinates (X1, Z1) of another point in the virtual mining area, and record the longitude and latitude information J2 of the point in the real world again. Then the conversion ratio k between the longitude and latitude values ​​and the virtual mining area is: (J2_x-J1_x) / (X1-Oo)=(J2_x-J1_x) / X1, where J1_x, J1_z, J2_x, and J2_z represent the longitude and latitude information in the longitude and latitude information J1 and J2, respectively; for the longitude and latitude information Jn of any point in the real mining area, the x coordinate of the point in the virtual mining area is (Jn_x / k), and the z coordinate is (Jn_z / k); where Jn_x and Jn_z represent the longitude and latitude information in the longitude and latitude information Jn, respectively.

[0022] Furthermore, the step S4 specifically includes:

[0023] (1) Create a new virtual sphere, add rigid body properties to the virtual sphere, and set its XZ coordinates to the coordinate position in the virtual mining area obtained after longitude and latitude conversion; set the y value of the sphere to the maximum height value of the current virtual mining area;

[0024] (2) allowing the sphere to fall freely and restricting its rotation and displacement after landing;

[0025] (3) Detecting the point where the sphere falls into the virtual mining area, where the falling point is the three-dimensional virtual space coordinate point corresponding to the longitude and latitude coordinate point, and the y value of the landing point is the height value corresponding to the longitude and latitude coordinate point; or by emitting rays directly below the sphere, the height of the virtual mining area point hit by the rays is the y value of the point, that is, the height value.

[0026] A second aspect of an embodiment of the present application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the three-dimensional space coordinate conversion method as described in the first aspect of the present application.

[0027] A second aspect of an embodiment of the present application provides a computing device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes, the steps in the three-dimensional space coordinate conversion method described in the first aspect of the present application are implemented.

[0028] The present invention achieves the following technical effects:

[0029] The present invention adopts the unity simulation environment to realize the three-dimensional space coordinate conversion method of the real mining area and the virtual mining area, so as to realize the dynamic update of the virtual mining area data and query the height value of the coordinate point in the virtual mining area by inputting the longitude and latitude coordinates. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] Figure 1 is a flow chart of the three-dimensional space coordinate conversion method of the present invention;

[0031] Figure 2 It is a diagram of a virtual mining area;

[0032] Figure 3 It is a diagram showing the relative relationship between the virtual sphere and the virtual mining area. DETAILED DESCRIPTION

[0033] To further illustrate the various embodiments, the present invention provides drawings. These drawings are part of the disclosure of the present invention, which are mainly used to illustrate the embodiments and can be used in conjunction with the relevant descriptions in the specification to explain the operating principles of the embodiments. With reference to these contents, a person of ordinary skill in the art should be able to understand other possible implementations and advantages of the present invention. The components in the figures are not drawn to scale, and similar component symbols are generally used to represent similar components.

[0034] The present invention will now be further described with reference to the accompanying drawings and specific implementation methods.

[0035] like Figure 1 , Figure 2 , Figure 3 As shown, the present invention proposes a three-dimensional space coordinate conversion method for a real mining area and a virtual mining area, comprising the following steps:

[0036] Step S1: Based on the two-dimensional map and contour map of the real mining area, a virtual mining area that is exactly the same as the real mining area is established. This step is achieved through 3D mapping software such as 3Dmax and Sketchup.

[0037] If 3Dmax is used, the implementation method is:

[0038] (1) Based on the two-dimensional map and contour map of the actual mining area (such as CAD format drawings), select the map range where the 3D terrain needs to be drawn;

[0039] (2) Convert the contour map of the determined range into a height map (i.e., a grayscale map, with different grayscale values ​​representing different heights);

[0040] (3) Import the height map into 3Dmax, and use the built-in terrain editor of 3Dmax to automatically identify the location information of the height map and generate 3D terrain.

[0041] 3D mapping software such as Sketchup also has similar automatic terrain generation tools, which can be used to automatically generate 3D terrain from height maps (grayscale images).

[0042] Step S2: Select a geographical landmark point in the real mining area as the coordinate origin, and record the longitude and latitude coordinates of the point. In specific applications, the lower left corner of the mining area is usually taken as the coordinate origin; select the virtual mining area coordinate origin corresponding to the coordinate origin of the real mining area in the virtual mining area, input the virtual mining area into the Unity simulation environment, and normalize the position coordinates of the virtual mining area by setting up the coordinate origin corresponding to the real mining area, so as to facilitate the subsequent calculation of the position coordinates of the virtual mining area.

[0043] Step S3: Take another reference point at the same position in the real mining area and the virtual mining area. The reference point is independent of the coordinate origin, and obtain the proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area, so as to realize the XZ space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area.

[0044] This step specifically includes:

[0045] Step S31: taking another reference point at the same position in the real mining area and the virtual mining area, the reference point is independent of the coordinate origin, and recording the latitude and longitude coordinates of the reference point in the real mining area and the three-dimensional virtual coordinates in the virtual mining area respectively;

[0046] Step S32: According to the spatial coordinate correspondence between the coordinate origin and the reference point of the real mining area and the virtual mining area, the proportional relationship between the latitude and longitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area is solved, so as to realize the XZ space coordinate projection transformation from the latitude and longitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area, and the Y value of the three-dimensional virtual space coordinate is used to represent the height information of the virtual mining area. The calculation process of step S32 is as follows:

[0047] (1) Select the coordinate origin Oo(0,y,0) of the three-dimensional virtual space coordinates (where y is the height value, and the initial value can be any value); record the longitude and latitude information J1 of the coordinate origin in the real mining area;

[0048] (2) In the XZ plane space, select the coordinates (X1, Z1) of another point in the virtual mining area, and record the longitude and latitude information J2 of the point in the real world again. Then the conversion ratio k between the longitude and latitude values ​​and the coordinates of the virtual mining area is: (J2_x-J1_x) / (X1-Oo_x) or (J2_z-J1_z) / (Z1-Oo_z), where J1_x, J1_z, J2_x, and J2_z represent the longitude and latitude information in the longitude and latitude information J1 and J2, respectively, Oo_x=0, Oo_z=0; then for any longitude and latitude information Jn of a real mining area, the x coordinate of the point in the virtual mining area is (Jn_x / k), and the z coordinate is (Jn_z / k).

[0049] Step S4: After the XZ plane coordinates of the virtual mining area are determined, the Y value of the three-dimensional virtual space coordinates of the virtual mining area at the latitude and longitude geographic location point, i.e., the height value, is obtained in the Unity simulation environment according to the rigid body vertical drop method. The method is as follows:

[0050] (1) Create a new virtual sphere, add rigid body properties to the virtual sphere, and set its XZ coordinates to the coordinate position in the virtual mining area obtained after longitude and latitude conversion; set the height Y value of the sphere to the maximum height value of the current virtual mining area;

[0051] (2) allowing the sphere to fall freely and restricting its rotation and displacement after landing;

[0052] (3) Detecting the point where the sphere falls into the virtual mining area, where the falling point is the three-dimensional virtual mining area geographical point corresponding to the longitude and latitude coordinate point, and the height value y of the landing point is the height value corresponding to the longitude and latitude coordinate point; or by emitting rays directly below the sphere, the height of the virtual mining area point hit by the rays is the height Y value of the point, thereby completing the three-dimensional spatial coordinate conversion between the real mining area and the virtual mining area.

[0053] The present invention adopts the unity simulation environment to realize the three-dimensional space coordinate conversion method, so as to realize the dynamic update of virtual mining area data, and can query the height value of the coordinate point in the virtual mining area by inputting the longitude and latitude coordinates.

[0054] Based on the same inventive concept, another embodiment of the present application provides a computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the steps in the method described in any of the above embodiments of the present application are implemented.

[0055] Based on the same inventive concept, another embodiment of the present application provides a computing device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method described in any of the above embodiments of the present application when executing the computer program.

[0056] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0057] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, devices or computer program products. Therefore, the present application can be implemented in the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present application can be implemented in the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0058] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, terminal devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0059] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0060] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0061] Although the present invention has been specifically shown and described in conjunction with the preferred embodiments, it should be understood by those skilled in the art that various changes may be made to the present invention in form and details without departing from the spirit and scope of the present invention as defined by the appended claims, all of which are within the scope of protection of the present invention.

Claims

1. A three-dimensional space coordinate conversion method, characterized in that: include: Step S1: Based on the two-dimensional map and contour map of the real mining area, a virtual mining area that is completely identical to the real mining area is established; Step S2: Establishing the correspondence between the coordinate origin of the real mining area and the coordinate origin of the virtual mining area, and inputting the virtual mining area into the Unity simulation environment; Step S3: taking another reference point at the same position in the real mining area and the virtual mining area, the reference point is independent of the coordinate origin, and obtaining the proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area, so as to realize the XZ space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area; Step S4: for the latitude and longitude coordinate points of the real mining area, after the XZ plane coordinates of the virtual mining area are determined, the Y value of the three-dimensional virtual space coordinates of the latitude and longitude coordinate points in the virtual mining area, that is, the height value, is obtained in the Unity simulation environment; The step S4 specifically includes: (1) Create a new virtual sphere, add rigid body properties to the virtual sphere, and set its XZ coordinates to the coordinate position in the virtual mining area obtained after longitude and latitude conversion; set the y value of the sphere to the maximum height value of the current virtual mining area; (2) allowing the sphere to fall freely and restricting its rotation and displacement after landing; (3) Detecting the point where the sphere falls into the virtual mining area, where the falling point is the three-dimensional virtual space coordinate point corresponding to the longitude and latitude coordinate point, and the y value of the landing point is the height value corresponding to the longitude and latitude coordinate point; or by emitting rays directly below the sphere, the height of the virtual mining area point hit by the rays is the y value of the point, that is, the height value.

2. The three-dimensional space coordinate conversion method according to claim 1, characterized in that: Step S1 specifically includes: (1) Based on the two-dimensional map and contour map of the actual mining area, select the map range where 3D terrain drawing is required; (2) Convert the contour topographic map of the determined range into a height map; (3) Importing the height map into 3D mapping software, and using a terrain editor provided in the 3D mapping software to automatically identify the location information of the height map and generate 3D terrain.

3. The three-dimensional space coordinate conversion method according to claim 2, characterized in that: The 3D drawing software is one of 3Dmax and Sketchup.

4. The three-dimensional space coordinate conversion method according to claim 1, characterized in that: Step S2 specifically includes: selecting a geographical landmark point in the real mining area as the coordinate origin, recording the longitude and latitude coordinates of the point, selecting a virtual mining area coordinate origin corresponding to the coordinate origin of the real mining area in the virtual mining area, and inputting the virtual mining area into the Unity simulation environment.

5. The three-dimensional space coordinate conversion method according to claim 4, characterized in that: In step S2, the lower left corner of the mining area is selected as the coordinate origin.

6. The three-dimensional space coordinate conversion method according to claim 1, characterized in that: The step S3 specifically includes: Step S31: taking another reference point at the same position in the real mining area and the virtual mining area, the reference point is independent of the coordinate origin, and recording the latitude and longitude coordinates of the reference point in the real mining area and the three-dimensional virtual coordinates in the virtual mining area respectively; Step S32: According to the spatial coordinate correspondence between the coordinate origin and the reference point of the real mining area and the virtual mining area, the proportional relationship between the longitude and latitude coordinates of the real mining area and the three-dimensional virtual space coordinates of the virtual mining area is solved, thereby realizing the XZ space coordinate projection transformation from the longitude and latitude coordinate information of the real mining area to the three-dimensional virtual space coordinates of the virtual mining area. The Y value of the three-dimensional virtual space coordinate is used to represent the height information of the virtual mining area.

7. The three-dimensional space coordinate conversion method according to claim 6, characterized in that: The step S32 specifically includes: (1) Select the coordinate origin Oo(0,y,0) of the three-dimensional virtual space coordinates, and record the longitude and latitude information J1 of the coordinate origin in the real mining area, where y is an arbitrary value; (2) In the XZ plane space, select the coordinates (X1, Z1) of another point in the virtual mining area, and record the latitude and longitude information J2 of the point in the real world again. Then the conversion ratio k between the latitude and longitude values ​​and the virtual mining area is: (J2_x-J1_x) / (X1-Oo_x) or (J2_z-J1_z) / (Z1-Oo_z), where J1_x, J1_z, J2_x, and J2_z represent the latitude and longitude information J1, The longitude and latitude information in J2, Oo_x and Oo_z respectively represent the longitude and latitude information of the coordinate origin Oo of the three-dimensional virtual space coordinate, Oo_x=0, Oo_z=0; for the longitude and latitude information Jn of any point in the real mining area, the x coordinate of the point in the virtual mining area is (Jn_x / k), and the z coordinate is (Jn_z / k); wherein Jn_x and Jn_z respectively represent the longitude and latitude information in the longitude and longitude information Jn.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps in the three-dimensional space coordinate conversion method as described in any one of claims 1 to 7 are implemented.

9. A computing device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When executed, the processor implements the steps in the three-dimensional space coordinate conversion method as described in any one of claims 1-7.

Citation Information

Patent Citations

  • Three-dimensional geographical scene simulation method for virtual emergency exercises

    CN104318617A

  • Green mine construction planning method based on live-action three-dimensional modeling

    CN112307552A