Definition at line 34 of file LbpEval.h. Referenced by Impala::Core::VideoSet::MakeMap(). 00035 { 00036 int base = 1; 00037 int current = c & base; 00038 int current2; 00039 int changes = 0; 00040 for (int i=1;i<bits;i++) 00041 { 00042 base <<= 1; 00043 current2 = (c & base) >> i; 00044 if (current ^ current2) 00045 changes++; 00046 current = current2; 00047 } 00048 return changes; //(changes <= 2)? 1 : 0; 00049 }
|