aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/TerrainUtil.cs
diff options
context:
space:
mode:
authorUbitUmarov2019-01-20 20:58:27 +0000
committerUbitUmarov2019-01-20 20:58:27 +0000
commit0c38d52538a5d713e034fcec8da8df434e3ca924 (patch)
treeb54bb1749bae275e77bbfcaafb98833fd436748b /OpenSim/Region/Framework/Scenes/TerrainUtil.cs
parentcosmetics (diff)
downloadopensim-SC-0c38d52538a5d713e034fcec8da8df434e3ca924.zip
opensim-SC-0c38d52538a5d713e034fcec8da8df434e3ca924.tar.gz
opensim-SC-0c38d52538a5d713e034fcec8da8df434e3ca924.tar.bz2
opensim-SC-0c38d52538a5d713e034fcec8da8df434e3ca924.tar.xz
cosmetics on terrain patchs
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/TerrainUtil.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/TerrainUtil.cs16
1 files changed, 6 insertions, 10 deletions
diff --git a/OpenSim/Region/Framework/Scenes/TerrainUtil.cs b/OpenSim/Region/Framework/Scenes/TerrainUtil.cs
index 79ce908..7f76e01 100644
--- a/OpenSim/Region/Framework/Scenes/TerrainUtil.cs
+++ b/OpenSim/Region/Framework/Scenes/TerrainUtil.cs
@@ -62,17 +62,13 @@ namespace OpenSim.Region.Framework.Scenes
62 double h10 = map[(int) x + stepSize, (int) y]; 62 double h10 = map[(int) x + stepSize, (int) y];
63 double h01 = map[(int) x, (int) y + stepSize]; 63 double h01 = map[(int) x, (int) y + stepSize];
64 double h11 = map[(int) x + stepSize, (int) y + stepSize]; 64 double h11 = map[(int) x + stepSize, (int) y + stepSize];
65 double h1 = h00; 65 double a00 = h00;
66 double h2 = h10; 66 double a10 = h10 - h00;
67 double h3 = h01; 67 double a01 = h01 - h00;
68 double h4 = h11; 68 double a11 = h11 - h10 - h01 + h00;
69 double a00 = h1;
70 double a10 = h2 - h1;
71 double a01 = h3 - h1;
72 double a11 = h1 - h2 - h3 + h4;
73 double partialx = x - (int) x; 69 double partialx = x - (int) x;
74 double partialz = y - (int) y; 70 double partialy = y - (int) y;
75 double hi = a00 + (a10 * partialx) + (a01 * partialz) + (a11 * partialx * partialz); 71 double hi = a00 + (a10 * partialx) + (a01 * partialy) + (a11 * partialx * partialy);
76 return hi; 72 return hi;
77 } 73 }
78 74