Method for generating orthographic projection drawing of annual shadow according to tile data of three-dimensional reconstruction of unmanned aerial vehicle

Through the three-dimensional reconstruction of tile data and orthogonal projection diagram technology of drone, combined with ray tracing and sun position algorithm, the problem of insufficient accuracy, dynamicity and flexibility of shadow analysis in the existing technology is solved, and high-precision analysis and flexible output of shadows throughout the year are achieved.

CN119941903APending Publication Date: 2025-05-06BEIJING SHANGFANG SMART CLEAN ENERGY CO LTD
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202510056942.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-14
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

The prior art is difficult to achieve high precision, dynamic and flexible shadow analysis in building planning and photovoltaic power plant design, especially in the assessment of shadow change over a year or over a long period of time.

Method used

Through the three-dimensional reconstruction of tile data by drone, combined with orthophotogram technology, the ray tracing algorithm and sun position algorithm are used to calculate the sun direction vectors at multiple time points, grid sampling and shadow weight calculations are performed, and the orthophotogram of shadows throughout the year is generated.

Benefits of technology

It realizes high-precision shadow calculation, improves the ability to analyze shadow changes throughout the year or in a long period of time, supports flexible output resolution and format, and is suitable for areas such as photovoltaic power station design and architectural planning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119941903A_ABST
    Figure CN119941903A_ABST
Patent Text Reader

Abstract

The invention relates to the field of building planning, and discloses a method for generating an orthographic projection drawing of a full-year shadow according to tile data of three-dimensional reconstruction of an unmanned aerial vehicle, and the method comprises the following steps: calculating the geographic coordinates of four corner points of the orthographic projection drawing through inputting the central point geographic coordinates of the orthographic projection drawing, the actual width, height and rotation angle of the image; the method comprises the following steps: generating a three-dimensional tile model by using aerial photography data of an unmanned aerial vehicle, and analyzing vertex coordinates and a patch structure in the tile model; according to the input time interval, sun direction vectors of multiple time points in the time interval are calculated through a sun position algorithm; according to the method, the shadow distribution in the time interval is dynamically calculated by combining the three-dimensional reconstruction model and the orthographic projection drawing of the unmanned aerial vehicle and utilizing the sun position algorithm, so that the shadow calculation precision is improved, a result containing complex shadows of the earth surface and the roof of the building can be generated, and shadow weight analysis of multiple time periods is supported; and meanwhile, flexible resolution setting and result output are provided.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of building planning, and in particular to a method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions. Background Art

[0002] In the current technical context, the generation and application of orthographic projection shadows are mainly focused on the removal of image shadows. These methods usually use digital surface models (DTMs) and digital building models (DBMs) to calculate the range of shadows cast by buildings on the surface in combination with the local solar altitude and azimuth. The core goal is to remove shadows from images to improve the usability of images. This type of method has played an important role in image processing and surface visualization in the field of surveying and mapping, but it has also exposed many limitations.

[0003] For example, the Chinese Academy of Surveying and Mapping published a study on shadows and occlusions of large-scale urban true orthogonal images in 2010, which discussed in detail the process of calculating shadow ranges based on DTM and DBM. However, the accuracy of such methods is heavily dependent on the fineness of DTM and DBM data, and these models usually have problems with insufficient data resolution or missing architectural details in actual scenes, resulting in limited accuracy of the calculation results. In addition, shadow calculations are usually performed for a single time point, which cannot effectively evaluate shadow changes throughout the year or over a long period of time.

[0004] Similarly, in the study "ORTHOPHOTOSHADOW DETECTION METHOD UNDER ARTIFICIAL SHADOW" published in the International Archives of Photogrammetry and Remote Sensing Science in 2019, a method based on DBM data to extract building outlines was used to calculate the surface shadows of buildings separately. This method focuses more on simplifying the projection analysis of buildings, but is also limited to the shadow calculation within the surface projection range and cannot cover the three-dimensional complexity of the building itself. For example, these methods cannot effectively calculate the local shadows caused by obstacles and protruding structures on the roof of the building, and the results often deviate greatly from the actual scene.

[0005] Another prominent problem is the static nature and time limitations of existing methods. Most of these methods can only calculate the shadow distribution at a specific moment and lack the ability to analyze dynamic time periods. This is clearly insufficient in scenarios that require shadow distribution throughout the year or shadow weight analysis within a specific time period. Taking photovoltaic power station design as an example, shadows have a direct impact on the arrangement and power generation efficiency of solar panels, and shadow analysis at a single point in time cannot provide sufficient information support. In addition, the fields of architectural planning and design also require systematic analysis of shadow changes throughout the year or during a certain period of time, and existing technologies are obviously unable to meet these needs.

[0006] More importantly, existing technologies lack support for the flexibility of output results. In many practical applications, users need to use the generated shadow distribution map in conjunction with other design tools or software (such as CAD software). However, the shadow data generated by existing methods usually have a fixed resolution and lack the ability to adjust the resolution or format according to specific applications, resulting in limited applicability in practical engineering.

[0007] In summary, the existing technology has obvious deficiencies in terms of accuracy, dynamics, three-dimensional modeling capabilities and output flexibility, and it is difficult to meet the needs of photovoltaic power station design, building planning and other fields for high-precision, multi-time period and flexible shadow analysis. Summary of the invention

