Neq() публичный Метод

public Neq ( Point p ) : bool
p Point
Результат bool
Пример #1
0
        // Partition a x-monotone mountain into triangles O(n)
        // See "Computational Geometry in C", 2nd edition, by Joseph O'Rourke, page 52
        public void Process()
        {
            // Establish the proper sign
            _positive = AngleSign();
            // create monotone polygon - for dubug purposes
            GenMonoPoly();

            // Initialize internal angles at each nonbase vertex
            // Link strictly convex vertices into a list, ignore reflex vertices
            Point p = _head.Next;

            while (p.Neq(_tail))
            {
                float a = Angle(p);
                // If the point is almost colinear with it's neighbor, remove it!
                if (a >= PiSlop || a <= -PiSlop || a == 0.0f)
                {
                    Remove(p);
                }
                else if (IsConvex(p))
                {
                    _convexPoints.Add(p);
                }
                p = p.Next;
            }

            Triangulate();
        }
Пример #2
0
 private bool Valid(Point p)
 {
     return(p.Neq(_head) && p.Neq(_tail) && IsConvex(p));
 }
Пример #3
0
 private bool Valid(Point p)
 {
     return p.Neq(_head) && p.Neq(_tail) && IsConvex(p);
 }