International Journal of Geo-Information

Article VisWebDrone: A Web Application for UAV Photogrammetry Based on Open-Source Software

Nathalie Guimarães 1,2,* , Luís Pádua 1,3 , Telmo Adão 1,3 , Jonáš Hruška 1, Emanuel Peres 1,3 and Joaquim J. Sousa 1,3

1 Engineering Department, School of Science and Technology, University of Trás-os-Montes e Alto Douro, 5000-801 Vila Real, Portugal; [email protected] (L.P.); [email protected] (T.A.); [email protected] (J.H.); [email protected] (E.P.); [email protected] (J.J.S.) 2 Centre for the Research and Technology of Agro-Environmental and Biological Sciences, CITAB, Universidade de Trás-os-Montes e Alto Douro, UTAD, 5000-801 Vila Real, Portugal 3 Centre for Robotics in Industry and Intelligent Systems (CRIIS), INESC Technology and Science (INESC-TEC), 4200-465 Porto, Portugal * Correspondence: [email protected]; Tel.: +351-259-350-762 (ext. 4762)

 Received: 24 September 2020; Accepted: 13 November 2020; Published: 15 November 2020 

Abstract: Currently, the use of free and open-source software is increasing. The flexibility, availability, and maturity of this software could be a key driver to develop useful and interesting solutions. In general, open-source solutions solve specific tasks that can replace commercial solutions, which are often very expensive. This is even more noticeable in areas requiring analysis and manipulation/visualization of a large volume of data. Considering that there is a major gap in the development of web applications for photogrammetric processing, based on open-source technologies that offer quality results, the application presented in this article is intended to explore this niche. Thus, in this article a solution for photogrammetric processing is presented, based on the integration of MicMac, GeoServer, Leaflet, and Potree software. The implemented architecture, focusing on open-source software for data processing and for graphical manipulation, visualization, measuring, and analysis, is presented in detail. To assess the results produced by the proposed web application, a case study is presented, using imagery acquired from an unmanned aerial vehicle in two different areas.

Keywords: open-source; web application; photogrammetry; unmanned aerial vehicles; MicMac; GeoServer; Leaflet; Potree

1. Introduction Currently, a wide range of geodetic procedures and methods to record the actual state of objects on the Earth surface is available [1]. Photogrammetry is one of these methodologies, which is considered to be the art, science, and technology of acquiring geometric information related to physical objects through processes of recording, measuring, and interpreting photographs and patterns [2]. These processes include automated interest-point detection [3], Structure from Motion (SfM) algorithms [4], and dense image-matching techniques [5]. To improve and speed up photogrammetric processing, several commercial and open-source libraries and pieces of software have been developed [6,7]. Among the most used commercial software, Pix4Dmapper (Pix4D SA, Lausanne, Switzerland), Agisoft Metashape (Agisoft LLC, St. Petersburg, Russia), and DroneDeploy (DroneDeploy, San Francisco, CA, USA) stand out. Some examples of open-source software and libraries include MicMac [6], VisualSFM [8], Bundler [9], Python Photogrammetry Toolbox [10], and Open Drone Map [11], which are based on SfM techniques [12]. Despite the availability of several solutions for photogrammetric processing, the cost and the performance associated with each solution

ISPRS Int. J. Geo-Inf. 2020, 9, 679; doi:10.3390/ijgi9110679 www.mdpi.com/journal/ijgi ISPRS Int. J. Geo-Inf. 2020, 9, 679 2 of 16 could be a deciding factor [13]. Regarding the cost of commercial software, prices vary, DroneDeploy being the best option from an economic point of view. In contrast, open-source solutions are free and can be a feasible solution for several users. Despite the high costs associated with commercial software, it is important to consider that software providers make all of needed functionalities available off-the-shelf in a single software package, whereas free and open-source software (FOSS) usually offer a single category of functionalities [14]. In this way, the development of a global and complete application involves the use of different open-source libraries, which has become a great challenge for developers [15]. In the last decade, Internet access through devices (computers, smartphones, and tablets) has increased significantly [16]. For this reason, many organizations are considering the Internet as the main platform for software solutions, creating software as a service (SaaS). This type of platform presents several advantages and it is worth highlighting its ability to maintain and update the applications without distributing and installing any software on client computers [17]. Considering the commercial photogrammetric SaaS, Pix4D Cloud, DroneDeploy, and 4DMapper stand out. Some free photogrammetric web-interfaces (e.g., ARC 3D Webservice, MiaW, Culture 3D Cloud Platform, CMP SfM web service, 3DNOW) are available. However, there is a lack of open-source solutions that offer a complete and integrated solution for the processing and visualization of aerial imagery acquired from unmanned aerial vehicles (UAVs). As a result, considering the aforementioned advantages, the aim of the proposed research is to present VisWebDrone (visual web platform for drone-based imagery analysis), a web application for UAV photogrammetry based on open-source technologies. The proposed solution will be maintained as a free and open-source platform, available on GitHub, relying on the users contribute. The web application is composed of several pieces of open-source software that are completely integrated, combining the data-processing stage with the graphical presentation of the results. The data-processing stage is performed using MicMac, while the graphical presentation of the results is provided by Leaflet and Potree. Several Graphical User Interface (GUI) solutions, integrating MicMac, have already been developed. Among the solutions developed, the CEREMA (Centre d’études et d’expertise sur les risques, l’environnement, la mobilité et l’aménagemen) has released the AperoDeDenis, a GUI for MicMac that is under development. Another GUI, the InterfaceMicmac, developed by IGN (Institut national de l’information géographique et forestière) was discontinued. Recently, Alessio Calantropio of Politecnico di Torino developed the GEMINI (Graphically Enhanced MicMac’s New Interface) solution, which is focused on the quality assessment of the achieved results [18]. Although all GUI solutions presented applied the abstracting command line provided by MicMac software, none of them has available graphical solutions for the manipulation and visualization of the achieved results, using photogrammetric processing (e.g., visualization of orthophoto mosaics and point clouds). VisWebDrone intends to fill this gap, providing the appropriate tools for this purpose. Following this introductory section, Section2 describes the VisWebDrone structure and architecture, presenting the modules and software integrated into the web application. Section3 is dedicated to the demonstration of the implemented solutions presented in Section2. Then, to exemplify and test the web application functionalities, two study areas are presented in Section4. In Section5, the results are presented and discussed. Finally, in Section6 the conclusions of the present research are addressed.

2. System Architecture The conception of a web application for manipulation, analysis, and visualization of UAV-based imagery outputs requires four modules. Module 1 is responsible for the photogrammetric processing, receiving as inputs the images collected by UAVs and producing as outputs an orthophoto mosaic and a 3D dense point cloud. Next, Module 2 is used to store the orthophoto mosaic in a map server. This module receives as input the orthophoto, generated in Module 1, and makes available several web services for geographical data publishing. Module 3 is responsible for orthophoto mosaic visualization, using a Web Map Service (WMS) layer as input and produces a web-mapping page for orthophoto ISPRS Int. J. Geo-Inf. 2020, 9, 679 3 of 16

ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 3 of 16 visualization as output. Finally, Module 4 deals with dense point cloud visualization and analysis. Thisorthophoto module visualization receives the as point output. cloud Finally, data, Module provided 4 deals by Module with dense 1, and point builds cloud a visualization webpage for and its visualization.analysis. This Figuremodule1 presents receives thethe flowchartpoint cloud of thedata, modules. provided by Module 1, and builds a webpage for its visualization. Figure 1 presents the flowchart of the modules.

