m.setBuffer(Type.Position, 3, BufferUtils.createFloatBuffer(vertices));
m.setBuffer(Type.TexCoord, 2, BufferUtils.createFloatBuffer(texCoords));
m.setBuffer(Type.Normal, 3, BufferUtils.createFloatBuffer(normals));
m.setBuffer(Type.Index, 1, BufferUtils.createIntBuffer(indexes));
m.updateCounts();
m.updateBound();
return new Geometry("Terrain", m);
}
private float getIsoLevel(float x, float y, float z, float scale,