[0008] In view of the shortcomings of the existing technology, the present invention provides a method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by an unmanned aerial vehicle in three dimensions, which solves the problems of insufficient accuracy, lack of time dynamic analysis capability and limited shadow calculation of complex three-dimensional scenes in the existing orthographic projection map shadow generation technology.

[0009] To achieve the above objectives, the present invention is implemented by the following technical solutions: A method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions, comprising the following steps: By inputting the geographic coordinates of the center point of the orthographic projection, the actual width, height and rotation angle of the image, the geographic coordinates of the four corner points of the orthographic projection are calculated; Generate a 3D tile model using drone aerial photography data and analyze the vertex coordinates and facet structure in the tile model; According to the input time interval, the sun direction vector at multiple time points in the time interval is calculated by the sun position algorithm; Unify the three coordinates of the orthographic projection corner point geographic coordinates, tile model data and sun direction vector into the same east-north-sky local coordinate system; Perform grid sampling on the three-dimensional reconstructed model within the range of the orthographic projection image to generate a set of sampling point coordinates; Based on the ray tracing algorithm, the sampling points and the sun direction vector are used to determine whether the sampling points are blocked by the 3D tile model point by point, and the lighting status of each sampling point in the time interval is obtained; The shadow duration of each sampling point in the time interval is counted, the shadow weight is calculated, and an orthographic projection map representing the shadow distribution is generated.

[0010] Preferably, the geographic coordinates of the four corner points of the orthographic projection are calculated by the following steps: Based on the latitude and longitude coordinates of the input image center point, the image width and height are converted to the actual ground size; Combined with the rotation angle of the projection image, the offset of the four corner points is corrected using geometric transformation; The ground offset of the corner point is converted into geographic coordinates through the latitude and longitude coordinate transformation formula on the earth's surface.

[0011] Preferably, the parsing of the three-dimensional tile model comprises the following steps: Extract vertex coordinates from tile data, where vertex coordinates are a set of points in three-dimensional space; The patch information in the tile data is extracted, where the patch information represents the triangle patch relationship formed by connecting vertices.

[0012] Preferably, the calculation of the sun direction vector comprises the following steps: Based on the sun position algorithm, the sun's altitude angle and azimuth angle are calculated in combination with each time point in the time interval; According to the altitude angle and azimuth angle, the direction vector of the sun in three-dimensional space is generated to describe the incident direction of the sun's rays.

[0013] Preferably, the step of unifying the coordinates into the east-north-sky local coordinate system comprises: The center point of the orthographic projection is taken as the origin of the local coordinate system; Using the geographic coordinate conversion formula, the coordinates of the corner points of the orthographic projection image, the three-dimensional tile model data and the sun direction vector are converted from the geographic coordinate system to the local coordinate system.

[0014] Preferably, the grid sampling step includes: Divide the orthographic projection image range into regular grids according to the input resolution; Generate sampling points on each grid cell of a regular grid; The spacing of the sampling points is determined by the resolution, and each sampling point represents a position within the orthographic projection.

[0015] Preferably, the step of calculating the shadow based on the ray tracing algorithm comprises: The sampling point is taken as the starting point of the ray, and the sun direction vector is taken as the ray direction; Determine whether the ray intersects with the face of the 3D tile model; If the ray intersects the patch, the sampling point is recorded as being in shadow at that time point, otherwise it is recorded as being in the illuminated state.

[0016] Preferably, the calculation of the shadow weight includes: Count the shadow duration and total sunshine duration of each sampling point in the time interval; The shadow weight is calculated by the ratio of shadow duration to total sunshine duration. The shadow weight indicates the degree of shadow coverage of the sampling point within the time interval.

[0017] Preferably, the generation of the orthographic projection image includes: According to the shadow weight of the sampling point, the weight value is mapped to the grayscale value; Generate a grayscale image representing the shadow distribution, and the resolution of the grayscale image is consistent with the grid sampling resolution.

[0018] The present invention provides a method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions. The method has the following beneficial effects: 1. The present invention adopts a technical solution that combines drone aerial photography reconstruction with orthographic projection to generate more detailed three-dimensional building and surface models, thereby achieving high-precision shadow calculation. Compared with the calculation method in the prior art that is only based on digital surface models and digital building models, it solves the problem of insufficient accuracy of traditional methods in shadow range analysis, especially in the field of photovoltaic power station design and architectural planning, showing higher applicability.

[0019] 2. The present invention introduces a technical solution of block calculation, which can dynamically adjust the calculation scale according to hardware conditions, and finally merge to generate the overall shadow result. Compared with the limitation of the prior art that cannot effectively handle large-scale shadow calculations, the present invention solves the problem of low large-scale computing efficiency under the condition of limited hardware resources, and improves the scalability and applicability of the algorithm.

[0020] 3. The present invention calculates the sun direction vector within a time interval based on the sun position algorithm, can flexibly set the time interval, and realizes the time interval analysis of dynamic shadows. Compared with the technical solutions in the prior art that can only calculate the shadow at a specific moment, it solves the problem of being unable to conduct a comprehensive analysis of the changes in light and shadow throughout the year or over a long period of time, and provides technical support for refined time period analysis.

[0021] 4. The present invention supports setting the resolution accuracy of the output shadow map, corresponds each pixel point to the actual ground length, and is convenient for use in combination with other design software. Compared with the restrictive solution of fixed output result resolution in the prior art, the present invention solves the problem of poor flexibility of output results, especially in CAD software-assisted design, providing stronger adaptability and application scope. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] Figure 1 One of the schematic flow charts of the method of the present invention; Figure 2 This is the second schematic flow chart of the method of the present invention. DETAILED DESCRIPTION

