OSDN Git Service

bugfix: heightmap.setHeightScale is set from grid's heightscale instead of constant...
authoranthyon@gmail.com <anthyon@gmail.com@75d07b2b-3a1a-0410-a2c5-0572b91ccdca>
Fri, 10 Jun 2011 21:21:21 +0000 (21:21 +0000)
committeranthyon@gmail.com <anthyon@gmail.com@75d07b2b-3a1a-0410-a2c5-0572b91ccdca>
Fri, 10 Jun 2011 21:21:21 +0000 (21:21 +0000)
git-svn-id: http://jmonkeyengine.googlecode.com/svn/trunk@7570 75d07b2b-3a1a-0410-a2c5-0572b91ccdca

engine/src/terrain/com/jme3/terrain/heightmap/FractalHeightMapGrid.java

index 26c8419..ce35c1b 100644 (file)
@@ -49,7 +49,7 @@ public class FractalHeightMapGrid implements HeightMapGrid {
                                BufferedImage im = null;\r
                                im = ImageIO.read(new File(this.cacheDir, "terrain_" + (int) location.x + "_" + (int) location.z + ".png"));\r
                                heightmap = new Grayscale16BitHeightMap(im);\r
-                               heightmap.setHeightScale(256);\r
+                               heightmap.setHeightScale(heightScale);\r
                        } catch (IOException e) {}\r
                } else {\r
                        FloatBuffer buffer = this.base.getBuffer(location.x * (this.size - 1), location.z * (this.size - 1), 0, this.size);\r