Implemented polygon drawing.