Wondercoll
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros
Classes | Macros | Typedefs | Enumerations | Functions
cxmisc.h File Reference
#include <limits.h>

Go to the source code of this file.

Classes

struct  CvFuncTable
 
struct  CvBigFuncTable
 
struct  CvBtFuncTable
 

Macros

#define CV_MAX_INLINE_MAT_OP_SIZE   10
 
#define CV_MAX_LOCAL_MAT_SIZE   32
 
#define CV_MAX_LOCAL_SIZE   (CV_MAX_LOCAL_MAT_SIZE*CV_MAX_LOCAL_MAT_SIZE*(int)sizeof(double))
 
#define CV_DEFAULT_IMAGE_ROW_ALIGN   4
 
#define CV_DEFAULT_MAT_ROW_ALIGN   1
 
#define CV_MAX_ALLOC_SIZE   (((size_t)1 << (sizeof(size_t)*8-2)))
 
#define CV_MALLOC_ALIGN   32
 
#define CV_STRUCT_ALIGN   ((int)sizeof(double))
 
#define CV_STORAGE_BLOCK_SIZE   ((1<<16) - 128)
 
#define CV_SPARSE_MAT_BLOCK   (1<<12)
 
#define CV_SPARSE_HASH_SIZE0   (1<<10)
 
#define CV_SPARSE_HASH_RATIO   3
 
#define CV_MAX_STRLEN   1024
 
#define CV_MAX_THREADS   1
 
#define CV_CHECK_NANS(arr)
 
#define cvStackAlloc(size)   cvAlignPtr( alloca((size) + CV_MALLOC_ALIGN), CV_MALLOC_ALIGN )
 
#define CV_BIG_INT(n)   n##LL
 
#define CV_BIG_UINT(n)   n##ULL
 
#define CV_IMPL   CV_EXTERN_C
 
#define CV_DBG_BREAK()   { volatile int* crashMe = 0; *crashMe = 0; }
 
#define CV_STUB_STEP   (1 << 30)
 
#define CV_SIZEOF_FLOAT   ((int)sizeof(float))
 
#define CV_SIZEOF_SHORT   ((int)sizeof(short))
 
#define CV_ORIGIN_TL   0
 
#define CV_ORIGIN_BL   1
 
#define CV_POS_INF   0x7f800000
 
#define CV_NEG_INF   0x807fffff /* CV_TOGGLE_FLT(0xff800000) */
 
#define CV_1F   0x3f800000
 
#define CV_TOGGLE_FLT(x)   ((x)^((int)(x) < 0 ? 0x7fffffff : 0))
 
#define CV_TOGGLE_DBL(x)   ((x)^((int64)(x) < 0 ? CV_BIG_INT(0x7fffffffffffffff) : 0))
 
#define CV_NOP(a)   (a)
 
#define CV_ADD(a, b)   ((a) + (b))
 
#define CV_SUB(a, b)   ((a) - (b))
 
#define CV_MUL(a, b)   ((a) * (b))
 
#define CV_AND(a, b)   ((a) & (b))
 
#define CV_OR(a, b)   ((a) | (b))
 
#define CV_XOR(a, b)   ((a) ^ (b))
 
#define CV_ANDN(a, b)   (~(a) & (b))
 
#define CV_ORN(a, b)   (~(a) | (b))
 
#define CV_SQR(a)   ((a) * (a))
 
#define CV_LT(a, b)   ((a) < (b))
 
#define CV_LE(a, b)   ((a) <= (b))
 
#define CV_EQ(a, b)   ((a) == (b))
 
#define CV_NE(a, b)   ((a) != (b))
 
#define CV_GT(a, b)   ((a) > (b))
 
#define CV_GE(a, b)   ((a) >= (b))
 
#define CV_NONZERO(a)   ((a) != 0)
 
#define CV_NONZERO_FLT(a)   (((a)+(a)) != 0)
 
#define CV_CAST_8U(t)   (uchar)(!((t) & ~255) ? (t) : (t) > 0 ? 255 : 0)
 
#define CV_CAST_8S(t)   (schar)(!(((t)+128) & ~255) ? (t) : (t) > 0 ? 127 : -128)
 
#define CV_CAST_16U(t)   (ushort)(!((t) & ~65535) ? (t) : (t) > 0 ? 65535 : 0)
 
