kinfu h介面大全

2021-07-13 22:33:18 字數 3086 閱讀 7107

pcl的kinfu中文資料比較少,看開源**的標頭檔案是乙個不錯的入手點,所以總結了kinfu.h的一些介面用法供參考。

kinfutracker類

kinfutracker (int rows = 480, int cols = 640);

建構函式

setdepthintrinsics、getdepthintrinsics:

獲取深度本來的資訊x,y 焦距等資訊

setinitalcamerapose、getinitalcamerapose:

快速初始化相機位置,並關聯到體積座標空間

setdepthtruncationforicp(float max_icp_distance= 0.f):

為icp階段設定截斷閾值,過濾測試

seticpcorespfilteringparams(float distthreshold,float sineofangle)

設定icp過濾引數

setcameramovementthreshold(float threshold =0.001f);

整合閾值

initcolorintegration(int max_weight = -1)

顏色初始化

bool operator() (const depthmap& depth, eigen::affine3f* hint=null)

到下一幀

eigen::affine3f getcamerapose(int time = -1)const

給定時刻的相機位置

size_t getnumberofposes() const;

返回位置的個數,包括初始的位置

consttsdfvolume& volume() const;

tsdf立方體

constcolorvolume& colorvolume() const;

帶顏色立方體

void getimage(view& view) const;

渲出3d場景       

void getlastframecloud(devicearray2d& cloud) const;

返回上乙個相機位置的點雲(重要)

引數是點雲陣列

void getlastframenormals(devicearray2d& normals) const;

引數是法線

void disableicp();

終止icp

private:

enum ;

金字塔層級分為3級

typedef devicearray2dcorespmap;

定義corespmap為icp對應點對映

typedef devicearray2dmaparr;

定義maparr為頂點和法線對映

typedef eigen::matrixmatrix3frm;

定義3×3矩陣matrix3frm,按行儲存

typedef eigen::vector3f vector3f;

定義3維向量vector3f

int rows_;

深度圖形高對應rows

int cols_;

深度影象對應cols

int global_time_;

幀計數器

float max_icp_distance_;

深度影象的擷取閾值

float fx_, fy_,cx_, cy_;

相機內參,f焦距,c離中心點距離

tsdfvolume::ptr tsdf_volume_;

tsdf立方體容器

colorvolume::ptr color_volume_;

帶顏色的立方體容器               

matrix3frm init_rcam_;

在立方體的座標空間中初始化相機的旋轉引數

vector3f init_tcam_;

在立方體的座標空間中初始化相機的位置引數

int icp_iterations_[levels];

各個層級的icp有不同的迭代次數

float  distthres_;

距離閾值,用於相關點過濾

float anglethres_;

角度閾值       

std::vectordepths_curr_;

深度層級       

std::vectorvmaps_g_curr_;

在當前幀下,全域性座標空間的頂點資訊

std::vectornmaps_g_curr_;

在當前幀下,全域性座標空間下的法線資訊

std::vectorvmaps_g_prev_;

前一幀下,全域性座標空間的頂點資訊

std::vectornmaps_g_prev_;

前一幀下,全域性座標空間的法線資訊

std::vectorvmaps_curr_;

在當前幀下,當前座標空間的頂點資訊

std::vectornmaps_curr_;

在當前幀下,當前座標空間的法線資訊

std::vectorcoresps_;

陣列緩衝區,icp對應的不同層級      

devicearray2ddepthrawscaled_;

緩衝儲存擴充套件深度影象     

devicearray2dgbuf_;

臨時緩衝

devicearraysumbuf_;

mls矩陣

std::vectorrmats_;

每個時刻的相機旋轉矩陣       

std::vectortvecs_;

每個時刻的相機位置轉移矩陣

float integration_metric_threshold_;

相機運動閾值

bool disable_icp_;

記錄icp是否完全終止       

void allocatebufffers(int rows_arg, intcols_arg);

分配所有gpu內部緩衝區

void reset ();

將追蹤程序重置為初始狀態,在相機追蹤失敗的時候呼叫

Mysql介面大全

做c 開發時,使用mysql 資料庫的時候 難免 會發生不知道資料庫的介面的問題 下面是mysql資料庫的一些介面 mysql affected rows 返回被最新的update,delete或insert查詢影響的行數。mysql close 關閉乙個伺服器連線。mysql connect 連線...

介面工具大全

下劃線 下劃線較粗,用途 頁面便簽欄 match parent android layout height 1dp android layout alignparenttop true android background ffdadada 下劃線較細,用途 賬號 密碼下劃線 id id first...

MySQL的C語言介面大全

2011 05 29 21 59 mysql在 c api 中可用的函式 mysql affected rows 返回被最新的update,delete或insert查詢影響的行數。mysql close 關閉乙個伺服器連線。mysql connect 連線乙個mysql伺服器。該函式不推薦 使用m...