1. Introduction
In recent years, Structure from Motion (SfM) has received increased interest. Aided by a rapid development of software solutions [
1], SfM offer reconstructions of 3D geometric models in great detail with simple, fast, and low-cost acquisition [
2,
3,
4]. As a result, potential applications of SfM for quantitative geometric measurements have been considered within a broader range of fields such as cultural heritage [
5,
6], geoscience [
7,
8,
9,
10,
11,
12], construction and architecture [
13,
14,
15], and surface inspection [
16,
17,
18,
19,
20,
21]. Common for these fields is the need for accurate geometric models to allow reliable quantitative analyses. Since the applications cover large differences in object surfaces and capturing conditions, many factors may influence the SfM reconstructions. Among these are the local variations in surface color or surface roughness of the object. Both of these properties are often referred to as the ‘texture’ of the surface. While several recent studies have applied SfM for measuring surface roughness [
10,
11,
12,
22,
23,
24], quantitative studies of the influence of texture on the reconstruction accuracy are missing or provided for very specific use cases. This shows that further in-depth studies of the factors influencing the capture of micro- and macro-textures of 3D surfaces are needed.
In SfM, objects and surfaces are reproduced in 3D by using a number of image acquisitions from different distances and angles. The algorithms utilize image feature correspondences, sparse point cloud triangulation, and point interpolation to create dense point clouds and 3D meshes from the imaged objects and surfaces [
25,
26]. As the creation of the dense point cloud applies multi-view stereo algorithms, the full SfM pipeline can sometimes be referred to as SfM-MVS [
26]. SfM has many advantages compared to other 3D reconstruction methods [
27]. As it requires only conventional hardware such as a DSLR camera, SfM has relatively lower overhead costs compared to, e.g., laser scanning or LiDAR scanning. SfM can be used both indoors and outdoors [
28] unlike structured light [
29] and time of flight [
30] scanners, which tend to fail when direct sunlight is present. Finally, it is capable of creating much more detailed reconstructions than most 3D-from-stereo systems. On the software side, a number of commercial SfM solutions are available. The work by [
5] focuses on the low-cost and free solutions, in [
31], incremental SfM pipelines with open source code are evaluated, while the work by [
1,
3,
32] covers the newer free and paid software packages.
A drawback of SfM is that it is dependent on the quality of the acquisition system as well as on the physical properties of the captured object or surface. Since SfM depends on classical feature extraction, matching, and 3D triangulation, the angular coverage and resolution of the images greatly affect the quality of the reconstructed surface [
33]. Thus, an increase in the number of images can improve the accuracy when additional angles and poses are added [
4,
34]. Another factor is the ground sampling distance (GSD) of the images. This depends on the focal length of the camera as well as the capturing range, which is the distance between the captured surface and the camera. A very large range gives a large GSD and can result in poor reconstructions [
26]. As the spatial resolution of the acquired photos scales with range, the reconstruction accuracy scales accordingly [
26,
35,
36]. Furthermore, the accuracy depends on the used optics and imaging equipment [
37], the lighting conditions [
38] as well as the surface properties of the captured objects. In SfM, the object surfaces ideally should not be glossy or transparent, and in the absence of external contrast sources, such as structured light, a level of texture on the surface is needed. This texture can either originate from a local variation in surface coloring or a local height variation of the surface topography, e.g., roughness. If too few distinct features are found on the object surface, this can result in a lot of false matches and degradation of performance [
4,
9] or outright empty regions and holes in the point cloud [
39]. In contrast, other conventional 3D reconstruction methods are less sensitive toward surface texture. Laser-based methods such as LiDAR are not impacted by the local texture as long as a sufficient light intensity is reflected from the surface. In Photometric stereo first introduced by Woodham [
40], light from different directions creates a shadow variation originating from the micro- and macro-surface details that is used to reconstruct the 3D surface [
41,
42]. While Photometric stereo can more easily capture smaller surface details, the limited light direction angles create difficulties in representing the larger overall surface shape. In addition, Photometric stereo introduces the need for an external light source that can move independently of the camera which would limit outdoor usage. Comparatively, SfM requires more pronounced surface textures but can capture both the micro- and macro-surface shape using a fixed light source. It has been shown that combining SfM and Photometric stereo reconstructions can lead to better results in laboratory conditions [
43].
Several approaches have been applied to evaluate the accuracy of SfM reconstructions. In [
44], an approach from vision metrology was incorporated by using well-defined scan settings and reference targets to document the geometric accuracy. More often, approaches rely on a comparison to other optical techniques such as LiDAR, a laser scanner or a total station. In the case of reference point clouds as with LiDAR or a laser scanner, a direct comparison with the SfM point cloud through the calculation of signed or unsigned distances can be carried out [
4,
5,
8,
45]. Similarly, when digital elevation models (DEM) are produced, a direct raster-to-raster comparison is possible [
22,
45,
46]. Conversely, a comparison can be made between a point cloud and reference target points obtained with, e.g., a total station [
2,
39]. In all cases, the comparison is limited by the measurement uncertainty in the reference model, e.g., of reference points or pre-aligned point-cloud [
46]. A way to alleviate this is obtaining replicas of the surface by, e.g., replication molding and producing a highly accurate reference DEM using optical microscopy [
23]. In addition, the use of 3D-printed objects allows for direct comparison of the measured geometries to the design geometry of the used CAD model [
47].
To quantify the reconstruction accuracy, quantitative parameters or metrics are needed. Common metrics for evaluating SfM reconstructions are the standard deviation (SD) [
1,
2,
5] or root mean squared (RMS) deviation [
36,
39,
45] between SfM reconstructions and reference points. The SD and RMS metrics have usually been reported as overall global statistics. An advantage of the SD and RMS metrics is that negative and positive deviations will not cancel each other out as with the sometimes reported mean deviation or mean error [
26]. As the accuracy might vary locally with the object surface geometry, metrics that capture spatial information across multiple length scales are of interest when evaluating SfM reconstructions. One way is by estimating an SD value for either each point on the point cloud or in a moving window around each point on the DEM [
10,
22,
46,
48,
49].This can be used to study, e.g., the effect of local surface height—either absolute value or variation—on the reconstruction accuracy. Another way is power-spectral density (PSD) analysis, which gives a multi-scale quantification of the surface height variation [
50,
51]. Areal roughness parameters that describe different length scales were introduced by [
23] for comparison between regions of interest in SfM and reference DEM. In addition, some studies have compared geometric measures on the object such as distances or angles [
6,
52] to the SfM point clouds. Notwithstanding, more systematic approaches for studying the accuracy dependence on local topography and surface roughness are needed.
Contributions: In this study, we present the first quantitative investigation of the influence of surface texture on SfM reconstructions. To isolate the effect of texture from other factors, the SfM measurements were performed indoors using two sets of reference artifacts as shown in
Figure 1. These artifacts are easily replicable and use 3D-printed and easily obtainable materials. To study the effect of varying color contrast, a 3D-printed step-height artifact was prepared with different color patterns applied to the surface. The effect of local height variations was studied using a set of artifacts with industrial sandpaper of varying grit size covering the surface. The artifacts were chosen to provide quantitative reference values, i.e., the nominal height of the steps and the sandpaper grain size distributions are in accordance with ISO 6344 [
53]. In addition, the use of a 3D-printed artifact allows for direct comparison to the design geometry. The influence of texture was compared to the effect of the camera-to-object range on the reconstruction.
We organize the surface analysis presented in the paper as a baseline that can be used for comparative studies of the performance of SfM. For optimal reconstruction quality, the SfM capture settings were designed to ensure a sufficiently small GSD of around 0.03 mm, which would be smaller or similar to the sandpaper grain sizes. To achieve this, SfM reconstructions were based on high-resolution images taken with a DSLR camera with a focal length of 260 mm and at a close range of around 2 m. In addition, the small GSD allows for comparing the SfM reconstructions to DEMs measured using calibrated confocal (CM) and focus variation microscopes (FVM).
To quantify the texture influence, we investigate a number of previously reported parameters and metrics that describe the reconstructed topography on both global, local, or multiple scales. These parameters include RMSE values, heights of surface structures, surface roughness values as well as PSD analysis.
We approach the investigations with the following hypotheses:
For a reconstruction without erroneous areas, the GSD of the capture must be comparable to the spatial variation of the surface texture.
Specifically for topographic or roughness texture, the GSD should be smaller than the roughness length scale.
Multi-scale metrics are needed for a thorough analysis of the texture influence on the reconstruction.
Exploring these hypotheses can improve the understanding of the interplay between surface texture and reconstruction quality in SfM. Furthermore, the proposed metrics may provide quantitative guidelines for SfM settings when reconstructing low-texture regions or objects.
5. Discussion
Overall, the results show that some level of texture is required in SfM reconstructions. This was illustrated by the scan of the monochrome step-height artifact where the reconstruction failed altogether. In addition, this study demonstrates that the surface texture also heavily influences the reconstructed surface topography of SfM DEMs. In comparison to the marked pattern step-height, the low-level color-contrast of the projected light pattern resulted in a lower precision of the measured height as well as a reduced lateral resolution. However, whereas [
44] found that a projected light pattern decreased the accuracy compared to no pattern, the projected light in this study did aid in the SfM reconstruction. At low roughness-levels of the sandpaper artifact, reconstruction errors in the color texture were observed.
Furthermore, the PSD analysis of both artifact types indicated an increase in noise at low texture levels. This was observed as a larger PSD intensity at high spatial frequencies for the projected light pattern of the step-height artifact and for finer grit sizes of the sandpaper artifact. In this way, the PSD analysis indicated when the texture level became a significant source of high-frequency noise. In the case of the sandpaper artifacts, a transition was seen between P100 and P120. Thus, the roughness texture became insufficient for a nominal average grain size between 125 and 160 m corresponding to five to six times the GSD of 27 m.
The spatial resolution in the SfM scans was found to be around 0.5 mm. This was seen from the best-case ER values from the marked step height as well as the fCM model used for the sandpaper data. The best-case ER values are used, as these give the best estimate for the achievable resolution without other factors influencing the ER. Interestingly, the 0.5 mm resolution means that the texture transition level was below the lateral spatial resolution. This indicates that the texture is important for the reconstruction even though the variations themselves cannot be spatially resolved. As observed here, the spatial resolution was more than an order of magnitude larger than the GSD, which has also been reported by other high-resolution SfM studies [
23,
51]. When the size of surface structures was close to the spatial resolution, the error in the reconstruction increased as observed from the ER in the step-height artifact. Below the resolution, individual sandpaper grains could not be accurately resolved.
The importance of texture level poses a challenge when evaluating the quality of SfM reconstructions. Commercial software may produce a reconstruction even at low levels of texture. As seen in this study, these reconstructions could introduce erroneous texture features and increased geometrical variations. Although such deviations may be possible to detect when measuring known surfaces, the effect of low texture could lead to false interpretations when inspecting unknown surfaces. Thus, the level of texture on the object surface should be taken into account when applying SfM for geometrical measurements.
The influence of spatial resolution of the SfM reconstructions was probed by a variation in range. Keeping a constant focal length, changing the range from 1.5 to 2.2 m increased the GSD from 24 to 35
m. At a larger range, the SfM reconstructions of the sandpaper artifact resulted in smaller particle height and
values. For the marked pattern step-height artifact, an increase in range from 1.5 to 2.0 m resulted in less precise reconstructions as seen from the larger height SD, RMSE, and ER values. The RMSE values of 0.57 mm at 1.5 m and 0.70 mm at 2.0 mm are comparable to previously reported values [
36]. However, the low texture of the projected light pattern led to a doubling in RMSE of 1.04 mm at 1.5 m range. For the PSD analysis, an increase in range led to smaller PSD intensities at high spatial frequencies for both artifact types. This was in contrast to the observations at low texture levels where increased intensities were observed. Thus, the PSD analysis might indicate whether a SfM measurement is limited by insufficient spatial resolution or surface texture.
6. Conclusions
With this study, we demonstrate how the accuracy of 3D reconstructions using SfM changes is based on the surface texture of the imaged objects. In SfM, while attention is often given to the environment, lighting, and camera setup, the requirements for the imaged surfaces are normally only inspected for transparency and reflectivity. We demonstrate through an in-depth comparative analysis between microscopy and SfM reconstructions that both micro- and macro-surface texture and shape details have a strong influence on the quality of the produced 3D models. This was inspected using a range of quantitative metrics. For micro-surface textures, we show that the SfM reconstructions begin to struggle when the spatial size of the surface roughness becomes smaller and approaches the GSD. Erroneous areas begin to appear in the reconstruction, and the overall noise level increases. We observe a transition at around five to six times the GSD, which could be used as a guideline when setting up measurements using SfM. Furthermore, PSD analysis could be a way to probe for sufficient texture by inspecting the high-frequency end for noise components.
A range of local, global, and multi-scale quantitative metrics were investigated. While an effect of low texture could be observed in both global RMSE or more local Sq, particle size, ER or height values, the most insight was gained from the multi-scale PSD analysis. This made it possible to distinguish behavior at both large and small spatial scales.
The observed spatial resolution was 10–20 times larger than the GSD, which illustrates that a sort of low-pass smoothing takes place as part of the SfM reconstruction. Furthermore, the spatial resolution was larger than the observed transition at five to six times the GSD, which indicates that sub-resolution features are important for the overall reconstruction.
As a future study, the influence of color texture could be investigated more thoroughly using a range of color patterns of varying areal coverage, size, and shape. This might determine whether a transition level of insufficient color contrast exists. The type of patterns should preferably be marked directly on the surface rather than projected using a light projector. In addition, other state-of-the-art SfM software solutions could be investigated to determine whether the influence of texture depends on the software or is a fundamental property of SfM.