Rewritten the retriangulation method. Seems to work well in around 80% of the cases now.