Filled Polygon

Inspired by @Bortels I wrote a code to fill polygons, but without the use of sprites. I thought this can be used to fill facets of a 3D cube and let that rotate then. Had no idea how doing that with sprites.
Please find the code here.

Any comments how to improve are welcome