Пример #1
0
            public Point3d UpdatedPosition()
            {
                Point3d p1 = this.Position;

                p1 += this.Velocity;
                p1  = p1.BoundPoint(this.Bounds, this._Bounce);
                return(p1);
            }
Пример #2
0
        public Point3d NextPoint()
        {
            Point3d        pOut       = this.currentPoint;
            Box            reachBox   = new Box(new Plane(currentPoint, Vector3d.ZAxis), new Interval((0 - this.StepSize), this.StepSize), new Interval((0 - this.StepSize), this.StepSize), new Interval((0 - this.StepSize), this.StepSize));
            DoFPointsArray points     = reachBox.GetFreePoints();
            List <Point3d> pointCloud = points.GetPoints(_HV2D, _HV3D, _FaceHV2D, _FaceHV3D, _Diag);
            int            index      = this.Rand.Next(0, (pointCloud.Count - 1));

            pOut = pointCloud[index];
            pOut = pOut.BoundPoint(this.Bounds, true);
            this.currentPoint = pOut;
            return(pOut);
        }