diff options
Diffstat (limited to 'OpenSim')
3 files changed, 3 insertions, 6 deletions
diff --git a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/FlattenSphere.cs b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/FlattenSphere.cs index e1d651b..7bf88f0 100644 --- a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/FlattenSphere.cs +++ b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/FlattenSphere.cs | |||
@@ -42,7 +42,6 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes | |||
42 | 42 | ||
43 | double sum = 0.0; | 43 | double sum = 0.0; |
44 | double step2 = 0.0; | 44 | double step2 = 0.0; |
45 | double durationFactor = 0.15; //MCP: tuned, but would be nice to come from ini file | ||
46 | 45 | ||
47 | // compute delta map | 46 | // compute delta map |
48 | for (x = 0; x < map.Width; x++) | 47 | for (x = 0; x < map.Width; x++) |
@@ -66,7 +65,7 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes | |||
66 | { | 65 | { |
67 | for (y = 0; y < map.Height; y++) | 66 | for (y = 0; y < map.Height; y++) |
68 | { | 67 | { |
69 | double z = TerrainUtil.SphericalFactor(x, y, rx, ry, strength) * duration * durationFactor; | 68 | double z = TerrainUtil.SphericalFactor(x, y, rx, ry, strength) * duration; |
70 | 69 | ||
71 | if (z > 0) // add in non-zero amount | 70 | if (z > 0) // add in non-zero amount |
72 | { | 71 | { |
diff --git a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/SmoothSphere.cs b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/SmoothSphere.cs index fa0389d..fc0a579 100644 --- a/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/SmoothSphere.cs +++ b/OpenSim/Region/Environment/Modules/World/Terrain/PaintBrushes/SmoothSphere.cs | |||
@@ -42,7 +42,6 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes | |||
42 | 42 | ||
43 | double area = strength; | 43 | double area = strength; |
44 | double step = strength / 4.0; | 44 | double step = strength / 4.0; |
45 | double durationFactor = 0.15; //MCP: tuned, but would be nice to come from ini file | ||
46 | 45 | ||
47 | // compute delta map | 46 | // compute delta map |
48 | for (x = 0; x < map.Width; x++) | 47 | for (x = 0; x < map.Width; x++) |
@@ -81,7 +80,7 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain.PaintBrushes | |||
81 | { | 80 | { |
82 | double da = z; | 81 | double da = z; |
83 | double a = (map[x, y] - tweak[x, y]) * da; | 82 | double a = (map[x, y] - tweak[x, y]) * da; |
84 | double newz = map[x, y] - (a * duration * durationFactor); | 83 | double newz = map[x, y] - (a * duration); |
85 | 84 | ||
86 | if (newz > 0.0) | 85 | if (newz > 0.0) |
87 | map[x, y] = newz; | 86 | map[x, y] = newz; |
diff --git a/OpenSim/Region/Environment/Modules/World/Terrain/TerrainUtil.cs b/OpenSim/Region/Environment/Modules/World/Terrain/TerrainUtil.cs index 797c6a0..def28eb 100644 --- a/OpenSim/Region/Environment/Modules/World/Terrain/TerrainUtil.cs +++ b/OpenSim/Region/Environment/Modules/World/Terrain/TerrainUtil.cs | |||
@@ -34,8 +34,7 @@ namespace OpenSim.Region.Environment.Modules.World.Terrain | |||
34 | { | 34 | { |
35 | public static double MetersToSphericalStrength(double size) | 35 | public static double MetersToSphericalStrength(double size) |
36 | { | 36 | { |
37 | //return Math.Pow(2, size); | 37 | return Math.Pow(2, size); |
38 | return (size + 1) * 2.0; // MCP: a more useful brush size range | ||
39 | } | 38 | } |
40 | 39 | ||
41 | public static double SphericalFactor(double x, double y, double rx, double ry, double size) | 40 | public static double SphericalFactor(double x, double y, double rx, double ry, double size) |