THE USE OF BREAKLINES OF HYDROGRAPHIC OBJECTS IN THREE-DIMENSIONAL MODELING OF CITIES

: Three-dimensional polygonal models are used for various tasks. They are created based on aerial photography or aerial laser scanning. In this paper, a study is conducted on what tasks require the correct geometry of the model on water bodies. The main modeling problem related to the scanner and photogrammetric processing feature is described. The general scheme of creating mesh models is given. The authors propose a method for using breaklines and generating synthetic points on hydrographic objects. The authors describe the idea of the method, and also mention their technical implementation. The paper presents information about the source data and the result on one data example. The authors leave a lot of topics for discussion, as the method requires development.


INTRODUCTION
Three-dimensional city models are used everywhere for various tasks.Object models such as LOD CityGML are actively used for Digital Twin applications (City Information Modelling).They represent individual simple geometric objects containing semantic information.Meshes are another kind of 3D model.It is a photorealistic mesh polygonal model.It is continuous, geometrically unstructured, so it cannot be used to store semantic information.Such information is needed for complex spatial analysis (Lehner & Dorffner, 2020).But it is impossible not to mention that now actively develops methods of creating semantic mesh models (Wilk, 2022).Such an example is Cesium 3D Tiles Next (Cozzi, 2020).In any case, mesh models have advantages for visualization purposes.The main advantages include high level of information and realism of the model, because it includes all fixed objects of the city (buildings, trees, urban infrastructure).Creation of such a model is cost-effective because most of the process is performed by means of highly automated computations.

Application of mesh models
Three-dimensional mesh models help to solve various problems in architecture, urban planning, monitoring, process modeling.It is important to obtain reliable hydrographic objects in polygonal modeling.Mesh model for the city of Helsinki, Kalasatama district, was used in urban spatial planning.Planned construction projects were superimposed on the mesh model, including objects located in the bay area (Figure 1) (Airaksinen et al., 2019).In this and similar cases, a correct hydrographic surface is necessary to ensure that objects do not go underwater, overlap, for mathematical calculations and measurements.In complex areas, such as urban areas, a detailed digital model is an important tool to build accurate scenarios of flooding (Sole, 2013).Mesh can use for modeling floods and inundation zones.For example, the open source hydrodynamic modelling tool ANUGA takes a triangular mesh of the study area as input data for generating the time series water depth data.Details on polygonal mesh-based flood modeling can be found in K. Kumara, H. Ledouxa, J. Stoter, "Dynamic 3D visualization of floods: case of the Netherlands".For this, as well as for the design of flood zones as a result of natural and man-made emergencies, it is necessary to have a reliable hydrographic surface.If funnels remain on the water surface, a certain volume of water will be lost, which, with the effect of accumulation over the entire area, can lead to terrible consequences in a real situation.A similar situation can happen if there are inappropriate volumes on hydrography.The mesh can also be used in the analysis of changes after an earthquake (De Marco, 2021).A good example of managing a city using a mesh model is the Tomsk 3D project.It shows how, with the help of a polygonal problem, various tasks of urban management can be solved.One of the constantly applied directions for the use of a threedimensional model of the city is the modeling and monitoring of floodwaters (Korenev, 2020).Another important area is the parametric analysis of urban development.The model is also used for conducting graphoanalytic studies on the protection of historical and architectural monuments and others.For many of these tasks, it is especially important to have the right hydrographic surface.

Water bodies in mesh models
We analyzed various models that are publicly available on the Internet.It was found that the models have errors in the modeling of hydrographic objects.Errors consist in the appearance of funnels in the model of a water body, as well as convex areas.Splashes, vehicles, garbage, and more can also lead to an incorrect model.Several examples will be given.Figure 2 shows a fragment of the model for the city of Tomsk, which was written above.As can be seen from the figure, the model has an incorrect geometry on the water object.At the same time, the project is used for modeling floods and other.The tools built into the web application were used to calculate the volume of embankments and recesses relative to the height level of 35 m.Thus, in a small allocated area, the volume of the embankment was about 78 cubic meters, and the volume of the excavation was 47 cubic meters.Similar errors were found in the mesh models published on the Internet sites of other countries, for example, Finland (Helsinki 3D+ project).