Figure 1. Flowchart of the four modules needed for the conception of the web application. Figure 1. Flowchart of the four modules needed for the conception of the web application. 2.1. Module 1—Photogrammetric Processing 2.1. Module 1—Photogrammetric Processing Among the different photogrammetric packages freely available, OpenDroneMap (ODM) and MicMacAmong were the considered different the photogrammetric most suitable options packages for the freely development available, of theOpenDroneMap proposed web (ODM) application. and ThisMicMac choice were is mainly considered because the both most integrate suitable tools options allowing for thethe generation development of orthophoto of the proposed mosaics weband pointapplication. clouds, This in the choice same is pipeline. mainly because both integrate tools allowing the generation of orthophoto mosaicsODM and is point a community-based clouds, in the same open-source pipeline. toolkit, developed for processing and analyzing aerial imageryODM acquired is a community by UAVs.-based This command-line-basedopen-source toolkit, developed program runs for processing on all major and operating analyzing systems aerial throughimagery theacquired use of by UAVs. container This command (Docker,-line Inc.,-based Palo program Alto, CA, runs USA) on and all major is distributed operatin underg systems the GPLv3through license the use [19 of]. Docker container (Docker, Inc., Palo Alto, California, USA) and is distributed underMicMac the GPLv3 is associatedlicense [19] with. the acronym “Multi Images Correspondances par Méthodes AutomatiquesMicMac is de associated Corrélation—Multi with the Image acronym Matches “Multi by Images Automatic Correspondances Correlation Methods” par Méthodes and its developmentAutomatiques began de Corrélation in 2005, by - the Multi French Image National Matches Institute by Automatic of Geographic Correlation and Forestry Methods” Information and its (IGN)development and the began French in National 2005, by Schoolthe French of Geographic National Institute Sciences of (ENSG) Geographic [6]. MicMac and Forestry is an open-sourceInformation software(IGN) and distributed the French under National the CeCILL-BSchool of Geographic license. Initially, Sciences it was (ENSG) provided [6]. MicMac as an Extensible is an open Markup-source Languagesoftware distributed (XML) framework, under the allowing CeCILL the-B processinglicense. Initially, parametrization it was provided to be defined as an Extensible by users. However, Markup inLanguage 2010, the (XML) XML framework framework, was allowing discontinued, the processing giving way parametrization to a simplified to command-line be defined by interface users. thatHowever, has been in 2010, contributing the XML to framework an increase was of the discontinued, use of this open-source giving way software. to a simplified MicMac command is a versatile-line software,interface that which has can been be usedcontributing in different to an types increase of objects, of the fromuse of small this objectsopen-source acquired software. from the MicMac ground is perspectivea versatile software, to buildings which acquired can be from used an in aerial different perspective. types of Evenobjects, imagery from small form regionalobjects acquired areas, such from as citiesthe ground or natural perspective places, acquiredto buildings from acquired manned from aircraft an aerial or satellites, perspective. can be Even used imagery [20]. form regional areas,Both such ODM as cities and or MicMac natural are places, free andacquired open-source from manned solutions. aircraft However, or satellites the accuracy, can be ofused 3D [20] point. cloudsBoth is vital ODM in and VisWebDrone, MicMac are allowing free and the open execution-source solutions. of accurate However, three-dimensional the accuracy measurements. of 3D point Forclouds this is purpose, vital in VisWebDrone a preliminary, allowing comparative the execution test was performedof accurate betweenthree-dimensional both solutions. measurements In ODM,. theFor depthmap-resolutionthis purpose, a preliminary parameter comparative controls the test density was performed of the point between cloud by both setting solutions the resolution. In ODM of, thethe depthmapdepthmap- images.resolution Therefore, parameter a higher controls value the forden thissity parameterof the point (1200) cloud was by defined,setting the according resolution to theof the ODM depthmap community images. suggestions. Therefore, Regarding a higher value the MicMac for this parameter parameters, (1200 the) C3DC was defined, tool with according BigMac parameterto the ODM was community applied, whichsuggestions. presents Regarding a higher the preset MicMac of 1pt parameters,/4px. Considering the C3DC the tool results, with the BigMac point cloudparameter data was generated applied by, which MicMac presents presents a higher a higher preset density of 1pt/4px. of points Considering (12,462,884 the points), results, as the well point as acloud better data quality generated and definition by MicMac when presents compared a higher to ODM density results of points (10,851,334 (12,462 points).,884 points Figure), as2 well depicts as a thebetter dense quality point and clouds definition generated when usingcompared the same to ODM imagery results dataset (10,851 in,3 both34 points solutions.). Figure Regarding 2 depicts thethe performancedense point of clouds both software generated in theusing production the same of imagery orthophoto dataset mosaic, in the both results solutions. presented Regarding were good the andperformance met the expectations. of both software Therefore, in the for production the reasons of presented orthophoto above, mosaic, MicMac the wasresults selected presented to perform were photogrammetricgood and met the processing.expectations. Therefore, for the reasons presented above, MicMac was selected to perform photogrammetric processing.

ISPRS Int. J. Geo-Inf. 2020, 9, 679 4 of 16 ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 4 of 16

Figure 2. 3D dense point clouds produced by free and open-source photogrammetric processing Figure 2. 3D dense point clouds produced by free and open-source photogrammetric processing software: (a) OpenDroneMap, (b) MicMac. software: (a) OpenDroneMap, (b) MicMac. 2.2. Module 2—Orthophoto Mosaic Storage in a Web GIS Server 2.2. Module 2—Orthophoto Mosaic Storage in A Web GIS Server For the task of storing raster generated data in Module 1, two web Geographic Information SystemFor (GIS) the task servers of storing stand out raster as some generated of the data most in used Module in FOSS 1, two communities, web Geographic the MapServer Information and theSystem GeoServer. (GIS) servers stand out as some of the most used in FOSS communities, the MapServer and the GeoServerMapServer. was founded in 1996, at the University of Minnesota. It is an open-source web-mapping project,MapServer designed was for developing founded in interactive 1996, at the and University interoperable of web-mappingMinnesota. It applications.is an open-source MapServer web- omappingffers support project, for designed several Open for developing Geospatial Consortiuminteractive and (OGC) interoperable standards, web such-mapping as WMS, applications. Web Feature ServiceMapServer (WFS), offers and support Web Coverage for several Service Open (WCS), Geospatial and is Consortium compatible with(OGC) a wide standards, variety such of vector as WMS, and rasterWeb Feature formats. Service This web(WFS) server, and runsWeb asCoverage a common Service gateway (WCS) interface, and is (CGI)compatible application with a withwide Apachevariety andof vector Microsoft and raster web servers formats. [21 This]. web server runs as a common gateway interface (CGI) application with GeoServer,Apache and in Microsoft turn, was web founded servers in [21] 2001,. belonging to the Lime Group, the Open Planning Project,GeoServer, and Refractions in turn, Research. was founded This platform in 2001, belongingplays a crucial to the role Lime in the Group, management, the Open storage Planning and presentationProject, and Refractions of geospatial Research. data over This the platform Internet. plays Users a crucial can upload role in data the management, into the GeoServer storage using and apresentation web administration of geospatial tool, data a database, over the or Internet. gsconfig—a Users Python can upload library data for into manipulating the GeoServer a GeoServer using a instanceweb administration via the GeoServer tool, a RESTConfig database, or API. gsconfig As a web—a server,Python it library integrates for anmanipulating interface where a GeoServer users can searchinstance for via layers, the GeoServer consult data RESTConfig provided byAPI. database As a web or manageserver, it the integrates web services an interface used to where share rasterusers andcan search vector datafor layers, [22]. GeoServer consult data serves provided spatial by data database based onor OGCmanage standards: the web WMS services for theused display to share of mapsraster asand images, vector WFS data for [22] vector. GeoServer data, WCS serves for rasterspatial data, data Web based Processing on OGC Service standards: (WPS) WMS for invoking for the geospatialdisplay of maps processing as imag services,es, WFS and for WFS-T vectorfor data, edition WCS that for raster allows data, the creation, Web Processing deletion, Service and updating (WPS) offor features. invoking GeoServer geospatial is processing a RESTful services server where, and WFS every-T resource for edition could that be allows requested the creation, using a Universal deletion, Resourceand updating Identifier of features. (URI), whichGeoServer is dependent is a RESTful on the server web servicewhere every defined. resource Regarding could WMS be requested requests, mapsusing coulda Universal be provided Resource in several Identifier formats, (URI), such which as Geoti is dependentff, KML, and on Portable the web Network service Graphics defined. (PNG).Regarding On WMS the other requests, hand, maps in WFS could requests, be provided the vector in several data could formats, be provided such as inGeotiff, formats KML such, and as GeographyPortable Network Markup Graphics Language (PNG (GML),). On GeoJSON, the other and hand, Shapefile in WFS [23 requests,]. the vector data could be providedRegarding in formats the comparison such as Geography between Markup both web Language GIS servers (GML presented), GeoJSON in this, and subsection, Shapefile they[23]. are bothRegarding similar in thethe supportedcomparison OGC between standards. both web However, GIS servers GeoServer presented offers in WFS-T, this subsection which is, essentialthey are toboth edit similar processing in the results,supported allowing OGC featurestandards. creation, However, deletion, GeoServer and updating. offers WFS MapServer,-T, which inis essential contrast, doesto edit not processing offer this results, important allowing service. feature Moreover, creation, another deletion, important and updating. advantage MapServer, of GeoServer in contrast, is that it hasdoes a not web offer administration this important tool service. available Moreover, that optimizes another the important user experience advantage which of makesGeoServe it possibler is that toit searchhas a web for layers,administration consult data tool providedavailable bythat database, optimizes or managethe user theexperience web services which used makes to share it possible raster andto search vector for data layers, [24]. consult For the above-mentioneddata provided by reasons,database GeoServer, or manage was the elected web services as the web used GIS to servershare toraster store and orthophoto vector data mosaics. [24]. For the above-mentioned reasons, GeoServer was elected as the web GIS server to store orthophoto mosaics. 2.3. Module 3—Orthophoto Mosaic Visualization 2.3. Module 3—Orthophoto Mosaic Visualization Web-mapping Application Programming Interfaces (APIs) are function libraries that are usually basedWeb on- JavaScript.mapping Application These APIs Programming include tools Interfaces that facilitate (APIs) data are function fusion, providedlibraries that from are di usuallyfferent resources,based on JavaScript. through their The acquisition,se APIs include manipulation, tools that and facilitate visualization data fusion, [25]. provided To visualize from orthophoto different mosaics,resources, generated through intheir the Moduleacquisition, 1 of themanipulation proposed web, and application, visualization two [25] frequently. To visualize used web-mapping orthophoto mosaics, generated in the Module 1 of the proposed web application, two frequently used web- mapping APIs were analyzed—the OpenLayers and the Leaflet. The selection of these particular web-

