fixed bug: having a triangle around cpX does not guarantee that cpX is inside the quadrilateral