public void scaleTextureCoordinates(Vector2f scaleFactor) {
        VertexBuffer tc = getBuffer(Type.TexCoord);
        if (tc == null) {
            throw new IllegalStateException("The mesh has no texture coordinates");
        }

        if (tc.getFormat() != VertexBuffer.Format.Float) {
            throw new UnsupportedOperationException("Only float texture coord format is supported");
        }

        if (tc.getNumComponents() != 2) {
            throw new UnsupportedOperationException("Only 2D texture coords are supported");
        }

        FloatBuffer fb = (FloatBuffer) tc.getData();
        fb.clear();
        for (int i = 0; i < fb.limit() / 2; i++) {
            float x = fb.get();
            float y = fb.get();
            fb.position(fb.position() - 2);
            x *= scaleFactor.getX();
            y *= scaleFactor.getY();
            fb.put(x).put(y);
        }
        fb.clear();
        tc.updateData(fb);
    }
Scales the texture coordinate buffer on this mesh by the given scale
factor.
<p>
Note that values above 1 will cause the
texture to tile, while values below 1 will cause the texture
to stretch.
</p>

@param scaleFactor The scale factor to scale by. Every texture
coordinate is multiplied by this vector to get the result.

@throws IllegalStateException If there's no texture coordinate
buffer on the mesh
@throws UnsupportedOperationException If the texture coordinate
buffer is not in 2D float format.
jme3-core/src/main/java/com/jme3/scene/Mesh.java