#define CV_CAST_16S(t)   (short)(!(((t)+32768) & ~65535) ? (t) : (t) > 0 ? 32767 : -32768)
 
#define CV_CAST_32S(t)   (int)(t)
 
#define CV_CAST_64S(t)   (int64)(t)
 
#define CV_CAST_32F(t)   (float)(t)
 
#define CV_CAST_64F(t)   (double)(t)
 
#define CV_PASTE2(a, b)   a##b
 
#define CV_PASTE(a, b)   CV_PASTE2(a,b)
 
#define CV_EMPTY
 
#define CV_MAKE_STR(a)   #a
 
#define CV_DEFINE_MASK   float maskTab[2]; maskTab[0] = 0.f; maskTab[1] = 1.f;
 
#define CV_ANDMASK(m, x)   ((x) & (((m) == 0) - 1))
 
#define CV_MULMASK(m, x)   (maskTab[(m) != 0]*(x))
 
#define CV_MULMASK1(m, x)   (maskTab[(m)+1]*(x))
 
#define CV_ZERO_OBJ(x)   memset((x), 0, sizeof(*(x)))
 
#define CV_DIM(static_array)   ((int)(sizeof(static_array)/sizeof((static_array)[0])))
 
#define CV_UN_ENTRY_C1(worktype)   worktype s0 = scalar[0]
 
#define CV_UN_ENTRY_C2(worktype)   worktype s0 = scalar[0], s1 = scalar[1]
 
#define CV_UN_ENTRY_C3(worktype)   worktype s0 = scalar[0], s1 = scalar[1], s2 = scalar[2]
 
#define CV_UN_ENTRY_C4(worktype)   worktype s0 = scalar[0], s1 = scalar[1], s2 = scalar[2], s3 = scalar[3]
 
#define cvUnsupportedFormat   "Unsupported format"
 
#define CV_DESCALE(x, n)   (((x) + (1 << ((n)-1))) >> (n))
 
#define CV_FLT_TO_FIX(x, n)   cvRound((x)*(1<<(n)))
 
#define CV_MEMCPY_CHAR(dst, src, len)
 
#define CV_MEMCPY_INT(dst, src, len)
 
#define CV_MEMCPY_AUTO(dst, src, len)
 
#define CV_ZERO_CHAR(dst, len)
 
#define CV_ZERO_INT(dst, len)
 
#define CV_IMPLEMENT_QSORT_EX(func_name, T, LT, user_data_type)
 
#define CV_IMPLEMENT_QSORT(func_name, T, cmp)   CV_IMPLEMENT_QSORT_EX( func_name, T, cmp, int )
 
#define CV_ERROR_FROM_STATUS(result)   CV_ERROR( cvErrorFromIppStatus( result ), "OpenCV function failed" )
 
#define IPPI_CALL(Func)
 
#define CV_PLUGIN_NONE   0
 
#define CV_PLUGIN_OPTCV   1 /* custom "emerged" ippopencv library */
 
#define CV_PLUGIN_IPPCV   2 /* IPP: computer vision */
 
#define CV_PLUGIN_IPPI   3 /* IPP: image processing */
 
#define CV_PLUGIN_IPPS   4 /* IPP: signal processing */
 
#define CV_PLUGIN_IPPVM   5 /* IPP: vector math functions */
 
#define CV_PLUGIN_IPPCC   6 /* IPP: color space conversion */
 
#define CV_PLUGIN_MKL   8 /* Intel Math Kernel Library */
 
#define CV_PLUGIN_MAX   16
 
#define CV_PLUGINS1(lib1)   ((lib1)&15)
 
#define CV_PLUGINS2(lib1, lib2)   (((lib1)&15)|(((lib2)&15)<<4))
 
#define CV_PLUGINS3(lib1, lib2, lib3)   (((lib1)&15)|(((lib2)&15)<<4)|(((lib2)&15)<<8))
 
#define CV_NOTHROW   throw()
 
#define IPCVAPI(type, declspec, name, args)
 
#define IPCVAPI_EX(type, name, ipp_name, ipp_search_modules, args)   IPCVAPI(type,CV_STDCALL,name,args)
 
#define IPCVAPI_C_EX(type, name, ipp_name, ipp_search_modules, args)   IPCVAPI(type,CV_CDECL,name,args)
 
#define IPCVAPI_IMPL(type, name, args, arg_names)
 
#define CV_DEF_INIT_FUNC_TAB_2D(FUNCNAME, FLAG)
 
