diff options
author | Brian McBee | 2007-11-25 03:14:43 +0000 |
---|---|---|
committer | Brian McBee | 2007-11-25 03:14:43 +0000 |
commit | 6ed34cc27e53ad305f9306d5428868ca2a3b2128 (patch) | |
tree | 4b02229f27d9eedf3ff0c75000e7bb0ff432ede7 /OpenSim/Region/Terrain.BasicTerrain | |
parent | * Experimental updated Linux ODE library (diff) | |
download | opensim-SC-6ed34cc27e53ad305f9306d5428868ca2a3b2128.zip opensim-SC-6ed34cc27e53ad305f9306d5428868ca2a3b2128.tar.gz opensim-SC-6ed34cc27e53ad305f9306d5428868ca2a3b2128.tar.bz2 opensim-SC-6ed34cc27e53ad305f9306d5428868ca2a3b2128.tar.xz |
fixed order of map block requests to grid server. flipped map texture, as it was upside down.
Diffstat (limited to 'OpenSim/Region/Terrain.BasicTerrain')
-rw-r--r-- | OpenSim/Region/Terrain.BasicTerrain/TerrainEngine.cs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/OpenSim/Region/Terrain.BasicTerrain/TerrainEngine.cs b/OpenSim/Region/Terrain.BasicTerrain/TerrainEngine.cs index bbbb4d7..4ff22fb 100644 --- a/OpenSim/Region/Terrain.BasicTerrain/TerrainEngine.cs +++ b/OpenSim/Region/Terrain.BasicTerrain/TerrainEngine.cs | |||
@@ -1261,13 +1261,13 @@ namespace OpenSim.Region.Terrain | |||
1261 | } | 1261 | } |
1262 | 1262 | ||
1263 | Channel copy = heightmap.Copy(); | 1263 | Channel copy = heightmap.Copy(); |
1264 | for (int y = 0; y < copy.h; y++) | 1264 | for (int y = 0; y <copy.h; y++) |
1265 | { | 1265 | { |
1266 | for (int x = 0; x < copy.w; x++) | 1266 | for (int x = 0; x < copy.w; x++) |
1267 | { | 1267 | { |
1268 | // 512 is the largest possible height before colours clamp | 1268 | // 512 is the largest possible height before colours clamp |
1269 | int colorindex = (int) (Math.Max(Math.Min(1.0, copy.Get(x, y)/512.0), 0.0)*(pallete - 1)); | 1269 | int colorindex = (int) (Math.Max(Math.Min(1.0, copy.Get(x, y)/512.0), 0.0)*(pallete - 1)); |
1270 | bmp.SetPixel(x, y, colours[colorindex]); | 1270 | bmp.SetPixel(x, copy.h-y-1, colours[colorindex]); |
1271 | } | 1271 | } |
1272 | } | 1272 | } |
1273 | return bmp; | 1273 | return bmp; |