ISPRS Int. J. Geo-Inf. 2020, 9, 679 5 of 16

APIs were analyzed—the OpenLayers and the Leaflet. The selection of these particular web-mapping APIs is because of good support and documentation provided for the developers, which contributes to the increase in number of communities that are using these APIs. OpenLayers is a JavaScript library used for web map creation. This solution implements a JavaScript API for building rich web-based geographic applications, which is one of the mostly used open-source technologies. It also implements industry-standard methods for geographic data access, such as the OGC, WMS, and WFS standards [26]. Leaflet, in turn, is similar to OpenLayers, being a JavaScript library developed to create web maps. This library includes a wide variety of functions allowing the creation of simple web maps or complex and interactive web maps offering users changing/edition possibilities [27]. Considering the characteristics of each web-mapping API, it can be noted that Leaflet API has much shorter code than OpenLayers for doing the same process, which makes it faster. Moreover, Leaflet supports OpenStreetMap as well as other map providers. For these reasons, Leaflet was considered the most feasible API to load and visualize orthophoto mosaics.

2.4. Module 4—3D Point Cloud Visualization To allow the 3D point cloud visualization in VisWebDrone, point cloud viewers were analyzed. Despite the lack of FOSS software for this purpose, two solutions were identified: Potree and Plasio technologies [28]. Potree is a web-based point cloud renderer allowing the visualization of billions of points. It simplifies the dissemination of point cloud data, once it is presented in a web page, without requiring the existence of additional software [29]. Potree depends on WebGL technology, which is a JavaScript API compatible with HTML5. WebGL is a variation of OpenGL but is adapted to web browsers, allowing the Graphics Processing Unit (GPU) rendering capabilities to be applied to web pages. Potree also depends on three.js library which consists of a rendering library used to manipulate scene graphs and draw calls [30]. Plasio is also based on WebGL technology, being a web-based point cloud viewer that supports LASer (LAS) files and its compressed version LASer zip (LAZ). To use it for displaying single files, its development team is working on a multi-resolution indexing and rendering stack applied to large point clouds [31]. Potree was the chosen software for the point cloud visualization, once it proved to be the most robust platform, offering a wide set of tools for point cloud visualization, manipulation, and analysis.

2.5. Software Integration For the web application development, a Representational State Transfer (REST) architecture was implemented, which enables communications between client and server sides, performed through HyperText Transfer Protocol (HTTP) methods [32]. The client side is associated with the web application interface, responsible for enabling users to upload images on a system and define the processing parameters. Users can select a complete photogrammetric processing pipeline that generates the orthophoto mosaic and the point cloud, or select each one individually. The defined processing pipeline, in turn, is sent as a request for the server side, outlining the processing sequence that will be done by MicMac. This process is executed through several PHP and Ajax scripts. Once data processing performed by MicMac is complete, it is possible to obtain the orthophoto mosaic that will be stored on a GeoServer instance, using the gsconfig Python library. GeoServer has a set of web services available that can be used to share raster data in web applications. In this case, the WMS is used through the request of Leaflet. The point cloud is rendered in the web page, using Potree. This process is illustrated in Figure3. ISPRS Int. J. Geo-Inf. 2020, 9, 679 6 of 16

ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 6 of 16 ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 6 of 16

Figure 3. ArchitectureArchitecture of the proposed web application. Figure 3. Architecture of the proposed web application. The web web application application interface interface intends intends to promote to promote a user-friendly a user-friendly experience, experience, presenting presenting a simple, a simple,intuitive,The intuitiveweb and clean application, and design. clean VisWebDroneinterface design. intends VisWebDrone is composed to promote is of composed a section a user to- friendly of select a section and experience, upload to select images presenting and collected upload a simple,imageby UAVss intuitivecollected (Figure,4 byanda), UAV a sectioncleans (Figure4a) de tosign. select VisWebDrone, thea section type of to output select is composed the to process type ofof (Figure aoutput section4 b)—orthophototo toprocess select (Figure and mosaic, upload 4b)— imagepointorthophotos cloud, collected mosaic or both—andby ,UAV points (Figure4a) another cloud, section or, a section both to—visualize andto select another the type results section of ofoutput photogrammetricto visualize to process the (Figure processing results 4b) — of o(Figurephotogrammetricrthophoto4c). mosaic proces, pointsing cloud (Figure, or 4c ). both —and another section to visualize the results of photogrammetric processing (Figure 4c).

Figure 4. VisWebDrone functionalities and interface visualization: (a) upload of imagery; (b) type of FigureoutputFigure 4. 4.to VisWebDrone VisWebDroneprocess; and ( cfunctionalities functionalities) visualization and andand interface interfaceanalysis visualizationof visualization: the results.: ( (aa)) upload upload of of i imagery;magery; ( (bb)) type type of of outputoutput to to process; process; and and ( (cc)) visualization visualization and and analysis analysis of of the the results. results. 3. Software Implementation 3. Software Implementation 3. Software Implementation This section presents MicMac, GeoServer, Leaflet, and Potree functionalities and the way they This section presents MicMac, GeoServer, Leaflet, and Potree functionalities and the way they wereThis implemented section presents in the VisWebDroneMicMac, GeoServer, solution. Leaflet , and Potree functionalities and the way they were implemented in the VisWebDrone solution. were implemented in the VisWebDrone solution. 3.1. MicMac MicMac Implementation 3.1. MicMac Implementation MicMac implements photogrammetry based based on SfM algorithms, consisting of two successive steps.MicMac The The first first implements step step is is related photogrammetry to the detection based and matching on SfM algorithms, of automatic consisting tie points of while two successivethe second steps.step is The associated first step with is related the bundle to the detection adjustment and that matching corresponds of automatic to the computationtie points while of viewpointsthe second steprelative is associated locations (camerawith the positions)bundle adjustment [33]. These that steps corresponds are integrated to the in computationMicMac tools, of presented viewpoints in relativeFigure 4locations. MicMac (camerais very flexible, positions) offering [33]. Theseseveral steps tools are that integrated can be selected in MicMac to define tools, a completepresented and in Figure 4. MicMac is very flexible, offering several tools that can be selected to define a complete and

