From fa86a88ea37710646713228cae89b7babd52bde7 Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Wed, 11 Apr 2018 00:55:05 +0200 Subject: [PATCH] gp:: removed the unused version of be_in_triangle --- goldberg.cpp | 14 ++------------ hyper.h | 2 +- pattern2.cpp | 2 +- 3 files changed, 4 insertions(+), 14 deletions(-) diff --git a/goldberg.cpp b/goldberg.cpp index 1a97593f..f3a4ac80 100644 --- a/goldberg.cpp +++ b/goldberg.cpp @@ -511,7 +511,7 @@ namespace gp { pushScreen([texture_remap] () { gp::show(texture_remap); }); } - void be_in_triangle2(local_info& li) { // hyperpoint atz(const transmatrix& T, const transmatrix& corners, loc at, int cornerid = 6, ld cf = 3) { + void be_in_triangle(local_info& li) { int sp = 0; auto& at = li.relative; again: @@ -525,16 +525,6 @@ namespace gp { li.last_dir = fix7(li.last_dir - sp); } - void be_in_triangle(local_info& li) { - int& i = li.last_dir; - auto& at = li.relative; - - while(at.first < 0 || at.second < 0) { - at = at * eudir(1); - i = fix7(i-1); - } - } - int length(loc p) { return eudist(p.first, p.second); } @@ -568,7 +558,7 @@ namespace gp { int compute_dist(cell *c, int master_function(cell*)) { auto li = get_local_info(c); - be_in_triangle2(li); + be_in_triangle(li); cell *cm = c->master->c7; diff --git a/hyper.h b/hyper.h index 2e4feb84..40725b57 100644 --- a/hyper.h +++ b/hyper.h @@ -3006,7 +3006,7 @@ namespace gp { local_info get_local_info(cell *c); const char *disp(loc at); - void be_in_triangle2(local_info& li); + void be_in_triangle(local_info& li); int compute_dist(cell *c, int master_function(cell*)); diff --git a/pattern2.cpp b/pattern2.cpp index 44a3ed42..e96cce70 100644 --- a/pattern2.cpp +++ b/pattern2.cpp @@ -439,7 +439,7 @@ int getHemisphere(cell *c, int which) { int score = 0; if(gp::on) { auto li = gp::get_local_info(c); - gp::be_in_triangle2(li); + gp::be_in_triangle(li); auto corner = gp::corners * gp::loctoh_ort(li.relative); ld scored = corner[0] * getHemisphere(c->master->c7, which)