[0023] The following will be combined with the drawings in the specification of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0024] Please refer to the attached Figure 1 and attached Figure 2 The embodiment of the present invention provides a method for generating an orthographic projection map of shadows throughout the year according to tile data of three-dimensional reconstruction of an unmanned aerial vehicle, comprising the following steps: S1. Calculate the geographic coordinates of the four corner points of the orthographic projection image by inputting the geographic coordinates of the center point of the orthographic projection image, the actual width, height and rotation angle of the image; In some embodiments of the present invention, step S1 is the starting step for generating the orthographic projection map of the whole year. Its main purpose is to calculate the geographical coordinates of the four corner points of the projection map based on the input geographical coordinates of the center point of the orthographic projection map and related parameters, so as to provide clear spatial boundaries for subsequent model analysis, grid sampling and shadow calculation. This step complements steps S2 to S7 and lays the foundation for the spatial data processing of the entire method.

[0025] In general, by inputting the coordinates of the center point of the orthographic projection (the latitude and longitude coordinates in the geographic coordinate system), image width, height, and rotation angle, the four corner coordinates of the projection can be derived based on the geometric relationship of the earth's surface. These corner coordinates will be used in subsequent steps to determine the geographic boundaries and sampling point distribution of the orthographic projection range. It should be noted that the influence of the rotation angle of the projection on the boundary coordinates must be fully considered during the calculation process to ensure that the generated corner coordinates are consistent with the geometric boundaries of the actual image.

[0026] In this embodiment, calculating the coordinates of the four corner points of the orthographic projection image specifically includes the following aspects: First, input the geographic coordinates C(x c ,y c ), where x c Indicates longitude, y c Indicates latitude. At the same time, enter the actual width W and height H of the projection image (unit: meter), as well as the rotation angle θ (with due north as reference).

[0027] In one possible implementation, the width and height of the image are considered as the offsets of the four corner points of the center point on the local plane. For example, the offset of the upper left corner of the projection image relative to the center point can be expressed as The offsets of the other three corner points can be obtained by analogy, respectively:

[0028] Specifically, since the projection image may have a certain rotation angle, the plane offset of the corner point needs to be corrected in combination with the rotation angle θ. The rotation correction formula is as follows: Δx′=Δxcosθ-Δysinθ Δy′=Δxsinθ+Δycosθ Among them, Δx and Δy are the original horizontal and vertical offsets respectively, and Δx′ and Δy′ are the offsets after rotation correction.

[0029] The corrected corner offset is then mapped to the actual longitude and latitude coordinates through the geographic coordinate conversion formula. In general, the conversion formula for longitude and latitude coordinates is as follows: Where R is the average radius of the Earth (about 6371 km), cos(y c ) is the cosine of latitude and is used to correct the actual ratio of longitude at different latitudes on the Earth's surface.

[0030] In a possible implementation, the latitude and longitude coordinates of the four corner points can be calculated by the above formula. For example, assuming that the geographic coordinates of the center point of the projection image are (120.0°, 30.0°), the image width and height are 1000 meters and 500 meters respectively, and the rotation angle is 30 degrees, the specific values ​​of the geographic coordinates of the four corner points can be obtained by the above method.

[0031] As an option, the above calculation can also be further optimized. For example, when the image rotation angle is 0, the rotation correction step can be omitted and the original offset can be used directly for coordinate calculation, which can significantly simplify the calculation process. In the case of a small rotation angle, this optimization will not significantly affect the calculation accuracy.

[0032] Finally, the geographic coordinates of the four corner points are output, specifically expressed as: (x1,y1),(x2,y2),(x3,y3),(x4,y4) These corner point coordinates will be used for orthographic projection scoping and 3D model meshing sampling in subsequent steps.

[0033] In some embodiments, in addition to calculating the corner points of longitude and latitude, the length of the image boundary and the specific distance information from the center point to the boundary can also be calculated to provide additional reference data for further model analysis and shadow accuracy calibration.

[0034] By implementing this step, the geographic boundaries of the orthographic projection map can be accurately calculated, providing a clear input range for subsequent processing steps. At the same time, it is directly connected with the subsequent three-dimensional model analysis (step S2) and grid sampling (step S5), thereby ensuring the continuity of the overall method flow and data consistency.

[0035] S2, using drone aerial photography data to generate a three-dimensional tile model, and parsing the vertex coordinates and facet structure in the tile model; in some embodiments of the present invention, step S2 is mainly used to generate and parse the three-dimensional tile model, which is one of the key steps of the method. Its core task is to extract the geometric information in the model, i.e., vertex coordinates and facet structure, from the three-dimensional reconstruction model generated by drone aerial photography data. These parsed geometric data will be used for grid sampling and shadow calculation based on ray tracing in subsequent steps.

[0036] Generally, 3D tile models are generated by stitching, stereo matching and surface reconstruction of multi-angle images taken by drones. Tile models are usually stored in the standardized 3DTiles format, which contains vertex and face information used to describe the spatial geometric features of the model. Parsing these geometric data can provide high-precision input for shadow calculation.

[0037] In this embodiment, a tile model of the target area is first generated by inputting multiple image data taken by a drone and using a 3D reconstruction algorithm. The generation process of the tile model can be based on a multi-view geometry (MVG) method or a bundle adjustment (BundleAdjustment) technology, which can restore point cloud data in a 3D space from multiple overlapping images.

