From bb852cee91b52b71fccade7d4a1ef065eb0de2f0 Mon Sep 17 00:00:00 2001 From: Comment Date: Fri, 14 Mar 2014 00:51:24 +0000 Subject: nice --- offsetProject/src/imageStore.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'offsetProject/src/imageStore.h') diff --git a/offsetProject/src/imageStore.h b/offsetProject/src/imageStore.h index a2bd39d..9cde96c 100644 --- a/offsetProject/src/imageStore.h +++ b/offsetProject/src/imageStore.h @@ -3,15 +3,17 @@ #define IMAGE_STORE_SIZE 256 #define MIN_TILE_SIZE 8 -#define MAX_TILE_SIZE 16 +#define MAX_TILE_SIZE 32 -#define FLANN_MATRIX_SIZE 3 +#define FLANN_MATRIX_SIZE 5 #include "ofMain.h" #include "ofxJSONElement.h" #include "ofxOpenCv.h" //#include +//~9fps@33% 32*3 + using namespace cvflann; long ofToLong(const string& intString); @@ -115,7 +117,7 @@ class imageStore : public ofThread{ Matrix query(test,1,3); Matrix indices(new int[1], query.rows, 1); Matrix dists(new float[1], query.rows, 1); - index->knnSearch(query, indices, dists, 1,SearchParams(10)); + index->knnSearch(query, indices, dists, 1,SearchParams(20)); im=*imageptrs[*indices[0]]; //int i=rand()%imageptrs.size(); //im=images[imageptrs[i]]; @@ -159,6 +161,8 @@ class imageStore : public ofThread{ } } + //void flann(const ofImage& _img){ + //-------------------------- void threadedFunction(){ -- cgit v1.2.3