Processing Settings
Structures holding parameters and options for each stage of the processing
pipeline. All types are in the p3dm_api::settings namespace.
-
namespace settings
Structures holding parameters and options for processing procedures.
-
struct ScanRelating
- #include <ProcessingSettings.h>
Defines how relations between individual scans are determined.
During computation of alignment, scans in relations are minimizing their surface deviations. Fine-tuned scan relation computation may rapidly increase performance of alignment procedure.
Public Types
-
enum class Strategy : uint8_t
Possibilities how to relate a scan to other scans.
Values:
-
enumerator everything
Relate to all scans.
-
enumerator direction
Relate to scans with similar view direction.
-
enumerator coverage
Relate to scans with similar cover of visible surface.
-
enumerator ordered
Relate to successive scans.
-
enumerator everything
Public Members
-
Strategy pa_relating_strategy = Strategy::direction
Defines how the relations between scans are determined.
-
float pa_relating_max_view_angle = 90.0f
Maximal angle between cameras to consider relation (in degrees). Used only when strategy is set to Strategy::direction.
-
float pa_relating_cover_ratio = 0.2f
Minimum ratio of samples visible from the other scan. Used only when strategy is set to Strategy::coverage.
-
uint32_t pa_relating_ordered_graph_density = 3u
Number of scan relations to next scans in order. Used only when strategy is set to Strategy::ordered.
-
bool pa_relating_ordered_loop = false
If true, ordered graph is enclosed to a loop. Used only when strategy is set to Strategy::ordered.
-
enum class Strategy : uint8_t
-
struct PointPairing
- #include <ProcessingSettings.h>
Defines how point pairs between two scans are found for alignment.
-
struct Registration
- #include <ProcessingSettings.h>
Parameters for registration procedure.
Public Types
Public Members
-
uint32_t prg_max_ransac_iter = 50000
Maximum number of RANSAC iterations the PCL optimization should run for.
-
ProgressiveStrategy prg_progressive_strategy = ProgressiveStrategy::full
The strategy for using progressive steps. The registration algorithm tries running for a smaller number of iterations. In the case of an acceptable result, the remaining iterations are skipped.
-
float prg_progressive_fitness = 0.0001f
The Euclidean fitness score that accepts the progressive step or rejects it. The sum of squared distances from the source to the target. The lower, the more precision is required from the possible result.
-
float prg_progressive_optimization_time = 10.0f
If the time estimation for a full run is lower that this, the progressive steps are skipped.
-
uint32_t prg_max_ransac_iter = 50000
-
struct Alignment
- #include <ProcessingSettings.h>
Parameters for alignment procedure.
Public Members
-
settings::ScanRelating scan_relating
Options to customize decision of which scans to consider related.
-
float pa_ratio_of_samples = 0.1f
Ratio of samples used for alignment (in range 0 to 1). Lower the number, faster the calculations are but with less accuracy.
-
uint32_t pa_max_iter_global = 200
Maximum alignment iterations allowed. When function reaches this number, alignment iterations are forced to stop.
-
bool pa_enable_reference_scan = false
The space of the reference scan defines the target space for the global alignment process.
-
uint32_t pa_reference_scan_id = 0
Defines the id of the reference scan, if the reference scan option is enabled (enable_reference_scan).
-
bool pa_enable_translation_only = false
If true, the output transformation consists of a translation matrix only.
-
float pa_minimal_material_thickness = 0.0f
Fixes flipped normals on thin materials. If set to zero, thin materials are not fixed.
-
bool pa_enable_plane_slide = false
Enables plane sliding to correctly reconstruct “cube-like” objects.
-
PointPairing pairing
Defines how pairs of points between two scans are found.
-
settings::ScanRelating scan_relating
-
struct RotableBackgroundRemoval
- #include <ProcessingSettings.h>
Background removal procedure parameters.
Procedure projects scan space into 2D and projected space is then divided into cells to find the optimal cutting cylinder, which contains scanned object. Surface of the optimal cutting cylinder (represented by a set of cells) should contain minimal amount of points.
Public Members
-
float prb_cell_width = 1.0f
Defines width of cutting cylinder “wall”.
-
float prb_cell_height = 1.0f
Defines height of cutting cylinder “ceiling”.
-
size_t prb_min_num_included_points = 1000
Defines a minimal amount of points to be included in the optimal cutting cylinder.
-
size_t prb_max_num_points_on_cut = 100
Defines a maximal amount of points lying on the the cut.
-
float ground_offset = 0.0f
Defines offset from the ground, or distance of cutting plane from the origin (0, 0, 0) in the direction of the plane normal.
-
float prg_precision = 0.5f
Span of a single slice in rotation pad parallel 3D space for the ground removal procedure.
-
float prg_max_height = 50.0f
Maximum possible height at which the ground can be detected for the ground removal procedure.
-
float prg_offset = 1.0f
Cutting offset from the detected ground for the ground removal procedure.
-
float prb_cell_width = 1.0f
-
struct Filtering
- #include <ProcessingSettings.h>
Scan filtering procedure parameters.
Procedure divides scan space into a cubic cells. For each point of a scan, the cell is analyzed. If there is not enough points of other valid scans in cell, the point is removed.
Public Members
-
bool pf_auto_cell_size = true
If true, cell_size parameter is automatically determined based on point cloud density.
-
float pf_cell_size = 1.0f
Size of cell for spacial subdivision.
-
float pf_max_view_dot = 0.97f
Maximum dot product between view directions of two scans. Scans above this threshold are considered invalid.
-
uint32_t pf_consensus_level = 1
Minimal number of other scans, which must report data in cell in order to not remove a point. Value 0 will not filter anything.
-
bool pf_use_projection_filter = true
Enables faster projection-based filtering method.
-
float pf_min_projection_normal_dot = 0.9f
Defines max accepted angle between normals in projection-based filtering method.
-
bool use_cluster_filtering = false
Use cluster filtering after background is removed.
-
float pcf_cluster_tolerance = 5.0f
Distance tolerance for cluster filtering.
Note
Two points are considered to belong to the same cluster if their distance is lower than this threshold.
-
float pcf_filtering_buffer = 1.0f
Cluster filtering buffer.
Note
Positive values only - ideally around 1.0, the default tested acceptable buffer. Increasing the value will prevent removing points belonging to the surface at the cost of not removing smaller groups of outliers close to the surface.
Warning
Values smaller than 0.75 can lead to unstable results - patches of the actual surface may be removed.
-
bool pf_auto_cell_size = true
-
struct UnionCreation
- #include <ProcessingSettings.h>
Defines point cloud union creation properties.
Public Members
-
bool pr_is_intensity_to_color_enabled = {true}
If true, intensity data is converted to color data. If false, color data is converted to intensity data.
-
bool pr_enable_union_smoothing = {false}
Multi-view denoising. Essential for intensity data usage for most reconstructions.
-
float pr_noise_size = {2.0f}
Defines max point movement during union post-process.
-
float pr_min_noise_dot = {0.9f}
Defines minimal normal dot of unioned surfaces during union post-process.
-
bool pr_enable_upsampling = {false}
If enabled, point cloud union contains additional interpolated points.
-
bool pr_is_intensity_to_color_enabled = {true}
-
struct Reconstruction
- #include <ProcessingSettings.h>
Poisson reconstruction procedure parameters.
Public Members
-
UnionCreation union_creation
-
float color_correction_distance = 0.0f
If set to positive value, color of all black points is corrected by duplicating the color of the nearest point with non-black color up to this distance in milimeters. If there is no such point, the black point is removed. If the value is zero, the feature will be disabled.
-
uint32_t depth = 9
Depth of octree used by Poisson reconstruction. Greater the depth, the more detailed mesh will be created.
-
uint32_t point_weight = 1
Set to zero, reconstruction is equivalent to Poisson reconstruction. Higher values highlights sharp geometric details and noise.
-
std::string intermediate_dir = "intermediate"
Intermediate directory for data exchange with Poisson application executable.
-
UnionCreation union_creation
-
struct Export
- #include <ProcessingSettings.h>
Export parameters.
Public Members
-
int color_min = 0
Lower remapping coefficient for color/intensity values. Values are remapped from range <color_min, color_max> to <0, 255> and then exported.
-
int color_max = 1024
Higher remapping coefficient for color/intensity values. Values are remapped from range <color_min, color_max> to <0, 255> and then exported.
-
int color_min = 0
-
struct ProcessingSettings
-
Public Members
-
PointPairing point_pairing
-
Registration registration
-
RotableBackgroundRemoval rotable_background_removal
-
UnionCreation union_creation
-
Reconstruction reconstruction
-
PointPairing point_pairing
-
struct ScanRelating