[0038] In one possible implementation, after reconstruction is completed, the tile data is stored in 3DTiles format. 3DTiles is a commonly used 3D data organization method, and its core content includes vertex coordinates and the connection relationship between triangular patches. Vertex coordinates represent discrete points in the model, and patch relationships describe how these points are combined to form a surface.

[0039] Specifically, the result of vertex information parsing can be expressed as: V={v1,v2,…,v n},v i =(x i ,y i ,z i ) Among them, v i Represents a vertex in the model, which contains the three-dimensional space coordinate x i ,y i ,z i . These coordinates are based on the model's original coordinate system.

[0040] For the patch information, it can be expressed as: F={f1,f2,…,f m},f i =(v i1 ,v i2 ,v i3 ) Among them, f i Represented by vertex v i1 ,v i2 ,v i3 These patches define the geometric surface of the 3D model and are used to describe the structural form of buildings or land surfaces.

[0041] As an option, the upper surface data of the model can be extracted first during the analysis process, because in this method, the upper surface of the roof and the ground is more important for shadow calculation. For example, by calculating the normal vector of each triangular patch, it is possible to quickly determine whether the patch is facing the sky, thereby eliminating irrelevant lower surface data.

[0042] In some embodiments, the parsing of tile data can be further optimized. For example, for models with large amounts of data, vertices and faces can be processed in blocks during the parsing process, and loaded and parsed block by block to reduce memory usage. The parsed data can be used directly in the ray tracing algorithm, or reorganized into a spatial data structure for accelerated calculation, such as an octree or a bounding volume hierarchy (BVH) as needed.

[0043] Specifically, after parsing the tile data, the vertices and faces can be counted. For example, a tile model of a certain area may contain millions of vertices and faces. The organization and optimization of these data directly determines the efficiency of subsequent calculations. In one implementation, the boundary points of the model can be extracted to quickly determine whether the spatial range of the model overlaps with the boundary of the orthographic projection.

[0044] Generally speaking, the data format and parsing results of the tile model need to be compatible with the subsequent steps. Therefore, the parsed vertex coordinates and face information will be uniformly converted to a coordinate system consistent with the orthographic projection range, which can avoid geometric errors caused by inconsistent coordinate systems.

[0045] Through this step, the vertex and patch data obtained by parsing provide a comprehensive data basis for the mesh sampling in the subsequent step S5. These data not only ensure the accuracy of sampling, but also provide the necessary geometric input for the ray tracing algorithm in step S6.

[0046] S3, according to the input time interval, calculating the sun direction vector at multiple time points in the time interval by using the sun position algorithm; In some embodiments of the present invention, the main goal of step S3 is to calculate the sun direction vector at multiple time points in the time interval through the solar position algorithm (SPA) according to the input time interval. The sun direction vector is used to represent the incident direction of the sun's rays in the shadow calculation, and its accuracy directly affects the calculation result based on the ray tracing algorithm in the subsequent step S6. This step is based on the correlation between time information and geographical location, combined with the regularity of the earth's movement, to derive the relative position of the sun in three-dimensional space at a specific time point.

[0047] Generally, the calculation of the sun's position requires the input of a time interval and geographic coordinates as basic parameters. The time interval includes the start time and the end time, as well as the time interval for calculation, such as every hour or every minute. The geographic coordinates are usually the coordinates of the center point of the orthographic projection, indicating the position of the observation point on the earth. Through these input parameters, combined with the sun position algorithm, the sun's altitude angle and azimuth at each time point can be calculated, and further converted into a three-dimensional direction vector to describe the direction of the sun's rays.

[0048] In this embodiment, based on the input time interval and geographic coordinates, the key parameters required for the sun position algorithm are first determined, including time (date and moment), latitude and longitude coordinates, and standard time offset (such as time zone). The time parameters are used to calculate the sun's declination and hour angle, the geographic coordinates are used to determine the latitude position of the observation point, and the time offset is used to adjust the difference between local time and universal time.

[0049] Specifically, the calculation formulas for the solar altitude angle h and the azimuth angle φ are as follows: h=arcsin(sinδsinφ o +cosδcosφ o cosH) Where Δ is the solar declination, which is determined by the input date; φ o is the latitude of the observation point; H is the hour angle, which is calculated from the time and geographical longitude.

[0050] In one possible implementation, the solar altitude angle h describes the vertical angle of the sun, that is, the angle between the sun's rays and the ground; the azimuth angle φ describes the horizontal angle of the sun relative to the north direction. Through these angles, the spatial position of the sun can be further represented as a three-dimensional direction vector.

[0051] The calculation formula for the sun direction vector is as follows: In the above formula, It is a three-dimensional unit vector representing the direction of the sun, and its components describe the projection of the sun's rays in the east-west, north-south, and vertical directions respectively.

[0052] As an option, the time interval can be adjusted according to actual needs. For example, a larger time interval (such as every hour) is suitable for rough analysis over a long period of time, while a smaller time interval (such as every minute) is suitable for more accurate shadow calculations. In some embodiments, in order to optimize the calculation efficiency, the time interval can be dynamically adjusted according to the length of the input time interval, for example, high-frequency calculations are used in a short period of time, while the calculation frequency is reduced in a long period of time.