The main stages of mesh construction
The technology involves building a mesh model based on a dense point cloud, the source data for which are the results of aerial photography (manned and unmanned) and laser scanning.Availability of high-resolution images allows to obtain a photogrammetric, photorealistic model, as well as to perform its texturing.Laser reflection point clouds can provide more accurate geometric data or additional information about places inaccessible for aerialphoto survey.Creating a mesh includes: -processing the raw data.It is the loading of images, elements of orientation, control and reference points; -phototriangulation, camera self-calibration and accuracy control; -creation of dense point cloud, classification, import of additional materials (LIDAR); -polygonal model building, editing and texturing.Figure 3 shows the flowchart of meshes model construction.
The initial data are aerial images, elements of external and internal orientation images and a catalog of reference and control points, it can be accompanied by photo frames.Photogrammetric processing is performed by standard methods.If the result is satisfactory, then after constructing a dense point cloud, it is filtered and classified.There is also no need to describe in detail the preparation of laser scanning data.It includes calculating the exact trajectory, preprocessing, obtaining point clouds, route summary, cropping, classification of noise, ground points and others.After preparation, the data can be integrated into the project and used in the construction of meshes.They are geometrically more precise, unambiguous.Lidar data also allows you to get points on the ground under vegetation, facades of buildings hidden by trees.A photogrammetric dense point cloud and scan data are a set of closely spaced points and do not contain information about their connectivity and belonging to surfaces.The task of restoring the surface can have an ambiguous solution, which can lead to ruptures.The methods of constructing polygonal models based on point clouds are different.Some rely on Poisson reconstruction.Others are based on nearest neighbor interpolation methods.It is also possible to use the VRIP method (image processing in the volume range), as the name implies, it is the construction of polygonal models based on depth maps.The most applicable in spatial modeling is the Poisson reconstruction, which represents one of the methods of Marching Cubes.The geometry of the created model often needs to be corrected.It may have redundant geometry, holes, incorrect topology.Therefore, there is a need to edit it.The main steps are thinning, simplifying, removing polygons, closing holes, correcting topological connectivity, smoothing.One of the last stages is texturing.

Automated system
The creation process is mostly automated.It is necessary to perform data preparation, determine some of the parameters and perform accuracy control.At the same time, the main success of creation and quality of the result depends on the accuracy, resolution and quantity of raw data (Airaksinen et al., 2019).
As mentioned, most of the steps are automated.There is a large list of software for photogrammetric processing.These are Bentley ContextCapture, Agisoft Metashape, Pix4D, RealityCapture, PHOTOMOD, Trimble Inpho and others.But not every software is able to work with a large amount of data, which is necessary to create models on cities.There are also a number of programs that are for editing 3D models.Such programs are Blender, MeshLab, SketchUp.The process of automation implies the need to use powerful computing resources, a large amount of memory and productive equipment.

