Export (0) Print
Expand All

Vector3D.LengthSquared Property

Gets the square of the length of this Vector3D structure.

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

public double LengthSquared { get; }
You cannot set this property in XAML.

Property Value

Type: System.Double
The square of the length of this Vector3D structure.

The length of a Vector3D is sometimes referred to as the magnitude.

The following example shows how to get the square of the length of a Vector3D structure.

						// Gets the square of the length of a Vector3D.   
						// Returns a Vector3D.

						Vector3D vector1 = new Vector3D(20, 30, 40);
						Double lengthSq;

						lengthSq = vector1.LengthSquared;
                        // lengthSq is equal to 2900

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

Community Additions

ADD
Show:
© 2014 Microsoft