MUCH better polygonizer (still buggy)