#define CV_DEF_INIT_BIG_FUNC_TAB_2D(FUNCNAME, FLAG)
 
#define CV_DEF_INIT_FUNC_TAB_0D(FUNCNAME)
 
#define CV_DEF_INIT_FUNC_TAB_1D   CV_DEF_INIT_FUNC_TAB_0D
 
#define CV_DEF_INIT_PIXSIZE_TAB_2D(FUNCNAME, FLAG)
 
#define CV_GET_FUNC_PTR(func, table_entry)
 

Typedefs

typedef enum CvStatus CvStatus
 
typedef enum CvDataType CvDataType
 
typedef enum CvHintAlgorithm CvHintAlgorithm
 
typedef enum CvCmpOp CvCmpOp
 
typedef struct CvFuncTable CvFuncTable
 
typedef struct CvBigFuncTable CvBigFuncTable
 
typedef struct CvBtFuncTable CvBtFuncTable
 
typedef CvStatus(CV_STDCALLCvFunc2D_1A )(void *arr, int step, CvSize size)
 
typedef CvStatus(CV_STDCALLCvFunc2D_1A1P )(void *arr, int step, CvSize size, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2D_1A1P1I )(void *arr, int step, CvSize size, void *param, int flag)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_1A1P )(void *arr, int step, CvSize size, int cn, int coi, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2D_1A2P )(void *arr, int step, CvSize size, void *param1, void *param2)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_1A2P )(void *arr, int step, CvSize size, int cn, int coi, void *param1, void *param2)
 
typedef CvStatus(CV_STDCALLCvFunc2D_1A4P )(void *arr, int step, CvSize size, void *param1, void *param2, void *param3, void *param4)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_1A4P )(void *arr, int step, CvSize size, int cn, int coi, void *param1, void *param2, void *param3, void *param4)
 
typedef CvStatus(CV_STDCALLCvFunc2D_2A )(void *arr0, int step0, void *arr1, int step1, CvSize size)
 
typedef CvStatus(CV_STDCALLCvFunc2D_2A1P )(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_2A1P )(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2D_2A2P )(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param1, void *param2)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_2A2P )(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param1, void *param2)
 
typedef CvStatus(CV_STDCALLCvFunc2D_2A1P1I )(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param, int flag)
 
typedef CvStatus(CV_STDCALLCvFunc2D_2A4P )(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param1, void *param2, void *param3, void *param4)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_2A4P )(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param1, void *param2, void *param3, void *param4)
 
typedef CvStatus(CV_STDCALLCvFunc2D_3A )(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size)
 
typedef CvStatus(CV_STDCALLCvFunc2D_3A1P )(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2D_3A1I )(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, int flag)
 
typedef CvStatus(CV_STDCALLCvFunc2DnC_3A1P )(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, int cn, int coi, void *param)
 
typedef CvStatus(CV_STDCALLCvFunc2D_4A )(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, void *arr3, int step3, CvSize size)
 
typedef CvStatus(CV_STDCALLCvFunc0D )(const void *src, void *dst, int param)
 

Enumerations

enum  CvStatus {
  CV_BADMEMBLOCK_ERR = -113, CV_INPLACE_NOT_SUPPORTED_ERR = -112, CV_UNMATCHED_ROI_ERR = -111, CV_NOTFOUND_ERR = -110,
  CV_BADCONVERGENCE_ERR = -109, CV_BADDEPTH_ERR = -107, CV_BADROI_ERR = -106, CV_BADHEADER_ERR = -105,
  CV_UNMATCHED_FORMATS_ERR = -104, CV_UNSUPPORTED_COI_ERR = -103, CV_UNSUPPORTED_CHANNELS_ERR = -102, CV_UNSUPPORTED_DEPTH_ERR = -101,
  CV_UNSUPPORTED_FORMAT_ERR = -100, CV_BADARG_ERR = -49, CV_NOTDEFINED_ERR = -48, CV_BADCHANNELS_ERR = -47,
  CV_BADRANGE_ERR = -44, CV_BADSTEP_ERR = -29, CV_BADFLAG_ERR = -12, CV_DIV_BY_ZERO_ERR = -11,
  CV_BADCOEF_ERR = -10, CV_BADFACTOR_ERR = -7, CV_BADPOINT_ERR = -6, CV_BADSCALE_ERR = -4,
  CV_OUTOFMEM_ERR = -3, CV_NULLPTR_ERR = -2, CV_BADSIZE_ERR = -1, CV_NO_ERR = 0,
  CV_OK = CV_NO_ERR
}
 
