semi-working solution for polygon painting using the geometry shader