[0053] During the calculation process, the sun position algorithm needs to combine the periodic characteristics of the earth's rotation and revolution, so it may involve the conversion of multiple time variables. For example, when the input time is local time, it needs to be converted to universal time (UTC) first, and then the corresponding hour angle H is calculated. Similarly, when the geographic coordinates are longitude and latitude, the solar declination δ needs to be calculated in combination with the inclination angle of the earth's equator.

[0054] In some embodiments, the calculation result of the sun direction vector can be stored as a time-vector mapping relationship in the form of For example, if the time interval is from 8:00 on January 1, 2024 to 18:00 on January 1, 2024, and the time interval is 1 hour, the stored results are 10 sets of sun direction vectors, each set of vectors corresponds to a time point. This result will be used for shadow calculation at each time step in the subsequent steps.

[0055] As an improvement, the calculation of the sun direction vector can be optimized by table lookup or pre-calculation. For example, a pre-calculated database containing the sun position can be established for a specific date and geographic location. In practical applications, table lookup can significantly improve the calculation speed, especially in shadow analysis tasks over a large area and multiple time periods.

[0056] Through this step, an accurate sun direction vector can be generated for each time point, providing necessary direction information for the unified conversion of the coordinate system in step S4 and the ray tracing calculation in step S6. At the same time, this step is combined with the three-dimensional tile model analysis in step S2 to ensure the calculation uniformity of the light direction and the geometric model. In this way, efficient and accurate shadow simulation can be achieved in subsequent steps.

[0057] S4, unifying the three coordinates of the orthographic projection corner point geographic coordinates, tile model data and sun direction vector into the same east-north-sky local coordinate system; In some embodiments of the present invention, the main purpose of step S4 is to unify the geographic coordinates of the corner points of the orthographic projection, the three-dimensional tile model data obtained by analysis, and the sun direction vector calculated by the sun position algorithm into the East-North-Sky (ENU) local coordinate system. This step provides a unified coordinate system for subsequent grid sampling and ray tracing calculations to ensure the accuracy of geometric calculations. Since the input data originates from different geographic reference systems or model coordinate systems, direct use may result in calculation errors, so they need to be unified into the same reference system through coordinate transformation.

[0058] In general, the east-north-sky local coordinate system is a local rectangular coordinate system with a selected geographic point as the origin, east as the X-axis, north as the Y-axis, and sky as the Z-axis. It avoids the influence of the earth's curvature on the accuracy of small-scale data and is suitable for scenes requiring precise geometric calculations in the present invention. By converting the corner coordinates of the orthographic projection, the vertex data of the three-dimensional model, and the sun direction vector into the local coordinate system, subsequent geometric operations can be performed in a unified coordinate system.

[0059] In this embodiment, firstly, the geographical coordinates C(x c ,y c ,z c ) as the origin of the local coordinate system. Here, x c and c are the longitude and latitude of the center point, z c is the altitude of the center point. If the altitude is not explicitly given, it can be set to zero, indicating a sea level reference point.

[0060] For the geographic coordinates of the corner points of the orthographic projection, use the following formula for coordinate conversion: x=R·(x i -x c )·cos(y c ) y=R·(y i -y c ) z=z i -z c Where: R is the average radius of the earth (about 6371 kilometers), which is used to convert the difference in longitude and latitude into actual distance; x i ,y i ,z i are the longitude, latitude and altitude of the corner points of the orthographic projection image; x, y, z are the coordinates converted to the local coordinate system.

[0061] Specifically, the four corner points of the orthographic projection image will be converted into coordinates using the above formulas respectively, and output as four sets of local coordinates for defining the range of the orthographic projection image.

[0062] For the vertices V in the 3D tile model data, V = {v1, v2, ..., v n}, each vertex v i =(x i ,y i ,z i ) represents a 3D point in the model. Similar to the conversion of corner coordinates, the conversion of vertex coordinates also needs to be processed point by point according to the formula from geographic coordinates to local coordinates. As a possible implementation method, all vertex data can be processed in batches to improve computing efficiency.

[0063] In some embodiments, a 3D tile model may contain a large amount of vertex data, so the conversion process can be optimized by processing in blocks. For example, the model can be divided into several small-scale tile blocks, and only the vertex data of the current tile block is loaded and converted each time. This can significantly reduce memory usage and is suitable for scenes with limited hardware resources.

[0064] For the sun direction vector calculated by the sun position algorithm It needs to be corrected according to the position of the observation point and the origin of the local coordinate system. The local coordinate transformation formula of the sun direction vector is as follows: S′ x =S x S′ y =S y S′ z =S z Among them, S x ,S y ,S z They represent the components of the sun direction vector in the east-west, north-south and vertical directions, (S′ x ,S′ y ,S′ z ) is the direction vector component transformed into the local coordinate system.

[0065] In a possible implementation, the conversion of the sun direction vector can directly use the characteristic that the observation point is the origin of the local coordinate system to avoid additional complex calculations. This method simplifies the implementation steps and ensures accuracy.

[0066] As an option, the intermediate results of the coordinate transformation process can be stored as cached data for reuse in subsequent steps. For example, for long-term analysis tasks, the uniformly transformed sun direction vector and tile model data can be directly loaded without repeated transformation.

[0067] Through the implementation of this step, the corner coordinates of the orthographic projection, the geometric data of the tile model and the sun direction vector can be unified into the same local coordinate system, providing accurate and consistent input data for subsequent steps. It is closely connected with the previous steps (such as the calculation of the sun position in S3), and at the same time lays a geometric foundation for the subsequent grid sampling and ray tracing algorithms.

