http://www.emgu.com

The CvInvoke type exposes the following members.

Methods

  NameDescription
Public methodStatic memberApplyColorMap
Apply color map to the image
Public methodStatic memberCV_FOURCC
Generate 4-character code of codec used to compress the frames. For example, CV_FOURCC('P','I','M','1') is MPEG-1 codec, CV_FOURCC('M','J','P','G') is motion-jpeg codec etc.
Public methodStatic memberCV_IS_SET_ELEM
Determined whether the specified node is occupied or not
Public methodStatic memberCV_MAKETYPE
This function performs the same as CV_MAKETYPE macro
Public methodStatic memberCV_NEXT_SEQ_ELEM
Move to the next element in the sequence
Public methodStatic memberCV_READ_SEQ_ELEM<(Of <<'(T>)>>)
forward reading the sequence reader
Public methodStatic membercv2DRotationMatrix
Calculates rotation matrix
Public methodStatic membercvAbsDiff
Calculates absolute difference between two arrays. dst(I)c = abs(src1(I)c - src2(I)c). All the arrays must have the same data type and the same size (or ROI size)
Public methodStatic membercvAbsDiffS
Calculates absolute difference between array and scalar
Public methodStatic membercvAcc
Adds the whole image or its selected region to accumulator sum
Public methodStatic membercvAdaptiveThreshold
Transforms grayscale image to binary image. Threshold calculated individually for each pixel. For the method CV_ADAPTIVE_THRESH_MEAN_C it is a mean of blockSize x blockSize pixel neighborhood, subtracted by param1. For the method CV_ADAPTIVE_THRESH_GAUSSIAN_C it is a weighted sum (gaussian) of blockSize x blockSize pixel neighborhood, subtracted by param1.
Public methodStatic membercvAdd
Adds one array to another one: dst(I)=src1(I)+src2(I) if mask(I)!=0All the arrays must have the same type, except the mask, and the same size (or ROI size)
Public methodStatic membercvAddS
Adds scalar value to every element in the source array src1 and stores the result in dst dst(I)=src(I)+value if mask(I)!=0 All the arrays must have the same type, except the mask, and the same size (or ROI size)
Public methodStatic membercvAddWeighted
Calculated weighted sum of two arrays as following: dst(I)=src1(I)*alpha+src2(I)*beta+gamma All the arrays must have the same type and the same size (or ROI size)
Public methodStatic membercvAnd
Calculates per-element bit-wise logical conjunction of two arrays: dst(I)=src1(I) & src2(I) if mask(I)!=0 In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvAndS
Calculates per-element bit-wise conjunction of array and scalar: dst(I)=src(I)&value if mask(I)!=0 Prior to the actual operation the scalar is converted to the same type as the arrays. In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvApproxPoly
Approximates one or more curves and returns the approximation result[s]. In case of multiple curves approximation the resultant tree will have the same structure as the input one (1:1 correspondence).
Public methodStatic membercvArcLength
Calculates length or curve as sum of lengths of segments between subsequent points
Public methodStatic membercvAvg
Calculates the average value M of array elements, independently for each channel: N = sumI mask(I)!=0 Mc = 1/N * sumI,mask(I)!=0 arr(I)c If the array is IplImage and COI is set, the function processes the selected channel only and stores the average to the first scalar component (S0).
Public methodStatic membercvAvgSdv
The function cvAvgSdv calculates the average value and standard deviation of array elements, independently for each channel
Public methodStatic membercvBGCodeBookClearStale(IntPtr, Int32, Rectangle, IntPtr)
Public methodStatic membercvBGCodeBookClearStale(MCvBGCodeBookModel%, Int32, Rectangle, IntPtr)
Public methodStatic membercvBGCodeBookDiff(IntPtr, IntPtr, IntPtr, Rectangle)
Public methodStatic membercvBGCodeBookDiff(MCvBGCodeBookModel%, IntPtr, IntPtr, Rectangle)
Public methodStatic membercvBGCodeBookUpdate(IntPtr, IntPtr, Rectangle, IntPtr)
Update the BG code book model
Public methodStatic membercvBGCodeBookUpdate(MCvBGCodeBookModel%, IntPtr, Rectangle, IntPtr)
Update the BG code book model
Public methodStatic membercvBoundingRect(IntPtr, Boolean)
Returns the up-right bounding rectangle for 2d point set
Public methodStatic membercvBoundingRect(IntPtr, Int32)
Returns the up-right bounding rectangle for 2d point set
Public methodStatic membercvBoxPoints(MCvBox2D, array<PointF>[]()[][])
Calculates vertices of the input 2d box.
Public methodStatic membercvBoxPoints(MCvBox2D, array<Single>[]()[][])
Calculates vertices of the input 2d box.
Public methodStatic membercvCalcArrBackProject
Calculates the back project of the histogram. For each tuple of pixels at the same position of all input single-channel images the function puts the value of the histogram bin, corresponding to the tuple, to the destination image. In terms of statistics, the value of each output image pixel is probability of the observed tuple given the distribution (histogram).
Public methodStatic membercvCalcArrHist(array<IntPtr>[]()[][], IntPtr, Boolean, IntPtr)
Calculates the histogram of one or more single-channel images. The elements of a tuple that is used to increment a histogram bin are taken at the same location from the corresponding input images.
Public methodStatic membercvCalcArrHist(array<IntPtr>[]()[][], IntPtr, Int32, IntPtr)
Calculates the histogram of one or more single-channel images. The elements of a tuple that is used to increment a histogram bin are taken at the same location from the corresponding input images.
Public methodStatic membercvCalcBackProject
Calculates the back project of the histogram. For each tuple of pixels at the same position of all input single-channel images the function puts the value of the histogram bin, corresponding to the tuple, to the destination image. In terms of statistics, the value of each output image pixel is probability of the observed tuple given the distribution (histogram).
Public methodStatic membercvCalcBackProjectPatch
Compares histogram, computed over each possible rectangular patch of the specified size in the input images, and stores the results to the output map dst.
Public methodStatic membercvCalcCovarMatrix
Calculates the covariation matrix and, optionally, mean vector of the set of input vectors.
Public methodStatic membercvCalcEigenObjects
Calculates orthonormal eigen basis and the averaged object for a group of the input objects.
Public methodStatic membercvCalcEMD2
Computes earth mover distance and/or a lower boundary of the distance between the two weighted point configurations. One of the application described in [RubnerSept98] is multi-dimensional histogram comparison for image retrieval. EMD is a transportation problem that is solved using some modification of simplex algorithm, thus the complexity is exponential in the worst case, though, it is much faster in average. In case of a real metric the lower boundary can be calculated even faster (using linear-time algorithm) and it can be used to determine roughly whether the two signatures are far enough so that they cannot relate to the same object.
Public methodStatic membercvCalcGlobalOrientation
Calculates the general motion direction in the selected region and returns the angle between 0 and 360. At first the function builds the orientation histogram and finds the basic orientation as a coordinate of the histogram maximum. After that the function calculates the shift relative to the basic orientation as a weighted sum of all orientation vectors: the more recent is the motion, the greater is the weight. The resultant angle is a circular sum of the basic orientation and the shift.
Public methodStatic membercvCalcHist
Calculates the histogram of one or more single-channel images. The elements of a tuple that is used to increment a histogram bin are taken at the same location from the corresponding input images.
Public methodStatic membercvCalcMotionGradient
Calculates the derivatives Dx and Dy of mhi and then calculates gradient orientation as: orientation(x,y)=arctan(Dy(x,y)/Dx(x,y)) where both Dx(x,y)' and Dy(x,y)' signs are taken into account (as in cvCartToPolar function). After that mask is filled to indicate where the orientation is valid (see delta1 and delta2 description).
Public methodStatic membercvCalcOpticalFlowBM
Calculates optical flow for overlapped blocks block_size.width * block_size.height pixels each, thus the velocity fields are smaller than the original images. For every block in prev the functions tries to find a similar block in curr in some neighborhood of the original block or shifted by (velx(x0,y0),vely(x0,y0)) block as has been calculated by previous function call (if use_previous=1)
Public methodStatic membercvCalcOpticalFlowFarneback
Computes dense optical flow using Gunnar Farneback's algorithm
Public methodStatic membercvCalcOpticalFlowHS
Computes flow for every pixel of the first input image using Horn & Schunck algorithm
Public methodStatic membercvCalcOpticalFlowLK
Computes flow for every pixel of the first input image using Lucas & Kanade algorithm
Public methodStatic membercvCalcOpticalFlowPyrLK(IntPtr, IntPtr, IntPtr, IntPtr, array<PointF>[]()[][], array<PointF>[]()[][], Int32, Size, Int32, array<Byte>[]()[][], array<Single>[]()[][], MCvTermCriteria, LKFLOW_TYPE)
Implements sparse iterative version of Lucas-Kanade optical flow in pyramids ([Bouguet00]). It calculates coordinates of the feature points on the current video frame given their coordinates on the previous frame. The function finds the coordinates with sub-pixel accuracy.
Public methodStatic membercvCalcOpticalFlowPyrLK(IntPtr, IntPtr, IntPtr, IntPtr, array<Single,2>[,](,)[,][,], array<Single,2>[,](,)[,][,], Int32, Size, Int32, array<Byte>[]()[][], array<Single>[]()[][], MCvTermCriteria, LKFLOW_TYPE)
Implements sparse iterative version of Lucas-Kanade optical flow in pyramids ([Bouguet00]). It calculates coordinates of the feature points on the current video frame given their coordinates on the previous frame. The function finds the coordinates with sub-pixel accuracy.
Public methodStatic membercvCalcPCA
Performs PCA analysis of the vector set. First, it uses cvCalcCovarMatrix to compute covariation matrix and then it finds its eigenvalues and eigenvectors. The output number of eigenvalues/eigenvectors should be less than or equal to MIN(rows(data),cols(data)).
Public methodStatic membercvCalcPGH
Calculates 2D pair-wise geometrical histogram (PGH), described in [Iivarinen97], for the contour. The algorithm considers every pair of the contour edges. The angle between the edges and the minimum/maximum distances are determined for every pair. To do this each of the edges in turn is taken as the base, while the function loops through all the other edges. When the base edge and any other edge are considered, the minimum and maximum distances from the points on the non-base edge and line of the base edge are selected. The angle between the edges defines the row of the histogram in which all the bins that correspond to the distance between the calculated minimum and maximum distances are incremented (that is, the histogram is transposed relatively to [Iivarninen97] definition). The histogram can be used for contour matching
Public methodStatic membercvCalcProbDensity
calculates the object probability density from the two histograms as: dist_hist(I)=0, if hist1(I)==0; dist_hist(I)=scale, if hist1(I)!=0 && hist2(I)>hist1(I); dist_hist(I)=hist2(I)*scale/hist1(I), if hist1(I)!=0 && hist2(I)<=hist1(I)
Public methodStatic membercvCalcSubdivVoronoi2D
Calculates coordinates of virtual points. All virtual points corresponding to some vertex of original subdivision form (when connected together) a boundary of Voronoi cell of that point
Public methodStatic membercvCalibrateCamera2
Estimates intrinsic camera parameters and extrinsic parameters for each of the views
Public methodStatic membercvCalibrationMatrixValues
Computes various useful camera (sensor/lens) characteristics using the computed camera calibration matrix, image frame resolution in pixels and the physical aperture size
Public methodStatic membercvCamShift
Implements CAMSHIFT object tracking algorithm ([Bradski98]). First, it finds an object center using cvMeanShift and, after that, calculates the object size and orientation.
Public methodStatic membercvCanny
Finds the edges on the input image and marks them in the output image edges using the Canny algorithm. The smallest of threshold1 and threshold2 is used for edge linking, the largest - to find initial segments of strong edges.
Public methodStatic membercvCartToPolar(IntPtr, IntPtr, IntPtr, IntPtr, Boolean)
Calculates either magnitude, angle, or both of every 2d vector (x(I),y(I)): magnitude(I)=sqrt( x(I)2+y(I)2 ), angle(I)=atan( y(I)/x(I) ) The angles are calculated with ~0.1 degree accuracy. For (0,0) point the angle is set to 0
Public methodStatic membercvCartToPolar(IntPtr, IntPtr, IntPtr, IntPtr, Int32)
Calculates either magnitude, angle, or both of every 2d vector (x(I),y(I)): magnitude(I)=sqrt( x(I)2+y(I)2 ), angle(I)=atan( y(I)/x(I) ) The angles are calculated with ~0.1 degree accuracy. For (0,0) point the angle is set to 0
Public methodStatic membercvChangeSeqBlock
Public methodStatic membercvCheckArr
Checks that every array element is neither NaN nor Infinity. If CV_CHECK_RANGE is set, it also checks that every element is greater than or equal to minVal and less than maxVal.
Public methodStatic membercvCheckContourConvexity
Tests whether the input contour is convex or not. The contour must be simple, i.e. without self-intersections.
Public methodStatic membercvCircle
Draws a simple or filled circle with given center and radius. The circle is clipped by ROI rectangle.
Public methodStatic membercvClearHist
Sets all histogram bins to 0 in case of dense histogram and removes all histogram bins in case of sparse array
Public methodStatic membercvClearMemStorage
Resets the top (free space boundary) of the storage to the very beginning. This function does not deallocate any memory. If the storage has a parent, the function returns all blocks to the parent.
Public methodStatic membercvClearND
Clears (sets to zero) the particular element of dense array or deletes the element of sparse array. If the element does not exists, the function does nothing
Public methodStatic membercvClearSeq
Removes all elements from the sequence. The function does not return the memory to the storage, but this memory is reused later when new elements are added to the sequence. This function time complexity is O(1).
Public methodStatic membercvClipLine
Calculates a part of the line segment which is entirely in the image. It returns 0 if the line segment is completely outside the image and 1 otherwise.
Public methodStatic membercvCmp
Compares the corresponding elements of two arrays and fills the destination mask array: dst(I)=src1(I) op src2(I), dst(I) is set to 0xff (all '1'-bits) if the particular relation between the elements is true and 0 otherwise. All the arrays must have the same type, except the destination, and the same size (or ROI size)
Public methodStatic membercvCmpS
Compares the corresponding elements of array and scalar and fills the destination mask array: dst(I)=src(I) op scalar, where op is '=', '>', '>=', '<', '<=' or '!='. dst(I) is set to 0xff (all '1'-bits) if the particular relation between the elements is true and 0 otherwise. All the arrays must have the same size (or ROI size)
Public methodStatic membercvCompareHist
Compares two dense histograms
Public methodStatic membercvComputeCorrespondEpilines
For every point in one of the two images of stereo-pair the function cvComputeCorrespondEpilines finds equation of a line that contains the corresponding point (i.e. projection of the same 3D point) in the other image. Each line is encoded by a vector of 3 elements l=[a,b,c]^T, so that: l^T*[x, y, 1]^T=0, or a*x + b*y + c = 0 From the fundamental matrix definition (see cvFindFundamentalMatrix discussion), line l2 for a point p1 in the first image (which_image=1) can be computed as: l2=F*p1 and the line l1 for a point p2 in the second image (which_image=1) can be computed as: l1=F^T*p2Line coefficients are defined up to a scale. They are normalized (a2+b2=1) are stored into correspondent_lines
Public methodStatic membercvConDensInitSampleSet
Fills the samples arrays in the structure CvConDensation with values within specified ranges.
Public methodStatic membercvConDensUpdateByTime
Estimates the subsequent stochastic model state from its current state
Public methodStatic membercvContourArea
Calculates area of the whole contour or contour section.
Public methodStatic membercvContourFromContourTree
Return the contour from its binary tree representation
Public methodStatic membercvContourPerimeter
Find the perimeter of the contour
Public methodStatic membercvConvert
Same as cvConvertScale(src, dest, 1, 0);
Public methodStatic membercvConvertPointsHomogeneous
Converts 2D or 3D points from/to homogeneous coordinates, or simply copies or transposes the array. In case if the input array dimensionality is larger than the output, each point coordinates are divided by the last coordinate
Public methodStatic membercvConvertScale
This function has several different purposes and thus has several synonyms. It copies one array to another with optional scaling, which is performed first, and/or optional type conversion, performed after: dst(I)=src(I)*scale + (shift,shift,...) All the channels of multi-channel arrays are processed independently. The type conversion is done with rounding and saturation, that is if a result of scaling + conversion can not be represented exactly by a value of destination array element type, it is set to the nearest representable value on the real axis. In case of scale=1, shift=0 no prescaling is done. This is a specially optimized case and it has the appropriate cvConvert synonym. If source and destination array types have equal types, this is also a special case that can be used to scale and shift a matrix or an image and that fits to cvScale synonym.
Public methodStatic membercvConvertScaleAbs
Similar to cvCvtScale but it stores absolute values of the conversion results: dst(I)=abs(src(I)*scale + (shift,shift,...)) The function supports only destination arrays of 8u (8-bit unsigned integers) type, for other types the function can be emulated by combination of cvConvertScale and cvAbs functions.
Public methodStatic membercvConvexHull2
The function cvConvexHull2 finds convex hull of 2D point set using Sklansky's algorithm.
Public methodStatic membercvConvexityDefects
Finds all convexity defects of the input contour and returns a sequence of the CvConvexityDefect structures.
Public methodStatic membercvCopy
Copies selected elements from input array to output array: dst(I)=src(I) if mask(I)!=0. If any of the passed arrays is of IplImage type, then its ROI and COI fields are used. Both arrays must have the same type, the same number of dimensions and the same size. The function can also copy sparse arrays (mask is not supported in this case).
Public methodStatic membercvCopyHist
Makes a copy of the histogram. If the second histogram pointer *dst is NULL, a new histogram of the same size as src is created. Otherwise, both histograms must have equal types and sizes. Then the function copies the source histogram bins values to destination histogram and sets the same bin values ranges as in src.
Public methodStatic membercvCopyMakeBorder
Copies the source 2D array into interior of destination array and makes a border of the specified type around the copied area. The function is useful when one needs to emulate border type that is different from the one embedded into a specific algorithm implementation. For example, morphological functions, as well as most of other filtering functions in OpenCV, internally use replication border type, while the user may need zero border or a border, filled with 1's or 255's
Public methodStatic membercvCornerHarris
Runs the Harris edge detector on image. Similarly to cvCornerMinEigenVal and cvCornerEigenValsAndVecs, for each pixel it calculates 2x2 gradient covariation matrix M over block_size x block_size neighborhood. Then, it stores det(M) - k*trace(M)^2 to the destination image. Corners in the image can be found as local maxima of the destination image.
Public methodStatic membercvCountNonZero
Returns the number of non-zero elements in arr: result = sumI arr(I)!=0 In case of IplImage both ROI and COI are supported.
Public methodStatic membercvCreateBGCodeBookModel
Create a BG code book model
Public methodStatic membercvCreateCameraCapture
Allocates and initialized the CvCapture structure for reading a video stream from the camera. Currently two camera interfaces can be used on Windows: Video for Windows (VFW) and Matrox Imaging Library (MIL); and two on Linux: V4L and FireWire (IEEE1394).
Public methodStatic membercvCreateChildMemStorage
Creates a child memory storage that is similar to simple memory storage except for the differences in the memory allocation/deallocation mechanism. When a child storage needs a new block to add to the block list, it tries to get this block from the parent. The first unoccupied parent block available is taken and excluded from the parent block list. If no blocks are available, the parent either allocates a block or borrows one from its own parent, if any. In other words, the chain, or a more complex structure, of memory storages where every storage is a child/parent of another is possible. When a child storage is released or even cleared, it returns all blocks to the parent. In other aspects, the child storage is the same as the simple storage.
Public methodStatic membercvCreateConDensation
Creates CvConDensation structure and returns pointer to the structure
Public methodStatic membercvCreateContourTree
Creates binary tree representation for the input contour and returns the pointer to its root.
Public methodStatic membercvCreateFGDStatModel(IntPtr, MCvFGDStatModelParams%)
Create a foreground model
Public methodStatic membercvCreateFGDStatModel(IntPtr, IntPtr)
Create a background model
Public methodStatic membercvCreateFileCapture
Allocates and initialized the CvCapture structure for reading the video stream from the specified file. After the allocated structure is not used any more it should be released by cvReleaseCapture function.
Public methodStatic membercvCreateGaussianBGModel(IntPtr, MCvGaussBGStatModelParams%)
Create a Gaussian background model
Public methodStatic membercvCreateGaussianBGModel(IntPtr, IntPtr)
Create a Gaussian background model
Public methodStatic membercvCreateHist(Int32, array<Int32>[]()[][], HIST_TYPE, array<IntPtr>[]()[][], Boolean)
Creates a histogram of the specified size and returns the pointer to the created histogram. If the array ranges is 0, the histogram bin ranges must be specified later via The function cvSetHistBinRanges, though cvCalcHist and cvCalcBackProject may process 8-bit images without setting bin ranges, they assume equally spaced in 0..255 bins
Public methodStatic membercvCreateHist(Int32, array<Int32>[]()[][], HIST_TYPE, array<IntPtr>[]()[][], Int32)
Creates a histogram of the specified size and returns the pointer to the created histogram. If the array ranges is 0, the histogram bin ranges must be specified later via The function cvSetHistBinRanges, though cvCalcHist and cvCalcBackProject may process 8-bit images without setting bin ranges, they assume equally spaced in 0..255 bins
Public methodStatic membercvCreateImage
Creates the header and allocates data.
Public methodStatic membercvCreateImageHeader
Allocates, initializes, and returns the structure IplImage.
Public methodStatic membercvCreateKalman
Allocates CvKalman and all its matrices and initializes them somehow.
Public methodStatic membercvCreateKDTree
Constructs a balanced kd-tree index of the given feature vectors. The lifetime of the desc matrix must exceed that of the returned tree. I.e., no copy is made of the vectors.
Public methodStatic membercvCreateMat
Allocates header for the new matrix and underlying data, and returns a pointer to the created matrix. Matrices are stored row by row. All the rows are aligned by 4 bytes.
Public methodStatic membercvCreateMemStorage
Creates a memory storage and returns pointer to it. Initially the storage is empty. All fields of the header, except the block_size, are set to 0.
Public methodStatic membercvCreatePOSITObject
Allocates memory for the object structure and computes the object inverse matrix.
Public methodStatic membercvCreateSeq
Creates a sequence and returns the pointer to it. The function allocates the sequence header in the storage block as one continuous chunk and sets the structure fields flags, elem_size, header_size and storage to passed values, sets delta_elems to the default value (that may be reassigned using cvSetSeqBlockSize function), and clears other header fields, including the space after the first sizeof(CvSeq) bytes
Public methodStatic membercvCreateSparseMat
The function allocates a multi-dimensional sparse array. Initially the array contain no elements, that is Get or GetReal returns zero for every index
Public methodStatic membercvCreateSpillTree
Constructs a spill tree index of the given feature vectors. The lifetime of the desc matrix must exceed that of the returned tree. I.e., no copy is made of the vectors.
Public methodStatic membercvCreateStereoBMState
Creates the stereo correspondence structure and initializes it. It is possible to override any of the parameters at any time between the calls to cvFindStereoCorrespondenceBM
Public methodStatic membercvCreateStereoGCState
Creates the stereo correspondence structure and initializes it.
Public methodStatic membercvCreateStructuringElementEx
Creates an structuring element.
Public methodStatic membercvCreateSubdiv2D
Creates new subdivision
Public methodStatic membercvCreateSubdivDelaunay2D
Creates an empty Delaunay subdivision, where 2d points can be added further using function cvSubdivDelaunay2DInsert. All the points to be added must be within the specified rectangle, otherwise a runtime error will be raised.
Public methodStatic membercvCreateVideoWriter(String, Int32, Double, Size, Boolean)
Creates video writer structure.
Public methodStatic membercvCreateVideoWriter(String, Int32, Double, Size, Int32)
Creates video writer structure.
Public methodStatic membercvCrossProduct
Calculates the cross product of two 3D vectors
Public methodStatic membercvCvtColor
Converts input image from one color space to another. The function ignores colorModel and channelSeq fields of IplImage header, so the source image color space should be specified correctly (including order of the channels in case of RGB space, e.g. BGR means 24-bit format with B0 G0 R0 B1 G1 R1 ... layout, whereas RGB means 24-bit format with R0 G0 B0 R1 G1 B1 ... layout).
Public methodStatic membercvCvtPixToPlane
Divides a multi-channel array into separate single-channel arrays. Two modes are available for the operation. If the source array has N channels then if the first N destination channels are not IntPtr.Zero, all they are extracted from the source array, otherwise if only a single destination channel of the first N is not IntPtr.Zero, this particular channel is extracted, otherwise an error is raised. Rest of destination channels (beyond the first N) must always be IntPtr.Zero. For IplImage cvCopy with COI set can be also used to extract a single channel from the image
Public methodStatic membercvCvtPlaneToPix
This function is the opposite to cvSplit. If the destination array has N channels then if the first N input channels are not IntPtr.Zero, all they are copied to the destination array, otherwise if only a single source channel of the first N is not IntPtr.Zero, this particular channel is copied into the destination array, otherwise an error is raised. Rest of source channels (beyond the first N) must always be IntPtr.Zero. For IplImage cvCopy with COI set can be also used to insert a single channel into the image.
Public methodStatic membercvCvtScale
This function has several different purposes and thus has several synonyms. It copies one array to another with optional scaling, which is performed first, and/or optional type conversion, performed after: dst(I)=src(I)*scale + (shift,shift,...) All the channels of multi-channel arrays are processed independently. The type conversion is done with rounding and saturation, that is if a result of scaling + conversion can not be represented exactly by a value of destination array element type, it is set to the nearest representable value on the real axis. In case of scale=1, shift=0 no prescaling is done. This is a specially optimized case and it has the appropriate cvConvert synonym. If source and destination array types have equal types, this is also a special case that can be used to scale and shift a matrix or an image and that fits to cvScale synonym.
Public methodStatic membercvCvtSeqToArray
Copies the entire sequence or subsequence to the specified buffer and returns the pointer to the buffer
Public methodStatic membercvDCT
Performs forward or inverse transform of 1D or 2D floating-point array
Public methodStatic membercvDestroyWindow
Destroys the window with a given name
Public methodStatic membercvDet
Returns determinant of the square matrix mat. The direct method is used for small matrices and Gaussian elimination is used for larger matrices. For symmetric positive-determined matrices it is also possible to run SVD with U=V=NULL and then calculate determinant as a product of the diagonal elements of W
Public methodStatic membercvDFT
Performs forward or inverse transform of 1D or 2D floating-point array In case of real (single-channel) data, the packed format, borrowed from IPL, is used to to represent a result of forward Fourier transform or input for inverse Fourier transform
Public methodStatic membercvDilate
Dilates the source image using the specified structuring element that determines the shape of a pixel neighborhood over which the maximum is taken The function supports the in-place mode. Dilation can be applied several (iterations) times. In case of color image each channel is processed independently
Public methodStatic membercvDistTransform
Calculates distance to closest zero pixel for all non-zero pixels of source image
Public methodStatic membercvDiv
Divides one array by another: dst(I)=scale * src1(I)/src2(I), if src1!=IntPtr.Zero; dst(I)=scale/src2(I), if src1==IntPtr.Zero; All the arrays must have the same type, and the same size (or ROI size)
Public methodStatic membercvDotProduct
Calculates and returns the Euclidean dot product of two arrays. src1 dot src2 = sumI(src1(I)*src2(I)) In case of multiple channel arrays the results for all channels are accumulated. In particular, cvDotProduct(a,a), where a is a complex vector, will return ||a||2. The function can process multi-dimensional arrays, row by row, layer by layer and so on.
Public methodStatic membercvDrawChessboardCorners(IntPtr, Size, array<PointF>[]()[][], Int32, Int32)
Draws the individual chessboard corners detected (as red circles) in case if the board was not found (pattern_was_found=0) or the colored corners connected with lines when the board was found (pattern_was_found != 0).
Public methodStatic membercvDrawChessboardCorners(IntPtr, Size, IntPtr, Int32, Int32)
Draws the individual chessboard corners detected (as red circles) in case if the board was not found (pattern_was_found=0) or the colored corners connected with lines when the board was found (pattern_was_found != 0).
Public methodStatic membercvDrawContours
Draws contour outlines in the image if thickness >=0 or fills area bounded by the contours if thickness<0.
Public methodStatic membercvEigenDecomposite
Calculates all decomposition coefficients for the input object using the previously calculated eigen objects basis and the averaged object
Public methodStatic membercvEigenProjection
Calculates an object projection to the eigen sub-space or, in other words, restores an object using previously calculated eigen objects basis, averaged object, and decomposition coefficients of the restored object.
Public methodStatic membercvEigenVV
Computes eigenvalues and eigenvectors of a symmetric matrix
Public methodStatic membercvEllipse
Draws a simple or thick elliptic arc or fills an ellipse sector. The arc is clipped by ROI rectangle. A piecewise-linear approximation is used for antialiased arcs and thick arcs. All the angles are given in degrees.
Public methodStatic membercvEllipseBox
Draws a simple or thick elliptic arc or fills an ellipse sector. The arc is clipped by ROI rectangle. A piecewise-linear approximation is used for antialiased arcs and thick arcs. All the angles are given in degrees.
Public methodStatic membercvEndFindContours
Finishes the scanning process and returns a pointer to the first contour on the highest level.
Public methodStatic membercvEqualizeHist
The algorithm normalizes brightness and increases contrast of the image
Public methodStatic membercvErode
Erodes the source image using the specified structuring element that determines the shape of a pixel neighborhood over which the minimum is taken: dst=erode(src,element): dst(x,y)=min((x',y') in element)) src(x+x',y+y') The function supports the in-place mode. Erosion can be applied several (iterations) times. In case of color image each channel is processed independently.
Public methodStatic membercvErrorStr
Returns the textual description for the specified error status code. In case of unknown status the function returns NULL pointer.
Public methodStatic membercvEstimateRigidTransform
Estimate rigid transformation between 2 images or 2 point sets.
Public methodStatic membercvExp
Calculates exponent of every element of input array: dst(I)=exp(src(I)) Maximum relative error is 7e-6. Currently, the function converts denormalized values to zeros on output
Public methodStatic membercvExtractSURF
Finds robust features in the image. For each feature it returns its location, size, orientation and optionally the descriptor, basic or extended. The function can be used for object tracking and localization, image stitching etc
Public methodStatic membercvFillConvexPoly
Fills convex polygon interior. This function is much faster than The function cvFillPoly and can fill not only the convex polygons but any monotonic polygon, i.e. a polygon whose contour intersects every horizontal line (scan line) twice at the most
Public methodStatic membercvFilter2D
Applies arbitrary linear filter to the image. In-place operation is supported. When the aperture is partially outside the image, the function interpolates outlier pixel values from the nearest pixels that is inside the image
Public methodStatic membercvFindChessboardCorners
Attempts to determine whether the input image is a view of the chessboard pattern and locate internal chessboard corners
Public methodStatic membercvFindContours
Retrieves contours from the binary image and returns the number of retrieved contours. The pointer firstContour is filled by the function. It will contain pointer to the first most outer contour or IntPtr.Zero if no contours is detected (if the image is completely black). Other contours may be reached from firstContour using h_next and v_next links. The sample in cvDrawContours discussion shows how to use contours for connected component detection. Contours can be also used for shape analysis and object recognition - see squares.c in OpenCV sample directory The function modifies the source image? content
Public methodStatic membercvFindCornerSubPix(IntPtr, array<PointF>[]()[][], Int32, Size, Size, MCvTermCriteria)
Iterates to find the sub-pixel accurate location of corners, or radial saddle points
Public methodStatic membercvFindCornerSubPix(IntPtr, IntPtr, Int32, Size, Size, MCvTermCriteria)
Iterates to find the sub-pixel accurate location of corners, or radial saddle points
Public methodStatic membercvFindExtrinsicCameraParams2
Estimates extrinsic camera parameters using known intrinsic parameters and extrinsic parameters for each view. The coordinates of 3D object points and their correspondent 2D projections must be specified. This function also minimizes back-projection error
Public methodStatic membercvFindFeatures
Searches feature tree for k nearest neighbors of given reference points.
Public methodStatic membercvFindFeaturesBoxed
Performs orthogonal range searching on the given kd-tree. That is, it returns the set of vectors v in tr that satisfy bounds_min[i] <= v[i] <= bounds_max[i], 0 <= i < d, where d is the dimension of vectors in the tree. The function returns the number of such vectors found
Public methodStatic membercvFindFundamentalMat
Calculates fundamental matrix using one of four methods listed above and returns the number of fundamental matrices found (1 or 3) and 0, if no matrix is found.
Public methodStatic membercvFindHomography
Finds perspective transformation H=||hij|| between the source and the destination planes
Public methodStatic membercvFindNearestPoint2D
Locates input point within subdivision. It finds subdivision vertex that is the closest to the input point. It is not necessarily one of vertices of the facet containing the input point, though the facet (located using cvSubdiv2DLocate) is used as a starting point.
Public methodStatic membercvFindNextContour
Finds the next contour in the image
Public methodStatic membercvFindStereoCorrespondence
Calculates disparity for stereo-pair
Public methodStatic membercvFindStereoCorrespondenceBM(IntPtr, IntPtr, IntPtr, MCvStereoBMState%)
Computes disparity map for the input rectified stereo pair.
Public methodStatic membercvFindStereoCorrespondenceBM(IntPtr, IntPtr, IntPtr, IntPtr)
Computes disparity map for the input rectified stereo pair.
Public methodStatic membercvFindStereoCorrespondenceGC(IntPtr, IntPtr, IntPtr, IntPtr, MCvStereoGCState%, Int32)
Computes disparity maps for the input rectified stereo pair
Public methodStatic membercvFindStereoCorrespondenceGC(IntPtr, IntPtr, IntPtr, IntPtr, IntPtr, Int32)
Computes disparity maps for the input rectified stereo pair
Public methodStatic membercvFitEllipse2
Calculates ellipse that fits best (in least-squares sense) to a set of 2D points. The meaning of the returned structure fields is similar to those in cvEllipse except that size stores the full lengths of the ellipse axises, not half-lengths
Public methodStatic membercvFitLine
Fits line to 2D or 3D point set
Public methodStatic membercvFlip(IntPtr, IntPtr, FLIP)
Flips the array in one of different 3 ways (row and column indices are 0-based)
Public methodStatic membercvFlip(IntPtr, IntPtr, Int32)
Flips the array in one of different 3 ways (row and column indices are 0-based): dst(i,j)=src(rows(src)-i-1,j) if flip_mode = 0 dst(i,j)=src(i,cols(src1)-j-1) if flip_mode > 0 dst(i,j)=src(rows(src)-i-1,cols(src)-j-1) if flip_mode < 0
Public methodStatic membercvFloodFill(IntPtr, Point, MCvScalar, MCvScalar, MCvScalar, MCvConnectedComp%, Int32, IntPtr)
Fills a connected component with given color.
Public methodStatic membercvFloodFill(IntPtr, Point, MCvScalar, MCvScalar, MCvScalar, MCvConnectedComp%, CONNECTIVITY, FLOODFILL_FLAG, IntPtr)
Fills a connected component with given color.
Public methodStatic membercvGEMM
Performs generalized matrix multiplication: dst = alpha*op(src1)*op(src2) + beta*op(src3), where op(X) is X or XT
Public methodStatic membercvGet1D
Return the particular array element
Public methodStatic membercvGet2D
Return the particular array element
Public methodStatic membercvGet3D
Return the particular array element
Public methodStatic membercvGetAffineTransform(array<PointF>[]()[][], array<PointF>[]()[][], IntPtr)
Calculates the matrix of an affine transform such that: (x'_i,y'_i)^T=map_matrix (x_i,y_i,1)^T where dst(i)=(x'_i,y'_i), src(i)=(x_i,y_i), i=0..2.
Public methodStatic membercvGetAffineTransform(IntPtr, IntPtr, IntPtr)
Calculates the matrix of an affine transform such that: (x'_i,y'_i)^T=map_matrix (x_i,y_i,1)^T where dst(i)=(x'_i,y'_i), src(i)=(x_i,y_i), i=0..2.
Public methodStatic membercvGetCaptureDomain
Return the type of the capture (eg, CV_CAP_V4W, CV_CAP_UNICAP), which is unknown if created with CV_CAP_ANY
Public methodStatic membercvGetCaptureProperty
Retrieves the specified property of camera or video file
Public methodStatic membercvGetCentralMoment
Retrieves the central moment, which in case of image moments is defined as: mu_{x_order,y_order}=sum_{x,y}(I(x,y)*(x-x_c)^{x_order} * (y-y_c)^{y_order}), where x_c=M10/M00, y_c=M01/M00 - coordinates of the gravity center
Public methodStatic membercvGetCol
Return the header, corresponding to a specified column of the input array
Public methodStatic membercvGetCols
Return the header, corresponding to a specified col span of the input array
Public methodStatic membercvGetDiag
returns the header, corresponding to a specified diagonal of the input array
Public methodStatic membercvGetErrMode
Returns the current error mode
Public methodStatic membercvGetErrStatus
Returns the current error status - the value set with the last cvSetErrStatus call. Note, that in Leaf mode the program terminates immediately after error occurred, so to always get control after the function call, one should call cvSetErrMode and set Parent or Silent error mode.
Public methodStatic membercvGetFileNodeByName
Finds a file node by name
Public methodStatic membercvGetHuMoments
Calculates seven Hu invariants
Public methodStatic membercvGetImage
Returns image header for the input array that can be matrix - CvMat*, or image - IplImage*.
Public methodStatic membercvGetImageCOI
Returns channel of interest of the image (it returns 0 if all the channels are selected).
Public methodStatic membercvGetImageROI
Returns channel of interest of the image (it returns 0 if all the channels are selected).
Public methodStatic membercvGetMat
Returns matrix header for the input array that can be matrix - CvMat, image - IplImage or multi-dimensional dense array - CvMatND* (latter case is allowed only if allowND != 0) . In the case of matrix the function simply returns the input pointer. In the case of IplImage* or CvMatND* it initializes header structure with parameters of the current image ROI and returns pointer to this temporary structure. Because COI is not supported by CvMat, it is returned separately.
Public methodStatic membercvGetMinMaxHistValue
Finds the minimum and maximum histogram bins and their positions
Public methodStatic membercvGetModuleInfo
Returns information about one of or all of the registered modules
Public methodStatic membercvGetNormalizedCentralMoment
Retrieves normalized central moment, which in case of image moments is defined as: eta_{x_order,y_order}=mu_{x_order,y_order} / M00^{(y_order+x_order)/2+1}, where mu_{x_order,y_order} is the central moment
Public methodStatic membercvGetNumThreads
Return the current number of threads that are used by parallelized (via OpenMP) OpenCV functions.
Public methodStatic membercvGetOptimalDFTSize
Returns the minimum number N that is greater to equal to size0, such that DFT of a vector of size N can be computed fast. In the current implementation N=2^p x 3^q x 5^r for some p, q, r.
Public methodStatic membercvGetPerspectiveTransform(array<PointF>[]()[][], array<PointF>[]()[][], IntPtr)
calculates matrix of perspective transform such that: (t_i x'_i,t_i y'_i,t_i)^T=map_matrix (x_i,y_i,1)^T where dst(i)=(x'_i,y'_i), src(i)=(x_i,y_i), i=0..3.
Public methodStatic membercvGetPerspectiveTransform(IntPtr, IntPtr, IntPtr)
calculates matrix of perspective transform such that: (t_i x'_i,t_i y'_i,t_i)^T=map_matrix (x_i,y_i,1)T where dst(i)=(x'_i,y'_i), src(i)=(x_i,y_i), i=0..3.
Public methodStatic membercvGetQuadrangleSubPix
Extracts pixels from src at sub-pixel accuracy and stores them to dst as follows: dst(x, y)= src( A_11 x'+A_12 y'+ b1, A_21 x'+A_22 y'+ b2), where A and b are taken from map_matrix: map_matrix = [ [A11 A12 b1], [ A21 A22 b2 ] ] x'=x-(width(dst)-1)*0.5, y'=y-(height(dst)-1)*0.5 where the values of pixels at non-integer coordinates A (x,y)^T + b are retrieved using bilinear interpolation. When the function needs pixels outside of the image, it uses replication border mode to reconstruct the values. Every channel of multiple-channel images is processed independently.
Public methodStatic membercvGetRawData
Fills output variables with low-level information about the array data. All output parameters are optional, so some of the pointers may be set to NULL. If the array is IplImage with ROI set, parameters of ROI are returned.
Public methodStatic membercvGetReal1D
Return the particular element of single-channel array. If the array has multiple channels, runtime error is raised. Note that cvGet*D function can be used safely for both single-channel and multiple-channel arrays though they are a bit slower.
Public methodStatic membercvGetReal2D
Return the particular element of single-channel array. If the array has multiple channels, runtime error is raised. Note that cvGet*D function can be used safely for both single-channel and multiple-channel arrays though they are a bit slower.
Public methodStatic membercvGetReal3D
Return the particular element of single-channel array. If the array has multiple channels, runtime error is raised. Note that cvGet*D function can be used safely for both single-channel and multiple-channel arrays though they are a bit slower.
Public methodStatic membercvGetRectSubPix
Extracts pixels from src: dst(x, y) = src(x + center.x - (width(dst)-1)*0.5, y + center.y - (height(dst)-1)*0.5) where the values of pixels at non-integer coordinates are retrieved using bilinear interpolation. Every channel of multiple-channel images is processed independently. Whereas the rectangle center must be inside the image, the whole rectangle may be partially occluded. In this case, the replication border mode is used to get pixel values beyond the image boundaries.
Public methodStatic membercvGetRow
Return the header, corresponding to a specified row of the input array
Public methodStatic membercvGetRows
Return the header, corresponding to a specified row span of the input array
Public methodStatic membercvGetSeqElem
Finds the element with the given index in the sequence and returns the pointer to it. If the element is not found, the function returns 0. The function supports negative indices, where -1 stands for the last sequence element, -2 stands for the one before last, etc. If the sequence is most likely to consist of a single sequence block or the desired element is likely to be located in the first block, then the macro CV_GET_SEQ_ELEM( elemType, seq, index ) should be used, where the parameter elemType is the type of sequence elements ( CvPoint for example), the parameter seq is a sequence, and the parameter index is the index of the desired element. The macro checks first whether the desired element belongs to the first block of the sequence and returns it if it does, otherwise the macro calls the main function GetSeqElem. Negative indices always cause the cvGetSeqElem call. The function has O(1) time complexity assuming that number of blocks is much smaller than the number of elements.
Public methodStatic membercvGetSize
Returns number of rows (CvSize::height) and number of columns (CvSize::width) of the input matrix or image. In case of image the size of ROI is returned.
Public methodStatic membercvGetSpatialMoment
Retrieves the spatial moment, which in case of image moments is defined as: M_{x_order,y_order}=sum_{x,y}(I(x,y) * x^{x_order} * y^{y_order}) where I(x,y) is the intensity of the pixel (x, y).
Public methodStatic membercvGetStarKeypoints
Retrieve the star keypoint location from the specific image
Public methodStatic membercvGetSubRect
Returns header, corresponding to a specified rectangle of the input array. In other words, it allows the user to treat a rectangular part of input array as a stand-alone array. ROI is taken into account by the function so the sub-array of ROI is actually extracted.
Public methodStatic membercvGetTextSize
Calculates the binding rectangle for the given text string when a specified font is used
Public methodStatic membercvGetThreadNum
Returns the index, from 0 to cvGetNumThreads()-1, of the thread that called the function. It is a wrapper for the function omp_get_thread_num() from OpenMP runtime. The retrieved index may be used to access local-thread data inside the parallelized code fragments.
Public methodStatic membercvGoodFeaturesToTrack
Finds corners with big eigenvalues in the image.
Public methodStatic memberCvGrabCut
The grab cut algorithm for segmentation
Public methodStatic membercvGrabFrame
Grab a frame
Public methodStatic membercvHaarDetectObjects
Finds rectangular regions in the given image that are likely to contain objects the cascade has been trained for and returns those regions as a sequence of rectangles. The function scans the image several times at different scales (see cvSetImagesForHaarClassifierCascade). Each time it considers overlapping regions in the image and applies the classifiers to the regions using cvRunHaarClassifierCascade. It may also apply some heuristics to reduce number of analyzed regions, such as Canny prunning. After it has proceeded and collected the candidate rectangles (regions that passed the classifier cascade), it groups them and returns a sequence of average rectangles for each large enough group. The default parameters (scale_factor=1.1, min_neighbors=3, flags=0) are tuned for accurate yet slow object detection. For a faster operation on real video images the settings are: scale_factor=1.2, min_neighbors=2, flags=CV_HAAR_DO_CANNY_PRUNING, min_size=<minimum possible face size> (for example, ~1/4 to 1/16 of the image area in case of video conferencing).
Public methodStatic membercvHoughCircles
Finds circles in grayscale image using some modification of Hough transform
Public methodStatic membercvHoughLines2
The function cvHoughLines2 implements a few variants of Hough transform for line detection
Public methodStatic membercvInitFont
Initializes the font structure that can be passed to text rendering functions
Public methodStatic membercvInitImageHeader
Initializes the image header structure, pointer to which is passed by the user, and returns the pointer.
Public methodStatic membercvInitMatHeader(IntPtr, Int32, Int32, MAT_DEPTH, IntPtr, Int32)
Initializes already allocated CvMat structure. It can be used to process raw data with OpenCV matrix functions.
Public methodStatic membercvInitMatHeader(IntPtr, Int32, Int32, Int32, IntPtr, Int32)
Initializes already allocated CvMat structure. It can be used to process raw data with OpenCV matrix functions.
Public methodStatic membercvInitMatNDHeader
Initializes CvMatND structure allocated by the user
Public methodStatic membercvInitSubdivDelaunay2D
Initializes Delaunay triangulation
Public methodStatic membercvInitUndistortMap
Pre-computes the undistortion map - coordinates of the corresponding pixel in the distorted image for every pixel in the corrected image. Then, the map (together with input and output images) can be passed to cvRemap function.
Public methodStatic membercvInitUndistortRectifyMap
This function is an extended version of cvInitUndistortMap. That is, in addition to the correction of lens distortion, the function can also apply arbitrary perspective transformation R and finally it can scale and shift the image according to the new camera matrix
Public methodStatic membercvInpaint
Reconstructs the selected image area from the pixel near the area boundary. The function may be used to remove dust and scratches from a scanned photo, or to remove undesirable objects from still images or video.
Public methodStatic membercvInRange
Performs range check for every element of the input array: dst(I)=lower(I)_0 <= src(I)_0 <= upper(I)_0 For single-channel arrays, dst(I)=lower(I)_0 <= src(I)_0 <= upper(I)_0 && lower(I)_1 <= src(I)_1 <= upper(I)_1 For two-channel arrays etc. dst(I) is set to 0xff (all '1'-bits) if src(I) is within the range and 0 otherwise. All the arrays must have the same type, except the destination, and the same size (or ROI size)
Public methodStatic membercvInRangeS
Does the range check for every element of the input array: dst(I)=lower0 <= src(I)0 <= upper0 for a single-channel array, dst(I)=lower0 <= src(I)0 <= upper0 && lower1 <= src(I)1 <= upper1 for a two-channel array etc. dst(I) is set to 0xff (all '1'-bits) if src(I) is within the range and 0 otherwise. All the arrays must have the same size (or ROI size)
Public methodStatic membercvIntegral
Calculates one or more integral images for the source image Using these integral images, one may calculate sum, mean, standard deviation over arbitrary up-right or rotated rectangular region of the image in a constant time. It makes possible to do a fast blurring or fast block correlation with variable window size etc. In case of multi-channel images sums for each channel are accumulated independently.
Public methodStatic membercvInvert
Inverts matrix src1 and stores the result in src2
Public methodStatic membercvKalmanCorrect(IntPtr, IntPtr)
Adjusts stochastic model state on the basis of the given measurement of the model state. The function stores adjusted state at kalman->state_post and returns it on output
Public methodStatic membercvKalmanCorrect(MCvKalman%, IntPtr)
Adjusts stochastic model state on the basis of the given measurement of the model state. The function stores adjusted state at kalman->state_post and returns it on output
Public methodStatic membercvKalmanPredict(IntPtr, IntPtr)
Estimates the subsequent stochastic model state by its current state and stores it at kalman->state_pre The function returns the estimated state
Public methodStatic membercvKalmanPredict(MCvKalman%, IntPtr)
Estimates the subsequent stochastic model state by its current state and stores it at kalman->state_pre The function returns the estimated state
Public methodStatic membercvKMeans2
implements k-means algorithm that finds centers of cluster_count clusters and groups the input samples around the clusters. On output labels(i) contains a cluster index for sample stored in the i-th row of samples matrix
Public methodStatic membercvLaplace
Calculates Laplacian of the source image by summing second x- and y- derivatives calculated using Sobel operator: dst(x,y) = d2src/dx2 + d2src/dy2 Specifying aperture_size=1 gives the fastest variant that is equal to convolving the image with the following kernel: |0 1 0| |1 -4 1| |0 1 0| Similar to cvSobel function, no scaling is done and the same combinations of input and output formats are supported.
Public methodStatic membercvLatentSvmDetectObjects
Find rectangular regions in the given image that are likely to contain objects and corresponding confidence levels
Public methodStatic membercvLine
Draws the line segment between pt1 and pt2 points in the image. The line is clipped by the image or ROI rectangle. For non-antialiased lines with integer coordinates the 8-connected or 4-connected Bresenham algorithm is used. Thick lines are drawn with rounding endings. Antialiased lines are drawn using Gaussian filtering.
Public methodStatic membercvLinearPolar
The function emulates the human "foveal" vision and can be used for fast scale and rotation-invariant template matching, for object tracking etc.
Public methodStatic membercvLoad
Loads object from file. It provides a simple interface to cvRead. After object is loaded, the file storage is closed and all the temporary buffers are deleted. Thus, to load a dynamic structure, such as sequence, contour or graph, one should pass a valid destination memory storage to the function.
Public methodStatic membercvLoadImage
Loads an image from the specified file and returns the pointer to the loaded image. Currently the following file formats are supported: Windows bitmaps - BMP, DIB; JPEG files - JPEG, JPG, JPE; Portable Network Graphics - PNG; Portable image format - PBM, PGM, PPM; Sun rasters - SR, RAS; TIFF files - TIFF, TIF; OpenEXR HDR images - EXR; JPEG 2000 images - jp2.
Public methodStatic membercvLoadLatentSvmDetector
Load trained detector from a file
Public methodStatic membercvLog
Calculates natural logarithm of absolute value of every element of input array: dst(I)=log(abs(src(I))), src(I)!=0 dst(I)=C, src(I)=0 Where C is large negative number (-700 in the current implementation)
Public methodStatic membercvLogPolar
The function emulates the human "foveal" vision and can be used for fast scale and rotation-invariant template matching, for object tracking etc.
Public methodStatic membercvLUT
Fills the destination array with values from the look-up table. Indices of the entries are taken from the source array. That is, the function processes each element of src as following: dst(I)=lut[src(I)+DELTA] where DELTA=0 if src has depth CV_8U, and DELTA=128 if src has depth CV_8S
Public methodStatic membercvMahalanobis
Calculates the weighted distance between two vectors and returns it
Public methodStatic membercvMakeHistHeaderForArray
initializes the histogram, which header and bins are allocated by user. No cvReleaseHist need to be called afterwards. Only dense histograms can be initialized this way.
Public methodStatic membercvMakeSeqHeaderForArray
Initializes sequence header for array. The sequence header as well as the sequence block are allocated by the user (for example, on stack). No data is copied by the function. The resultant sequence will consists of a single block and have IntPtr.Zero storage pointer, thus, it is possible to read its elements, but the attempts to add elements to the sequence will raise an error in most cases
Public methodStatic membercvMatchContourTrees
Calculates the value of the matching measure for two contour trees. The similarity measure is calculated level by level from the binary tree roots. If at the certain level difference between contours becomes less than threshold, the reconstruction process is interrupted and the current difference is returned
Public methodStatic membercvMatchShapes
Compares two shapes. The 3 implemented methods all use Hu moments
Public methodStatic membercvMatchTemplate
This function is similiar to cvCalcBackProjectPatch. It slids through image, compares overlapped patches of size wxh with templ using the specified method and stores the comparison results to result
Public methodStatic membercvMax
Calculates per-element maximum of two arrays: dst(I)=max(src1(I), src2(I)) All the arrays must have a single channel, the same data type and the same size (or ROI size).
Public methodStatic membercvMaxRect
Finds minimum area rectangle that contains both input rectangles inside
Public methodStatic membercvMaxS

