Stroke.GetPoints Method (Int32, Int32)
Returns a specified range of the Point structures that make up the Stroke object.
Namespace: Microsoft.Ink
Assembly: Microsoft.Ink (in Microsoft.Ink.dll)
Syntax
'Declaration
Public Function GetPoints ( _
index As Integer, _
count As Integer _
) As Point()
'Usage
Dim instance As Stroke
Dim index As Integer
Dim count As Integer
Dim returnValue As Point()
returnValue = instance.GetPoints(index, _
count)
public Point[] GetPoints(
int index,
int count
)
public:
array<Point>^ GetPoints(
int index,
int count
)
public function GetPoints(
index : int,
count : int
) : Point[]
Parameters
index
Type: System.Int32The starting zero-based index within the array of Point structures that make up the Stroke object.
count
Type: System.Int32The number of points to return.
Return Value
Type: array<System.Drawing.Point[]
Returns an array of Point structures that make up the Stroke object.
Examples
In this example, each selected Stroke object of an InkOverlay is examined. If the Stroke object contains at least 90 packets, 50 Point objects (starting with the Point object in position 39) of the Stroke object are obtained, and used to create a new Stroke object. The new Stroke object is then moved by 200 HIMETRIC units in both the X and Y direction.
For Each S As Stroke In mInkOverlay.Selection
If S.PacketCount >= 90 Then
Dim sPts() As Point = S.GetPoints(39, 50)
Dim newStroke As Stroke = S.Ink.CreateStroke(sPts)
newStroke.Move(200, 200)
End If
Next
foreach (Stroke S in mInkOverlay.Selection)
{
if (S.PacketCount >= 90)
{
Point[] sPts = S.GetPoints(39, 50);
Stroke newStroke = S.Ink.CreateStroke(sPts);
newStroke.Move(200, 200);
}
}
Platforms
Windows 7, Windows Vista, Windows Server 2008 R2, Windows Server 2008
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.
Version Information
.NET Framework
Supported in: 3.0