public void CheckClosest(Cl3DModel.Cl3DModelPointIterator point)
 {
     if (MinDistance == -1)
     {
         MinDistance = this - point;
         ClosestPoint = point.CopyIterator();
     }
     else
     {
         float tmpDistance = this - point;
         if (tmpDistance < MinDistance)
         {
             MinDistance = tmpDistance;
             ClosestPoint = point.CopyIterator();
         }
     }
 }
 public static void GetPathBetweenPoints(Cl3DModel.Cl3DModelPointIterator p_StartPoint, Cl3DModel.Cl3DModelPointIterator p_EndPoint, out List<Cl3DModel.Cl3DModelPointIterator> p_Path)
 {
     p_Path = new List<Cl3DModel.Cl3DModelPointIterator>();
     ClTools.CalculateGeodesicDistanceFromSourcePointToAllPoints(p_StartPoint, Cl3DModel.Cl3DModelPointIterator.eSpecificValues.GeodesicDistanceFromPoint.ToString());
     Cl3DModel.Cl3DModelPointIterator iter = p_EndPoint.CopyIterator();
     while (iter.IsSpecificValueCalculated("Path"))
     {
         uint PiD = (uint)iter.GetSpecificValue("Path");
         iter.MoveToPoint(PiD);
         p_Path.Add(iter.CopyIterator());
     }
     p_Path.Add(p_StartPoint);
     Cl3DModel.Cl3DModelPointIterator itRemove = p_StartPoint.GetManagedModel().GetIterator();
     do
     {
         itRemove.RemoveSpecificValue(Cl3DModel.Cl3DModelPointIterator.eSpecificValues.GeodesicDistanceFromPoint);
         itRemove.RemoveSpecificValue("Path");
     } while (itRemove.MoveToNext());
 }
 public ClTriangle(Cl3DModel.Cl3DModelPointIterator point1, Cl3DModel.Cl3DModelPointIterator point2, Cl3DModel.Cl3DModelPointIterator point3)
 {
     m_point1 = point1.CopyIterator();
     m_point2 = point2.CopyIterator();
     m_point3 = point3.CopyIterator();
 }
        public static void GetListOfTriangles(out List<ClTriangle> triangles, Cl3DModel.Cl3DModelPointIterator iter)
        {
            triangles = new List<ClTriangle>();

            List<Cl3DModel.Cl3DModelPointIterator> Neighbors = iter.GetListOfNeighbors();
            for (int i = 0; i < Neighbors.Count; i++)
            {
                for (int j = i; j < Neighbors.Count; j++)
                {
                    if (Neighbors[i].IsPointInNeighbors(Neighbors[j].PointID))
                    {
                        triangles.Add(new ClTriangle(iter.CopyIterator(), Neighbors[i].CopyIterator(), Neighbors[j].CopyIterator()));
                    }
                }
            }
        }