ISPRS Int. J. Geo-Inf. 2020, 9, 679 7 of 16 relative locations (camera positions) [33]. These steps are integrated in MicMac tools, presented in Figure4. MicMac is very flexible, o ffering several tools that can be selected to define a complete and appropriate workflow. The workflow used for imagery processing (Figure5) is based on the followingISPRS Int. J. steps: Geo-Inf. 2020, 9, x FOR PEER REVIEW 7 of 16

1.appropriateTie points workflow. are identified The using workflow the Tapioca used tool.for imagery This procedure processing is based (Figure on the 5) identificationis based on of the followingcommon steps: features present in the images. Considering the higher computation time on large sets of1. images,Tie points the MulScaleare identified mode using can reducethe Tapioca the processing tool. This procedure time, after is the based first on computation the identification of tie pointsof iscommon performed features at a lowpresent resolution. in the images. Considering the higher computation time on large 2. Tapassets is thenof images, used for the calculating MulScale mode the relative can reduce orientation the processing of images, time, using after the the identified first computation tie points, by computingof tie points the is position performed and at the a low distortion resolution. model of the camera optics; 3. AperiCloud2. Tapas is isthen used used to produce for calculating a Polygon the Filerelative (PLY) orientation with the position of images, of cameras; using the identified tie 4. Thepoints, next step by computing could depend the position on the usage and the of distortion ground control model pointsof the camera (GCPs). optics; If nonexistent

CenterBascule3. AperiCloud is is used, used if to GCPs produce are considered a Polygon toFile be (PLY) SaisieAppuisInitQT, with the position and of GCPBasculecameras; tools

can4. beThe applied, next step CenterBascule could depend transforms on the usage a relative of ground orientation control intopoints an (GCPs) absolute. If one,nonexistent using embeddedCenterBascule Global Positioning is used, if SystemGCPs are (GPS), considered while SaisieAppuisInitQT to be SaisieAppuisInitQT tool is applied, and GCPBascule to perform the GCPstools markingcan be applied and then, CenterBascule GCPBascule executestransforms the a same relative process orientation as CenterBascule into an absolute but, in thisone, case,using also using embedded GCPs. Global The web Positioning application System documentation (GPS), while will SaisieAppuisInitQT explain how users cantool select is applied the imagesto andperform the GCP the to GCPs be marked. marking The and web then application GCPBascule activates executes the MicMac the same external process tool toas performCenterBascule the GCP marking. but, in this case, also using GCPs. The web application documentation will explain how users can select the images and the GCP to be marked. The web application 5. Campari is responsible for bundle adjustment using tie points and GCPs; activates the MicMac external tool to perform the GCP marking. 6. ChgSysCo is used to define the final coordinate system of orientation; an XML file that specifies 5. Campari is responsible for bundle adjustment using tie points and GCPs; the European Petroleum Survey Group (EPSG) code associated with the coordinate system is 6. ChgSysCo is used to define the final coordinate system of orientation; an XML file that used in this step. specifies the European Petroleum Survey Group (EPSG) code associated with the coordinate 7. To obtain the point cloud data, theC3DC tool, provided by Culture 3D Cloud project, system is used in this step. was applied [34]. This tool computes an automatic matching, generating a point cloud, in PLY 7. To obtain the point cloud data, theC3DC tool, provided by Culture 3D Cloud project, was format, from a set of oriented images. The Pims2Mnt tool was responsible for the merging of the applied [34]. This tool computes an automatic matching, generating a point cloud, in PLY individual depth maps into a global Digital Surface Model. To produce the orthophoto mosaic, format, from a set of oriented images. The Pims2Mnt tool was responsible for the merging of the Tawny tool was used. The orthophoto mosaic was generated in TIF format and is based on the individual depth maps into a global Digital Surface Model. To produce the orthophoto individual orthophotos [35]. mosaic, the Tawny tool was used. The orthophoto mosaic was generated in TIF format and is based on individual orthophotos [35].

FigureFigure 5. 5.MicMac MicMac workflow. workflow.

3.2. GeoServer and Leaflet Integration The communication between Leaflet (client side) and GeoServer (server side) is performed through the use of GetMap requests that are used to load the geospatial data, stored in server, into the web-mapping page (Figure 6). The specifications of GetMap requests are defined by Leaflet library, using the WMS standard that is based on HTTP methods [36].

ISPRS Int. J. Geo-Inf. 2020, 9, 679 8 of 16

3.2. GeoServer and Leaflet Integration The communication between Leaflet (client side) and GeoServer (server side) is performed through the use of GetMap requests that are used to load the geospatial data, stored in server, into the web-mapping page (Figure6). The specifications of GetMap requests are defined by Leaflet library, using the WMS standard that is based on HTTP methods [36]. ISPRS Int. J. Geo-Inf. 2020, 9, x FOR PEER REVIEW 8 of 16

Figure 6. GeoServer and Leaflet integration. Figure 6. GeoServer and Leaflet integration.

3.3. Potree Potree I Implementationmplementation In Potree, a wide set of tools for navigating, measuring measuring,, and analyzing the point cloud data are available, contributing to enhanc enhancinging this powerful open-sourceopen-source solution.solution. The The Point Point-Picking-Picking tool is used for navigation navigation and and interaction interaction operations, operations, such such as as in in zooming zooming to to a apoint point or or in in the the creation of measurements. The The Navigation Navigation to toolol offers offers several several navigation navigation modes modes to to be be adapted adapted to to all all situations. situations. The first first mode, OrbitControls, offers offers a a set of controls that that allows allows orbiting orbiting around around a a target target or or pivot. pivot. The second mode,mode, FirstPersonControls,FirstPersonControls, allows allows a a fly- fly or- or walk-through-like walk-through-like experience, experience, which which could could be bevery very useful useful to to navigate navigate through through enclosed enclosed spaces spaces or or vast vast landscapes.landscapes. The last mode, EarthControls, is very very similar similar to to the the mode mode provided provided by by Google Google Earth. Earth. The The left mouse left mouse button button allows allows the drag the and drag drop and movements,drop movements, a n d andthe right the right mouse mouse button button allows allows users users to rotate to rotate around around the clicked the clicked locations. locations. The ClipThe- Clip-BoxesBoxes tool allows tool allows the catchment the catchment of areas of areas of interest of interest using using a box a for box selection, for selection, highlighting highlighting only theonly defined the defined area. area.The Measurement The Measurement tool allows tool allows the measurement the measurement of distances, of distances, areas, areas, heights heights,, and angles.and angles. The performed The performed measures measures could be could saved be in saved JSON inor JSONDXF formats or DXF [37] formats. The Height [37]. TheProfile Height tool isProfile usedtool to defineis used several to define segments, several segments, to obtain to the obtain heights the heights in the in defined the defined locations. locations. Finally, Finally, the Annotationsthe Annotations tool tool allows allows the thecreation creation of ofannotations annotations in inpoint point cloud cloud data, data, highlighting highlighting some some specific specific interestinginteresting points.

4. Case Case S Studytudy To explore and test the web application functionalities, two st studyudy areas areas,, with data collected collected from UAV, werewere selectedselected andand areare presentedpresented inin thisthis section.section. The data were collected on the campus of the University of TrTrásás-os-Montes-os-Montes ee Alto Alto Douro, Douro, Vila Vila Real, Real, Portugal. Portugal. The The first first study study area area is is related related to to a seta set of ofagronomical agronomical trials, trials, while while the second the second includes includes building building areas (Figure areas7 (Figure). The idea 7). behind The idea this behind selection this is selectionto evaluate is the to evaluateperformance the of performance the solution of in the rural solution environments, in rural where environments, geometric whereentities geometric are scarce entitiesand in semi-urban are scarce and environments, in semi-urban where environments, the existence where of these the geometric existence structuresof these geometric has the potential structures to has the potential to improve the performance of these solutions, as they are easily recognizable. Thus, the performance of the proposed application can be tested in most common application cases.

ISPRS Int. J. Geo-Inf. 2020, 9, 679 9 of 16 improve the performance of these solutions, as they are easily recognizable. Thus, the performance of ISPRSthe proposed Int. J. Geo-Inf. application 2020, 9, x FOR can PEER betested REVIEW in most common application cases. 9 of 16

