How to create seamless textures

This is probably already known to everybody else, but either I’m an idiot, or I missed the day that everyone learned about it, but there’s a very quick and easy way to create seamless textures.

Now that I’m thinking of sharing the stuff that I make, I’ve become absolutely paranoid about having full rights to the textures that I use — which pretty much limits me to Linda Kellie’s texture collection. Which is huge, but still…

So, for example, I want to have a rock-textured wall in a building I’m making. There are a ton of public domain image sites where the images are completely free, can be used commercially, and don’t need to be attributed. The attribution part is important, because I’m too lazy to keep track of where every single texture came from and to find a place to credit the original creator.

So, for example, I found these nice rock textures at the site Public Domain Images — but, oh, noes, they’re not seamless. Normally, I’d give up and go home at this point, or try to mirror the image or something like that to get rid of the seam, but that never works well. Or maybe use a clone brush in GIMP to try to paint over the seam — though I’m really really bad at GIMP.

But somehow, when I Googled the topic today (is Google getting better?) I discovered that there’s a simple one-click way to turn a regular texture into a seamless one. Just open the image in GIMP and go to Filters-Map-Make Seamless.

Say, for example, there’s this nice photo of a barn on the National Park Service website, which is totally public domain:

I’m interested in that nice stonework it’s got at the top there.  I crop a little square out of it. (I use Paint because it’s fast and easy, and also because I still can’t crop in GIMP. It’s all those layers, they always trip me up.)

Pretty, no? But not yet seamless. So I open the image with GIMP (free download here) and go to Filters-Map-Make Seamless. One click. That’s it. No options, no settings, nothing. It does everything automatically. I save and I’m done.

These two images might look identical, but they’re not. Things are moved around slightly in the second one so that all the edges line up perfectly. I loaded both of these textures and put them on a wall, and you can see the seams in the first one if you look close.

The one on the left is the one with seams — if you look closely, you can see where the tiles meet.

Okay, you might have to look closer to see the seams:

The edges of the not-seamless tiles don’t line up.

I tried the same technique on a few other textures from Public Domain Images. Feel free to grab any of the textures on this page to do with as you like, they’re based on public domain images and I’m hereby sending them back into the public domain.

Seamless tile.

Colored stones seamless.

Old stone wall seamless.

Limestone concrete seamless.

One thing I noticed while doing this is that large, rectangular patterns don’t do well with the GIMP Make Seamless tool, while small and irregular patterns work great.

If you do happen to make a set of seamless textures based on public domain images, feel free to upload them to OpenSim Creations under a public domain license with a note about where you found the original public domain image. You can make your work public domain — or as close to it as you can legally get — by licensing it CCO — “No Rights Reserved.” 

The more public domain textures OpenSim creators have to work with, the more stuff they can create and distribute without worrying about license terms — and the less tempted OpenSim users will be to use stuff of unknown provenance.'

Maria Korolov

Maria Korolov is editor and publisher of Hypergrid Business. She has been a journalist for more than twenty years and has worked for the Chicago Tribune, Reuters, and Computerworld and has reported from over a dozen countries, including Russia and China.

  • Good idea. GIMP is quite powerful for a free piece of software (and once you get the hang of layers it is even better). What is great about that is you can use a digital camera (and most phones have a camera on them now days) and take photos of textures around where you live (but some things you still can’t just take photos of and share) and make them seamless, you don’t need a very high resolution camera (as the images arr going to end up no larger than 1024×1024, and most likely less).

    So you don’t just have to use the public domain images on the web, you can make your own images (and even make them public domain afterwards).

    I might just have to go around my house this week taking photos of interesting textures and making them seamless.

    The best way to get a handle on layers in GIMP is to think of them as a transparent piece of plastic (like an old over head projector) and you are just drawing on them with a marker pen.

    The easiest way I have found to crop an image when you want to just extract a small piece from it (like you are trying to do in the above article) is to just use the rectangle selection tool and then copy the selection and paste it as a new image using the Edit menu -> Paste as -> New Image (or just press: ctrl + shift +v).

    This will copy the bit selected then create a new image to fit the size of the piece. It basically auto-crops it for you. If you want to get precise about positioning and size of the area copied cropped then you can use the manual adjustments on the tool pane (usually on the side of the screen) where you can enter the exact pixel position and size of the selection rectangle.

    Also, if the final image is not to the exact dimensions you want, you can go to the Image menu -> Scale Image and then enter in the exact pixel dimensions you want to rescale the image to (think stretch or shrink). This is good if the texture you have is larger than you want (say 2048 x 2048 and you want it in 512 x 512). Just open up the scale image screen and enter in the size you want and it does it for you.

    Another tip is to have a master image at the higher resolution, but then make a copy of the image (either through making a copy of the image file or copying the image in GIMP and pasting as a new image), and then down scaling it for release, this preserves the original image in its full details and will allow you to more easily do other things with it later on (as OpenSim, computers and the internet get more powerful we might be having 2048 x 2048 textures).

    • Paul —

      Great cropping tip, thanks! Avoids the whole issue of whether I’m cropping to selection, cropping the image, etc… etc…

  • fantastic post Maria! =)

  • WesternPrairie

    This is good info, I never knew the feature was in Gimp!

  • Gren

    Should not use camera’s on phones for this as they are not capable of
    taking highest quality pictures. Really need a good Digital Camera as
    high a megapixel capable as finance permit.

    it will save as jpeg and 2048 or over. Taking the image into Photoshop,
    Gimp or the picture can be worked on after be made seamless,
    worked on meaning dodge, burn, smudge, blur, lens flare, liquify using
    filters or brushes to add dirt, scratches, I suppose Grunge effect
    layer, or you can even bake the image inworld using windlight settings
    then downloading to the image to work on it again.

    Iit’s always good to paint onto a layer over an image then merge down when finished, sometimes just called Flatten.

    For buildings textures you don’t want alpha usually so don’t save as PNG,
    save as TGA if with see through windows or JPEG if not, keep in mind
    that TGA retains more detail than JPEG so will look better. On mesh JPEG must be used.

    Sizes to save to is personal choice, a case of lag vs quality, I tend to compromise and save as 512×512 or for textures for smaller prims 256×256 or 128×128.