Calculates per-element maximum of array and scalar:

dst(I)=max(src(I), value)

All the arrays must have a single channel, the same data type and the same size (or ROI size).

Public methodStatic membercvMeanShift
Iterates to find the object center given its back projection and initial position of search window. The iterations are made until the search window center moves by less than the given value and/or until the function has done the maximum number of iterations.
Public methodStatic membercvMerge
This function is the opposite to cvSplit. If the destination array has N channels then if the first N input channels are not IntPtr.Zero, all they are copied to the destination array, otherwise if only a single source channel of the first N is not IntPtr.Zero, this particular channel is copied into the destination array, otherwise an error is raised. Rest of source channels (beyond the first N) must always be IntPtr.Zero. For IplImage cvCopy with COI set can be also used to insert a single channel into the image.
Public methodStatic membercvMin
Calculates per-element minimum of two arrays: dst(I)=min(src1(I),src2(I)) All the arrays must have a single channel, the same data type and the same size (or ROI size).
Public methodStatic membercvMinAreaRect2
Finds a circumscribed rectangle of the minimal area for 2D point set by building convex hull for the set and applying rotating calipers technique to the hull.
Public methodStatic membercvMinEnclosingCircle
Finds the minimal circumscribed circle for 2D point set using iterative algorithm. It returns nonzero if the resultant circle contains all the input points and zero otherwise (i.e. algorithm failed)
Public methodStatic membercvMinMaxLoc
Finds minimum and maximum element values and their positions. The extremums are searched over the whole array, selected ROI (in case of IplImage) or, if mask is not IntPtr.Zero, in the specified array region. If the array has more than one channel, it must be IplImage with COI set. In case if multi-dimensional arrays min_loc->x and max_loc->x will contain raw (linear) positions of the extremums
Public methodStatic membercvMinS
Calculates minimum of array and scalar: dst(I)=min(src(I), value) All the arrays must have a single channel, the same data type and the same size (or ROI size).
Public methodStatic membercvMixChannels(array<IntPtr>[]()[][], array<IntPtr>[]()[][], array<Int32>[]()[][])
The function cvMixChannels is a generalized form of cvSplit and cvMerge and some forms of cvCvtColor. It can be used to change the order of the planes, add/remove alpha channel, extract or insert a single plane or multiple planes etc.
Public methodStatic membercvMixChannels(array<IntPtr>[]()[][], Int32, array<IntPtr>[]()[][], Int32, array<Int32>[]()[][], Int32)
The function cvMixChannels is a generalized form of cvSplit and cvMerge and some forms of cvCvtColor. It can be used to change the order of the planes, add/remove alpha channel, extract or insert a single plane or multiple planes etc.
Public methodStatic membercvMoments
Calculates spatial and central moments up to the third order and writes them to moments. The moments may be used then to calculate gravity center of the shape, its area, main axises and various shape characeteristics including 7 Hu invariants.
Public methodStatic membercvMorphologyEx
Performs advanced morphological transformations.
Public methodStatic membercvMul
Calculates per-element product of two arrays: dst(I)=scale*src1(I)*src2(I) All the arrays must have the same type, and the same size (or ROI size)
Public methodStatic membercvMulSpectrums
Performs per-element multiplication of the two CCS-packed or complex matrices that are results of real or complex Fourier transform.
Public methodStatic membercvMultiplyAcc
Adds product of 2 images or thier selected regions to accumulator acc
Public methodStatic membercvMulTransposed
Calculates the product of src and its transposition. The function evaluates dst=scale(src-delta)*(src-delta)^T if order=0, and dst=scale(src-delta)^T*(src-delta) otherwise.
Public methodStatic membercvNamedWindow
Creates a window which can be used as a placeholder for images and trackbars. Created windows are reffered by their names. If the window with such a name already exists, the function does nothing.
Public methodStatic membercvNorm
Returns the calculated norm. The multiple-channel array are treated as single-channel, that is, the results for all channels are combined.
Public methodStatic membercvNormalize
normalizes the input array so that it's norm or value range takes the certain value(s).
Public methodStatic membercvNormalizeHist
Normalizes the histogram bins by scaling them, such that the sum of the bins becomes equal to factor
Public methodStatic membercvNot
Inverses every bit of every array element:
Public methodStatic membercvOpenFileStorage
Opens file storage for reading or writing data. In the latter case a new file is created or existing file is rewritten. Type of the read of written file is determined by the filename extension: .xml for XML, and .yml or .yaml for YAML
Public methodStatic membercvOr
Calculates per-element bit-wise disjunction of two arrays: dst(I)=src1(I)|src2(I) In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvOrS
Calculates per-element bit-wise disjunction of array and scalar: dst(I)=src(I)|value if mask(I)!=0 Prior to the actual operation the scalar is converted to the same type as the arrays. In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvPerspectiveTransform
Transforms every element of src (by treating it as 2D or 3D vector) in the following way: (x, y, z) -> (x'/w, y'/w, z'/w) or (x, y) -> (x'/w, y'/w), where (x', y', z', w') = mat4x4 * (x, y, z, 1) or (x', y', w') = mat3x3 * (x, y, 1) and w = w' if w'!=0, inf otherwise
Public methodStatic membercvPointPolygonTest(IntPtr, PointF, Boolean)
Determines whether the point is inside contour, outside, or lies on an edge (or coinsides with a vertex). It returns positive, negative or zero value, correspondingly
Public methodStatic membercvPointPolygonTest(IntPtr, PointF, Int32)
Determines whether the point is inside contour, outside, or lies on an edge (or coinsides with a vertex). It returns positive, negative or zero value, correspondingly
Public methodStatic membercvPolarToCart(IntPtr, IntPtr, IntPtr, IntPtr, Boolean)
Calculates either x-coodinate, y-coordinate or both of every vector magnitude(I)* exp(angle(I)*j), j=sqrt(-1): x(I)=magnitude(I)*cos(angle(I)), y(I)=magnitude(I)*sin(angle(I))
Public methodStatic membercvPolarToCart(IntPtr, IntPtr, IntPtr, IntPtr, Int32)
Calculates either x-coodinate, y-coordinate or both of every vector magnitude(I)* exp(angle(I)*j), j=sqrt(-1): x(I)=magnitude(I)*cos(angle(I)), y(I)=magnitude(I)*sin(angle(I))
Public methodStatic membercvPolyLine(IntPtr, array<IntPtr>[]()[][], array<Int32>[]()[][], Int32, Boolean, MCvScalar, Int32, LINE_TYPE, Int32)
Draws a single or multiple polygonal curves
Public methodStatic membercvPolyLine(IntPtr, array<IntPtr>[]()[][], array<Int32>[]()[][], Int32, Int32, MCvScalar, Int32, LINE_TYPE, Int32)
Draws a single or multiple polygonal curves
Public methodStatic membercvPOSIT(IntPtr, IntPtr, Double, MCvTermCriteria, IntPtr, IntPtr)
Implements POSIT algorithm. Image coordinates are given in a camera-related coordinate system. The focal length may be retrieved using camera calibration functions. At every iteration of the algorithm new perspective projection of estimated pose is computed.
Public methodStatic membercvPOSIT(IntPtr, array<Single,2>[,](,)[,][,], Double, MCvTermCriteria, array<Single>[]()[][], array<Single>[]()[][])
Implements POSIT algorithm. Image coordinates are given in a camera-related coordinate system. The focal length may be retrieved using camera calibration functions. At every iteration of the algorithm new perspective projection of estimated pose is computed.
Public methodStatic membercvPow
Raises every element of input array to p: dst(I)=src(I)p, if p is integer dst(I)=abs(src(I))p, otherwise That is, for non-integer power exponent the absolute values of input array elements are used. However, it is possible to get true values for negative values using some extra operations, as the following sample, computing cube root of array elements, shows: CvSize size = cvGetSize(src); CvMat* mask = cvCreateMat( size.height, size.width, CV_8UC1 ); cvCmpS( src, 0, mask, CV_CMP_LT ); /* find negative elements */ cvPow( src, dst, 1./3 ); cvSubRS( dst, cvScalarAll(0), dst, mask ); /* negate the results of negative inputs */ cvReleaseMat( &mask ); For some values of power, such as integer values, 0.5 and -0.5, specialized faster algorithms are used.
Public methodStatic membercvProjectPCA
Projects vectors to the specified subspace
Public methodStatic membercvProjectPoints2
Computes projections of 3D points to the image plane given intrinsic and extrinsic camera parameters. Optionally, the function computes jacobians - matrices of partial derivatives of image points as functions of all the input parameters w.r.t. the particular parameters, intrinsic and/or extrinsic. The jacobians are used during the global optimization in cvCalibrateCamera2 and cvFindExtrinsicCameraParams2. The function itself is also used to compute back-projection error for with current intrinsic and extrinsic parameters. Note, that with intrinsic and/or extrinsic parameters set to special values, the function can be used to compute just extrinsic transformation or just intrinsic transformation (i.e. distortion of a sparse set of points).
Public methodStatic membercvPutText
Renders the text in the image with the specified font and color. The printed text is clipped by ROI rectangle. Symbols that do not belong to the specified font are replaced with the rectangle symbol.
Public methodStatic membercvPyrDown
Performs downsampling step of Gaussian pyramid decomposition. First it convolves source image with the specified filter and then downsamples the image by rejecting even rows and columns.
Public methodStatic membercvPyrMeanShiftFiltering
Filters image using meanshift algorithm
Public methodStatic membercvPyrSegmentation
The function cvPyrSegmentation implements image segmentation by pyramids. The pyramid builds up to the level level. The links between any pixel a on level i and its candidate father pixel b on the adjacent level are established if p(c(a),c(b))>threshold1. After the connected components are defined, they are joined into several clusters. Any two segments A and B belong to the same cluster, if p(c(A),c(B))>threshold2. The input image has only one channel, then p(c1,c2)=|c1-c2|. If the input image has three channels (red, green and blue), then p(c1,c2)=0.3*(c1r-c2r)+0.59 * (c1g-c2g)+0.11 *(c1b-c2b) . There may be more than one connected component per a cluster.
Public methodStatic membercvPyrUp
Performs up-sampling step of Gaussian pyramid decomposition. First it upsamples the source image by injecting even zero rows and columns and then convolves result with the specified filter multiplied by 4 for interpolation. So the destination image is four times larger than the source image.
Public methodStatic membercvQueryFrame
Grabs a frame from camera or video file, decompresses and returns it. This function is just a combination of cvGrabFrame and cvRetrieveFrame in one call.
Public methodStatic membercvQueryHistValue_1D
Return the value of the specified bin of 1D histogram. In case of sparse histogram the function returns 0, if the bin is not present in the histogram, and no new bin is created.
Public methodStatic membercvQueryHistValue_2D
Return the value of the specified bin of 2D histogram. In case of sparse histogram the function returns 0, if the bin is not present in the histogram, and no new bin is created.
Public methodStatic membercvQueryHistValue_3D
Return the value of the specified bin of 3D histogram. In case of sparse histogram the function returns 0, if the bin is not present in the histogram, and no new bin is created.
Public methodStatic membercvRandArr
Fills the destination array with uniformly or normally distributed random numbers.
Public methodStatic membercvRandShuffle
Shuffles the matrix by swapping randomly chosen pairs of the matrix elements on each iteration (where each element may contain several components in case of multi-channel arrays)
Public methodStatic membercvRange
Initializes the matrix as following: arr(i,j)=(end-start)*(i*cols(arr)+j)/(cols(arr)*rows(arr))
Public methodStatic membercvRead
Decodes user object (creates object in a native representation from the file storage subtree) and returns it
Public methodStatic membercvReadByName
Public methodStatic membercvRectangle
Draws a rectangle with two opposite corners pt1 and pt2
Public methodStatic membercvRectangleR
Draws a rectangle specified by a CvRect structure
Public methodStatic membercvRedirectError(IntPtr, IntPtr, IntPtr)
Sets a new error handler that can be one of standard handlers or a custom handler that has the certain interface. The handler takes the same parameters as cvError function. If the handler returns non-zero value, the program is terminated, otherwise, it continues. The error handler may check the current error mode with cvGetErrMode to make a decision.
Public methodStatic membercvRedirectError(CvInvoke..::..CvErrorCallback, IntPtr, IntPtr)
Sets a new error handler that can be one of standard handlers or a custom handler that has the certain interface. The handler takes the same parameters as cvError function. If the handler returns non-zero value, the program is terminated, otherwise, it continues. The error handler may check the current error mode with cvGetErrMode to make a decision.
Public methodStatic membercvReduce
Reduces matrix to a vector by treating the matrix rows/columns as a set of 1D vectors and performing the specified operation on the vectors until a single row/column is obtained.
Public methodStatic membercvReleaseBGCodeBookModel
Release the BG code book model
Public methodStatic membercvReleaseBGStatModel
Releases memory used by BGStatMode
Public methodStatic membercvReleaseCapture
The function cvReleaseCapture releases the CvCapture structure allocated by cvCreateFileCapture or cvCreateCameraCapture
Public methodStatic membercvReleaseConDensation
Releases the structure CvConDensation (see cvConDensation) and frees all memory previously allocated for the structure.
Public methodStatic membercvReleaseFeatureTree
Deallocates the given kd-tree
Public methodStatic membercvReleaseFileStorage
Closes the file associated with the storage and releases all the temporary structures. It must be called after all I/O operations with the storage are finished
Public methodStatic membercvReleaseHaarClassifierCascade
Deallocates the cascade that has been created manually or loaded using cvLoadHaarClassifierCascade or cvLoad
Public methodStatic membercvReleaseHist
Releases the histogram (header and the data). The pointer to histogram is cleared by the function. If *hist pointer is already NULL, the function does nothing.
Public methodStatic membercvReleaseImage
Releases the header and the image data.
Public methodStatic membercvReleaseImageHeader
Releases the header.
Public methodStatic membercvReleaseKalman
Releases the structure CvKalman and all underlying matrices
Public methodStatic membercvReleaseLatentSvmDetector
Release memory allocated for CvLatentSvmDetector structure
Public methodStatic membercvReleaseMat
Decrements the matrix data reference counter and releases matrix header
Public methodStatic membercvReleaseMemStorage
Deallocates all storage memory blocks or returns them to the parent, if any. Then it deallocates the storage header and clears the pointer to the storage. All children of the storage must be released before the parent is released.
Public methodStatic membercvReleasePOSITObject
The function cvReleasePOSITObject releases memory previously allocated by the function cvCreatePOSITObject.
Public methodStatic membercvReleaseSparseMat
The function releases the sparse array and clears the array pointer upon exit.
Public methodStatic membercvReleaseStereoBMState
Releases the stereo correspondence structure and all the associated internal buffers
Public methodStatic membercvReleaseStereoGCState
Releases the stereo correspondence structure and all the associated internal buffers
Public methodStatic membercvReleaseStructuringElement
Releases the structuring element.
Public methodStatic membercvReleaseVideoWriter
Finishes writing to video file and releases the structure.
Public methodStatic membercvRemap
Similar to other geometrical transformations, some interpolation method (specified by user) is used to extract pixels with non-integer coordinates.
Public methodStatic membercvRepeat
Fills the destination array with source array tiled: dst(i,j)=src(i mod rows(src), j mod cols(src))So the destination array may be as larger as well as smaller than the source array
Public methodStatic membercvReprojectImageTo3D
Transforms 1-channel disparity map to 3-channel image, a 3D surface.
Public methodStatic membercvResetImageROI
Releases image ROI. After that the whole image is considered selected.
Public methodStatic membercvReshape
initializes CvMat header so that it points to the same data as the original array but has different shape - different number of channels, different number of rows or both
Public methodStatic membercvResize
Resizes image src so that it fits exactly to dst. If ROI is set, the function consideres the ROI as supported as usual
Public methodStatic membercvRetrieveFrame
Get the frame grabbed with cvGrabFrame(..) This function may apply some frame processing like frame decompression, flipping etc.
Public methodStatic membercvRodrigues2
Converts a rotation vector to rotation matrix or vice versa. Rotation vector is a compact representation of rotation matrix. Direction of the rotation vector is the rotation axis and the length of the vector is the rotation angle around the axis.
Public methodStatic membercvRunningAvg
Calculates weighted sum of input image and the accumulator acc so that acc becomes a running average of frame sequence: acc(x,y)=(1-alpha) * acc(x,y) + alpha * image(x,y) if mask(x,y)!=0 where alpha regulates update speed (how fast accumulator forgets about previous frames).
Public methodStatic membercvSampleLine
Implements a particular case of application of line iterators. The function reads all the image points lying on the line between pt1 and pt2, including the ending points, and stores them into the buffer
Public methodStatic membercvSaveImage
Saves the image to the specified file. The image format is chosen depending on the filename extension, see cvLoadImage. Only 8-bit single-channel or 3-channel (with 'BGR' channel order) images can be saved using this function. If the format, depth or channel order is different, use cvCvtScale and cvCvtColor to convert it before saving, or use universal cvSave to save the image to XML or YAML format
Public methodStatic membercvSegmentMotion
Finds all the motion segments and marks them in segMask with individual values each (1,2,...). It also returns a sequence of CvConnectedComp structures, one per each motion components. After than the motion direction for every component can be calculated with cvCalcGlobalOrientation using extracted mask of the particular component (using cvCmp)
Public methodStatic membercvSeqInsert
Shifts the sequence elements from the inserted position to the nearest end of the sequence and copies the element content there if the pointer is not IntPtr.Zero
Public methodStatic membercvSeqPop
Removes element from sequence end.
Public methodStatic membercvSeqPopFront
Removes element from sequence beginning.
Public methodStatic membercvSeqPopMulti
Removes several elements from either end of the sequence. If the number of the elements to be removed exceeds the total number of elements in the sequence, the function removes as many elements as possible
Public methodStatic membercvSeqPush
Adds an element to the end of sequence and retuns pointer to the allocated element. If the input element is NULL, the function simply allocates a space for one more element.
Public methodStatic membercvSeqPushFront
Adds an element to the front of sequence and retuns pointer to the allocated element. If the input element is NULL, the function simply allocates a space for one more element.
Public methodStatic membercvSeqPushMulti
Adds several elements to either end of the sequence. The elements are added to the sequence in the same order as they are arranged in the input array but they can fall into different sequence blocks.
Public methodStatic membercvSeqRemove
Removes element from sequence middle
Public methodStatic membercvSeqSlice(IntPtr, MCvSlice, IntPtr, Boolean)
Creates a sequence that represents the specified slice of the input sequence. The new sequence either shares the elements with the original sequence or has own copy of the elements. So if one needs to process a part of sequence but the processing function does not have a slice parameter, the required sub-sequence may be extracted using this function.
Public methodStatic membercvSeqSlice(IntPtr, MCvSlice, IntPtr, Int32)
Creates a sequence that represents the specified slice of the input sequence. The new sequence either shares the elements with the original sequence or has own copy of the elements. So if one needs to process a part of sequence but the processing function does not have a slice parameter, the required sub-sequence may be extracted using this function.
Public methodStatic membercvSet
Copies scalar value to every selected element of the destination array: arr(I)=value if mask(I)!=0 If array arr is of IplImage type, then is ROI used, but COI must not be set
Public methodStatic membercvSet2D
Assign the new value to the particular element of array
Public methodStatic membercvSetCaptureProperty
Sets the specified property of video capturing
Public methodStatic membercvSetData
Assigns user data to the array header.
Public methodStatic membercvSetErrMode
Sets the specified error mode.
Public methodStatic membercvSetErrStatus
Sets the error status to the specified value. Mostly, the function is used to reset the error status (set to it CV_StsOk) to recover after error. In other cases it is more natural to call cvError or CV_ERROR.
Public methodStatic membercvSetIdentity
Initializes scaled identity matrix: arr(i,j)=value if i=j, 0 otherwise
Public methodStatic membercvSetImageCOI
Sets the channel of interest to a given value. Value 0 means that all channels are selected, 1 means that the first channel is selected etc. If ROI is NULL and coi != 0, ROI is allocated.
Public methodStatic membercvSetImageROI
Sets the image ROI to a given rectangle. If ROI is NULL and the value of the parameter rect is not equal to the whole image, ROI is allocated.
Public methodStatic membercvSetMemoryManager
The function cvSetMemoryManager sets user-defined memory managment functions (substitutors for malloc and free) that will be called by cvAlloc, cvFree and higher-level functions (e.g. cvCreateImage)
Public methodStatic membercvSetNumThreads
Sets the number of threads that are used by parallelized OpenCV functions.
Public methodStatic membercvSetReal1D
Assign the new value to the particular element of single-channel array
Public methodStatic membercvSetReal2D
Assign the new value to the particular element of single-channel array
Public methodStatic membercvSetReal3D
Assign the new value to the particular element of single-channel array
Public methodStatic membercvSetRealND
Assign the new value to the particular element of single-channel array
Public methodStatic membercvSetZero
Clears the array. In case of dense arrays (CvMat, CvMatND or IplImage) cvZero(array) is equivalent to cvSet(array,cvScalarAll(0),0), in case of sparse arrays all the elements are removed
Public methodStatic membercvShowImage
Shows the image in the specified window
Public methodStatic membercvSmooth
Smooths image using one of several methods. Every of the methods has some features and restrictions listed below Blur with no scaling works with single-channel images only and supports accumulation of 8-bit to 16-bit format (similar to cvSobel and cvLaplace) and 32-bit floating point to 32-bit floating-point format. Simple blur and Gaussian blur support 1- or 3-channel, 8-bit and 32-bit floating point images. These two methods can process images in-place. Median and bilateral filters work with 1- or 3-channel 8-bit images and can not process images in-place.
Public methodStatic membercvSnakeImage(IntPtr, array<Point>[]()[][], Int32, array<Single>[]()[][], array<Single>[]()[][], array<Single>[]()[][], Int32, Size, MCvTermCriteria, Int32)
Updates snake in order to minimize its total energy that is a sum of internal energy that depends on contour shape (the smoother contour is, the smaller internal energy is) and external energy that depends on the energy field and reaches minimum at the local energy extremums that correspond to the image edges in case of image gradient.
Public methodStatic membercvSnakeImage(IntPtr, IntPtr, Int32, array<Single>[]()[][], array<Single>[]()[][], array<Single>[]()[][], Int32, Size, MCvTermCriteria, Boolean)
Updates snake in order to minimize its total energy that is a sum of internal energy that depends on contour shape (the smoother contour is, the smaller internal energy is) and external energy that depends on the energy field and reaches minimum at the local energy extremums that correspond to the image edges in case of image gradient.
Public methodStatic membercvSnakeImage(IntPtr, IntPtr, Int32, array<Single>[]()[][], array<Single>[]()[][], array<Single>[]()[][], Int32, Size, MCvTermCriteria, Int32)
Updates snake in order to minimize its total energy that is a sum of internal energy that depends on contour shape (the smoother contour is, the smaller internal energy is) and external energy that depends on the energy field and reaches minimum at the local energy extremums that correspond to the image edges in case of image gradient.
Public methodStatic membercvSobel
The Sobel operators combine Gaussian smoothing and differentiation so the result is more or less robust to the noise. Most often, the function is called with (xorder=1, yorder=0, aperture_size=3) or (xorder=0, yorder=1, aperture_size=3) to calculate first x- or y- image derivative. The first case corresponds to
 
              |-1  0  1|
              |-2  0  2|
              |-1  0  1|