Features of obtaining points on water surfaces by LIDAR and photogrammetry method
The process of editing a model or a dense point cloud is necessary because the model has errors on hydrological objects.This is due to the peculiarities of the photogrammetric process and scanning.This is mainly because water does not diffusely reflect the incoming light and, also, for passive methods, do not have a special texture needed for image matching tasks (Morelli, 2022).The automatic calculation of photogrammetric cloud is based on determining connection points on the images.The points may be not enough or they may have low fidelity.This is because of strong reflections and changing appearance due its moving surface prohibit the accurate reconstruction of waterbodies from images employing stereo vision methods.Water surface detection with LIDAR is possible, but the interaction of laser radiation with the water-air interface is complex.A reliable result can only be obtained in a small range of angles around the nadir (Mandlburger, 2019), and angles outside the nadir exceeding 5-7° lead to laser dropout (Höfle, 2009).For a detailed study of the scanning parameters that affect the result of backscattering of the signal from water surfaces, one can refer to Mandlburger, G. ( 2017).There the dependence on laser wavelength, angle of incidence, beam divergence, scan spot size, albedo effect, specular reflection etc. is given.And also the results of field work, specific measurements on the ground are presented.Now there are LiDAR sensors using low-energy pulses and single-photon sensitive detectors.They increase the effective imaging area of water surfaces compared to traditional LiDAR sensors (Stoker, 2016).This method has resulted in a decrease in range accuracy and an increase in measurement noise (Ullrich, 2016(Ullrich, , 2018)).The technology is called Single Photon LiDAR and is manufactured by Leica/Hexagon (SPL100) (Leica, 2022).But the use of such a sensor is complicated by the cost of equipment, complexity of processing and inaccessibility.

THE MODELING OF WATERBODIES
Boundaries of water objects are determined by the water level at the time of the survey (International Glossary of Hydrology, 2016).Accordingly, the altitudes of area water bodies (lakes, reservoirs, ponds, swamps) must be the same.Thus, during modeling all points that are located within a water body should have the same altitudes.

Theoretical method
We propose a solution.It is a method that allows to improve the result of model building with hydrographic objects.We propose to use breaklines (e.g.shorelines of water bodies).It is necessary to make digitization on the source data used to build a mesh model.So determine the boundaries of the water body.assign an elevation for each vertex of the polygon.For this purpose, the average value of the elevation is used, or a concrete mark of the elevation of the benchmark at the time of survey (if it is available).The next step is automatic generation of synthetic points grid with specified elevation within selected boundaries.It is necessary to remove existing points in the cloud, while introducing synthetic points.Then the standard modeling steps are taken.
For watercourses we change the technology, because they have a fall.This is the difference in elevation of the water surface between two points of a stream (International Glossary of Hydrology, 2016).Shoreline elevations can change irregularly downstream.As you work with the shoreline vector, you need to get the altitudes of the vertices, and you need to track the changes.The slope must be correct.You may have to make changes manually.When generating synthetic points, the altitudes of the vertices are taken into account and interpolation takes place.In that way we will get the surface of the river with changes of elevations.

Technical realization
At the first stage, the technical solution of this method was as follows.Vector cartographic materials on hydrographic objects from a single data collection were used.Vector layers were imported into AutoCAD, then the height for the vertices was set.The height mark was calculated manually, measurements were carried out using a model, a point cloud or in stereo mode.After receiving a vector with the correct elevation marks, it was imported into TerraScan, and points were automatically generated.Then the point cloud was saved and integrated into the Metashape project for further modeling.In the process of improving the technology of applying the method on specific projects, it was modernized.First, in order to build a correct mesh, it is necessary to vectorize hydrographic objects according to current data.It is important to use the data on which the simulation will be carried out.So, it is necessary to carry out vectorization in the Metashape software.It should be noted that the vertices get heights from adjacent data.The next thing that was decided was the rejection of a large amount of software.Currently, vertex heights are edited in Agisoft Metashape.A Python script was written that adds new features to the toolbar (Metashape Python, 2022).The main difficulty that arose on the way was the absence of an object in the class -the vertex of a polygon, a polyline.They could not be accessed to change the height.To do this, a function was written to convert a polygon into points.After this operation, you can select the necessary points, 1 or more.Then, also using the tool implemented by the script, also set the required height.It is convenient to use it across on opposite shores of the reservoir or nearby points.Next, combine all the points into a polygon.At the same time, the possibility of creating a landfill for lakes and reservoirs, the edge of which is at the same height, was realized.The script shown in Figure 4 is our implementation.
Unfortunately, at the moment there is no working script for generating synthetic points in Agisoft Metashape.Development is underway, this required the connection of third-party libraries that allow interpolation.Also, it has not yet been possible to implement obtaining the elevation of the coastline from the center of the reservoir in cross-section.This is done only with manual analysis, and the generation of synthetic points uses TerraScan.

