Home || Architecture || Video Search || Visual Search || Scripts || Applications || Important Messages || OGL || Src

MakeFilter.h

Go to the documentation of this file.
00001 #ifndef Impala_Util_MakeFilter_h
00002 #define Impala_Util_MakeFilter_h
00003 
00004 #include "Core/Array/Arrays.h"
00005 
00006 namespace Impala
00007 {
00008 namespace Util
00009 {
00010 
00014 // could be templated, but only used for this type now.
00015 bool*
00016 MakeFilterElemLess(const Core::Array::Array2dScalarReal64* matrix,
00017                    int dimension, double treshold)
00018 {
00019     bool* filter = new bool[matrix->CH()];
00020     for(int i=0 ; i<matrix->CH() ; ++i)
00021         filter[i] = (*matrix->CPB(dimension, i) < treshold);
00022     return filter;
00023 }
00024 
00025 } // namespace Util
00026 } // namespace Impala
00027 
00028 #endif

Generated on Fri Mar 19 09:31:04 2010 for ImpalaSrc by  doxygen 1.5.1