System.Drawing.PieChart.PieSlice.CylinderSurfaceSectionContainsPoint C# (CSharp) Method

CylinderSurfaceSectionContainsPoint() private method

Checks if given point is contained within upper and lower pie slice surfaces or within the outer slice brink.
private CylinderSurfaceSectionContainsPoint ( PointF point, float startAngle, float endAngle, PointF point1, PointF point2 ) : bool
point System.Drawing.PointF /// PointF structure to check for. ///
startAngle float /// Start angle of the slice. ///
endAngle float /// End angle of the slice. ///
point1 System.Drawing.PointF /// Starting point on the periphery. ///
point2 System.Drawing.PointF /// Ending point on the periphery. ///
return bool
        private bool CylinderSurfaceSectionContainsPoint(PointF point, float startAngle, float endAngle, PointF point1, PointF point2)
        {
            if (m_sliceHeight > 0) {
                return Quadrilateral.Contains(point, new PointF[] { point1, new PointF(point1.X, point1.Y + m_sliceHeight), new PointF(point2.X, point2.Y + m_sliceHeight), point2 } );
            }
            return false;
        }