From a6fd8146dd530d1048d883c612597025d90adefa Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Sun, 3 Mar 2019 00:38:11 +0100 Subject: [PATCH] 3d:: binary:: changes so that it can be generate as an alt (virtualRebaseSimple, generation without c7 --- binary-tiling.cpp | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/binary-tiling.cpp b/binary-tiling.cpp index 59e047d2..63c71240 100644 --- a/binary-tiling.cpp +++ b/binary-tiling.cpp @@ -80,7 +80,8 @@ namespace binary { heptagon *build(heptagon *parent, int d, int d1, int t, int side, int delta) { auto h = buildHeptagon1(tailored_alloc (t), parent, d, hsOrigin, d1); h->distance = parent->distance + delta; - h->c7 = newCell(t, h); + h->c7 = NULL; + if(parent->c7) h->c7 = newCell(t, h); h->cdata = NULL; h->zebraval = side; #if DEBUG_BINARY_TILING @@ -403,6 +404,38 @@ int celldistance3(heptagon *c1, heptagon *c2) { int celldistance3(cell *c1, cell *c2) { return celldistance3(c1->master, c2->master); } #endif +void virtualRebaseSimple(heptagon*& base, transmatrix& at) { + + while(true) { + + double currz = at[DIM][DIM]; + + heptagon *h = base; + + heptagon *newbase = NULL; + + transmatrix bestV; + + for(int d=0; dcmove(d); + } + } + + if(newbase) { + base = newbase; + at = bestV; + continue; + } + + return; + } + } + } }