http://www.emgu.com
Assembly: Emgu.CV (in Emgu.CV.dll) Version: 2.3.0.1416 (2.3.0.1416)
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).
Namespace: Emgu.CVAssembly: Emgu.CV (in Emgu.CV.dll) Version: 2.3.0.1416 (2.3.0.1416)
Syntax
C# |
---|
public static void cvCalcMotionGradient( IntPtr mhi, IntPtr mask, IntPtr orientation, double delta1, double delta2, int apertureSize ) |
Visual Basic |
---|
Public Shared Sub cvCalcMotionGradient ( _ mhi As IntPtr, _ mask As IntPtr, _ orientation As IntPtr, _ delta1 As Double, _ delta2 As Double, _ apertureSize As Integer _ ) |
Visual C++ |
---|
public: static void cvCalcMotionGradient( IntPtr mhi, IntPtr mask, IntPtr orientation, double delta1, double delta2, int apertureSize ) |
Parameters
- mhi
- Type: System..::..IntPtr
Motion history image
- mask
- Type: System..::..IntPtr
Mask image; marks pixels where motion gradient data is correct. Output parameter.
- orientation
- Type: System..::..IntPtr
Motion gradient orientation image; contains angles from 0 to ~360.
- delta1
- Type: System..::..Double
The function finds minimum (m(x,y)) and maximum (M(x,y)) mhi values over each pixel (x,y) neihborhood and assumes the gradient is valid only if min(delta1,delta2) <= M(x,y)-m(x,y) <= max(delta1,delta2).
- delta2
- Type: System..::..Double
The function finds minimum (m(x,y)) and maximum (M(x,y)) mhi values over each pixel (x,y) neihborhood and assumes the gradient is valid only if min(delta1,delta2) <= M(x,y)-m(x,y) <= max(delta1,delta2).
- apertureSize
- Type: System..::..Int32
Aperture size of derivative operators used by the function: CV_SCHARR, 1, 3, 5 or 7 (see cvSobel).