Esempio n. 1
0
        private PointCloudVertices ICPOnPoints_WithSubset_PointsData(List <PointCloudVertices> PointsDataList, List <System.Drawing.Point> pointsLeft, List <System.Drawing.Point> pointsRight)
        {
            PointCloudVertices myPointsTarget = PointsDataList[0];
            PointCloudVertices mypointsSource = PointsDataList[1];

            if (PointsDataList.Count > 1)
            {
                if (pointsLeft != null)
                {
                    PointCloudVertices mySubsetLeft  = PointCloudVertices.FromPoints2d(pointsLeft, PointsDataList[0], pointsRight);
                    PointCloudVertices mySubsetRight = PointCloudVertices.FromPoints2d(pointsRight, PointsDataList[1], pointsLeft);

                    if (mySubsetLeft.Count == mySubsetRight.Count)
                    {
                        PointCloudVertices myPointsTransformed = ICPOnPoints_WithSubset(myPointsTarget, mypointsSource, mySubsetLeft, mySubsetRight);
                        return(myPointsTransformed);
                    }
                    else
                    {
                        MessageBox.Show("Error in identifying stitched points ");
                    }
                }
            }

            return(null);
        }