enum  CvDataType {
  cv1u, cv8u, cv8s, cv16u,
  cv16s, cv16sc, cv32u, cv32s,
  cv32sc, cv32f, cv32fc, cv64u,
  cv64s, cv64sc, cv64f, cv64fc
}
 
enum  CvHintAlgorithm { cvAlgHintNone, cvAlgHintFast, cvAlgHintAccurate }
 
enum  CvCmpOp {
  cvCmpLess, cvCmpLessEq, cvCmpEq, cvCmpGreaterEq,
  cvCmpGreater
}
 

Functions

CV_INLINE void * cvAlignPtr (const void *ptr, int align=32)
 
CV_INLINE int cvAlign (int size, int align)
 
CV_INLINE CvSize cvGetMatSize (const CvMat *mat)
 

Macro Definition Documentation

#define CV_1F   0x3f800000
#define CV_ADD (   a,
  b 
)    ((a) + (b))
#define CV_AND (   a,
  b 
)    ((a) & (b))
#define CV_ANDMASK (   m,
  x 
)    ((x) & (((m) == 0) - 1))
#define CV_ANDN (   a,
  b 
)    (~(a) & (b))
#define CV_BIG_INT (   n)    n##LL
#define CV_BIG_UINT (   n)    n##ULL
#define CV_CAST_16S (   t)    (short)(!(((t)+32768) & ~65535) ? (t) : (t) > 0 ? 32767 : -32768)
#define CV_CAST_16U (   t)    (ushort)(!((t) & ~65535) ? (t) : (t) > 0 ? 65535 : 0)
#define CV_CAST_32F (   t)    (float)(t)
#define CV_CAST_32S (   t)    (int)(t)
#define CV_CAST_64F (   t)    (double)(t)
#define CV_CAST_64S (   t)    (int64)(t)
#define CV_CAST_8S (   t)    (schar)(!(((t)+128) & ~255) ? (t) : (t) > 0 ? 127 : -128)
#define CV_CAST_8U (   t)    (uchar)(!((t) & ~255) ? (t) : (t) > 0 ? 255 : 0)
#define CV_CHECK_NANS (   arr)
#define CV_DBG_BREAK ( )    { volatile int* crashMe = 0; *crashMe = 0; }
#define CV_DEF_INIT_BIG_FUNC_TAB_2D (   FUNCNAME,
  FLAG 
)
#define CV_DEF_INIT_FUNC_TAB_0D (   FUNCNAME)
Value:
static void icvInit##FUNCNAME##Table( CvFuncTable* tab ) \
{ \
tab->fn_2d[CV_8U] = (void*)icv##FUNCNAME##_8u; \
tab->fn_2d[CV_8S] = (void*)icv##FUNCNAME##_8s; \
tab->fn_2d[CV_16U] = (void*)icv##FUNCNAME##_16u; \
tab->fn_2d[CV_16S] = (void*)icv##FUNCNAME##_16s; \
tab->fn_2d[CV_32S] = (void*)icv##FUNCNAME##_32s; \
tab->fn_2d[CV_32F] = (void*)icv##FUNCNAME##_32f; \
tab->fn_2d[CV_64F] = (void*)icv##FUNCNAME##_64f; \
}
#define CV_DEF_INIT_FUNC_TAB_1D   CV_DEF_INIT_FUNC_TAB_0D
#define CV_DEF_INIT_FUNC_TAB_2D (   FUNCNAME,
  FLAG 
)
Value:
static void icvInit##FUNCNAME##FLAG##Table( CvFuncTable* tab ) \
{ \
assert( tab ); \
\
tab->fn_2d[CV_8U] = (void*)icv##FUNCNAME##_8u_##FLAG; \
tab->fn_2d[CV_8S] = (void*)icv##FUNCNAME##_8s_##FLAG; \
tab->fn_2d[CV_16U] = (void*)icv##FUNCNAME##_16u_##FLAG; \
tab->fn_2d[CV_16S] = (void*)icv##FUNCNAME##_16s_##FLAG; \
tab->fn_2d[CV_32S] = (void*)icv##FUNCNAME##_32s_##FLAG; \
tab->fn_2d[CV_32F] = (void*)icv##FUNCNAME##_32f_##FLAG; \
tab->fn_2d[CV_64F] = (void*)icv##FUNCNAME##_64f_##FLAG; \
}
#define CV_DEF_INIT_PIXSIZE_TAB_2D (   FUNCNAME,
  FLAG 
)
Value:
static void icvInit##FUNCNAME##FLAG##Table( CvBtFuncTable* table ) \
{ \
table->fn_2d[1] = (void*)icv##FUNCNAME##_8u_C1##FLAG; \
table->fn_2d[2] = (void*)icv##FUNCNAME##_8u_C2##FLAG; \
table->fn_2d[3] = (void*)icv##FUNCNAME##_8u_C3##FLAG; \
table->fn_2d[4] = (void*)icv##FUNCNAME##_16u_C2##FLAG; \
table->fn_2d[6] = (void*)icv##FUNCNAME##_16u_C3##FLAG; \
table->fn_2d[8] = (void*)icv##FUNCNAME##_32s_C2##FLAG; \
table->fn_2d[12] = (void*)icv##FUNCNAME##_32s_C3##FLAG; \
table->fn_2d[16] = (void*)icv##FUNCNAME##_64s_C2##FLAG; \
table->fn_2d[24] = (void*)icv##FUNCNAME##_64s_C3##FLAG; \
table->fn_2d[32] = (void*)icv##FUNCNAME##_64s_C4##FLAG; \
}
#define CV_DEFAULT_IMAGE_ROW_ALIGN   4
#define CV_DEFAULT_MAT_ROW_ALIGN   1
#define CV_DEFINE_MASK   float maskTab[2]; maskTab[0] = 0.f; maskTab[1] = 1.f;
#define CV_DESCALE (   x,
  n 
)    (((x) + (1 << ((n)-1))) >> (n))
#define CV_DIM (   static_array)    ((int)(sizeof(static_array)/sizeof((static_array)[0])))
#define CV_EMPTY
#define CV_EQ (   a,
  b 
)    ((a) == (b))
#define CV_ERROR_FROM_STATUS (   result)    CV_ERROR( cvErrorFromIppStatus( result ), "OpenCV function failed" )
#define CV_FLT_TO_FIX (   x,
  n 
)    cvRound((x)*(1<<(n)))
#define CV_GE (   a,
  b 
)    ((a) >= (b))
#define CV_GET_FUNC_PTR (   func,
  table_entry 
)
Value:
func = (table_entry); \
if( !func ) \
CV_ERROR( CV_StsUnsupportedFormat, "" )
#define CV_GT (   a,
  b 
)    ((a) > (b))
#define CV_IMPL   CV_EXTERN_C
#define CV_IMPLEMENT_QSORT (   func_name,
  T,
  cmp 
)    CV_IMPLEMENT_QSORT_EX( func_name, T, cmp, int )
#define CV_IMPLEMENT_QSORT_EX (   func_name,
  T,
  LT,
  user_data_type 
)
#define CV_LE (   a,
  b 
)    ((a) <= (b))
#define CV_LT (   a,
  b 
)    ((a) < (b))
#define CV_MAKE_STR (   a)    #a
#define CV_MALLOC_ALIGN   32
#define CV_MAX_ALLOC_SIZE   (((size_t)1 << (sizeof(size_t)*8-2)))
#define CV_MAX_INLINE_MAT_OP_SIZE   10
#define CV_MAX_LOCAL_MAT_SIZE   32
#define CV_MAX_LOCAL_SIZE   (CV_MAX_LOCAL_MAT_SIZE*CV_MAX_LOCAL_MAT_SIZE*(int)sizeof(double))
#define CV_MAX_STRLEN   1024
#define CV_MAX_THREADS   1
#define CV_MEMCPY_AUTO (   dst,
  src,
  len 
)
Value:
{ \
size_t _icv_memcpy_i_, _icv_memcpy_len_ = (len); \
char* _icv_memcpy_dst_ = (char*)(dst); \
const char* _icv_memcpy_src_ = (const char*)(src); \
if( (_icv_memcpy_len_ & (sizeof(int)-1)) == 0 ) \
{ \
assert( ((size_t)_icv_memcpy_src_&(sizeof(int)-1)) == 0 && \
((size_t)_icv_memcpy_dst_&(sizeof(int)-1)) == 0 ); \
for( _icv_memcpy_i_ = 0; _icv_memcpy_i_ < _icv_memcpy_len_; \
_icv_memcpy_i_+=sizeof(int) ) \
{ \
*(int*)(_icv_memcpy_dst_+_icv_memcpy_i_) = \
*(const int*)(_icv_memcpy_src_+_icv_memcpy_i_); \
} \
} \
else \
{ \
for(_icv_memcpy_i_ = 0; _icv_memcpy_i_ < _icv_memcpy_len_; _icv_memcpy_i_++)\
_icv_memcpy_dst_[_icv_memcpy_i_] = _icv_memcpy_src_[_icv_memcpy_i_]; \
} \
}
#define CV_MEMCPY_CHAR (   dst,
  src,
  len 
)
Value:
{ \
size_t _icv_memcpy_i_, _icv_memcpy_len_ = (len); \
char* _icv_memcpy_dst_ = (char*)(dst); \
const char* _icv_memcpy_src_ = (const char*)(src); \
for( _icv_memcpy_i_ = 0; _icv_memcpy_i_ < _icv_memcpy_len_; _icv_memcpy_i_++ ) \
_icv_memcpy_dst_[_icv_memcpy_i_] = _icv_memcpy_src_[_icv_memcpy_i_]; \
}
#define CV_MEMCPY_INT (   dst,
  src,
  len 
)
Value:
{ \
size_t _icv_memcpy_i_, _icv_memcpy_len_ = (len); \
int* _icv_memcpy_dst_ = (int*)(dst); \
const int* _icv_memcpy_src_ = (const int*)(src); \
assert( ((size_t)_icv_memcpy_src_&(sizeof(int)-1)) == 0 && \
((size_t)_icv_memcpy_dst_&(sizeof(int)-1)) == 0 ); \
for(_icv_memcpy_i_=0;_icv_memcpy_i_<_icv_memcpy_len_;_icv_memcpy_i_++) \
_icv_memcpy_dst_[_icv_memcpy_i_] = _icv_memcpy_src_[_icv_memcpy_i_]; \
}
#define CV_MUL (   a,
  b 
)    ((a) * (b))
#define CV_MULMASK (   m,
  x 
)    (maskTab[(m) != 0]*(x))
#define CV_MULMASK1 (   m,
  x 
)    (maskTab[(m)+1]*(x))
#define CV_NE (   a,
  b 
)    ((a) != (b))
#define CV_NEG_INF   0x807fffff /* CV_TOGGLE_FLT(0xff800000) */
#define CV_NONZERO (   a)    ((a) != 0)
#define CV_NONZERO_FLT (   a)    (((a)+(a)) != 0)
#define CV_NOP (   a)    (a)
#define CV_NOTHROW   throw()
#define CV_OR (   a,
  b 
)    ((a) | (b))
#define CV_ORIGIN_BL   1
#define CV_ORIGIN_TL   0
#define CV_ORN (   a,
  b 
)    (~(a) | (b))
#define CV_PASTE (   a,
  b 
)    CV_PASTE2(a,b)
#define CV_PASTE2 (   a,
  b 
)    a##b
#define CV_PLUGIN_IPPCC   6 /* IPP: color space conversion */
#define CV_PLUGIN_IPPCV   2 /* IPP: computer vision */
#define CV_PLUGIN_IPPI   3 /* IPP: image processing */
#define CV_PLUGIN_IPPS   4 /* IPP: signal processing */
#define CV_PLUGIN_IPPVM   5 /* IPP: vector math functions */
#define CV_PLUGIN_MAX   16
#define CV_PLUGIN_MKL   8 /* Intel Math Kernel Library */
#define CV_PLUGIN_NONE   0
#define CV_PLUGIN_OPTCV   1 /* custom "emerged" ippopencv library */
#define CV_PLUGINS1 (   lib1)    ((lib1)&15)
#define CV_PLUGINS2 (   lib1,
  lib2 
)    (((lib1)&15)|(((lib2)&15)<<4))
#define CV_PLUGINS3 (   lib1,
  lib2,
  lib3 
)    (((lib1)&15)|(((lib2)&15)<<4)|(((lib2)&15)<<8))
#define CV_POS_INF   0x7f800000
#define CV_SIZEOF_FLOAT   ((int)sizeof(float))
#define CV_SIZEOF_SHORT   ((int)sizeof(short))
#define CV_SPARSE_HASH_RATIO   3
#define CV_SPARSE_HASH_SIZE0   (1<<10)
#define CV_SPARSE_MAT_BLOCK   (1<<12)
#define CV_SQR (   a)    ((a) * (a))
#define CV_STORAGE_BLOCK_SIZE   ((1<<16) - 128)
#define CV_STRUCT_ALIGN   ((int)sizeof(double))
#define CV_STUB_STEP   (1 << 30)
#define CV_SUB (   a,
  b 
)    ((a) - (b))
#define CV_TOGGLE_DBL (   x)    ((x)^((int64)(x) < 0 ? CV_BIG_INT(0x7fffffffffffffff) : 0))
#define CV_TOGGLE_FLT (   x)    ((x)^((int)(x) < 0 ? 0x7fffffff : 0))
#define CV_UN_ENTRY_C1 (   worktype)    worktype s0 = scalar[0]
#define CV_UN_ENTRY_C2 (   worktype)    worktype s0 = scalar[0], s1 = scalar[1]
#define CV_UN_ENTRY_C3 (   worktype)    worktype s0 = scalar[0], s1 = scalar[1], s2 = scalar[2]
#define CV_UN_ENTRY_C4 (   worktype)    worktype s0 = scalar[0], s1 = scalar[1], s2 = scalar[2], s3 = scalar[3]
#define CV_XOR (   a,
  b 
)    ((a) ^ (b))
#define CV_ZERO_CHAR (   dst,
  len 
)
Value:
{ \
size_t _icv_memcpy_i_, _icv_memcpy_len_ = (len); \
char* _icv_memcpy_dst_ = (char*)(dst); \
for( _icv_memcpy_i_ = 0; _icv_memcpy_i_ < _icv_memcpy_len_; _icv_memcpy_i_++ ) \
_icv_memcpy_dst_[_icv_memcpy_i_] = '\0'; \
}
#define CV_ZERO_INT (   dst,
  len 
)
Value:
{ \
size_t _icv_memcpy_i_, _icv_memcpy_len_ = (len); \
int* _icv_memcpy_dst_ = (int*)(dst); \
assert( ((size_t)_icv_memcpy_dst_&(sizeof(int)-1)) == 0 ); \
for(_icv_memcpy_i_=0;_icv_memcpy_i_<_icv_memcpy_len_;_icv_memcpy_i_++) \
_icv_memcpy_dst_[_icv_memcpy_i_] = 0; \
}
#define CV_ZERO_OBJ (   x)    memset((x), 0, sizeof(*(x)))
#define cvStackAlloc (   size)    cvAlignPtr( alloca((size) + CV_MALLOC_ALIGN), CV_MALLOC_ALIGN )
#define cvUnsupportedFormat   "Unsupported format"
#define IPCVAPI (   type,
  declspec,
  name,
  args 
)
Value:
/* function pointer */ \
typedef type (declspec* name##_t) args; \
extern name##_t name##_p; \
type declspec name args;
#define IPCVAPI_C_EX (   type,
  name,
  ipp_name,
  ipp_search_modules,
  args 
)    IPCVAPI(type,CV_CDECL,name,args)
#define IPCVAPI_EX (   type,
  name,
  ipp_name,
  ipp_search_modules,
  args 
)    IPCVAPI(type,CV_STDCALL,name,args)
#define IPCVAPI_IMPL (   type,
  name,
  args,
  arg_names 
)
Value:
static type CV_STDCALL name##_f args; \
name##_t name##_p = name##_f; \
type CV_STDCALL name args { return name##_p arg_names; } \
static type CV_STDCALL name##_f args
#define IPPI_CALL (   Func)
Value:
{ \
CvStatus ippi_call_result; \
ippi_call_result = Func; \
if( ippi_call_result < 0 ) \
CV_ERROR_FROM_STATUS( (ippi_call_result)); \
}

Typedef Documentation

typedef struct CvBtFuncTable CvBtFuncTable
typedef enum CvCmpOp CvCmpOp
typedef enum CvDataType CvDataType
typedef CvStatus(CV_STDCALL * CvFunc0D)(const void *src, void *dst, int param)
typedef CvStatus(CV_STDCALL * CvFunc2D_1A)(void *arr, int step, CvSize size)
typedef CvStatus(CV_STDCALL * CvFunc2D_1A1P)(void *arr, int step, CvSize size, void *param)
typedef CvStatus(CV_STDCALL * CvFunc2D_1A1P1I)(void *arr, int step, CvSize size, void *param, int flag)
typedef CvStatus(CV_STDCALL * CvFunc2D_1A2P)(void *arr, int step, CvSize size, void *param1, void *param2)
typedef CvStatus(CV_STDCALL * CvFunc2D_1A4P)(void *arr, int step, CvSize size, void *param1, void *param2, void *param3, void *param4)
typedef CvStatus(CV_STDCALL * CvFunc2D_2A)(void *arr0, int step0, void *arr1, int step1, CvSize size)
typedef CvStatus(CV_STDCALL * CvFunc2D_2A1P)(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param)
typedef CvStatus(CV_STDCALL * CvFunc2D_2A1P1I)(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param, int flag)
typedef CvStatus(CV_STDCALL * CvFunc2D_2A2P)(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param1, void *param2)
typedef CvStatus(CV_STDCALL * CvFunc2D_2A4P)(void *arr0, int step0, void *arr1, int step1, CvSize size, void *param1, void *param2, void *param3, void *param4)
typedef CvStatus(CV_STDCALL * CvFunc2D_3A)(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size)
typedef CvStatus(CV_STDCALL * CvFunc2D_3A1I)(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, int flag)
typedef CvStatus(CV_STDCALL * CvFunc2D_3A1P)(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, void *param)
typedef CvStatus(CV_STDCALL * CvFunc2D_4A)(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, void *arr3, int step3, CvSize size)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_1A1P)(void *arr, int step, CvSize size, int cn, int coi, void *param)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_1A2P)(void *arr, int step, CvSize size, int cn, int coi, void *param1, void *param2)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_1A4P)(void *arr, int step, CvSize size, int cn, int coi, void *param1, void *param2, void *param3, void *param4)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_2A1P)(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_2A2P)(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param1, void *param2)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_2A4P)(void *arr0, int step0, void *arr1, int step1, CvSize size, int cn, int coi, void *param1, void *param2, void *param3, void *param4)
typedef CvStatus(CV_STDCALL * CvFunc2DnC_3A1P)(void *arr0, int step0, void *arr1, int step1, void *arr2, int step2, CvSize size, int cn, int coi, void *param)
typedef struct CvFuncTable CvFuncTable
typedef CvStatus