FigureFigure 7. LocationLocation of of the the study study sit sites.es.

4.1.4.1. Data Data Acquisition Acquisition TheThe images images were were acquired acquired using using a a commercial commercial unmanned unmanned aerial aerial system system (UAS), (UAS), the the DJI DJI Phantom Phantom 44 (DJI, Shenzhen, China). China). It It is is a a cost cost-e-effectiveffective solution solution that that is is prepared prepared to to execute execute manual manual or or fully fully automaticautomatic flights, flights, using using di ff differenterent configurations configurations through through a set of a user-defined set of user-defined waypoints. waypoints. DJI Phantom DJI Phantom4 is a multi-rotor 4 is a UAV, multi equipped-rotor UAV, with equipped an RGB sensor with with an RGB 1/2.3” sensor CMOS with that has 1/2.3’’ a resolution CMOS that of 12.4 has MP. a resolutionThe focal lengthof 12.4 ofMP. the The camera focal islength 3.6 mm of the (35 mmcamera equivalent: is 3.6 mm 20.0 (35 mm).mm equivalent: The images 20.0 collected mm). The are 4000 3000 pixels, and latitude, longitude, and altitude information were provided by the on-board images× collected are 4000 × 3000 pixels, and latitude, longitude, and altitude information were providedGlobal Navigation by the on- Satelliteboard Global System Navigation (GNSS) receiver. Satellite System (GNSS) receiver. ForFor the first first study area, 8989 imagesimages werewere acquiredacquired in in a a single-grid single-grid configuration configuration at at a flighta flight height height of of40 40 m, m, with with a longitudinal a longitudinal overlapping overlapping between between images images of 80% of and 80% a lateraland a overlappinglateral overlapping of 70%, whileof 70%, in whilethe second in the study second area study a double-grid area a double flight-grid configuration flight configu wasration planned was at planned a height ofat 80a height m (324 of images 80 m (324acquired), images giving acquired), a longitudinal giving overlapping a longitudinal between overlapping images of between 90% and images lateral ofoverlapping 90% and of lateral 75%. overlappingTo correct of 75%. the errors of the UAV GNSS receiver, GCPs were acquired in the PT-TM06/ETRS89 coordinateTo correct system, the usingerrors theof the Mobilemapper UAV GNSS 100 receiver, GNSS GCPs receiver were (Ashtech acquired Inc., in CA, the USA) PT-TM06/ETRS89 in RTK mode coordinateand were used system for, imageryusing the alignment Mobilemapper during 100 photogrammetric GNSS receiver processing.(Ashtech Inc., In theCalifornia, first and USA) second in RTKstudy mode areas, and 8 and were 5 GCPs used werefor imagery acquired, alignment respectively. during photogrammetric processing. In the first and second study areas, 8 and 5 GCPs were acquired, respectively. 4.2. Data Processing, Aligment, and Visualization 4.2. DataThe Processin data acquiredg, Aligment in the, and two V studyisualization areas were processed using MicMac. However, to allow a comparison with commercial solutions, the photogrammetric software Pix4Dmapper Pro was also used. The data acquired in the two study areas were processed using MicMac. However, to allow a Thus, it was possible to compare the processing time and to assess the quality of the orthorectified comparison with commercial solutions, the photogrammetric software Pix4Dmapper Pro was also mosaic and the point cloud data. The photogrammetric processing in both solutions was performed used. Thus, it was possible to compare the processing time and to assess the quality of the locally in the same workstation equipped with two Intel(R) Xeon(R) CPU E5-2680 v4, two NVIDIA orthorectified mosaic and the point cloud data. The photogrammetric processing in both solutions Quadro M4000 GPUs, 128 GB RAM and a 1 TB SDD in the Windows 10 Enterprise operating system. was performed locally in the same workstation equipped with two Intel(R) Xeon(R) CPU E5-2680 v4, two4.2.1. NVIDIA Data Processing Quadro UsingM4000Pix4Dmapper GPUs, 128 GB Pro RAM and a 1 TB SDD in the Windows 10 Enterprise operating system. The photogrammetric processing using the Pix4Dmapper Pro (version 4.5.6) was based on three 4.2.1.main Data processes. Processing In the U firstsing process Pix4Dmapper (Initial Processing),Pro the digital photo camera was calibrated, and images were oriented. Considering the relative orientation, tie points were automatically measured The photogrammetric processing using the Pix4Dmapper Pro (version 4.5.6) was based on three main processes. In the first process (Initial Processing), the digital photo camera was calibrated, and images were oriented. Considering the relative orientation, tie points were automatically measured through the stereo pairs in overlapping areas. On the next step, GCPs were entered and measured automatically, with a manual correction in the position of these points. Having concluded the relative

ISPRS Int. J. Geo-Inf. 2020, 9, 679 10 of 16 through the stereo pairs in overlapping areas. On the next step, GCPs were entered and measured automatically, with a manual correction in the position of these points. Having concluded the relative orientation, the aerial triangulation step was performed. The triangulation was an automatic step, where tie points were transformed into geodetic coordinates system. In the second process (Point Cloud and Mesh), the point cloud was generated, combining the filtering and smoothing steps to determine point cloud densification, avoiding noisy and erroneous points. In the third process (Digital Surface Model (DSM), Orthomosaic and Index), the generation of DSM and the orthophoto mosaic included several sections allowing the definition of the data format and the specifications of outputs.

4.2.2. Data Processing Using MicMac Initially, the ExifTool software was used to read the metadata associated with the images collected by UAV. These data provided important information, such as the focal length of the camera and the absolute and the relative altitude and the GNSS coordinates, which were used to locate each image in a basemap presented in a web application. Following the initial procedure, tie points identification was performed using the Tapioca tool. This tool required the identification of two mandatory arguments, the directory/path of images and the image size, in pixels. After the identification of tie points, these were used by the Tapas tool to calculate the relative orientation of images and the position and distortion model of the camera’s optics. The Tapas tool required, as mandatory arguments, the identification of calibration model (FraserBasic) and the directory/path of images. On the next process, a PLY file with the position of the cameras was generated, using the AperiCloud tool. The following step consisted of the use of SaisieAppuisInitQT for GCPs marking, following by the GCPBascule tool, to transform the relative orientation into an absolute one, based on GCP data. Then, the Campari tool was applied to execute the bundle adjustment made using camera positions and tie points. ChgSysCo was then used to define the final coordinate system. For this purpose, an XML file that identified the EPSG code parameters was created. The defined code was the EPSG: 3763 (ETRS89/ PT-TM06), which is an official coordinate system of Portugal and the same as the GCP. After this step, the C3DC tool was used to perform an automatic match, generating a high-density point cloud, in PLY format, from a set of oriented images. Finally, photogrammetric processing was concluded by the Tawny tool, which was used to produce the orthophoto mosaic in a TIF format.

4.2.3. Visualization of Data Using Leaflet and Potree On successful completion of data processing, the orthophoto mosaic was uploaded into the GeoServer using the gsconfig Python library. This library allowed the automatic configuration of layer style, as well as the definition of the final coordinate system. Once this procedure was concluded, the communication was implemented between the server (GeoServer) and the Leaflet using the WMS service. On the Leaflet library, the coordinates of the base map were always updated, according to the coordinates associated with the orthophoto mosaic. Regarding to Potree, the PotreeConverter tool was applied to transform the point cloud in PLY format into a WebGL HTML file optimized to visualize and manipulate the data.

4.2.4. Data Alignment To evaluate the point cloud accuracy, the mean error and the Root Mean Square Error (RMSE) was calculated as in Equation (1), using Microsoft Excel. RMSE measures the difference between forecast and corresponding observed values, giving a relatively high weight to large errors. In this way, the RMSE is most feasible when large errors are particularly undesirable [38]. Usually, photogrammetry ISPRS Int. J. Geo-Inf. 2020, 9, 679 11 of 16 projects require a good accuracy and the existence of lower errors. Therefore, accuracy evaluation through RMSE is essential. s Pn 2 = ei ISPRSISPRS Int. Int. J. J.Geo Geo-Inf.-Inf. 20 202020, 9, ,9 x, xFOR FOR PEER PEER REVIEW REVIEWRMSE = i 1 1111 of of (1)16 16 n wwherehere 푒 푖푒, 푖represent, represents sthe the error error of of each each point point in in a a given given directiondirection (X, Y, Z), and 푛 the numbernumber ofof CheckCheck where ei, represents the error of each point in a given direction (X, Y, Z), and n the number of Check PointsPoints (CPs). (CPs). Points (CPs).