kernel and the second one corresponds to
              |-1 -2 -1|
              | 0  0  0|
              | 1  2  1|
or
              | 1  2  1|
              | 0  0  0|
              |-1 -2 -1|
kernel, depending on the image origin (origin field of IplImage structure). No scaling is done, so the destination image usually has larger by absolute value numbers than the source image. To avoid overflow, the function requires 16-bit destination image if the source image is 8-bit. The result can be converted back to 8-bit using cvConvertScale or cvConvertScaleAbs functions. Besides 8-bit images the function can process 32-bit floating-point images. Both source and destination must be single-channel images of equal size or ROI size
Public methodStatic membercvSolve
Solves linear system (src1)*(dst) = (src2)
Public methodStatic membercvSolveCubic
finds real roots of a cubic equation: coeffs[0]*x^3 + coeffs[1]*x^2 + coeffs[2]*x + coeffs[3] = 0 (if coeffs is 4-element vector) or x^3 + coeffs[0]*x^2 + coeffs[1]*x + coeffs[2] = 0 (if coeffs is 3-element vector)
Public methodStatic membercvSolvePoly
Finds all real and complex roots of any degree polynomial with real coefficients
Public methodStatic membercvSplit
Divides a multi-channel array into separate single-channel arrays. Two modes are available for the operation. If the source array has N channels then if the first N destination channels are not IntPtr.Zero, all they are extracted from the source array, otherwise if only a single destination channel of the first N is not IntPtr.Zero, this particular channel is extracted, otherwise an error is raised. Rest of destination channels (beyond the first N) must always be IntPtr.Zero. For IplImage cvCopy with COI set can be also used to extract a single channel from the image
Public methodStatic membercvSqrt
Calculate square root of each source array element. in the case of multichannel arrays each channel is processed independently. The function accuracy is approximately the same as of the built-in std::sqrt.
Public methodStatic membercvSquareAcc
Adds the input image or its selected region, raised to power 2, to the accumulator sqsum
Public methodStatic membercvStartFindContours
Initializes and returns a pointer to the contour scanner. The scanner is used in cvFindNextContour to retrieve the rest of the contours.
Public methodStatic membercvStartReadSeq
Initializes the reader state
Public methodStatic membercvStereoCalibrate
Estimates transformation between the 2 cameras making a stereo pair. If we have a stereo camera, where the relative position and orientatation of the 2 cameras is fixed, and if we computed poses of an object relative to the fist camera and to the second camera, (R1, T1) and (R2, T2), respectively (that can be done with cvFindExtrinsicCameraParams2), obviously, those poses will relate to each other, i.e. given (R1, T1) it should be possible to compute (R2, T2) - we only need to know the position and orientation of the 2nd camera relative to the 1st camera. That's what the described function does. It computes (R, T) such that: R2=R*R1, T2=R*T1 + T
Public methodStatic membercvStereoRectify
computes the rotation matrices for each camera that (virtually) make both camera image planes the same plane. Consequently, that makes all the epipolar lines parallel and thus simplifies the dense stereo correspondence problem. On input the function takes the matrices computed by cvStereoCalibrate and on output it gives 2 rotation matrices and also 2 projection matrices in the new coordinates. The function is normally called after cvStereoCalibrate that computes both camera matrices, the distortion coefficients, R and T
Public methodStatic membercvStereoRectifyUncalibrated
computes the rectification transformations without knowing intrinsic parameters of the cameras and their relative position in space, hence the suffix "Uncalibrated". Another related difference from cvStereoRectify is that the function outputs not the rectification transformations in the object (3D) space, but the planar perspective transformations, encoded by the homography matrices H1 and H2. The function implements the following algorithm [Hartley99].
Public methodStatic membercvSub
Subtracts one array from another one: dst(I)=src1(I)-src2(I) if mask(I)!=0 All the arrays must have the same type, except the mask, and the same size (or ROI size)
Public methodStatic membercvSubdiv2DLocate
Locates input point within subdivision
Public methodStatic membercvSubdivDelaunay2DInsert
Inserts a single point to subdivision and modifies the subdivision topology appropriately. If a points with same coordinates exists already, no new points is added. The function returns pointer to the allocated point. No virtual points coordinates is calculated at this stage.
Public methodStatic membercvSubRS
Subtracts every element of source array from a scalar: dst(I)=value-src(I) if mask(I)!=0 All the arrays must have the same type, except the mask, and the same size (or ROI size)
Public methodStatic membercvSubS
Subtracts a scalar from every element of the source array: dst(I)=src(I)-value if mask(I)!=0 All the arrays must have the same type, except the mask, and the same size (or ROI size)
Public methodStatic membercvSubstituteContour
The function replaces the retrieved contour, that was returned from the preceding call of cvFindNextContour and stored inside the contour scanner state, with the user-specified contour. The contour is inserted into the resulting structure, list, two-level hierarchy, or tree, depending on the retrieval mode. If the parameter new contour is IntPtr.Zero, the retrieved contour is not included in the resulting structure, nor are any of its children that might be added to this structure later.
Public methodStatic membercvSum
Calculates sum S of array elements, independently for each channel Sc = sumI arr(I)c If the array is IplImage and COI is set, the function processes the selected channel only and stores the sum to the first scalar component (S0).
Public methodStatic membercvSURFParams
Create a CvSURFParams using the specific values
Public methodStatic membercvSVD
Decomposes matrix A into a product of a diagonal matrix and two orthogonal matrices: A=U*W*VT Where W is diagonal matrix of singular values that can be coded as a 1D vector of singular values and U and V. All the singular values are non-negative and sorted (together with U and V columns) in descenting order.
Public methodStatic membercvThreshHist
Clears histogram bins that are below the specified threshold
Public methodStatic membercvThreshold
Applies fixed-level thresholding to single-channel array. The function is typically used to get bi-level (binary) image out of grayscale image (cvCmpS could be also used for this purpose) or for removing a noise, i.e. filtering out pixels with too small or too large values. There are several types of thresholding the function supports that are determined by threshold_type
Public methodStatic membercvTrace
Returns sum of diagonal elements of the matrix mat.
Public methodStatic membercvTransform
Performs matrix transformation of every element of array src and stores the results in dst Both source and destination arrays should have the same depth and the same size or selected ROI size. transmat and shiftvec should be real floating-point matrices.
Public methodStatic membercvTranspose
Transposes matrix src1: dst(i,j)=src(j,i) Note that no complex conjugation is done in case of complex matrix. Conjugation should be done separately: look at the sample code in cvXorS for example
Public methodStatic membercvUndistort2
Transforms the image to compensate radial and tangential lens distortion. The camera matrix and distortion parameters can be determined using cvCalibrateCamera2. For every pixel in the output image the function computes coordinates of the corresponding location in the input image using the formulae in the section beginning. Then, the pixel value is computed using bilinear interpolation. If the resolution of images is different from what was used at the calibration stage, fx, fy, cx and cy need to be adjusted appropriately, while the distortion coefficients remain the same.
Public methodStatic membercvUndistortPoints
Similar to cvInitUndistortRectifyMap and is opposite to it at the same time. The functions are similar in that they both are used to correct lens distortion and to perform the optional perspective (rectification) transformation. They are opposite because the function cvInitUndistortRectifyMap does actually perform the reverse transformation in order to initialize the maps properly, while this function does the forward transformation.
Public methodStatic membercvUpdateBGStatModel
Updates statistical model and returns number of found foreground regions
Public methodStatic membercvUpdateMotionHistory
Updates the motion history image as following: mhi(x,y)=timestamp if silhouette(x,y)!=0 0 if silhouette(x,y)=0 and mhi(x,y)<timestamp-duration mhi(x,y) otherwise That is, MHI pixels where motion occurs are set to the current timestamp, while the pixels where motion happened far ago are cleared.
Public methodStatic membercvUseOptimized(Boolean)
Switches between the mode, where only pure C implementations from cxcore, OpenCV etc. are used, and the mode, where IPP and MKL functions are used if available. When cvUseOptimized(0) is called, all the optimized libraries are unloaded. The function may be useful for debugging, IPP&MKL upgrade on the fly, online speed comparisons etc. Note that by default the optimized plugins are loaded, so it is not necessary to call cvUseOptimized(1) in the beginning of the program (actually, it will only increase the startup time)
Public methodStatic membercvUseOptimized(Int32)
Switches between the mode, where only pure C implementations from cxcore, OpenCV etc. are used, and the mode, where IPP and MKL functions are used if available. When cvUseOptimized(0) is called, all the optimized libraries are unloaded. The function may be useful for debugging, IPP&MKL upgrade on the fly, online speed comparisons etc. Note that by default the optimized plugins are loaded, so it is not necessary to call cvUseOptimized(1) in the beginning of the program (actually, it will only increase the startup time)
Public methodStatic membercvWaitKey
Waits for key event infinitely (delay <= 0) or for "delay" milliseconds.
Public methodStatic membercvWarpAffine
Transforms source image using the specified matrix
Public methodStatic membercvWarpPerspective
Transforms source image using the specified matrix
Public methodStatic membercvWatershed
Implements one of the variants of watershed, non-parametric marker-based segmentation algorithm, described in [Meyer92] Before passing the image to the function, user has to outline roughly the desired regions in the image markers with positive (>0) indices, i.e. every region is represented as one or more connected components with the pixel values 1, 2, 3 etc. Those components will be "seeds" of the future image regions. All the other pixels in markers, which relation to the outlined regions is not known and should be defined by the algorithm, should be set to 0's. On the output of the function, each pixel in markers is set to one of values of the "seed" components, or to -1 at boundaries between the regions.
Public methodStatic membercvWriteFrame
Writes/appends one frame to video file.
Public methodStatic membercvXor
Calculates per-element bit-wise logical conjunction of two arrays: dst(I)=src1(I)^src2(I) if mask(I)!=0 In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvXorS
Calculates per-element bit-wise conjunction of array and scalar: dst(I)=src(I)^value if mask(I)!=0 Prior to the actual operation the scalar is converted to the same type as the arrays. In the case of floating-point arrays their bit representations are used for the operation. All the arrays must have the same type, except the mask, and the same size
Public methodStatic membercvZero
Clears the array. In case of dense arrays (CvMat, CvMatND or IplImage) cvZero(array) is equivalent to cvSet(array,cvScalarAll(0),0), in case of sparse arrays all the elements are removed
Public methodStatic memberGetModuleFormatString
Get the module format string.
Public methodStatic membericvSubdiv2DCheck
Checks planar subdivision for correctness. It is not an absolute check, but it verifies some relations between quad-edges
Public methodStatic memberLoadUnmanagedModules
Attemps to load opencv modules from the specific location

