ofxTriangle
ofxTriangle copied to clipboard
need a setup() / or constructor that sets inits some variables
nTriangles is set to 0 in clear() but nowhere else, so sometimes it has a bad default value and since the triangulate function never sets this to zero (it should, right?) the nTriangles count can be crazy.
in order to not crash or get good values back, I need to call:
TRI.clear();
TRI.triangulate(pts);
it might be fine to clear that in the constructor, or make a setup function, but it's not that obvious to call clear before the triangulate function.