openCV extra modules and dependency problems

i am working with OF 0.9.3 which, if i am not mistaken, was recently updated to use openCV 3.0.

i was hoping to use some of the extra modules shown here:


specifically

but it seems OF’s version of openCV is missing a lot of the dependencies like:

for example i get error because these files can not be found:
include “opencv2/hal/defs.h”
or cvstd.hpp

looks like opencv 3.1 was added but so far only to the master on github.
when using the master surface_matching seems to compile fine.

next step get the example code running

almost.

had to add surface_matching.hpp and the surface_matching folder to opencv2

now the code compiles until i command out the call to the surfaceMatching function in setup.

void ofApp::setup(){

    //surfaceMatching();
    
}
void ofApp::surfaceMatching(){
 string modelFileName = "file1.ply";
    string sceneFileName = "file2.ply";
    Mat pc = cv::ppf_match_3d::loadPLYSimple(modelFileName.c_str(), 1);
    //cv::ppf_match_3d::writePLY
    
    // Now train the model
    cout << "Training..." << endl;
    int64 tick1 = cv::getTickCount();
    ppf_match_3d::PPF3DDetector detector(0.025, 0.05);
    detector.trainModel(pc);
    int64 tick2 = cv::getTickCount();
.
.
.
.
}

here is the project:

here a screen shot of the errors:

i guess the opencv.a lib needs to be rebuild with the opencv_contrib stuff included.

not sure if i know how to do that.