Author Topic: Find the midpoint between two points  (Read 1506 times)

0 Members and 1 Guest are viewing this topic.

Offline Patriiick

  • Administrator
  • *****
  • Posts: 130
  • Karma: +1/-0
  • Gender: Male
    • prefered language: VB
    • Prog expertise: Good
    • View Profile
  • Twitter: @Patriiick
Find the midpoint between two points
« on: November 19, 2010, 10:40:23 AM »
Code: [Select]
''' <summary>
    '''=========================================================
    '''NAME: myMidPoint
    '''AUTHOR: Patrick EMIN
    '''DESCRIPTION: Finds the midpoint between two points
    '''ARGUMENTS: P1 and P2
    '''DATE: 03/11/2010
    '''=========================================================
    ''' </summary>
    ''' <param name="P1"></param>
    ''' <param name="P2"></param>
    ''' <returns>myLineSegment.MidPoint</returns>
    ''' <remarks>easier to create a line segment because we have the .MidPoint property...</remarks>
    Public Function myMidPoint(ByVal P1 As Point3d, ByVal P2 As Point3d) As Point3d
        Dim myLineSegment As New LineSegment3d(P1, P2)
        Return myLineSegment.MidPoint
    End Function

target audience:{beginner}
« Last Edit: November 21, 2010, 05:43:47 PM by Patriiick »