5.5.5. Results Results Results and and and Discussion DiscussionDiscussion

5.1.5.1.5.1. Orthophoto Orthophoto Orthophoto M MosaicMosaicosaic and andand Point PointPoint C CloudCloudloud R ResultsResultsesults ConsideringConsideringConsidering the the firstfirst first study study area,area area, ,thethe the orthophotoorthophoto orthophoto mosaic mosaicmosaicgenerated generatedgenerated (Figure (Figure8 a)8a was)) waswas created createdcreated with withwith a aGround aGround Ground Sampling Sampling Sampling Distance Distance Distance (GSD) (GSD) (GSD) of of of 1.78 1.78 1.78 cm, cm, cm, makingmaking making it itit possible possiblepossible toto visualizevisualize the surveyed areaarea withwith greatgreatgreat detail. detail. detail. RegardingRegarding Regarding the the the second secondsecond study study study area, area aarea lower,, a a spatiallower lower resolutionspatial spatial resolution was obtained was was on obtained obtained the orthophoto on on the the orthophotomosaicorthophoto (Figure mosaic mosaic8b) with (Figure (Figure a GSD 8b of8b) 3.70) with with cm. a a Considering GSD GSD of of 3.73.7 the00 cmcm orthophoto.. Considering mosaic the observations, orthophoto problems mosaic mosaic observations,inobservations, transition areasproblems problems were in notin transition transition noticeable areasareas in the werewere region notnot ofnoticeablenoticeable interest, inin as the it is region not presenting of interestinterest displacement,, asas itit isis notnot presentingareas,presenting and verifying displacement displacement a good areas, areas, balance andand in verifying verifyingbrightness aa levels good good in balance balance both cases. in brightness However, levels outside in in the both both region cases. cases. of However,interest,However, where outs outside aide fewer the the regionnumber region of of of interest, imagesinterest, were where where acquired, a a fewer fewer some number number radiometric of images or coloring were acquired, acquired, variations somesome are radiometricmoreradiometric noticeable or or coloring coloring close to variations variations the borders. are are Thesemore more noticeable issuesnoticeable were closeclose already toto the observed borders. in Th otherese issuesissues studies werwer [39ee already].already observedobserved in in other other studies studies [39]. [39].

FigureFigure 8. 8.Orthophoto Orthophoto mosaicsmosaics producedproduced in MicMacMicMac in firstfirst study area ( a)),, and and second second study study area area ( (bb)).. Figure 8. Orthophoto mosaics produced in MicMac in first study area (a), and second study area (b). ConsideringConsidering thethe point cloud cloud data data,, in in first first study study area area (Figure (Figure 9a)9, aa), total a total of 12,462,884 of 12,462,884 points points were Considering the point cloud data, in first study area (Figure 9a), a total of 12,462,884 points were weregenerated. generated. Regarding Regarding the point the point cloud cloud data data produced produced in second in second study study area area(Figure (Figure 9b),9 b), a total a total of generated.of15,637,246 15,637,246 Regarding points points were were the generated pointgenerated. cloud. Both Both data cases cases produced high high-quality-quality in second dense dense study point point area cloud clouds (Figures were were 9b ) generated, generated. a total of. 15,637,246However,However, some pointssome points points were from from generated dense dense. tall tall Both vegetationvegetation cases high werewere-quality notnot estimatedestimated dense pointinin thethe secondcloudseconds study were area. generated . However, some points from dense tall vegetation were not estimated in the second study area.

Figure 9. Point cloud visualization, using Potree in first study area (a) and second study area (b). FigureFigure 9. 9. PointPoint cloud cloud visualization, visualization, using using Potree Potree in in first first study study are areaa ( (aa)) and and second second study study area area ( b). 5.2. Data Alignment and Photogrammetric Processing Time Evaluation 5.2. Data Alignment and Photogrammetric Processing Time Evaluation The mean error and RMSE in X, Y, and Z directions were calculated in for both study areas. In thisThe way, mean several error points and wereRMSE identified in X, Y, and in the Z directionspoint cloud were data calculated and the coordinates in for both ofstudy their areas centers. In thiswere way, obtained. several These points coordinates were identified were then in the compared point cloud with data the corresponding and the coordinates GCPs, obtainedof their centers in the werefield obtained. with the TheseGNSS coordinates equipment. wereThe resultsthen compared provided with by MicMacthe corresponding were also comparedGCPs, obtained with thosein the fieldobtained with bythe Pix4Dmapper GNSS equipment. Pro. Table The results1 present provideds the comparative by MicMac results. were also compared with those obtained by Pix4Dmapper Pro. Table 1 presents the comparative results.

ISPRS Int. J. Geo-Inf. 2020, 9, 679 12 of 16

5.2. Data Alignment and Photogrammetric Processing Time Evaluation The mean error and RMSE in X, Y, and Z directions were calculated in for both study areas. In this way, several points were identified in the point cloud data and the coordinates of their centers were obtained. These coordinates were then compared with the corresponding GCPs, obtained in the field with the GNSS equipment. The results provided by MicMac were also compared with those obtained by Pix4Dmapper Pro. Table1 presents the comparative results.

Table 1. Comparative results of photogrammetric processing in Pix4Dmapper Pro and MicMac in the two study areas.

Pix4Dmapper MicMac Study Area Direction Mean (cm) RMSE (cm) Mean (cm) RMSE (cm) X 0.076 0.923 0.200 1.183 − 1 Y 0.002 0.669 0.340 0.904 − − Z 0.025 1.916 1.800 2.145 X 0.357 1.662 0.174 1.947 − 2 Y 0.636 1.426 0.292 1.552 − Z 0.379 2.169 0.620 2.290

Considering first study area, the accuracy obtained in the processing carried out by MicMac is lower than the GSD, respectively RMSEX = 1.18 cm, RMSEY = 0.90 cm, and RMSEZ = 2.15 cm. Regarding Pix4Dmapper Pro results, the RMSE is slightly lower in all directions, respectively RMSEX = 0.92 cm, RMSEY = 0.67 cm, and RMSEZ = 1.92 cm. However, these results prove the effectiveness of MicMac in photogrammetric processing, since the results are similar to those obtained using a commercial solution and the errors are below the GSD. Regarding the second study area, MicMac results continue to be comparable to Pix4Dmapper Pro, again with a slight advantage for the commercial solution. However, MicMac results respect the requirements by a wide margin. In fact, MicMac achieved individual RMSE of RMSEX =1.95 cm, RMSEY = 1.55 cm and RMSEZ = 2.29 cm, which are in line with those obtained by Pix4Dmapper Pro, respectively RMSEX = 1.66 cm, RMSEY = 1.43 cm, and RMSEZ = 2.17 cm. According to the literature related to absolute accuracy evaluation [40–42], an error of 1–2 times the GSD horizontally and 1–3 times the GSD vertically could be expected, which means that the accuracy obtained with MicMac is in line with these expected values. In this study, we purposely selected mixed areas, where anthropogenic objects occupied rural zones, to assess the global behavior of the analyzed solutions. However, in other studies, in which more homogeneous areas were analyzed, MicMac presented good accuracies, in some cases even better than commercial solutions [43–45]. A comparative evaluation of photogrammetric processing time executed by Pix4Dmapper Pro and MicMac was also carried out. The execution time of the two solutions for carrying out the two most relevant tasks are presented in Table2. Photogrammetric processing was performed with high-quality parameters in both pieces of software, contributing to higher computational costs. Regarding the Pix4Dmapper Pro software, the processing time was faster, since it used resources from both GPU and CPU. On the other hand, MicMac only used the CPU resources, which contributed to a longer processing time. Moreover, the MicMac configurations allow extremely detailed tie point detection, which also contributes to time spent in photogrammetric processing [39,45].

