summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libmoped/src/sfm/SFM_TRACKING_DISPLAY.hpp39
1 files changed, 2 insertions, 37 deletions
diff --git a/libmoped/src/sfm/SFM_TRACKING_DISPLAY.hpp b/libmoped/src/sfm/SFM_TRACKING_DISPLAY.hpp
index a3f5ddc..62fa9b2 100644
--- a/libmoped/src/sfm/SFM_TRACKING_DISPLAY.hpp
+++ b/libmoped/src/sfm/SFM_TRACKING_DISPLAY.hpp
@@ -27,7 +27,7 @@ namespace MopedNS {
SET_CONFIG(display);
}
- void processOne (FrameData &frameData, int i) {
+ inline void processOne (FrameData &frameData, int i) {
Image *image = frameData.images[i].get ();
IplImage* img0 = cvCreateImage (cvSize (image->width,
image->height),
@@ -74,43 +74,8 @@ namespace MopedNS {
if (display < 2) return;
- for( int i=0; i<(int)frameData.images.size(); i++) {
+ for( int i=0; i<(int)frameData.images.size(); i++)
processOne (frameData, i);
- /*
- string windowName = _stepName + " #" + toString(i) + ":" + frameData.images[i]->name;
-
- cvNamedWindow( windowName.c_str(), CV_WINDOW_AUTOSIZE);
-
- IplImage* img = cvCreateImage(cvSize(frameData.images[i]->width,frameData.images[i]->height), IPL_DEPTH_8U, 3);
-
- for (int y = 0; y < frameData.images[i]->height; y++) {
- for (int x = 0; x < frameData.images[i]->width; x++) {
- img->imageData[y*img->widthStep+3*x + 0] = frameData.images[i]->data[y*frameData.images[i]->width + x];
- img->imageData[y*img->widthStep+3*x + 1] = frameData.images[i]->data[y*frameData.images[i]->width + x];
- img->imageData[y*img->widthStep+3*x + 2] = frameData.images[i]->data[y*frameData.images[i]->width + x];
- }
- }
-
- foreach( featureKind, frameData.detectedFeatures ) {
-
- int objectHash = 0;
- for(unsigned int x=0; x<featureKind.first.size(); x++) objectHash = objectHash ^ featureKind.first[x];
- CvScalar color = objectColors[objectHash % 256];
-
- foreach( corresp, featureKind.second ) {
- if( corresp.imageIdx==i )
- cvCircle(img, cvPoint( corresp.coord2D[0], corresp.coord2D[1]), 2, color , CV_FILLED, CV_AA );
- }
- }
-
- cvShowImage (windowName.c_str(), img);
-
- cvReleaseImage(&img);
- }
-
- cvWaitKey( 10 );
- */
- }
}
};
};