コード例 #1
0
        /// <summary>
        /// according to distance to plane
        /// </summary>
        /// <param name="myPlane"></param>
        private void SetVertexConditions(Plane3 <double> myPlane)
        {
            for (int i = 0; i < Vertices.Count; i++)
            {
                double db = myPlane.DistanceTo(Vertices[i].Vector);

                if (Math.Abs(db) < GeneralSettings.AbsoluteTolerance)
                {
                    Vertices[i].Condition = 1;
                }

                else if (db > 0)
                {
                    Vertices[i].Condition = 2;
                }
                else if (db < 0)
                {
                    Vertices[i].Condition = 0;
                }
            }
        }
コード例 #2
0
ファイル: HullVoronoi.cs プロジェクト: whigg/PointClouds
        /// <summary>
        /// according to distance to plane
        /// </summary>
        /// <param name="myPlane"></param>
        private void SetVertexConditions(Plane3 <float> myPlane)
        {
            for (int i = 0; i < Vertices.Count; i++)
            {
                float db = myPlane.DistanceTo(Vertices[i].Vector);

                if (Math.Abs(db) < GlobalVariables.AbsoluteTolerance)
                {
                    Vertices[i].Condition = 1;
                }

                else if (db > 0)
                {
                    Vertices[i].Condition = 2;
                }
                else if (db < 0)
                {
                    Vertices[i].Condition = 0;
                }
            }
        }