IMVGaugeCalculations

The IMVGaugeCalculations interface contains methods to do some calculations with measured points from the MV Gauge filter.

Methods:

CalcAngle2L Calculate the angle between two lines.
CalcCircle3P Calculate the radius, area and center position of a circle.
CalcDistance2L Calculate the distance between two lines.
CalcDistance2P Calculate the distance between two points.

Header file: IMVGauge.h
Interface definition language file: IMVGauge.idl
Typelib: MVGauge
Interface ID: IID_IMVGaugeCalculations


Method IMVGaugeCalculations::CalcAngle2L

Declaration: Function CalcAngle2L(Point1 As Long, Point2 As Long, Point3 As Long, Point4 As Long) As Double

Calculate the angle between two lines.

Parameter:

Point1 Index of the first point  from the first line.
Point2 Index of the second point from the first line.
Point3 Index of the first point  from the second line.
Point4 Index of the second point from the second line.
C Prototype:

HRESULT CalcAngle2L(LONG Point1, LONG Point2, LONG Point3, LONG Point4, DOUBLE* value);


Method IMVGaugeCalculations::CalcCircle3P

Declaration: Sub CalcCircle3P(Point1 As Long, Point2 As Long, Point3 As Long, Radius As Double, Area As Double, CenterX As Double, CenterY As Double)

Calculate the radius, area and center position of a circle.

Parameter:

Point1 Index of the first point of the circle.
Point2 Index of the second point of the circle.
Point3 Index of the thired point of the circle.
Radius Radius of the circle.
Area Area of the circle.
CenterX X-Position of the circle center.
CenterY Y-Position of the circle center.
C Prototype:

HRESULT CalcCircle3P(LONG Point1, LONG Point2, LONG Point3, DOUBLE* Radius, DOUBLE* Area, DOUBLE* CenterX, DOUBLE* CenterY);


Method IMVGaugeCalculations::CalcDistance2L

Declaration: Function CalcDistance2L(Point1 As Long, Point2 As Long, Point3 As Long, Point4 As Long) As Double

Calculate the distance between two lines.

Parameter:

Point1 Index of the first point  from the first line.
Point2 Index of the second point from the first line.
Point3 Index of the first point  from the second line.
Point4 Index of the second point from the second line.
C Prototype:

HRESULT CalcDistance2L(LONG Point1, LONG Point2, LONG Point3, LONG Point4, DOUBLE* value);


Method IMVGaugeCalculations::CalcDistance2P

Declaration: Function CalcDistance2P(Point1 As Long, Point2 As Long) As Double

Calculate the distance between two points.

Parameter:

Point1 Index of the first point.
Point2 Index of the second point.
C Prototype:

HRESULT CalcDistance2P(LONG Point1, LONG Point2, DOUBLE* value);