- fix in GeoMap constructor

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8743 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
nor..67 14 years ago
parent ca69ef57b7
commit 8d3aa7bad9
  1. 3
      engine/src/terrain/com/jme3/terrain/GeoMap.java
  2. 2
      engine/src/terrain/com/jme3/terrain/geomipmap/LODGeomap.java

@ -58,7 +58,8 @@ public class GeoMap implements Savable {
@Deprecated @Deprecated
public GeoMap(FloatBuffer heightData, int width, int height, int maxval){ public GeoMap(FloatBuffer heightData, int width, int height, int maxval){
this(new float[heightData.limit()], width, height, maxval); hdata = new float[heightData.limit()];
heightData.get(hdata);
this.width = width; this.width = width;
this.height = height; this.height = height;
this.maxval = maxval; this.maxval = maxval;

@ -72,7 +72,7 @@ public class LODGeomap extends GeoMap {
@Deprecated @Deprecated
public LODGeomap(int size, FloatBuffer heightMap) { public LODGeomap(int size, FloatBuffer heightMap) {
this(size, new float[heightMap.limit()]); super(heightMap, size, size, 1);
} }
public LODGeomap(int size, float[] heightMap) { public LODGeomap(int size, float[] heightMap) {

Loading…
Cancel
Save