FloatBuffer texs = BufferUtils.createVector2Buffer(((FloatBuffer)batch.getTextureBuffers().get(0)), batch.getVertexCount()); batch.getTextureBuffers().set(0, texs); texs.clear();
FloatBuffer texs = BufferUtils.createVector2Buffer(batch .getTextureBuffers().get(0), batch.getVertexCount()); batch.getTextureBuffers().set(0, texs); texs.clear();
   private void buildTextureCoordinates() {       offset.x += (int) (offsetAmount * stepScale.x);       offset.y += (int) (offsetAmount * stepScale.z);       TriangleBatch batch = getBatch(0);       FloatBuffer texs = BufferUtils.createVector2Buffer(((FloatBuffer)batch.getTextureBuffers().get(0)), batch.getVertexCount());       batch.getTextureBuffers().set(0, texs);       texs.clear();       batch.getVertexBuffer().rewind();       for (int i = 0; i < batch.getVertexCount(); i++) {           texs.put((batch.getVertexBuffer().get() + offset.x)                   / (stepScale.x * (totalSize - 1)));           batch.getVertexBuffer().get(); // ignore vert y coord.           texs.put((batch.getVertexBuffer().get() + offset.y)                   / (stepScale.z * (totalSize - 1)));       }   }