Photogrammetry/Regard3D/Installation

Download Regard3D and Camera Sensor Database
Cameras have different optical properties, that are relevant for the reconstruction of the 3D model from set of images. The main property Regard3D needs is the "Camera Sensor Width". The property can be searched on the internet, if you camera is not available in Camera Sensor Database. According to this requirement you need two downloads to perform the photogrammetry example:
 * Regard3D OpenSource Software
 * Camera Sensor Database The camera sensor database is not shipped with the Regard3D, so you have to download it with the link above and store your camera model (if not found) in the Sensor Database. Open the file called "sensor_database.csv" and add an appropriate line for you camera.

Camera Sensor Database
The file is located in Windows in the path

on OS X in the installation directory of Regard3D
 * (usually ).

This contains the openMVG sensor size database. When new pictures are loaded in Regard3D, first the user-defined database is consulted, then. This way, it is possible to override manually the entries in  or add new cameras to the database. In Regard3D screenshot (4) on right you can see the camera properties that are stored in the set of images. You see the camera name "Panasonic Lumix DMC-TZ41". If that camera is missing in the camera sensor database, you will find the camera sensor with 6.08mm. Add the following line to the sensor database (e.g. approx. line 2406 in ):

and save the file.

Windows and MacOSX
Install Regard3D on you operating system with the installer downloaded above for Windows or MacOSX.

Linux Ubuntu 14.04
Install on Linux Ubuntu 14.04 see Compiling Regard3D on Linux

Linux Linux Mint 18.2
Install on Linux Mint 18.2 (2017) sudo apt-get install build-essential cmake libboost-all-dev libeigen3-dev libwxgtk3.0-dev libopencv-dev libopenscenegraph-dev libpcl1 libpcl1-dev libpcl-msgs-dev libpcl-conversion-dev pcl-tools libsuitesparse-dev meshlab

Ceres Solver Installation
The Ceres Solver is necessary for solver. The linear equation solver is necessary e.g. for calculation of the matching points and the point cloud. First the system must be prepared for installation of Ceres Solver:

sudo apt-get install cmake sudo apt-get install libgoogle-glog-dev sudo apt-get install libatlas-base-dev sudo apt-get install libeigen3-dev sudo apt-get install libsuitesparse-dev sudo add-apt-repository ppa:bzindovic/suitesparse-bugfix-1319687 sudo apt-get update sudo apt-get install libsuitesparse-dev
 * 1) CMake
 * 1) google-glog + gflags
 * 1) BLAS & LAPACK
 * 1) Eigen3
 * 1) SuiteSparse and CXSparse (optional)
 * 2) - If you want to build Ceres as a *static* library (the default)
 * 3)   you can use the SuiteSparse package in the main Ubuntu package
 * 4)   repository:
 * 1) - However, if you want to build Ceres as a *shared* library, you must
 * 2)   add the following PPA:

Download Ceres Solver with wget and unzip the solver: wget http://ceres-solver.org/ceres-solver-1.13.0.tar.gz tar zxf ceres-solver-1.13.0.tar.gz mkdir ceres-bin cd ceres-bin cmake ../ceres-solver-1.13.0 make -j3 make test make install
 * 1) Optionally install Ceres, it can also be exported using CMake which
 * 2) allows Ceres to be used without requiring installation, see the documentation
 * 3) for the EXPORT_BUILD_DIR option for more information.