Vector panorama fusion method based on live-action three dimensions
By setting the aerial photography center and camera parameters in a real three-dimensional scene, combined with collinear equations and Gaussian inverse calculation principles, the precise superposition and visualization of vector boundaries is achieved, solving the problems of managing boundary superposition and drone photography in the existing technology. solve the problem of low efficiency and improve work efficiency and data accuracy.
Patent Information
- Application Number
- CN202410771286.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-14
- Publication Date
- 2024-10-11
AI Technical Summary
Existing technology is difficult to flexibly realize the overlay display of management boundaries in real-life 3D model scenes, and the panoramic images captured by drones are affected by factors such as airspace and weather, and cannot directly display vector boundary elements, resulting in low work efficiency and data redundancy.
Using a vector panoramic fusion method based on real three-dimensional scenes, by setting the aerial photography center coordinates and camera parameters, the aerial photography is simulated for spatial processing to generate a panoramic image, and combined with collinear equations and Gaussian inverse calculation principles to achieve accurate vector boundaries Overlay and visualization.
It improves the display accuracy of boundaries in three-dimensional scenes, reduces manual operations, saves work costs, realizes low-cost, highly flexible panoramic image generation, supports customized panoramic image requirements, and ensures data confidentiality.
Smart Images

Figure CN118764601A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of real scene three-dimensional and photogrammetry, and in particular to a vector panorama fusion method based on real scene three-dimensional. Background Art
[0002] The real-life 3D model is an irregular triangulated mesh surface model with real textures and precise coordinates. It has been widely used in digital city construction, urban and rural planning, natural resource management, ecological protection, smart municipal administration, smart policing and other aspects. In the implementation of specific projects, it is necessary to superimpose various management boundaries in the real-life 3D model scene. However, due to the large amount of model data and the confidentiality of surveying and mapping results, it is impossible to flexibly realize the superposition display of various management boundaries. In this case, the method of using drones to shoot panoramic images is also affected by objective factors such as airspace and weather. At the same time, it is impossible to directly display various vector boundary elements in the panoramic images. Therefore, a low-cost, highly adaptable and flexible panoramic image generation method is of great significance for improving work efficiency, reducing the deployment of redundant data, and improving visualization results.
[0003] The vector panorama fusion method based on real-life 3D is based on the principle of aerial photography. By setting the camera's internal orientation elements and superimposing vector graphics in the real-life 3D scene, the scene is photographed in the real-life 3D scene, and the photographed image is projected onto the set spherical surface to complete the stitching. It avoids the steps of drone field aerial photography and image modification, thereby reducing a large amount of manual operation and improving the accuracy of the boundary display in the 3D scene. Summary of the invention
[0004] In view of the shortcomings of the prior art, the present invention proposes a method for generating a panoramic image based on a real three-dimensional scene. By setting parameters, a panoramic image can be automatically generated, and the overlay accuracy of the scene's internal boundaries and other vector graphics is high.
[0005] The present invention provides a method for generating a panoramic image based on a real three-dimensional scene.
[0006] In a first possible implementation, a method for generating a panoramic image based on a real three-dimensional scene includes:
[0007] Set the coordinates of the aerial photography center in the real 3D scene;
[0008] Set the camera parameters according to the set aerial photography center;
[0009] According to the real three-dimensional scene, a three-dimensional vector boundary is obtained;
[0010] The simulated aerial photography images are spatially processed to generate panoramic images.
[0011] In combination with the first possible implementation, in the second possible implementation, the principle of collinear equation is applied, and the distance, angle, terrain occlusion and other factors of the photographed object are comprehensively considered to set the focal length. The relationship between the focal length and the photographic center and the homonymous point of the photographed object is obtained by the following formula:
[0012]
[0013] In the above formula, x and y are the image plane coordinates of the image point; x0 and y0 are the coordinates of the image principal point in the frame coordinate system, f is the focal length, Xs, Y S , Z S is the spatial coordinate of the photography center, X A , Y A , Z A is the coordinate of the feature point; a i , b i 、c i (i=1, 2, 3) are 9 direction cosines composed of 3 exterior azimuth elements of the aerial photography image.
[0014] It is necessary to consider the resolution of the object in the image and the height of the aerial photography center. Therefore, the focal length can be expressed as:
[0015]
[0016] In the above formula, m is the aerial resolution; H is the aerial altitude of the aerial center, and f is the focal length. The coordinates of the ground object point, set the coordinates of the aerial center, to set the aerial scale of the panoramic image. The relationship between the aerial resolution and the aerial center can be obtained through the following formula:
[0017]
[0018] Combined with the second possible implementation method, in the third possible implementation method, each vector boundary is superimposed on the real-life 3D scene and visualized. Since there are a large number of vector boundary data nodes, it is necessary to apply the real-life 3D and vector boundary superposition to obtain the elevation value. Generally, the distance method is used to sample the elevation of the key node of the boundary, and the number of sampling points can be obtained by the following formula:
[0019]
[0020] In the above formula, o is the number of sampling points, L is the vector data length, and d is the sampling interval.
[0021] After setting the starting point, the position of each point on the vector boundary can be determined, and the corresponding elevation value can be obtained in the real 3D scene. After the sampling node obtains the elevation value, the elevation value between the sampling nodes can be calculated by quantitative interpolation and other methods to encrypt and refine the boundary and improve the visualization effect. The elevation value of the encrypted node can be obtained by the following formula:
[0022]
[0023] In the above formula, p is the elevation value of the encrypted point, and z is the ordinal number of the sampling point. Using this fitting method, the boundary can be adaptively superimposed in the scene according to the elevation of the three-dimensional scene itself.
[0024] Combined with the second and third feasible methods, the vector boundary is superimposed and displayed in the real three-dimensional scene, and simulated aerial photography is performed. In the fourth feasible method, a panoramic image stitching sphere is set. The stitching sphere is centered on the photography center, with the focal length as the radius, and the intersection of the plumb line passing through the center of the circle and the top of the sphere is set as the North Pole, and the intersection below is set as the South Pole. The true north direction in the real geographic coordinates is the longitude 0° from the North Pole to the South Pole on the stitching sphere, and the equator is the latitude 0°, to establish a geodetic coordinate system.
[0025] Set the benchmark of the original aerial photograph, set its frame corner points as the benchmark coordinates, sort and stack other adjacent original aerial photographs in order, and calculate the coordinates of other image frame corner points.
[0026] x i =x 基 +m×(i-1)
[0027] y j =y 基 +n×(j-1)
[0028] In the above formula, i is the serial number of the aerial image in the longitude direction, j is the serial number of the aerial image in the latitude direction, m is the width of the image frame in the frame mark coordinate system, and n is the height of the image frame in the frame mark coordinate system.
[0029] Based on the Gaussian inverse calculation principle, the coordinate system of each frame mark is inversely calculated, and the coordinates of each image frame mark are projected onto the panoramic image stitching sphere. In this way, the production of the panoramic image is completed. By Gaussian inverse calculation, the formula for inverse calculation of longitude and latitude of the frame mark coordinate system is as follows:
[0030]
[0031] In the above formula, B is the latitude of the spliced sphere, l is the longitude of the spliced sphere, y is the longitude direction coordinate value of the corner point of the frame coordinate system, and B f is the latitude of the projection base, t f , η f Press B f The corresponding quantity calculated is based on the Gaussian inverse calculation principle, M f 、N f The calculation method of other parameters is as follows:
[0032]
[0033] t f =tan B f
[0034]
[0035] N f =a / W f
[0036] In the above formula, a is the length of the major axis of the spliced sphere, and x is the latitude coordinate value of the corner point of the frame coordinate system.
[0037] It can be seen from the above technical solution that the beneficial technical effects of the present invention are as follows:
[0038] 1. Based on the panoramic images generated by real-life 3D scenes, various elements of scene visualization can be flexibly configured and adjusted, such as the modeling results of the 3D scene background, the color and transparency of the boundary superposition, etc., so as to customize the panoramic image requirements in different scenes.
[0039] 2. By establishing the mathematical relationship between the image frame coordinate system, the object coordinate system and the panoramic image stitching coordinate system, the functions of accurately measuring the coordinates and lengths of various elements in the panoramic image are realized, making the panoramic image accurate and measurable, avoiding the repetitive work of traditional aerial photogrammetry, saving work costs, and improving the production efficiency of panoramic images.
[0040] 3. The amount of panoramic image data produced based on real-life three-dimensional scenes can be deployed to the client through various methods such as the network and offline. It has strong scalability, which can not only ensure the rapid deployment of relevant results, but also ensure the confidentiality of the data. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following is a brief introduction to the drawings required for the specific embodiments or the prior art description. In all the drawings, similar elements or parts are generally identified by similar reference numerals. In the drawings, the elements or parts are not necessarily drawn according to the actual scale.
[0042] Figure 1 It is a schematic diagram of a vector panorama fusion method based on real scene three-dimensional provided in this embodiment.
[0043] Figure 2 It is a schematic diagram of setting the aerial photography center provided in this embodiment.
[0044] Figure 3 This embodiment provides a schematic diagram of the principle of solving the collinear equation principle.
[0045] Figure 4-a It is a schematic diagram of the resolution, focal length and altitude provided by this embodiment.
[0046] Figure 4-b It is a schematic diagram of a method for obtaining scene elevation using a vector boundary provided in this embodiment.
[0047] Figure 4-c It is a schematic diagram of projecting a frame mark coordinate onto a panoramic image sphere provided by this embodiment.
[0048] Figure 5 This is a schematic diagram of a panoramic image stitching result provided by this embodiment.
[0049] Figure 6 This is another schematic diagram of panoramic image stitching results provided by this embodiment. DETAILED DESCRIPTION
[0050] The following embodiments of the technical solution of the present invention are described in detail in conjunction with the accompanying drawings. The following embodiments are only used to more clearly illustrate the technical solution of the present invention, and are therefore only used as examples, and cannot be used to limit the protection scope of the present invention.
[0051] It should be noted that, unless otherwise specified, the technical terms or scientific terms used in this application should be the common meanings understood by technicians in the field to which the present invention belongs. The terms "first", "second", etc. in the specification and claims of the embodiments of the present disclosure and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so as to implement the embodiments of the present disclosure described here. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions. Unless otherwise specified, the term "multiple" means two or more. In the embodiments of the present disclosure, the character " / " indicates that the objects before and after are in an "or" relationship. For example, A / B means: A or B. The term "and / or" is a description of the association relationship of objects, indicating that there can be three relationships. For example, A and / or B means: A or B, or, A and B. The term "corresponding" can refer to an association relationship or a binding relationship, and A and B correspondingly refer to an association relationship or a binding relationship between A and B.
[0052] Combination Figure 1 As shown, this embodiment provides a method for generating a UAV patrol planning route, including:
[0053] Step S01, setting the aerial photography center coordinates in the real three-dimensional scene;
[0054] Step S02, setting camera parameters according to the set aerial photography center;
[0055] Step S03, obtaining a three-dimensional vector boundary according to the real three-dimensional scene;
[0056] Step S04: perform spatial processing on the simulated aerial photography image to generate a panoramic image.
[0057] Optionally, existing real-life three-dimensional scene data is selectively applied according to panoramic image requirements, and aerial photography center coordinates are set in the real-life three-dimensional scene, including two situations: a situation where there are aerial photography center coordinates and a situation where there are no specific aerial photography center coordinates. In the first situation, the aerial photography center coordinates are provided by the party in need of the results, such as the center point coordinates of a certain plot of land or a certain line; in the second situation, the center point coordinates are independently set in the three-dimensional scene according to the results requirements.
[0058] Optionally, the camera parameters are set according to the set aerial photography center, and the camera parameters are set according to factors such as resolution, distance between the object and the aerial photography center, including: focal length, image size and other parameters. Specifically: focal length m is the simulated aerial photography resolution, and H is the relative altitude of the aerial photography center. In addition, the focal length or the relative altitude of the aerial photography center can be adjusted according to the collinear equation and the coordinates of the object being photographed.
[0059] Optionally, combined Figure 2 , Figure 3 The resolution can be calculated by the following formula:
[0060]
[0061] In the above formula, x and y are the image plane coordinates of the image point; x0 and y0 are the coordinates of the image principal point in the frame coordinate system, f is the focal length, Xs, Y S , Z S is the spatial coordinate of the photography center, X A , Y A , Z A is the coordinate of the feature point; a i 、b i 、c i (i=1, 2, 3) are 9 direction cosines composed of 3 exterior azimuth elements of the aerial photography image.
[0062] Optionally, the real-life 3D model data base can be used to extract sampling nodes at a certain distance from various vector boundaries that need to be displayed in the panoramic image, and the highest point with the same name in the real-life 3D scene can be used as the sampling target elevation. According to the visualization requirements, an elevation value can be sampled at a certain distance, and the formula Get the number of sampling points, where L is the boundary length, d is the sampling interval, and o is the number of sampling points.
[0063] Optionally, after the sampling nodes obtained by the vector boundary have elevation values, they can be encrypted according to the needs of visualization effects, using the formula The elevation of the encrypted point can be obtained. Where p is the elevation value of the encrypted point and z is the ordinal number of the sampling point.
[0064] Optionally, after the sampling point completes the acquisition of the elevation value, the vector boundary is superimposed on the real three-dimensional scene, and the simulated aerial photography is completed according to the set camera parameters and aerial photography center;
[0065] Optionally, a panoramic image stitching sphere is set, which is a standard sphere, the center of the sphere is the photography center, and the radius is the focal length. A geodetic coordinate system is established on the sphere, with the meridian coinciding with the true north direction as the longitude 0° and the equator as the latitude 0°.
[0066] Optionally, in order to project the simulated aerial photography image onto the panoramic image stitching sphere, it is necessary to set the simulated aerial photography original film benchmark, and use the coordinate values of the four corner points of the benchmark image in the frame mark coordinate system to infer the frame mark corner point coordinates of other images. Generally, it is necessary to implement the simulated aerial photography original film benchmark and the stitching sphere orientation to ensure that the simulated aerial photography images have a certain overlap, and after preprocessing, the frame mark corner point coordinates are aligned to the same name points, and the image size of each image is consistent. The frame mark corner point coordinates of the simulated aerial photography image can be obtained by the following formula:
[0067] x i =x 基 +m×(i-1);
[0068] y j =y 基 +n×(-1);
[0069] In the above formula, i is the serial number of the aerial image in the longitude direction, j is the serial number of the aerial image in the latitude direction, m is the width of the image frame in the frame mark coordinate system, and n is the height of the image frame in the frame mark coordinate system.
[0070] Optionally, according to the result of calculating the frame mark coordinates of the corner points of the simulated aerial photography image, a Gauss projection back-calculation method is applied to obtain the longitude and latitude coordinates of the corner points on the spliced sphere.
[0071] Optionally, the longitude and latitude of each corner point can be calculated using the following formula:
[0072]
[0073]
[0074] In the above formula, B is the latitude of the spliced sphere, l is the longitude of the spliced sphere, y is the longitude direction coordinate value of the corner point of the frame coordinate system, and B f is the latitude of the projection base, t f ,ηx are respectively f The corresponding quantity calculated is based on the Gaussian inverse calculation principle, M f 、N f The calculation method of other parameters is as follows:
[0075]
[0076] t f =tan B f
[0077]
[0078] N f =a / W f
[0079] In the above formula, a is the length of the major semi-axis of the spliced sphere, which is equal to the radius of the spliced sphere. x is the latitude coordinate value of the corner point of the frame coordinate system.
[0080] Optionally, each simulated aerial photograph is spherically stitched according to the calculated longitude and latitude results to complete the generation of the panoramic image.
[0081] Optionally, under the condition that the drone can perform panoramic photography, the relevant parameters of the method can be set according to the actual coordinate parameters and the aerial camera parameters to achieve the superposition of the three-dimensional boundary on the real image and generate the final panoramic image.
[0082] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. These modifications or replacements do not make the essence of the corresponding technical solutions deviate from the scope of the technical solutions of the embodiments of the present invention, and they should all be included in the scope of the claims and specification of the present invention.
Claims
1. A method for producing panoramic images based on real scenes, characterized in that: include: Set the coordinates of the aerial photography center in the real 3D scene; Set the camera parameters according to the set aerial photography center; According to the real three-dimensional scene, a three-dimensional vector boundary is obtained; The simulated aerial photography images are spatially processed to generate panoramic images.
2. The method according to claim 1, characterized in that According to the real three-dimensional geographic coordinates and the requirements for generating panoramic images, determine the coordinates of the aerial photography center, including: According to the requirements of panoramic visualization, determine the three-dimensional coordinates of the aerial photography. According to the distance, angle, terrain occlusion in the real three-dimensional scene and other factors, set the coordinates of the aerial photography center to simulate the photography center.
3. The method according to claim 2, characterized in that By setting the camera parameters, a focal plane consisting of parameters such as focal length is formed. From the collinear equation, the relationship between the focal length, the photography center and the homonymous point of the photographed object is obtained through the following formula: In the above formula, x and y are the image plane coordinates of the image point; x0 and y0 are the coordinates of the image principal point in the frame coordinate system, f is the focal length, Xs, Y S , Z S is the spatial coordinate of the photography center, X A , Y A , Z A is the coordinate of the feature point; a i 、b i 、c i (i=1, 2, 3) are 9 direction cosines composed of 3 exterior azimuth elements of the aerial photography image.
4. The method according to claim 3, characterized in that Based on the real 3D scene, the 3D object coordinates of various boundaries such as planning and natural resource management are obtained in the real 3D scene, including: Set nodes on the boundary line at a certain distance and obtain the object coordinates of each node in the real three-dimensional scene; Calculate the coordinate system of each boundary key node in the image plane.
5. The method according to claim 4, characterized in that Perform spatial transformation on aerial images and various vector boundaries and couple them into the generated panoramic image, including: Set the panoramic image stitching sphere. The stitching sphere is a standard sphere, with the photography center as the sphere center, the radius as the focal length, the meridian coinciding with the true north direction as the longitude 0°, and the equator as the latitude 0°, to establish a geodetic coordinate system. Set the benchmark of the simulated aerial photography original film, set the coordinates of its frame corner points as the benchmark coordinates, and calculate the coordinates of other image frame corner points. x i =x 基 +m×(i-1); y j =y 基 +n×(j-1); In the above formula, i is the serial number of the aerial image in the longitude direction, j is the serial number of the aerial image in the latitude direction, m is the width of the image frame in the frame mark coordinate system, and n is the height of the image frame in the frame mark coordinate system. According to the method in requirement 4, use Gauss projection inverse calculation to convert the coordinates of the four corner points and various boundary nodes in each image frame corner point coordinate system into the geodetic coordinate system on the panoramic image stitching sphere, and implement image stitching according to the calculation results.
Citation Information
Cited By
Unmanned aerial vehicle flight video superposition and vector file real-time fusion method
CN119295301A