[0068] S5. Grid sampling is performed on the three-dimensional reconstructed model within the range of the orthographic projection image to generate a set of sampling point coordinates. In some embodiments of the present invention, the main task of step S5 is to grid sample the three-dimensional reconstructed model within the range of the orthographic projection image to generate a set of sampling point coordinates. This step is an important basic link to achieve accurate shadow calculation. The model surface is divided into a number of sampling points in a gridding manner for subsequent illumination and shadow state judgment based on the ray tracing algorithm. The input data of step S5 includes the orthographic projection image range, tile model data and model surface information unified to the east-north-sky local coordinate system in step S4.

[0069] Generally, the resolution of grid sampling is set by the user, which determines the density of sampling points and the final accuracy of the shadow orthographic projection map. A higher resolution can generate more sampling points, thereby improving the accuracy of shadow analysis, but it will also increase the amount of calculation and storage requirements. In the present invention, by combining the range of the orthographic projection map with the geometric information of the three-dimensional model, a regular set of sampling point coordinates is generated, so that the sampling points can fully cover the upper surface of the model within the range of the projection map.

[0070] In this embodiment, the specific implementation of grid sampling includes the following aspects.

[0071] First, according to the coordinates of the four corner points of the orthographic projection image calculated in step S4, the plane boundary range of the projection image is determined. Assume that the boundary range of the projection image in the local coordinate system is: (x min ,y min ) to (x max ,y max ) Among them, x min ,x max are the minimum and maximum values ​​of the projection in the east direction, y min ,y max They are the minimum and maximum values ​​of the projection image in the north direction, respectively.

[0072] In one possible implementation, the user inputs the sampling resolution d, which represents the actual ground length of each sampling point within the projection map. According to the resolution d, the boundary range is divided into a regular grid to generate uniformly distributed sampling point coordinates. The coordinates of the sampling points can be expressed as: P = {p ij},p ij =(x i ,y j ),x i =x min +i·d,y j =y min +j·d Among them, i,j are the grid indexes of the sampling points, x i and j are the easting and northing coordinates of the sampling point, respectively.

[0073] Specifically, the width W and height H of the projection image can be calculated from the boundary range: W = x max -x min ,H=y max -y min The total number of sampling points after meshing is: in, Indicates rounding up operation, n x and n y are the number of sampling points of the grid in the east and north directions respectively.

[0074] As an option, in addition to regular grid sampling, the sampling points can be optimized according to the geometric complexity of the 3D model in the projection area. For example, for areas such as building outlines and roof edges, the density of sampling points can be increased through adaptive refinement to more accurately capture the changes in lighting and shadows in these areas. In areas where the model is relatively flat, the density of sampling points can be appropriately reduced to improve computational efficiency.

[0075] In some embodiments, in order to further reduce unnecessary calculations, areas not covered by the 3D model can be eliminated during the grid sampling process. For example, by performing an intersection check between the outer bounding box (BoundingBox) of the 3D model and the projection map range, sampling points are generated only within the intersection range. This optimization method can significantly reduce the number of sampling points and is suitable for a wide range of shadow analysis tasks.

[0076] In this embodiment, the generation of sampling points is not limited to plane coordinates. For the upper surface of the three-dimensional model, the sampling point also needs to include its vertical height information. Specifically, by parsing the vertex and patch data of the three-dimensional tile model, the vertical height z of the sampling point on the model surface is calculated. Assume that the sampling point p ij =(x i ,y j ) is located in the model patch f k =(v k1 ,v k2 ,v k3 ), then its height z ij It can be calculated by plane interpolation.

[0077] In a possible implementation, the three-dimensional coordinates of the sampling point can be expressed as: p ij =(x i ,y j ,z ij ) Among them, z ij It is the interpolation height of the triangle patch where the sampling point is located.

[0078] As an improvement, the generated sampling point coordinate set can be associated with the face index of the 3D model, so that the face information to which the sampling point belongs can be quickly found in the subsequent steps. For example, the number and local coordinates of the face to which the sampling point belongs can be stored for each sampling point, so that there is no need to repeatedly search in the ray tracing calculation, thereby improving the calculation efficiency.

[0079] Through this step, a high-precision sampling point coordinate set covering the range of the orthographic projection map can be generated, providing comprehensive input data for the shadow calculation in step S6. Closely connected with the coordinate transformation in step S4, the spatial consistency of the sampling points with the three-dimensional model and the sun direction vector is ensured. The flexibility and adaptability of grid sampling enable the present invention to meet the requirements of high precision and high efficiency at the same time.

[0080] S6. Based on the ray tracing algorithm, using the sampling points and the sun direction vector, determine point by point whether the sampling points are blocked by the three-dimensional tile model, and obtain the illumination state of each sampling point in the time interval; In some embodiments of the present invention, the core task of step S6 is to determine whether the sampling point is blocked by the three-dimensional tile model at different time points based on the ray tracing algorithm, so as to determine the illumination state of the sampling point. This step is closely dependent on the sun direction vector calculated in step S3 and the sampling point coordinate set generated in step S5. By determining the illumination state of each sampling point and each time point one by one, accurate data support is provided for the shadow duration statistics and weight calculation in the subsequent step S7.

