/* external contour area function */ CV_IMPL double cvContourArea( const void *array, CvSlice slice, int oriented ) { double area = 0; CvContour contour_header; CvSeq* contour = 0; CvSeqBlock block; if( CV_IS_SEQ( array )) { contour = (CvSeq*)array; if( !CV_IS_SEQ_POLYLINE( contour )) CV_Error( CV_StsBadArg, "Unsupported sequence type" ); } else { contour = cvPointSeqFromMat( CV_SEQ_KIND_CURVE, array, &contour_header, &block ); } if( cvSliceLength( slice, contour ) == contour->total ) { IPPI_CALL( icvContourArea( contour, &area )); } else { if( CV_SEQ_ELTYPE( contour ) != CV_32SC2 ) CV_Error( CV_StsUnsupportedFormat, "Only curves with integer coordinates are supported in case of contour slice" ); IPPI_CALL( icvContourSecArea( contour, slice, &area )); } return oriented ? area : fabs(area); }
CV_IMPL void cvImgToObs_DCT( const void* arr, float *obs, CvSize dctSize, CvSize obsSize, CvSize delta ) { CV_FUNCNAME( "cvImgToObs_DCT" ); __BEGIN__; CvMat stub, *mat = (CvMat*)arr; CV_CALL( mat = cvGetMat( arr, &stub )); switch( CV_MAT_TYPE( mat->type )) { case CV_8UC1: IPPI_CALL( icvImgToObs_DCT_8u32f_C1R( mat->data.ptr, mat->step, cvGetMatSize(mat), obs, dctSize, obsSize, delta )); break; case CV_32FC1: IPPI_CALL( icvImgToObs_DCT_32f_C1R( mat->data.fl, mat->step, cvGetMatSize(mat), obs, dctSize, obsSize, delta )); break; default: CV_ERROR( CV_StsUnsupportedFormat, "" ); } __END__; }
CV_IMPL void cvCornerEigenValsAndVecs( const void* srcarr, void* eigenvarr, int block_size, int aperture_size ) { static CvFuncTable eig_tab; static int inittab = 0; void *buffer = 0; CV_FUNCNAME( "cvCornerEigenValsAndVecs" ); __BEGIN__; CvSize src_size; int buf_size; CvEigFunc func = 0; CvMat stub, *src = (CvMat*)srcarr; CvMat eigstub, *eigenv = (CvMat*)eigenvarr; if( !inittab ) { icvInitEigenValsVecsTable( &eig_tab ); inittab = 1; } CV_CALL( src = cvGetMat( srcarr, &stub )); CV_CALL( eigenv = cvGetMat( eigenv, &eigstub )); if( CV_ARR_CN(src->type) != 1 ) CV_ERROR(CV_StsBadArg, "Source image has more than 1 channel"); if( CV_ARR_CN(eigenv->type)*eigenv->width != src->width*6 ) CV_ERROR(CV_StsBadArg, "Eigen-vals&vecs image should be 6 times " "wider than the source image"); if( src->height != eigenv->height ) CV_ERROR( CV_StsUnmatchedSizes, "" ); if( CV_ARR_DEPTH(eigenv->type) != CV_32F ) CV_ERROR( CV_BadDepth, "Eigen-vals&vecs image does not have IPL_DEPTH_32F depth" ); func = (CvEigFunc)(eig_tab.fn_2d[CV_ARR_DEPTH(src->type)]); if( !func ) CV_ERROR( CV_StsUnsupportedFormat, "" ); src_size = icvGetMatSize( src ); IPPI_CALL( icvEigenValsVecsGetSize( src_size.width, aperture_size, block_size, &buf_size )); CV_CALL( buffer = cvAlloc( buf_size )); IPPI_CALL( func( src->data.ptr, src->step, eigenv->data.ptr, eigenv->step, src_size, aperture_size, block_size, buffer )); __END__; cvFree( &buffer ); }
CV_IMPL void cvCalcContrastHist( IplImage ** img, CvHistogram * hist, int dont_clear, IplImage * mask ) { CV_FUNCNAME( "cvCalcContrastHist" ); uchar *data[CV_HIST_MAX_DIM]; uchar *mask_data = 0; int step = 0; int mask_step = 0; CvSize roi = { 0, 0 }; __BEGIN__; { for( int i = 0; i < hist->c_dims; i++ ) CV_CALL( CV_CHECK_IMAGE( img[i] )); } if( mask ) { CV_CALL( CV_CHECK_IMAGE( mask )); if( mask->depth != IPL_DEPTH_8U ) CV_ERROR( CV_BadDepth, "bad mask depth" ); cvGetImageRawData( mask, &mask_data, &mask_step, 0 ); } { for( int i = 0; i < hist->c_dims; i++ ) cvGetImageRawData( img[i], &data[i], &step, &roi ); } if( img[0]->nChannels != 1 ) CV_ERROR( CV_BadNumChannels, "bad channels numbers" ); if( img[0]->depth != IPL_DEPTH_8U ) CV_ERROR( CV_BadDepth, "bad image depth" ); switch (img[0]->depth) { case IPL_DEPTH_8U: if( !mask ) { IPPI_CALL( icvCalcContrastHist8uC1R( data, step, roi, hist, dont_clear )); } else { IPPI_CALL( icvCalcContrastHistMask8uC1R( data, step, mask_data, mask_step, roi, hist, dont_clear )); } break; default: CV_ERROR( CV_BadDepth, "bad image depth" ); } __CLEANUP__; __END__; }
CV_IMPL void cvCornerMinEigenVal( const void* srcarr, void* eigenvarr, int block_size, int aperture_size ) { static CvFuncTable eig_tab; static int inittab = 0; void *buffer = 0; CV_FUNCNAME( "cvCornerMinEigenVal" ); __BEGIN__; CvSize src_size; int buf_size; CvEigFunc func = 0; CvMat stub, *src = (CvMat*)srcarr; CvMat eigstub, *eigenv = (CvMat*)eigenvarr; if( !inittab ) { icvInitMinEigenValTable( &eig_tab ); inittab = 1; } CV_CALL( src = cvGetMat( srcarr, &stub )); CV_CALL( eigenv = cvGetMat( eigenv, &eigstub )); if( CV_ARR_CN(src->type) != 1 || CV_ARR_CN(eigenv->type) != 1 ) CV_ERROR(CV_StsBadArg, "Source or min-eigen-val images have more than 1 channel"); if( CV_ARR_DEPTH(eigenv->type) != CV_32F ) CV_ERROR( CV_BadDepth, "min-eigen-val image does not have IPL_DEPTH_32F depth" ); if( !CV_ARE_SIZES_EQ( src, eigenv )) CV_ERROR( CV_StsUnmatchedSizes, "" ); func = (CvEigFunc)(eig_tab.fn_2d[CV_ARR_DEPTH(src->type)]); if( !func ) CV_ERROR( CV_StsUnsupportedFormat, "" ); src_size = icvGetMatSize( src ); IPPI_CALL( icvMinEigenValGetSize( src_size.width, aperture_size, block_size, &buf_size )); CV_CALL( buffer = cvAlloc( buf_size )); IPPI_CALL( func( src->data.ptr, src->step, eigenv->data.ptr, eigenv->step, src_size, aperture_size, block_size, buffer )); __END__; cvFree( &buffer ); }
/*F/////////////////////////////////////////////////////////////////////////////////////// // Name: cvFindHandRegion // Purpose: finds hand region in range image data // Context: // Parameters: // points - pointer to the input point's set. // count - the number of the input points. // indexs - pointer to the input sequence of the point's indexes // line - pointer to the 3D-line // size - size of the hand in meters // flag - hand direction's flag (0 - left, -1 - right, // otherwise j-index of the initial image center) // center - pointer to the output hand center // storage - pointer to the memory storage // numbers - pointer to the output sequence of the point's indexes inside // hand region // // Notes: //F*/ CV_IMPL void cvFindHandRegion( CvPoint3D32f * points, int count, CvSeq * indexs, float *line, CvSize2D32f size, int flag, CvPoint3D32f * center, CvMemStorage * storage, CvSeq ** numbers ) { if(flag == 0 || flag == -1) { IPPI_CALL( icvFindHandRegion( points, count, indexs, line, size, -flag, center, storage, numbers )); } else IPPI_CALL( icvFindHandRegionA( points, count, indexs, line, size, flag, center, storage, numbers )); }
CV_IMPL CvPOSITObject * cvCreatePOSITObject( CvPoint3D32f * points, int numPoints ) { CvPOSITObject *pObject = 0; IPPI_CALL( icvCreatePOSITObject( points, numPoints, &pObject )); return pObject; }
CV_IMPL void cvCalcPGH( const CvSeq * contour, CvHistogram * hist ) { CV_FUNCNAME( "cvCalcPGH" ); __BEGIN__; int size[CV_MAX_DIM]; int dims; if( !CV_IS_HIST(hist)) CV_ERROR( CV_StsBadArg, "The histogram header is invalid " ); if( CV_IS_SPARSE_HIST( hist )) CV_ERROR( CV_StsUnsupportedFormat, "Sparse histogram are not supported" ); dims = cvGetDims( hist->bins, size ); if( dims != 2 ) CV_ERROR( CV_StsBadSize, "The histogram must be two-dimensional" ); if( !CV_IS_SEQ_POINT_SET( contour ) || CV_SEQ_ELTYPE( contour ) != CV_32SC2 ) CV_ERROR( CV_StsUnsupportedFormat, "The contour is not valid or the point type is not supported" ); IPPI_CALL( icvCalcPGH( contour, ((CvMatND*)(hist->bins))->data.fl, size[0], size[1] )); __END__; }
/*F/////////////////////////////////////////////////////////////////////////////////////// // Name: cvCalcOpticalFlowLK // Purpose: Optical flow implementation // Context: // Parameters: // srcA, srcB - source image // velx, vely - destination image // Returns: // // Notes: //F*/ CV_IMPL void cvCalcOpticalFlowLK(const void* srcarrA, const void* srcarrB, CvSize winSize, void* velarrx, void* velarry) { CvMat stubA, *srcA = cvGetMat(srcarrA, &stubA); CvMat stubB, *srcB = cvGetMat(srcarrB, &stubB); CvMat stubx, *velx = cvGetMat(velarrx, &stubx); CvMat stuby, *vely = cvGetMat(velarry, &stuby); if (!CV_ARE_TYPES_EQ(srcA, srcB)) { CV_Error(CV_StsUnmatchedFormats, "Source images have different formats"); } if (!CV_ARE_TYPES_EQ(velx, vely)) { CV_Error(CV_StsUnmatchedFormats, "Destination images have different formats"); } if (!CV_ARE_SIZES_EQ(srcA, srcB) || !CV_ARE_SIZES_EQ(velx, vely) || !CV_ARE_SIZES_EQ(srcA, velx)) { CV_Error(CV_StsUnmatchedSizes, ""); } if (CV_MAT_TYPE(srcA->type) != CV_8UC1 || CV_MAT_TYPE(velx->type) != CV_32FC1) CV_Error(CV_StsUnsupportedFormat, "Source images must have 8uC1 type and " "destination images must have 32fC1 type"); if (srcA->step != srcB->step || velx->step != vely->step) { CV_Error(CV_BadStep, "source and destination images have different step"); } IPPI_CALL(icvCalcOpticalFlowLK_8u32fR((uchar*)srcA->data.ptr, (uchar*)srcB->data.ptr, srcA->step, cvGetMatSize(srcA), winSize, velx->data.fl, vely->data.fl, velx->step)); }
CV_IMPL CvSeq* cvContourConvexHullApprox( CvSeq * sequence, int bandwidth, int orientation, CvMemStorage * storage ) { CvSeq *hull = 0; CV_FUNCNAME( "cvContourConvexHullApprox" ); __BEGIN__; /* check arguments */ if( !sequence || !storage ) CV_ERROR_FROM_STATUS( CV_NULLPTR_ERR ); if( bandwidth < 1 ) CV_ERROR_FROM_STATUS( CV_BADSIZE_ERR ); if( orientation != CV_CLOCKWISE && orientation != CV_COUNTER_CLOCKWISE ) CV_ERROR_FROM_STATUS( CV_BADFLAG_ERR ); IPPI_CALL( icvConvexHull_Approx_Contour( sequence, bandwidth, orientation, storage, &hull )); __CLEANUP__; __END__; return hull; }
/* 改变轮廓位置使得它的能量最小 void cvSnakeImage( const IplImage* image, CvPoint* points, int length, float* alpha, float* beta, float* gamma, int coeff_usage, CvSize win, CvTermCriteria criteria, int calc_gradient=1 ); image 输入图像或外部能量域 points 轮廓点 (snake). length 轮廓点的数目 alpha 连续性能量的权 Weight[s],单个浮点数或长度为 length 的浮点数数组,每个轮廓点有一个权 beta 曲率能量的权 Weight[s],与 alpha 类似 gamma 图像能量的权 Weight[s],与 alpha 类似 coeff_usage 前面三个参数的不同使用方法: CV_VALUE 表示每个 alpha, beta, gamma 都是指向为所有点所用的一个单独数值; CV_ARRAY 表示每个 alpha, beta, gamma 是一个指向系数数组的指针,snake 上面各点的系数都不相同。因此,各个系数数组必须与轮廓具有同样的大小。所有数组必须与轮廓具有同样大小 win 每个点用于搜索最小值的邻域尺寸,两个 win.width 和 win.height 都必须是奇数 criteria 终止条件 calc_gradient 梯度符号。如果非零,函数为每一个图像象素计算梯度幅值,且把它当成能量场,否则考虑输入图像本身。 函数 cvSnakeImage 更新 snake 是为了最小化 snake 的整个能量,其中能量是依赖于轮廓形状的内部能量(轮廓越光滑,内部能量越小)以及依赖于能量场的外部能量之和,外部能量通常在哪些局部能量极值点中达到最小值(这些局部能量极值点与图像梯度表示的图像边缘相对应)。 参数 criteria.epsilon 用来定义必须从迭代中除掉以保证迭代正常运行的点的最少数目。 如果在迭代中去掉的点数目小于 criteria.epsilon 或者函数达到了最大的迭代次数 criteria.max_iter ,则终止函数。 */ CV_IMPL void cvSnakeImage( const IplImage* src, CvPoint* points, int length, float *alpha, float *beta, float *gamma, int coeffUsage, CvSize win, CvTermCriteria criteria, int calcGradient ) { CV_FUNCNAME( "cvSnakeImage" ); __BEGIN__; uchar *data; CvSize size; int step; if( src->nChannels != 1 ) CV_ERROR( CV_BadNumChannels, "input image has more than one channel" ); if( src->depth != IPL_DEPTH_8U ) CV_ERROR( CV_BadDepth, cvUnsupportedFormat ); cvGetRawData( src, &data, &step, &size ); IPPI_CALL( icvSnake8uC1R( data, step, size, points, length, alpha, beta, gamma, coeffUsage, win, criteria, calcGradient ? _CV_SNAKE_GRAD : _CV_SNAKE_IMAGE )); __END__; }
CV_IMPL void cvConvexHullApprox( CvPoint * points, int num_points, CvRect * bound_rect, int bandwidth, int orientation, int *hullpoints, int *hullsize ) { CV_FUNCNAME( "cvConvexHullApprox" ); __BEGIN__; if( !points || !hullpoints || !hullsize ) CV_ERROR_FROM_STATUS( CV_NULLPTR_ERR ); if( bandwidth < 1 ) CV_ERROR_FROM_STATUS( CV_BADSIZE_ERR ); IPPI_CALL( icvConvexHull_Approx( points, num_points, bound_rect, bandwidth, orientation, hullpoints, hullsize )); __CLEANUP__; __END__; }
static void icxLogicSM( const void* srcarr, CxScalar* scalar, void* dstarr, const void* maskarr, CxArithmUniMaskFunc2D func ) { CX_FUNCNAME( "icxLogicSM" ); __BEGIN__; double buf[12]; int coi1 = 0, coi2 = 0; CxMat srcstub, *src = (CxMat*)srcarr; CxMat dststub, *dst = (CxMat*)dstarr; CxMat maskstub, *mask = (CxMat*)maskarr; int pix_size, type; int dst_step, mask_step; CxSize size; if( !CX_IS_MAT(src)) CX_CALL( src = cxGetMat( src, &srcstub, &coi1 )); if( !CX_IS_MAT(dst)) CX_CALL( dst = cxGetMat( dst, &dststub )); if( coi1 != 0 || coi2 != 0 ) CX_ERROR( CX_BadCOI, "" ); CX_CALL( mask = cxGetMat( mask, &maskstub )); if( !CX_IS_MASK_ARR(mask) ) CX_ERROR_FROM_CODE( CX_StsBadMask ); if( !CX_ARE_SIZES_EQ( mask, dst ) ) CX_ERROR_FROM_CODE( CX_StsUnmatchedSizes ); if( src->data.ptr != dst->data.ptr ) { CX_CALL( cxCopy( src, dst, mask )); } size = cxGetMatSize( dst ); dst_step = dst->step; mask_step = mask->step; if( CX_IS_MAT_CONT( mask->type & dst->type )) { size.width *= size.height; dst_step = mask_step = CX_STUB_STEP; size.height = 1; } type = CX_MAT_TYPE( src->type ); pix_size = icxPixSize[type]; CX_CALL( cxScalarToRawData( scalar, buf, type, 0 )); IPPI_CALL( func( dst->data.ptr, dst_step, mask->data.ptr, mask_step, size, buf, pix_size )); __END__; }
CV_IMPL void cvPOSIT( CvPOSITObject * pObject, CvPoint2D32f * imagePoints, double focalLength, CvTermCriteria criteria, float* rotation, float* translation ) { IPPI_CALL( icvPOSIT( pObject, imagePoints,(float) focalLength, criteria, rotation, translation )); }
/*F/////////////////////////////////////////////////////////////////////////////////////// // Name: cvCreateContourTree // Purpose: // Create binary tree representation for the contour // Context: // Parameters: // contour - pointer to input contour object. // storage - pointer to the current storage block // tree - output pointer to the binary tree representation // threshold - threshold for the binary tree building // //F*/ CV_IMPL CvContourTree* cvCreateContourTree( const CvSeq* contour, CvMemStorage* storage, double threshold ) { CvContourTree* tree = 0; IPPI_CALL( icvCreateContourTree( contour, storage, &tree, threshold )); return tree; }
/*F/////////////////////////////////////////////////////////////////////////////////////// // Name: cvFindHandRegionA // Purpose: finds hand region in range image data // Context: // Parameters: // points - pointer to the input point's set. // count - the number of the input points. // indexs - pointer to the input sequence of the point's indexes // line - pointer to the 3D-line // size - size of the hand in meters // jc - j-index of the initial image center // center - pointer to the output hand center // storage - pointer to the memory storage // numbers - pointer to the output sequence of the point's indexes inside // hand region // // Notes: //F*/ CV_IMPL void cvFindHandRegionA( CvPoint3D32f * points, int count, CvSeq * indexs, float *line, CvSize2D32f size, int jc, CvPoint3D32f * center, CvMemStorage * storage, CvSeq ** numbers ) { IPPI_CALL( icvFindHandRegionA( points, count, indexs, line, size, jc, center, storage, numbers )); }
CV_IMPL void cvGetRectSubPix( const void* srcarr, void* dstarr, CvPoint2D32f center ) { static CvFuncTable gr_tab[2]; static int inittab = 0; CvMat srcstub, *src = (CvMat*)srcarr; CvMat dststub, *dst = (CvMat*)dstarr; CvSize src_size, dst_size; CvGetRectSubPixFunc func; int cn, src_step, dst_step; if( !inittab ) { icvInitGetRectSubPixC1RTable( gr_tab + 0 ); icvInitGetRectSubPixC3RTable( gr_tab + 1 ); inittab = 1; } if( !CV_IS_MAT(src)) src = cvGetMat( src, &srcstub ); if( !CV_IS_MAT(dst)) dst = cvGetMat( dst, &dststub ); cn = CV_MAT_CN( src->type ); if( (cn != 1 && cn != 3) || !CV_ARE_CNS_EQ( src, dst )) CV_Error( CV_StsUnsupportedFormat, "" ); src_size = cvGetMatSize( src ); dst_size = cvGetMatSize( dst ); src_step = src->step ? src->step : CV_STUB_STEP; dst_step = dst->step ? dst->step : CV_STUB_STEP; //if( dst_size.width > src_size.width || dst_size.height > src_size.height ) // CV_ERROR( CV_StsBadSize, "destination ROI must be smaller than source ROI" ); if( CV_ARE_DEPTHS_EQ( src, dst )) { func = (CvGetRectSubPixFunc)(gr_tab[cn != 1].fn_2d[CV_MAT_DEPTH(src->type)]); } else { if( CV_MAT_DEPTH( src->type ) != CV_8U || CV_MAT_DEPTH( dst->type ) != CV_32F ) CV_Error( CV_StsUnsupportedFormat, "" ); func = (CvGetRectSubPixFunc)(gr_tab[cn != 1].fn_2d[1]); } if( !func ) CV_Error( CV_StsUnsupportedFormat, "" ); IPPI_CALL( func( src->data.ptr, src_step, src_size, dst->data.ptr, dst_step, dst_size, center )); }
CV_IMPL void cvRelease2DHMM( CvEHMM ** hmm ) { CV_FUNCNAME( "cvRelease2DHMM" ); __BEGIN__; IPPI_CALL( icvRelease2DHMM( hmm )); __END__; }
CV_IMPL void cvUniformImgSegm( CvImgObsInfo * obs_info, CvEHMM * hmm ) { CV_FUNCNAME( "cvUniformImgSegm" ); __BEGIN__; IPPI_CALL( icvUniformImgSegm( obs_info, hmm )); __CLEANUP__; __END__; }
CV_IMPL void cvReleaseObsInfo( CvImgObsInfo ** obs_info ) { CV_FUNCNAME( "cvReleaseObsInfo" ); __BEGIN__; IPPI_CALL( icvReleaseObsInfo( obs_info )); __END__; }
CV_IMPL void cvMixSegmL2( CvImgObsInfo ** obs_info_array, int num_img, CvEHMM * hmm ) { CV_FUNCNAME( "cvMixSegmL2" ); __BEGIN__; IPPI_CALL( icvMixSegmL2( obs_info_array, num_img, hmm )); __END__; }
CV_IMPL void cvEstimateObsProb( CvImgObsInfo * obs_info, CvEHMM * hmm ) { CV_FUNCNAME( "cvEstimateObsProb" ); __BEGIN__; IPPI_CALL( icvEstimateObsProb( obs_info, hmm )); __END__; }
CV_IMPL void cvEstimateHMMStateParams( CvImgObsInfo ** obs_info_array, int num_img, CvEHMM * hmm ) { CV_FUNCNAME( "cvEstimateHMMStateParams" ); __BEGIN__; IPPI_CALL( icvEstimateHMMStateParams( obs_info_array, num_img, hmm )); __END__; }
CV_IMPL void cvKMeans( int num_clusters, CvVect32f * samples, int num_samples, int vec_size, CvTermCriteria termcrit, int *cluster ) { CV_FUNCNAME( "cvKMeans" ); __BEGIN__; IPPI_CALL( icvKMeans( num_clusters, samples, num_samples, vec_size, termcrit, cluster )); __END__; }
CV_IMPL void cvEstimateTransProb( CvImgObsInfo ** obs_info_array, int num_img, CvEHMM * hmm ) { CV_FUNCNAME( "cvEstimateTransProb" ); __BEGIN__; IPPI_CALL( icvEstimateTransProb( obs_info_array, num_img, hmm )); __END__; }
CV_IMPL void cvConvexHull( CvPoint * points, int num_points, CvRect * bound_rect, int orientation, int *hull, int *hullsize ) { CV_FUNCNAME( "cvConvexHull" ); __BEGIN__; IPPI_CALL( icvConvexHull( points, num_points, bound_rect, orientation, hull, hullsize )); __CLEANUP__; __END__; }
CV_IMPL void cvCalcPGH( CvSeq * contour, CvHistogram * hist ) { CV_FUNCNAME( "cvCalcPGH" ); __BEGIN__; if( hist->type != CV_HIST_ARRAY || hist->c_dims != 2 ) CV_ERROR( IPL_StsBadArg, icvUnsupportedFormat ); IPPI_CALL( icvCalcPGH( contour, hist->array, hist->dims[0], hist->dims[1] )); __END__; }
/*F/////////////////////////////////////////////////////////////////////////////////////// // Name: cvCreateContourTree // Purpose: // Create binary tree representation for the contour // Context: // Parameters: // contour - pointer to input contour object. // storage - pointer to the current storage block // tree - output pointer to the binary tree representation // threshold - threshold for the binary tree building // //F*/ CV_IMPL CvContourTree* cvCreateContourTree( const CvSeq* contour, CvMemStorage* storage, double threshold ) { CvContourTree* tree = 0; CV_FUNCNAME( "cvCreateContourTree" ); __BEGIN__; IPPI_CALL( icvCreateContourTree( contour, storage, &tree, threshold )); __CLEANUP__; __END__; return tree; }
CV_IMPL CvImgObsInfo* cvCreateObsInfo( CvSize num_obs, int obs_size ) { CvImgObsInfo *obs_info = 0; CV_FUNCNAME( "cvCreateObsInfo" ); __BEGIN__; IPPI_CALL( icvCreateObsInfo( &obs_info, num_obs, obs_size )); __END__; return obs_info; }
CV_IMPL CvEHMM* cvCreate2DHMM( int *state_number, int *num_mix, int obs_size ) { CvEHMM* hmm = 0; CV_FUNCNAME( "cvCreate2DHMM" ); __BEGIN__; IPPI_CALL( icvCreate2DHMM( &hmm, state_number, num_mix, obs_size )); __END__; return hmm; }