Table 2. Photogrammetric processing time in Pix4Dmapper and MicMac.

First Study Area (hh:mm:ss) Second Study Area (hh:mm:ss) Task MicMac Pix4Dmapper MicMac Pix4Dmapper Orthophoto Mosaic Generation 01:00:05 00:08:18 03:36:00 00:32:50 Point Cloud Densification 01:53:00 01:32:13 04:36:00 04:00:05 Total Time 02:53:05 01:40:31 08:12:00 04:32:55 ISPRS Int. J. Geo-Inf. 2020, 9, 679 13 of 16

In Table2, the photogrammetric processing time is proportional to the image number included on the web application. However, the platform works perfectly with a higher quantity of images. The higher processing times (approximately twice the time), obtained by MicMac, can be considered to be a disadvantage of this solution. However, this software is free and open-source, offering high-quality results with good accuracies that are in line with the accuracy thresholds defined in the literature. During the photogrammetric processing, Pastis/Tapioca and Apero/tapas were the slowest processes of the pipeline. Several algorithms, such as OriRedTieP, are in development and could optimize and improve the photogrammetric workflows.

6. Conclusions In the upcoming years, web-based software, services, and applications are expected to increase. The developed web application, presented in this paper, is based solely on open-source technologies, demonstrating its ability in the production of feasible solutions, as long as integration is performed correctly. In the present study, the integration of MicMac, GeoServer, Leaflet, and Potree was successfully performed. The proposed application is freely available and can be employed for multiple uses in academic or professional contexts. The target users can have little or no experience into the photogrammetric processing of UAV-based imagery since the interface is intuitive and minimal interactions are needed. Moreover, public entities can benefit from the use of this web application, since it can be installed on a server and multiple users can access to it through a web browser (or using Docker for a single device), minimizing the costs in the hardware needed to locally conduct the photogrammetric processing. An example of potential users are police forces responsible for road traffic accident reconstruction, which can use UAVs to acquire imagery from accident scenes and to process them in a quicker way, and to focus on the final products to produce accurate sketches and to digitally preserve evidence for future usage. The application allows not only visualization of the orthophoto mosaics and point clouds but also analysis of the results by enabling the users to perform several measurements. The web application was tested by analyzing the performance of photogrammetric processing. The orthophoto mosaic demonstrated a good balance in brightness. The point cloud, in turn, presented a high density of points, demonstrating good quality. Considering the RMSE results obtained by MicMac, the thresholds of 1–2 times the GSD horizontally and 1–3 times the GSD vertically were respected. Moreover, MicMac proved the ability to provide accurate results, even when compared with other popular commercial solutions, such as Pix4Dmapper Pro. Considering the integration of the results obtained in Leaflet and Potree, this process was executed with success being completely automatic, demonstrating a good quality and performance for the visualization of data. The web application development offers the possibility of being continuously updated. In this way, there is a continuous intention to integrate new open-source solutions and new products.

Author Contributions: Conceptualization—Nathalie Guimarães and Joaquim J. Sousa; Methodology— Nathalie Guimarães, Luís Pádua, and Joaquim J. Sousa; Validation—Nathalie Guimarães and Joaquim J. Sousa; Formal Analysis— Nathalie Guimarães, Luís Pádua, Telmo Adão, and Joaquim J. Sousa; Resources—Nathalie Guimarães, Luís Pádua, Telmo Adão, Jonáš Hruška, Emanuel Peres, and Joaquim J. Sousa; Data Curation—Nathalie Guimarães and Luís Pádua; Writing-Original Draft Preparation—Nathalie Guimarães, Luís Pádua, and Joaquim J. Sousa; Writing-Review and Editing—Nathalie Guimarães, Luís Pádua, and Joaquim J. Sousa; Visualization—Nathalie Guimarães, Luís Pádua, and Joaquim J. Sousa; Supervision—Emanuel Peres and Joaquim J. Sousa; Project Administration—Joaquim J. Sousa; Funding Acquisition—Joaquim J. Sousa. All authors have read and agreed to the published version of the manuscript. Funding: This study was supported by the FCT-Portuguese Foundation for Science and Technology for Nathalie Guimarães (UI/BD/150727/2020). This research was also funded by the European Regional Development Fund (ERDF) through the Operational Programme for Competitiveness and Internationalisation—COMPETE 2020—under the PORTUGAL 2020 Partnership Agreement, of project “REVEAL—Drones for supporting traffic accident evidence acquisition by Law Enforcement Agents” (Nº 33113). Financial support was also provided by the ISPRS Int. J. Geo-Inf. 2020, 9, 679 14 of 16

FCT to Luís Pádua (SFRH/BD/139702/2018). This work was also supported by National Funds by FCT-Portuguese Foundation for Science and Technology, under the project UIDB/04033/2020. Conflicts of Interest: The authors declare no conflict of interest.

References

1. Bartoš, K.; Pukanská, K.; Sabová, J. Overview of Available Open-Source Photogrammetric Software, its Use and Analysis. Int. J. Innov. Educ. Res. 2014, 2, 62–70. 2. Aber, J.S.; Marzolff, I.; Ries, J. Small-Format Aerial Photography: Principles, Techniques and Geoscience Applications; Elsevier: Amsterdam, The Netherlands, 2010; ISBN 978-0-08-093283-5. 3. Trujillo, L.; Olague, G. Automated Design of Image Operators that Detect Interest Points. Evol. Comput. 2008, 16, 483–507. [CrossRef][PubMed] 4. Cooper, S.D.; Roy, D.P.; Schaaf, C.B.; Paynter, I. Examination of the Potential of Terrestrial Laser Scanning and Structure-from-Motion Photogrammetry for Rapid Nondestructive Field Measurement of Grass Biomass. Remote Sens. 2017, 9, 531. [CrossRef] 5. Yan, L.; Fei, L.; Chen, C.; Ye, Z.; Zhu, R. A Multi-View Dense Image Matching Method for High-Resolution Aerial Imagery Based on a Graph Network. Remote Sens. 2016, 8, 799. [CrossRef] 6. Rupnik, E.; Daakir, M.; Pierrot Deseilligny, M. MicMac—A free, open-source solution for photogrammetry. Open Geospatial Data Softw. Stand. 2017, 2, 14. [CrossRef] 7. Gonçalves, J.A.; Henriques, R. UAV photogrammetry for topographic monitoring of coastal areas. ISPRS J. Photogramm. Remote Sens. 2015, 104, 101–111. [CrossRef] 8. Wu, C. VisualSFM: A Visual Structure from Motion System. Available online: http://ccwu.me/vsfm/ (accessed on 14 September 2020). 9. Snavely, N.; Seitz, S. Bundler User’s Manual. Available online: https://www.cs.cornell.edu/~{}snavely/ bundler/bundler-v0.4-manual.html (accessed on 9 September 2020). 10. Rahaman, H.; Champion, E. To 3D or Not 3D: Choosing a Photogrammetry Workflow for Cultural Heritage Groups. Heritage 2019, 2, 112. [CrossRef] 11. Open Drone Map, C. Open Drone Map Documentation. Available online: https://www.opendronemap.org/ (accessed on 7 September 2020). 12. Westoby, M.J.; Brasington, J.; Glasser, N.F.; Hambrey, M.J.; Reynolds, J.M. ‘Structure-from-Motion’ photogrammetry: A low-cost, effective tool for geoscience applications. Geomorphology 2012, 179, 300–314. [CrossRef] 13. Swain, N.R.; Latu, K.; Christensen, S.D.; Jones, N.L.; Nelson, E.J.; Ames, D.P.; Williams, G.P. A review of open source software solutions for developing water resources web applications. Environ. Model. Softw. 2015, 67, 108–117. [CrossRef] 14. Steiniger, S.; Hunter, A.J.S. The 2012 free and open source GIS software map—A guide to facilitate research, development, and adoption. Comput. Environ. Urban Syst. 2013, 39, 136–150. [CrossRef] 15. Gkatzoflias, D.; Mellios, G.; Samaras, Z. Development of a web GIS application for emissions inventory spatial allocation based on open source software tools. Comput. Geosci. 2013, 52, 21–33. [CrossRef] 16. Choi, A.J. Internet of Things: Evolution towards a hyper-connected society. In Proceedings of the 2014 IEEE Asian Solid-State Circuits Conference (A-SSCC), KaoHsiung, Taiwan, 10–12 November 2014; pp. 5–8. 17. Delipetrev, B.; Jonoski, A.; Solomatine, D.P. Development of a web application for water resources based on open source software. Comput. Geosci. 2014, 62, 35–42. [CrossRef] 18. Calantropio, A.; Deseilligny, M.P.; Rinaudo, F.; Rupnik, E. Evaluation of photogrammetric block orientation using quality descriptors from statistically filtered tie points. ISPRS Int. Arch. Photogramm. Remote Sens. Spat. Inf. Sci. 2018, XLII-2, 185–191. [CrossRef] 19. Groos, A.R.; Bertschinger, T.J.; Kummer, C.M.; Erlwein, S.; Munz, L.; Philipp, A. The Potential of Low-Cost UAVs and Open-Source Photogrammetry Software for High-Resolution Monitoring of Alpine Glaciers: A Case Study from the Kanderfirn (Swiss Alps). Geosciences 2019, 9, 356. [CrossRef] 20. MicMac documentation MicMac, Apero, Pastis and Other Beverages in a Nutshell! Available online: https: //github.com/micmacIGN/Documentation/blob/master/DocMicMac.pdf (accessed on 27 September 2019). 21. Kropla, B. Beginning MapServer: Open Source GIS Development; Apress: New York, NY, USA, 2006; ISBN 978-1-4302-0053-6. ISPRS Int. J. Geo-Inf. 2020, 9, 679 15 of 16

