Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

how to use ICP in openCV


I want to write a small programm to understand how the ICP work and want to test it. But i don't understand the function call of the ICP function, see code...

Can somebody show me how to do the ICP with 2 MATs? Or Any Idea/tip?

#include <iostream>
#include <opencv2/opencv.hpp>
#include <string>
#include <icp.hpp>
#include <ppf_match_3d.hpp>
#include <ppf_helpers.hpp>

using namespace std;
using namespace cv;
using namespace ppf_match_3d;

int main() {

Mat outputPLY;

// load PLYs
Mat iFirst     = loadPLYSimple("1.ply");
Mat iSecond = loadPLYSimple("2.ply");

ICP icp;

    // i dont understand this function with its parameters
    // is this the ICP ? 
    int t = icp.registerModelToScene(iFirst, iSecond, ?...?);

    // save solution of ICP as new PLY

    return 0;