dropPoint()

Synopsis

Returns the point on part that is nearest to another point p. The part can be any curve part .

Syntax

dropPoint ( p As Point, _
            part As Part ) As Point		
Argument Type Description
p point The return value is the point closest to this input point on the part 'part'.
part part The return point lies on this part .

Example 1

The line part for the example
Child Line_1 As :Line
    thruPoint1 = point(0, 0, 0)
    thruPoint2 = point(2, 0, 0)
End Child
Intent >dropPoint(point(1, 1, 1), Line_1) 
--> Point_(1.0, 0.0, 0.0, WorldFrame())
The example shows a point at 1,1,1 being dropped on a line along a segment of the x axis.

Example 2

The line part for the example
Child Line_1 As :Line
    thruPoint1 = point(0, 0, 0)
    thruPoint2 = point(0.5, 0.3, 0)
End Child
Intent >dropPoint(point(1, 1, 1), Line_1) 
--> Point_(1.176, 0.706, 0.0, WorldFrame()) 
The example shows a point at 1,1,1 being dropped on a line in the x-y plane. Note that the drop point is beyond the end points of the line.