TSDF学习:pcl::gpu::TsdfVolume Class Reference

爱⌒轻易说出口 提交于 2020-03-03 20:52:56

http://docs.pointclouds.org/trunk/classpcl_1_1gpu_1_1_tsdf_volume.html

Public Member Functions

  TsdfVolume (const Eigen::Vector3i &resolution)
 

Constructor. More...

构造函数

 
void  setSize (const Eigen::Vector3f &size)
 

Sets Tsdf volume size for each dimension. More...

设置Tsdf 立方体在X、Y、Z方向的大小,单位m

 
void  setTsdfTruncDist (float distance)
 

Sets Tsdf truncation distance. More...

设置Tsdf 截断距离,其值必须大于 2 * volume_voxel_size

 
DeviceArray2D< int >  data () const
 

Returns tsdf volume container that point to data in GPU memory. More...

 
const Eigen::Vector3f &  getSize () const
 

Returns volume size in meters. More...

返回体积大小,单位m

 
const Eigen::Vector3i &  getResolution () const
 

Returns volume resolution. More...

返回体素在X、Y、Z方向的个数

 
const Eigen::Vector3f  getVoxelSize () const
 

Returns volume voxel size in meters. More...

返回体素大小,单位m

 
float  getTsdfTruncDist () const
 

Returns tsdf truncation distance in meters. More...

返回截断距离

 
void  reset ()
  Resets tsdf volume data to uninitialized state. More...
 
void  fetchCloudHost (PointCloudPointType > &cloud, bool connected26=false) const
  Generates cloud using CPU (downloads volumetric representation to CPU memory) More...
 
DeviceArrayPointType >  fetchCloud (DeviceArrayPointType > &cloud_buffer) const
  Generates cloud using GPU in connected6 mode only. More...
 
void  fetchNormals (const DeviceArrayPointType > &cloud, DeviceArrayPointType > &normals) const
  Computes normals as gradient of tsdf for given points. More...
 
void  fetchNormals (const DeviceArrayPointType > &cloud, DeviceArrayNormalType > &normals) const
  Computes normals as gradient of tsdf for given points. More...
 
void  downloadTsdf (std::vector< float > &tsdf) const
 

Downloads tsdf volume from GPU memory. More...

 

[out] tsdf Array with tsdf values. if volume resolution is 512x512x512, so for voxel (x,y,z) tsdf value can be retrieved as volume[512*512*z + 512*y + x];
 
void 

downloadTsdfAndWeighs (std::vector< float > &tsdf, std::vector< short > &weights) const

 

Downloads TSDF volume and according voxel weights from GPU memory. More...

[out] tsdf Array with tsdf values. if volume resolution is 512x512x512, so for voxel (x,y,z) tsdf value can be retrieved as volume[512*512*z + 512*y + x];
[out] weights Array with tsdf voxel weights. Same size and access index as for tsdf. A weight of 0 indicates the voxel was never used.

 

 如图所示:

TSDF立方体的边长为3m;

分辨率可为32x32x32,64x64x64,128x128x128,256x256x256,512x512x512;

如每个坐标轴的体素数量设为512,则每个体素的边长为3/512=0.00585938m

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!