0
$\begingroup$

I have n points that determine a polygon. I need to color the interior of this polygon with a color . How can I do this?

  • 0
    I assume the points are given in order? Because, in general, n points do not determine a polygon (for example, there are multiple polygons with vertices (0,0), (0,1), (1,0), (1,1), and (1/2, 1/2)). Also, are you doing this within a particular programming environment?2010-12-23
  • 1
    Related to your problem: [Point in polygon](http://en.wikipedia.org/wiki/Point_in_polygon) article on Wikipedia.2010-12-23
  • 0
    yes, i'm doing it in c#. And yes, the vertices are in order.2010-12-23
  • 1
    I believe this belongs on StackOverflow rather than here, unless you need to know something more of the mathematics. Does this link suit your needs? http://www.homeandlearn.co.uk/csharp/csharp_s15p4.html2010-12-23

1 Answers 1