[0081] In general, the ray tracing algorithm is a commonly used geometric calculation method to determine the intersection relationship between the ray and the three-dimensional model. In this step, the ray starts from the sampling point and extends along the sun direction vector. If the ray intersects with any triangle face of the tile model during the extension process, it means that the sampling point is in the shadow at the current time point; otherwise, the sampling point is in the illuminated state.

[0082] In this embodiment, the specific steps of implementing ray tracing include the following contents.

[0083] First, according to the sampling point coordinate set P generated in step S5, ij} and the set of sun direction vectors calculated in step S3 For each sampling point p ij Construct a ray. The starting point of the ray is the coordinate of the sampling point, and the direction of the ray is the sun direction vector at the corresponding time point. The expression of the ray is: in: is the spatial position of the ray under parameter t; is the starting point of the ray (i.e. the sampling point coordinates); is the sun direction vector; t is the ray parameter, which indicates the distance the ray extends from the starting point along the direction.

[0084] Specifically, a triangular face in a tile model can be represented as a set of three vertices, for example, f = (v1, v2, v3). The key to determining whether a ray intersects a face is to calculate the intersection of the ray and the plane where the triangle is located, and further determine whether the intersection falls within the range of the triangle.

[0085] In a possible implementation, the intersection determination between a ray and a triangle may be implemented by the following steps: First, calculate the normal vector of the triangle Here, × represents the vector cross product operation.

[0086] Next, determine whether the ray is parallel to the plane. If the ray direction vector With the plane normal vector The dot product is zero, then the ray is parallel to the plane and there is no intersection: If the ray is not parallel, calculate the intersection parameter t of the ray and the plane: According to the intersection parameter t, calculate the specific coordinates of the intersection: Finally, determine whether the intersection point is inside the triangle. This can be done by calculating the direction vector of the intersection point relative to the three sides of the triangle and using the cross product result to determine whether the intersection point is within the range of the triangle.

[0087] As an option, the spatial partitioning optimization of the triangles in the tile model can be performed, such as using an octree or a bounding volume hierarchy (BVH) to speed up the intersection determination process. In this optimization scheme, the ray first performs an intersection test with the bounding box of the spatial partition, and only when the bounding box intersects is the intersection relationship between the ray and the triangles it contains further calculated.

[0088] In some embodiments, in order to further reduce unnecessary calculations, the possible intersection range of the ray and the model can be preliminarily screened in combination with the height information of the sampling point and the angle range of the sun's direction. For example, when the sun's altitude angle is large, the model patch in the area below the sampling point can be ignored, thereby reducing the complexity of the calculation.

[0089] For each sampling point and time point, after determining the lighting state through the above steps, the result is recorded as a lighting state matrix. Each element of the lighting state matrix indicates whether the corresponding sampling point is in the shadow at a certain time point. For example, the lighting state matrix can be expressed as: By implementing this step, the lighting status of each sampling point can be accurately determined at each time point, providing detailed basic data for the shadow duration statistics and weight calculation in step S7. At the same time, it is seamlessly connected with the grid sampling in step S5 to ensure that the distribution of the sampling points is consistent with the calculation range of the model geometry information. Furthermore, the optimization scheme of this step ensures the efficiency and accuracy of large-scale 3D models and long-range shadow calculations.

[0090] S7. Count the shadow duration of each sampling point in the time interval, calculate the shadow weight, and generate an orthographic projection map representing the shadow distribution.

[0091] In some embodiments of the present invention, the main purpose of step S7 is to count the shadow duration of each sampling point in the time interval, calculate the shadow weight based on the statistical results, and finally generate an orthographic projection map representing the shadow distribution. This step is based on the illumination state matrix obtained in step S6, and converts the dynamic illumination information in the time interval into a static shadow distribution result by analyzing the illumination and shadow states. This step is the last step to realize the generation of the shadow orthographic projection map, providing high-precision visualization data support for photovoltaic design, architectural planning and other fields.

[0092] In general, the illumination state matrix contains the illumination state information of each sampling point at each time interval. By counting these state data, the shadow coverage ratio of each sampling point in the entire time interval, that is, the shadow weight, can be calculated. The shadow weight reflects the degree of occlusion of the sampling point during the analysis time period and is the core basis for generating the shadow orthographic projection map.

[0093] In this embodiment, the illumination state matrix L(i,j,t) is first imported from step S6, where: L(i,j,t) represents the sampling point p ij Light state at time t; L(i,j,t) = 1 means that the sampling point is in light at time t; L(i,j,t)=0 means that the sampling point is in the shadow at time t.

[0094] In order to calculate the shadow duration of each sampling point in the entire time interval, we first need to count the sum of its shadow states at all time points. Shadow duration T shadow (p ij ) can be calculated by the following formula: Wherein: N represents the total number of time points in the time interval; ΔT represents the time interval (for example, 1 hour or 1 minute).

[0095] At the same time, the total sunshine duration T total It can be expressed as: T total =N·ΔT Next, according to the shadow duration T shadow (p ij ) and total sunshine duration T total , calculate the shadow weight W(p ij ): Among them, W(p ij ) is the shadow coverage ratio of the sampling point in the entire time interval, ranging from 0 to 1.

[0096] As an option, the calculated shadow weights can be mapped to grayscale values ​​to generate an orthographic projection map of the shadow distribution. For example, the grayscale value can be defined as: G(p ij )=W(p ij )·255 Among them, G(p ij ) is the grayscale value corresponding to the sampling point, ranging from 0 to 255. The higher the grayscale value, the greater the shadow coverage ratio of the sampling point in the time interval.

