public FloatBuffer writeTexCoordArray(FloatBuffer store, Vector2f offset, Vector2f scale){
        if (store!=null){
            if (store.remaining() < getWidth()*getHeight()*2)
                throw new BufferUnderflowException();
        }else{
            store = BufferUtils.createFloatBuffer(getWidth()*getHeight()*2);
        }

        if (offset == null)
            offset = new Vector2f();

        Vector2f tcStore = new Vector2f();
        for (int y = 0; y < getHeight(); y++){
            for (int x = 0; x < getWidth(); x++){
                getUV(x,y,tcStore);
                store.put( offset.x + tcStore.x * scale.x );
                store.put( offset.y + tcStore.y * scale.y );
            }

        }

        return store;
    }
Creates a vertex array from the height data in this Geomap

The scale argument specifies the scale to use for the vertex buffer.
For example, if scale is 10,1,10, then the greatest X value is getWidth()*10

@param store A preallocated FloatBuffer where to store the data (optional), 
size must be &gt;= getWidth()*getHeight()*3
@param scale Created vertexes are scaled by this vector

@return store, or a new FloatBuffer if store is null

@throws NullPointerException If isLoaded() is false
jme3-terrain/src/main/java/com/jme3/terrain/GeoMap.java