22. Iacovella, S. GeoServer Beginner’s Guide: Share Geospatial Data using Open Source Standards; Packt Publishing: Birmingham, UK, 2017; ISBN 978-1-78829-407-2. 23. Steiniger, S.; Hunter, A.J.S. Free and Open Source GIS Software for Building a Spatial Data Infrastructure. In Geospatial Free and Open Source Software in the 21st Century; Bocher, E., Neteler, M., Eds.; Springer: Berlin/Heidelberg, Germany, 2012; pp. 247–261. ISBN 978-3-642-10594-4. 24. Ballatore, A.; Tahir, A.; McArdle, G.; Bertolotto, M. A comparison of open source geospatial technologies for web mapping. Int. J. Web Eng. Technol. 2011, 6, 354. [CrossRef] 25. Bloch, J. How to Design a Good API and Why It Matters. In Companion to the 21st ACM SIGPLAN Symposium on Object-oriented Programming Systems, Languages, and Applications; ACM: New York, NY, USA, 2006; pp. 506–507. 26. Orchard, L.M. (Ed.) Professional JavaScript Frameworks: Prototype, YUI, Ext JS, Dojo and MooTools; Wrox Programmer to Programmer; Wiley: Indianapolis, IN, USA, 2009; ISBN 978-0-470-38459-6. 27. Crickard, P. Leaflet.js Essentials; Packt Publishing: Birmingham, UK, 2014; ISBN 978-1-78355-482-9. 28. Martinez-Rubi, O.; Verhoeven, S.; Meersbergen, M.V.; Schütz, M.; Oosterom, P.V.; Goncalves, R.; Tijssen, T. Taming the beast: Free and open-source massive point cloud web visualization. Capturing Real. 2015. [CrossRef] 29. Schutz, M.; Wimmer, M. High-quality point-based rendering using fast single-pass interpolation. In Proceedings of the 2015 Digital Heritage, Granada, Spain, 28 September–2 October 2015; 2015; pp. 369–372. 30. Discher, S.; Richter, R.; Döllner, J. A scalable webGL-based approach for visualizing massive 3D point clouds using semantics-dependent rendering techniques. In Proceedings of the 23rd International ACM Conference on 3D Web Technology—Web3D ’18, Pozna´n,Poland, 20–22 June 2018; pp. 1–9. 31. Verma, U.; Butler, H. Plasio. Available online: https://github.com/verma/plasio (accessed on 19 November 2019). 32. Masse, M. REST API Design Rulebook: Designing Consistent RESTful Web Service Interfaces; O’Reilly Media: Sebastopol, CA, USA, 2011; ISBN 978-1-4493-1990-8. 33. Galland, O.; Bertelsen, H.S.; Guldstrand, F.; Girod, L.; Johannessen, R.F.; Bjugger, F.; Burchardt, S.; Mair, K. Application of open-source photogrammetric software MicMac for monitoring surface deformation in laboratory models: Photogrammetry in laboratory models. J. Geophys. Res. Solid Earth 2016, 121, 2852–2872. [CrossRef] 34. Alliez, P.; Forge, F.; de Luca, L.; Pierrot-Deseilligny, M.; Preda, M. Culture 3D Cloud: A Cloud Computing Platform for 3D Scanning, Documentation, Preservation and Dissemination of Cultural Heritage. Available online: https://hal.archives-ouvertes.fr/hal-02096629 (accessed on 23 September 2020). 35. Duarte, L.; Teodoro, A.C.; Moutinho, O.; Gonçalves, J.A. Open-source GIS application for UAV photogrammetry based on MicMac. Int. J. Remote Sens. 2017, 38, 3181–3202. [CrossRef] 36. Veenendaal, B.; Brovelli, M.A.; Li, S. Review of Web Mapping: Eras, Trends and Directions. ISPRS Int. J. Geo-Inf. 2017, 6, 317. [CrossRef] 37. Schuetz, M. Potree: Rendering Large Point Clouds in Web Browsers; Technische Universität Wien: Vienna, Austria, 2016. 38. Willmott, C.; Matsuura, K. Advantages of the mean absolute error (MAE) over the root mean square error (RMSE) in assessing average model performance. Clim. Res. 2005, 30, 79–82. [CrossRef] 39. Labbé, S.; Gómez-Candón, D.; El-Natour, G.; Dorado, J.; Fernández-Quintanilla, C.; López-Granados, F.; Peña-Barragán, J.M.; de Castro, A.I.; Torres-Sánchez, J.; Rabatel, G. Automatic mosaicking of very high spatial resolution UAV multispectral images for precision agriculture: Test of MICMAC freeware. In Proceedings of the First RHEA International Conference on Robotics and associated High-technologies and Equipment for Agriculture, RHEA-2012, Pisa, Italy, 19–21 September 2012; pp. 269–274. 40. Barry, P.; Coakley, R. Accuracy of UAV Photogrammetry Compared With Network RTK GPS; Baseline Surveys: Cork, Ireland, 2018; Section 5. 41. Liu, Y.; Zheng, X.; Ai, G.; Zhang, Y.; Zuo, Y. Generating a High-Precision True Digital Orthophoto Map Based on UAV Images. ISPRS Int. J. Geo-Inf. 2018, 7, 333. [CrossRef] 42. Ruzgiene,˙ B.; Berteška, T.; Geˇcyte,S.; Jakubauskiene,˙ E.; Aksamitauskas, V.C.ˇ The surface modelling based on UAV Photogrammetry and qualitative estimation. Measurement 2015, 73, 619–627. [CrossRef] ISPRS Int. J. Geo-Inf. 2020, 9, 679 16 of 16

43. Jaud, M.; Passot, S.; Le Bivic, R.; Delacourt, C.; Grandjean, P.; Le Dantec, N. Assessing the Accuracy of High Resolution Digital Surface Models Computed by PhotoScan®and MicMac®in Sub-Optimal Survey Conditions. Remote Sens. 2016, 8, 465. [CrossRef] 44. Mendes, T.; Henriques, S.; Catalao, J.; Redweik, P.; Vieira, G. Photogrammetry with UAV’s: Quality assessment of open-source software for generation of ortophotos and digital surface models. In Proceedings of the VIII edição da Conferência Nacional de Cartografia e Geodesia (VIII CNCG), Reboleira, Portugal, 29–30 October 2015; pp. 29–30. 45. Moutinho, Ó. Uma Alternativa Open Source Para Fotogrametria Com RPAS. Master’s Thesis, Faculdade de Ciências da Universidade do Porto, Porto, Portugal, 2015.

Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

© 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).