[0097] Specifically, when generating an orthographic projection, the grayscale values ​​of all sampling points are mapped to the pixel values ​​of the image according to their spatial distribution to generate a grayscale image representing the shadow distribution. Each pixel corresponds to a sampling point, and its grayscale value represents the shadow coverage of the point.

[0098] In a possible implementation, in order to optimize the display effect of the shadow orthographic projection image, image processing techniques such as gamma correction or linear stretching can be applied to the grayscale image. For example, for a scene with a small grayscale value range, the contrast can be enhanced by linear stretching to make the shadow distribution more intuitive.

[0099] In some embodiments, orthographic projection images of different resolutions can also be output according to user needs. For example, a high-resolution shadow distribution map can be directly generated according to the resolution of grid sampling, or a low-resolution quick preview map can be generated through downsampling technology to meet different application scenarios.

[0100] In addition, in order to facilitate subsequent analysis and design, the generated shadow orthographic projection map can be exported to a variety of formats. For example, the image data can be saved in common bitmap formats (such as PNG or JPEG), or directly exported to georeferenced raster data formats (such as GeoTIFF) for compatibility with other geographic information system (GIS) data.

[0101] Through the implementation of this step, dynamic illumination data can be converted into an intuitive static shadow distribution map, providing clear reference data for photovoltaic power station design, building planning and site analysis. This step is closely connected with the previous steps (such as S6 illumination status determination), ensuring the accuracy and consistency of the data, and meeting the diverse application needs through flexible image processing and format output.

[0102] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions, characterized in that: The following steps are involved: By inputting the geographic coordinates of the center point of the orthographic projection, the actual width, height and rotation angle of the image, the geographic coordinates of the four corner points of the orthographic projection are calculated; Generate a 3D tile model using drone aerial photography data and analyze the vertex coordinates and facet structure in the tile model; According to the input time interval, the sun direction vector at multiple time points in the time interval is calculated by the sun position algorithm; Unify the three coordinates of the orthographic projection corner point geographic coordinates, tile model data and sun direction vector into the same east-north-sky local coordinate system; Perform grid sampling on the three-dimensional reconstructed model within the range of the orthographic projection image to generate a set of sampling point coordinates; Based on the ray tracing algorithm, the sampling points and the sun direction vector are used to determine whether the sampling points are blocked by the 3D tile model point by point, and the lighting status of each sampling point in the time interval is obtained; The shadow duration of each sampling point in the time interval is counted, the shadow weight is calculated, and an orthographic projection map representing the shadow distribution is generated.

2. The method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The geographic coordinates of the four corner points of the orthographic projection are calculated by the following steps: Based on the latitude and longitude coordinates of the input image center point, the image width and height are converted to the actual ground size; Combined with the rotation angle of the projection image, the offset of the four corner points is corrected using geometric transformation; The ground offset of the corner point is converted into geographic coordinates through the latitude and longitude coordinate transformation formula on the earth's surface.

3. The method for generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The parsing of the three-dimensional tile model comprises the following steps: Extract vertex coordinates from tile data, where vertex coordinates are a set of points in three-dimensional space; The patch information in the tile data is extracted, where the patch information represents the triangle patch relationship formed by connecting vertices.

4. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The calculation of the sun direction vector comprises the following steps: Based on the sun position algorithm, the sun's altitude angle and azimuth angle are calculated in combination with each time point in the time interval; According to the altitude angle and azimuth angle, the direction vector of the sun in three-dimensional space is generated to describe the incident direction of the sun's rays.

5. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The step of unifying the coordinates into the east-north-sky local coordinate system comprises: The center point of the orthographic projection is taken as the origin of the local coordinate system; Using the geographic coordinate conversion formula, the coordinates of the corner points of the orthographic projection image, the three-dimensional tile model data and the sun direction vector are converted from the geographic coordinate system to the local coordinate system.

6. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The grid sampling step comprises: Divide the orthographic projection image range into regular grids according to the input resolution; Generate sampling points on each grid cell of a regular grid; The spacing of the sampling points is determined by the resolution, and each sampling point represents a position within the orthographic projection.

7. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The step of calculating the shadow based on the ray tracing algorithm comprises: The sampling point is taken as the starting point of the ray, and the sun direction vector is taken as the ray direction; Determine whether the ray intersects with the face of the 3D tile model; If the ray intersects the patch, the sampling point is recorded as being in shadow at that time point, otherwise it is recorded as being in the illuminated state.

8. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The calculation of the shadow weight includes: Count the shadow duration and total sunshine duration of each sampling point in the time interval; The shadow weight is calculated by the ratio of shadow duration to total sunshine duration. The shadow weight indicates the degree of shadow coverage of the sampling point within the time interval.

9. The method of generating an orthographic projection map of shadows throughout the year based on tile data reconstructed by a drone in three dimensions according to claim 1, characterized in that: The generation of the orthographic projection diagram includes: According to the shadow weight of the sampling point, the weight value is mapped to the grayscale value; Generate a grayscale image representing the shadow distribution, and the resolution of the grayscale image is consistent with the grid sampling resolution.

Citation Information

Cited By

  • Map drawing method based on unmanned aerial vehicle

    CN120451325A

  • Method and system for testing albedo of unmanned aerial vehicle cruise photovoltaic power station

    CN122001297A