Click or drag to resize
Mat Class
The equivalent of cv::Mat
Inheritance Hierarchy

Namespace: Emgu.CV
Assembly: Emgu.CV.World (in Emgu.CV.World.dll) Version: (
public class Mat : MatDataAllocator, IImage, IDisposable, 
	ICloneable, IInputOutputArray, IInputArrayOfArrays, IOutputArrayOfArrays, IOutputArray, 
	IInputArray, IEquatable<Mat>, ISerializable

The Mat type exposes the following members.

Public propertyBitmap
The Get property provide a more efficient way to convert Image<Gray, Byte>, Image<Bgr, Byte> and Image<Bgra, Byte> into Bitmap such that the image data is shared with Bitmap. If you change the pixel value on the Bitmap, you change the pixel values on the Image object as well! For other types of image this property has the same effect as ToBitmap() Take extra caution not to use the Bitmap after the Mat object is disposed The Set property convert the bitmap to this Image type.
Public propertyCols
The number of columns
Public propertyData
Get the managed data used by the Mat
(Inherited from MatDataAllocator.)
Public propertyDataPointer
Pointer to the beginning of the raw data
Public propertyDepth
Depth type
Public propertyDims
The matrix dimensionality
Public propertyElementSize
The size of the elements in this matrix
Public propertyHeight
Get the height of the mat.
Public propertyIsContinuous
True if the data is continues
Public propertyIsEmpty
True if the Mat is empty
Public propertyIsSubmatrix
True if the matrix is a submatrix of another matrix
Public propertyNumberOfChannels
Number of channels
Public propertyPtr
Pointer to the unmanaged object
(Inherited from UnmanagedObject.)
Public propertyRows
The number of rows
Public propertySize
The size of this matrix
Public propertySizeOfDimemsion
Get an array of the size of the dimensions. e.g. if the mat is 9x10x11, the array of {9, 10, 11} will be returned.
Public propertyStep
Public propertyTotal
The method returns the number of array elements (a number of pixels if the array represents an image)
Public propertyWidth
Get the width of the mat
Public methodClone
Make a clone of the current Mat
Public methodCol
Creates a matrix header for the specified matrix column.
Public methodConvertTo
Converts an array to another data type with optional scaling.
Public methodCopyTo(IOutputArray, IInputArray)
Copy the data in this cv::Mat to an output array
Public methodCopyToT(T)
Copy data from this Mat to the managed array
Public methodCreate
Allocates new array data if needed.
Public methodCross
Computes a cross-product of two 3-element vectors.
Protected methodDeserializeObjectData
A function used for runtime deserailization of the object
Public methodDispose
The dispose function that implements IDisposable interface
(Inherited from DisposableObject.)
Protected methodDisposeObject
Release all the unmanaged memory associated with this object.
(Overrides MatDataAllocatorDisposeObject.)
Public methodDot
Computes a dot-product of two vectors.
Public methodEquals(Object) (Inherited from Object.)
Public methodEquals(Mat)
Compares two Mats and check if they are equal
Protected methodFinalize
(Inherited from DisposableObject.)
Public methodGetData
Gets the binary data from the specific indices.
Public methodGetHashCode (Inherited from Object.)
Public methodGetInputArray
Pointer to the InputArray
Public methodGetInputOutputArray
Pointer to the InputOutputArray
Public methodGetObjectData
A function used for runtime serialization of the object
Public methodGetOutputArray
Pointer to the OutputArray
Public methodGetType (Inherited from Object.)
Public methodGetUMat
Convert this Mat to UMat
Public methodGetValueRange
Get the minimum and maximum value across all channels of the mat
Protected methodMemberwiseClone (Inherited from Object.)
Public methodMinMax
Returns the min / max location and values for the image
Public methodPopBack
The method removes one or more rows from the bottom of the matrix
Public methodPushBack
Adds elements to the bottom of the matrix
Protected methodReleaseManagedResources
Release the managed resources. This function will be called during the disposal of the current object. override ride this function if you need to call the Dispose() function on any managed IDisposable object created by the current object
(Inherited from DisposableObject.)
Public methodReshape
Changes the shape and/or the number of channels of a 2D matrix without copying the data.
Public methodRow
Creates a matrix header for the specified matrix row.
Public methodSave
Save this image to the specific file.
Public methodSetTo(IInputArray, IInputArray)
Set the mat to the specific value
Public methodSetTo(MCvScalar, IInputArray)
Set the mat to the specific value
Public methodSetToT(T)
Copy data from managed array to this Mat
Public methodSplit
Split current Image into an array of gray scale images where each element in the array represent a single color channel of the original image
Public methodToImageTColor, TDepth
Convert this Mat to Image
Public methodToString (Inherited from Object.)
Protected field_ptr
A pointer to the unmanaged object
(Inherited from UnmanagedObject.)
Extension Methods
Public Extension MethodIsUmat
Determines whether the specified input array is umat.
(Defined by IInputArrayExtensions.)
See Also