SL_SpatialMappingParameters Struct Reference

Structure containing a set of parameters for the spatial mapping module. More...

Data Fields

float resolution_meter
 Spatial mapping resolution in meters. More...
 
float range_meter
 Depth range in meters. More...
 
bool save_texture
 Whether to save the texture. More...
 
bool use_chunk_only
 Whether to only use chunks. More...
 
int max_memory_usage
 The maximum CPU memory (in MB) allocated for the meshing process. More...
 
bool reverse_vertex_order
 Whether to inverse the order of the vertices of the triangles. More...
 
enum SL_SPATIAL_MAP_TYPE map_type
 The type of spatial map to be created. More...
 
int stability_counter
 Control the integration rate of the current depth into the mapping process. More...
 

Detailed Description

Structure containing a set of parameters for the spatial mapping module.

The default constructor sets all parameters to their default settings.

Note
Parameters can be adjusted by the user.

Field Documentation

◆ resolution_meter

float SL_SpatialMappingParameters::resolution_meter

Spatial mapping resolution in meters.

Default: 0.05f

◆ range_meter

float SL_SpatialMappingParameters::range_meter

Depth range in meters.

Can be different from the value set by SL_InitParameters.depth_maximum_distance.

Note
Set to 0 by default. In this case, the range is computed from resolution_meter and from the current internal parameters to fit your application.

◆ save_texture

bool SL_SpatialMappingParameters::save_texture

Whether to save the texture.

If set to true, you will be able to apply the texture to your mesh after it is created.
Default: false

Note
This option will consume more memory.
This option is only available for SL_SPATIAL_MAP_TYPE_MESH.

◆ use_chunk_only

bool SL_SpatialMappingParameters::use_chunk_only

Whether to only use chunks.

If set to false, you will ensure consistency between the mesh and its inner chunk data.
Default: false

Note
Updating the mesh is time-consuming.
Setting this to true results in better performance.

◆ max_memory_usage

int SL_SpatialMappingParameters::max_memory_usage

The maximum CPU memory (in MB) allocated for the meshing process.

Default: 2048

◆ reverse_vertex_order

bool SL_SpatialMappingParameters::reverse_vertex_order

Whether to inverse the order of the vertices of the triangles.

If your display process does not handle front and back face culling, you can use this to correct it.
Default: false

Note
This option is only available for SL_SPATIAL_MAP_TYPE_MESH.

◆ map_type

enum SL_SPATIAL_MAP_TYPE SL_SpatialMappingParameters::map_type

The type of spatial map to be created.

This dictates the format that will be used for the mapping (e.g. mesh, point cloud).
See SL_SPATIAL_MAP_TYPE.

◆ stability_counter

int SL_SpatialMappingParameters::stability_counter

Control the integration rate of the current depth into the mapping process.

This parameter controls how many times a stable 3D points should be seen before it is integrated into the spatial mapping.
Default: 0 (this will define the stability counter based on the mesh resolution, the higher the resolution, the higher the stability counter)