Fields

  NameDescription
Public fieldStatic memberBoolMarshalType
Represent a bool value in C++
Public fieldStatic memberBoolToIntMarshalType
Represent a int value in C++
Public fieldStatic memberCvCallingConvention
Opencv's calling convention
Public fieldStatic memberCvErrorHandlerIgnoreError
An error handler which will ignore any error and continute
Public fieldStatic memberCvErrorHandlerThrowException
The default Exception callback to handle Error thrown by OpenCV
Public fieldStatic memberEXTERN_GPU_LIBRARY
The file name of the cvextern_gpu library
Public fieldStatic memberEXTERN_LIBRARY
The file name of the cvextern library
Public fieldStatic memberOPENCV_CALIB3D_LIBRARY
The file name of the calib3d library
Public fieldStatic memberOPENCV_CONTRIB_LIBRARY
The file name of the contrib library
Public fieldStatic memberOPENCV_CORE_LIBRARY
The file name of the core library
Public fieldStatic memberOPENCV_FEATURES2D_LIBRARY
The file name of the feature2d library
Public fieldStatic memberOPENCV_FFMPEG_LIBRARY
The file name of the opencv_ffmpeg library
Public fieldStatic memberOPENCV_FLANN_LIBRARY
The file name of the flann library
Public fieldStatic memberOPENCV_GPU_LIBRARY
The file name of the gpu library
Public fieldStatic memberOPENCV_HIGHGUI_LIBRARY
The file name of the highgui library
Public fieldStatic memberOPENCV_IMGPROC_LIBRARY
The file name of the imgproc library
Public fieldStatic memberOPENCV_LEGACY_LIBRARY
The file name of the legacy library
Public fieldStatic memberOPENCV_ML_LIBRARY
The file name of the ml library
Public fieldStatic memberOPENCV_NONFREE_LIBRARY
The file name of the nonfree library
Public fieldStatic memberOPENCV_OBJDETECT_LIBRARY
The file name of the objdetect library
Public fieldStatic memberOPENCV_PHOTO_LIBRARY
The file name of the photo library
Public fieldStatic memberOPENCV_STITCHING_LIBRARY
The file name of the opencv_stitching library
Public fieldStatic memberOPENCV_VIDEO_LIBRARY
The file name of the video library
Public fieldStatic memberOPENCV_VIDEOSTAB_LIBRARY
The file name of the videostab library
Public fieldStatic memberStringMarshalType
string marshaling type
Public fieldStatic memberUnmanagedCodeBitness
The bit-ness of the unmanaged code (either 32 or 64)

See Also