Share via


Stroke.FindIntersections Method

Finds the points where this Stroke object intersects other Stroke objects within a given Strokes collection.

Namespace: Microsoft.Ink
Assembly: Microsoft.Ink (in microsoft.ink.dll)

Syntax

'Declaration
Public Function FindIntersections ( _
    strokes As Strokes _
) As Single()
'Usage
Dim instance As Stroke
Dim strokes As Strokes
Dim returnValue As Single()

returnValue = instance.FindIntersections(strokes)
public float[] FindIntersections (
    Strokes strokes
)
public:
array<float>^ FindIntersections (
    Strokes^ strokes
)
public float[] FindIntersections (
    Strokes strokes
)
public function FindIntersections (
    strokes : Strokes
) : float[]
Not applicable.

Parameters

  • strokes
    The Strokes collection used to test for intersections with this Stroke object. If a null reference (Nothing in Visual Basic) (Nothing in Microsoft® Visual Basic® .NET), uses all Strokes collections in the Ink object.

Return Value

This method returns an array of floating point index values that indicate the locations where the intersections occur. A floating point index is a float value that represents a location somewhere between two points in the Stroke object. As examples, if 0.0 is the first point in the stroke and 1.0 is the second point in the stroke, 0.5 is halfway between the first and second points. Similarly, a floating point index value of 37.25 represents a location that is 25 percent along the line between points 37 and 38 of the stroke.

Remarks

Note

The Strokes collection in the strokes parameter must come from the same Ink object as the Stroke object you are testing for intersection.

This method can determine only the points of intersection.

Example

This C# example finds all of the intersections of the Stroke object, theStroke, and the rest of the Strokes collection in the Ink object, theInk.

float[] findexArray = theStroke.FindIntersections(theInk.Strokes);

This Visual Basic .NET example finds all of the intersections of the Stroke object, theStroke, and the rest of the Strokes collection in the Ink object, theInk.

Dim findexArray() As Single = theStroke.FindIntersections(theInk.Strokes)

Platforms

Windows 98, Windows Server 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

Version Information

.NET Framework

Supported in: 3.0

See Also

Reference

Stroke Class
Stroke Members
Microsoft.Ink Namespace
Stroke.GetRectangleIntersections
Strokes