This documentation is archived and is not being maintained.

Point4D.Subtract Method

Subtracts a Point4D structure from a Point4D structure.

Namespace:  System.Windows.Media.Media3D
Assembly:  PresentationCore (in PresentationCore.dll)

public static Point4D Subtract(
	Point4D point1,
	Point4D point2
)
You cannot use methods in XAML.

Parameters

point1
Type: System.Windows.Media.Media3D.Point4D

The Point4D structure to be subtracted from.

point2
Type: System.Windows.Media.Media3D.Point4D

The Point4D structure to subtract from point1.

Return Value

Type: System.Windows.Media.Media3D.Point4D
Returns the difference between point1 and point2.

The following example shows how to subtract a Point4D structure from a Point4D structure.

                        // Subtracts a Point3D from a Point4D using the static Subtract method.  
                        // Returns a Point4D.

                        Point4D point1 = new Point4D(10, 5, 1, 4);
                        Point4D point2 = new Point4D(15, 40, 60, 75);
                        Point4D pointResult = new Point4D();

                        pointResult = Point4D.Subtract(point1, point2);
                        // pointResult is equal to (-5, -35, -59, -71) 

                        // Displaying Results
                        syntaxString = "pointResult = Point4D.Subtract(point1, point2);";
                        resultType = "Point4D";
						operationString = "Subtracting a Vector3D from a Point4D";
						ShowResults(pointResult.ToString(), syntaxString, resultType, operationString);

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0
Show: