Opencv 自带cvtexture.cpp中灰度共生矩阵函数和参数看不懂
风来我也来 2011-04-08 03:08:18 cvtexture下面的灰度共生矩阵你熟不熟?
#define CV_MAX_NUM_GREY_LEVELS_8U 256
struct CvGLCM
{
int matrixSideLength;
int numMatrices;
double*** matrices;
int numLookupTableElements;
int forwardLookupTable[CV_MAX_NUM_GREY_LEVELS_8U];
int reverseLookupTable[CV_MAX_NUM_GREY_LEVELS_8U];
double** descriptors;
int numDescriptors;
int descriptorOptimizationType;
int optimizationType;
};
static void icvCreateGLCM_LookupTable_8u_C1R( const uchar* srcImageData, int srcImageStep,
CvSize srcImageSize, CvGLCM* destGLCM,
int* steps, int numSteps, int* memorySteps );
static void
icvCreateGLCMDescriptors_AllowDoubleNest( CvGLCM* destGLCM, int matrixIndex );
CV_IMPL CvGLCM*
cvCreateGLCM( const IplImage* srcImage,
int stepMagnitude,
const int* srcStepDirections,/* should be static array..
or if not the user should handle de-allocation */
int numStepDirections,
int optimizationType )
static void
icvCreateGLCM_LookupTable_8u_C1R( const uchar* srcImageData,
int srcImageStep,
CvSize srcImageSize,
CvGLCM* destGLCM,
int* steps,
int numSteps,
int* memorySteps )
CV_IMPL void
cvCreateGLCMDescriptors( CvGLCM* destGLCM, int descriptorOptimizationType )
static void
icvCreateGLCMDescriptors_AllowDoubleNest( CvGLCM* destGLCM, int matrixIndex )
CV_IMPL double cvGetGLCMDescriptor( CvGLCM* GLCM, int step, int descriptor )
CV_IMPL void
cvGetGLCMDescriptorStatistics( CvGLCM* GLCM, int descriptor,
double* _average, double* _standardDeviation )
这些函数和参数是什么意思?
另外这个类的函数容易真的存在内存泄露,怎么解决?
答案好加分