Materials and Methods
The method of application of break lines and generation of synthetic points was tested on different raw data: aerial photography from a manned and UAV, LIDAR data; on a few territories with significant differences in building development, slope of the terrain.The table 1 shows the surveys and characteristics, the materials from which were used to write this article: 1) aerial survey from an airplane with a Leica RCD30 camera; 2) aerial survey from an airplane with a Leica RCD30 camera and an ALS70 scanner; 3) aerial survey with a Sony A6000 UAV camera; 4) aerial survey with a Sony A6000 UAV camera and an AGM MC1 scanner.The characteristics of the surveys are presented in Table 1.Table 1.Data sets and their parameters.
The exact trajectory of the vessel was calculated in Novatel Inertial Explorer (Waypoint, 2020).The generation of a geolinked cloud of laser points and the acquisition of photographing centers for Leica equipment was performed in HxMap (HxMap, 2021).For an unmanned aerial vehicle, these processes were performed in AGM ScanWorks.Photogrammetric processing was completely performed in Agisoft Metashape Professional (Agisoft, 2023).Laser reflection points were processed and classified in the TerraSolid software package (TerraScan, 2023).The mesh model was created in Agisoft Metashape Professional.

Result
Figures 5 show the visual results of using the proposed method on materials by unmanned aerial survey with a Sony A6000 camera and an AGM MC1 scanner.Figures 6 show the visual results of using the proposed method on materials by unmanned aerial survey with a Sony A6000 camera and an AGM MC1 scanner.
In addition to the visual assessment, the calculation of the change in the area of the polygonal model was carried out.The result showed a decrease in the number of polygons, vertices, respectively, and areas.For example, for the dataset mentioned above, the difference was 387 square meters.Thus, we can conclude about the usefulness of the method.Manual labor for its implementation is not long in time.But there are still a lot of topics to discuss.

Discussion
First, it is necessary to determine the need to obtain correct hydrography in the mesh model.For the purposes of urban planning, monitoring, emergency response -it is necessary to use the method described in this paper.
Secondly, practice and the study of the experience of others have shown that it is not so important on what materials the mesh is created.Hydrographic objects mostly have unreliable or low density results.It should also be noted that the method was described ideologically.Technical implementation features should be studied further and improved.It is necessary to study the interpolation methods and choose the most suitable one for a specific task.And also to develop tools that facilitate the process of using it.In our case, this is the Python programming language.It is also necessary to determine the methodology for large reservoirs, lakes.Often their level may not support a mark of the same height.We have not carried out an assessment with the results of ground measurements, but this can also be assessed.There is also a big idea that this method can be implemented for the road network, squares, stages, pedestals.But the most inspired idea is to use this method for modeling important buildings and objects in a mesh.Having some measurements of them, it is possible to generate synthetic points in vertical planes, describe shapes geometrically correctly, and embed such a cloud into the total mass of data.When modeling, it will be devoid of noise, but it will be part of a continuous model, have a texture.

CONCLUSION
Despite the fact that polygonal city models are used for many tasks, the technology of their creation is not perfect.To model flooding and inundation, for use in urban planning and management, it is necessary to display the correct geometry.Thus, the general technology of meshes model construction, features of photogrammetric processing and laser scanning of water objects were considered.A method was proposed, which allows to correctly obtain hydrographic objects.Its program realization was presented, results were shown and many topics for discussion were put forward.

Figure 2 .
Figure 2. A fragment of the model for the city of Tomsk.

Figure 3 .
Figure 3. Technological scheme of mesh model construction.

Figure 5 .
Figure 5.One of the examples of using the method.