Enumeration Type Documentation

enum CvCmpOp
Enumerator
cvCmpLess 
cvCmpLessEq 
cvCmpEq 
cvCmpGreaterEq 
cvCmpGreater 
enum CvDataType
Enumerator
cv1u 
cv8u 
cv8s 
cv16u 
cv16s 
cv16sc 
cv32u 
cv32s 
cv32sc 
cv32f 
cv32fc 
cv64u 
cv64s 
cv64sc 
cv64f 
cv64fc 
Enumerator
cvAlgHintNone 
cvAlgHintFast 
cvAlgHintAccurate 
enum CvStatus
Enumerator
CV_BADMEMBLOCK_ERR 
CV_INPLACE_NOT_SUPPORTED_ERR 
CV_UNMATCHED_ROI_ERR 
CV_NOTFOUND_ERR 
CV_BADCONVERGENCE_ERR 
CV_BADDEPTH_ERR 
CV_BADROI_ERR 
CV_BADHEADER_ERR 
CV_UNMATCHED_FORMATS_ERR 
CV_UNSUPPORTED_COI_ERR 
CV_UNSUPPORTED_CHANNELS_ERR 
CV_UNSUPPORTED_DEPTH_ERR 
CV_UNSUPPORTED_FORMAT_ERR 
CV_BADARG_ERR 
CV_NOTDEFINED_ERR 
CV_BADCHANNELS_ERR 
CV_BADRANGE_ERR 
CV_BADSTEP_ERR 
CV_BADFLAG_ERR 
CV_DIV_BY_ZERO_ERR 
CV_BADCOEF_ERR 
CV_BADFACTOR_ERR 
CV_BADPOINT_ERR 
CV_BADSCALE_ERR 
CV_OUTOFMEM_ERR 
CV_NULLPTR_ERR 
CV_BADSIZE_ERR 
CV_NO_ERR 
CV_OK 

Function Documentation

CV_INLINE int cvAlign ( int  size,
int  align 
)
CV_INLINE void* cvAlignPtr ( const void *  ptr,
int  align = 32 
)
CV_INLINE CvSize cvGetMatSize ( const CvMat mat)