diff --git a/3d-models.cpp b/3d-models.cpp index aa721011..3d36486c 100644 --- a/3d-models.cpp +++ b/3d-models.cpp @@ -30,7 +30,7 @@ vector geometry_information::get_shape(hpcshape sh) { return res; } -hyperpoint normalize_flat(hyperpoint h) { +EX hyperpoint normalize_flat(hyperpoint h) { if(prod) return product_decompose(h).second; return normalize(h); } diff --git a/nonisotropic.cpp b/nonisotropic.cpp index 27cae7f5..394ee2f2 100644 --- a/nonisotropic.cpp +++ b/nonisotropic.cpp @@ -842,6 +842,7 @@ EX namespace nisot { PHASEFROM(2); stop_game(); product::configure(); + if(vid.texture_step < 4) vid.texture_step = 4; return 0; } return 1; diff --git a/polygons.cpp b/polygons.cpp index 9ee225eb..e59654fc 100644 --- a/polygons.cpp +++ b/polygons.cpp @@ -704,13 +704,28 @@ void geometry_information::make_wall(int id, vector vertices, vector bshape(shWall3D[id], PPR::WALL); last->flags |= POLY_TRIANGLES; - + hyperpoint center = Hypc; int n = isize(vertices); + + vector altitudes; + if(prod) { + altitudes.resize(n); + for(int i=0; i vertices, vector hyperpoint h = center + v1 * x + v2 * y; if(nil && (x || y)) h = nilv::on_geodesic(center, nilv::on_geodesic(v1+center, v2+center, y / (x+y)), x + y); - if(prod) { hpcpush(h); return; } + if(prod) { + h = zshift(normalize_flat(h), center_altitude * (1-x-y) + altitudes[a] * x + altitudes[(a+1)%n] * y); + hpcpush(h); return; + } if(sol || !binarytiling) { hpcpush(normalize(h)); return; } hyperpoint res = binary::parabolic3(h[0], h[1]) * xpush0(yy*h[2]); hpcpush(res); @@ -730,7 +748,10 @@ void geometry_information::make_wall(int id, vector vertices, vector int STEP = vid.texture_step; for(int a=0; a