ToVector2()

View as Markdown

Definition

Converts a System.Windows.Point structure to a SharpDX.Vector2 when Using SharpDX for Custom Chart Rendering.

Method Return Value

A new SharpDX.Vector2 constructed with the point parameters X and Y values.

Syntax

DxExtensions.ToVector2(this System.Windows.Point point)

\<point\>.ToVector2()

Parameters

ParameterDescription
pointThe System.Windows.Point point to convert

Examples

1// gets the application/user WPF point and converts to a SharpDX Vector
2System.Windows.Point wpfPoint = ChartControl.MouseDownPoint;
3
4SharpDX.Vector2 dxVector2 = wpfPoint.ToVector2();