diff --git a/drawing.cpp b/drawing.cpp index 566f21c8..a0bc789c 100644 --- a/drawing.cpp +++ b/drawing.cpp @@ -1515,6 +1515,8 @@ bool broken_projection(dqi_poly& p0) { all.push_back(p0.V.T * glhr::gltopoint((*p0.tab)[p0.offset+i])); int fail = 0; int last_fail; + + for(auto& h: all) models::apply_orientation(h[0], h[1]); auto break_in = [&] (hyperpoint a, hyperpoint b) { return a[0] * b[0] <= 0 && (a[0] * b[zcoord] - b[0] * a[zcoord]) * (a[0] - b[0]) < 0; @@ -1528,6 +1530,11 @@ bool broken_projection(dqi_poly& p0) { p.tab = &v; p.offset = 0; p.V.T = Id; + + /* we don't rotate h's back, just change p.V */ + for(int i=0; i<3; i++) + models::apply_orientation(p.V.T[i][0], p.V.T[i][1]); + if(fail) { if(p0.tinf) return true; dynamicval ib(in_broken, true); diff --git a/hypgraph.cpp b/hypgraph.cpp index 30c88ae2..840ee8f6 100644 --- a/hypgraph.cpp +++ b/hypgraph.cpp @@ -2040,6 +2040,7 @@ EX void draw_boundary(int w) { h[broken_coord] = -sin_auto(a*degree) * rem; h[0] = sin_auto(a*degree) * eps * s; h[unbroken_coord] = cos_auto(a*degree); + models::apply_orientation(h[1], h[0]); curvepoint(h); } queuecurve(shiftless(Id), periodcolor, 0, PPR::CIRCLE).flags |= POLY_FORCEWIDE;