Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My graphics designer has made graphics in separate PNG files. Is there a clever tool/script that mashes them into a spritesheet?

I could probably code something myself, but why re-invent the wheel :)

share|improve this question

closed as off-topic by Josh Petrie Mar 11 '15 at 2:04

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions about "how to get started," "what to learn next," or "which technology to use" are discussion-oriented questions which involve answers that are either based on opinion, or which are all equally valid. Those kinds of questions are outside the scope of this site. Visit our help center for more information." – Josh Petrie
If this question can be reworded to fit the rules in the help center, please edit the question.

possible duplicate of Tool for creating Spritesheet? and Tips – Byte56 Apr 11 '12 at 14:20
@jhocking If you can post an answer to that question that is verbatim to the answer you've posted here. They are duplicates :) – Byte56 Apr 11 '12 at 18:17
That's not a good rule at all. Just to be ridiculous: What is 2 + 2? What is 8 - 4? OMG SAME QUESTION – jhocking Apr 11 '12 at 19:27
More serious response: My answer is exactly the same, sure, but the accepted answer there is completely unrelated to this question. My answer applies in both places because this question is a specific case of that question; that question asked "any tools for any sprite tasks?" and this question is "tool for this one specific task?" Honestly my answer applies more here; I should've just made it a comment to someone else's answer there. – jhocking Apr 11 '12 at 19:42
The accepted answer there doesn't make any reference to packing lots of images into one atlas. You don't have to take my word for it, you can go and read it. That question is nominally about spritesheets because they are mentioned in the title, but the question is mostly about animation techniques for generating the frames used in a spritesheet. – jhocking Apr 12 '12 at 0:04

10 Answers 10

up vote 18 down vote accepted

Am I the only one who uses SpriteSheetPacker? It's free and open source so you can modify it and learn how it works.

share|improve this answer
No, 9 other people use it as well. But this tool, although free, doesn't give you nearly as much flexibility as TexturePacker – bobobobo Aug 31 '12 at 16:11
@bobobobo Yeah? And guess what your images end up like? More 'flexibility' and features yeah right.. – NiCk Newman Nov 30 '15 at 6:55
@NiCkNewman there are several sort options. Try that – Evorlor Feb 20 at 4:10
Yeah, trying to use that is a pain. – javydreamercsw May 9 at 18:47

I've been using TexturePacker to create sprites from a folder of PNG images. I'm porting a game originally developed in Flash, so I'm simply exporting each frame of the MovieClip to png and then importing those images in Texture Packer.

Another similar tool is Zwoptex

(The latter is Mac software, but TP has a version for Windows too.)

share|improve this answer
TP is for all O/S's. Has GUI. My favorite so far. Zwoptex is Mac only. – bobobobo Aug 31 '12 at 16:22
oh sweet I didn't know it's all OS's. Either that's new or I missed it before. – jhocking Aug 31 '12 at 16:34
Psshaw. Mac users. – bobobobo Aug 31 '12 at 18:08

There's a tool called Atlas Image Packer. It'll do as you want, take a number of images and produce a single large image that contains all the other images.

Also, I wish I had your problem. A graphics designer producing images for me.

share|improve this answer
Thanks! The site is actually migrated poorly and the link doesn't work when you click on it, but this one does: – joon Apr 12 '12 at 1:24

I really like libgdx's (game framework) packer. Maybe a bit cumbersome to set up the framework just for the packer, though.

The packer works great. Read the libgdx texturepacker doc here, and see for yourself. My favourite feature is that is also saves a document with info about all the textures in the big spritesheet/atlas, so you can easily make a script that gets them for you. Libgdx also has this build in, so I can load/display any texture by it's original filename, even though it's in a big atlas. There also exists a GUI for the packer.

Excerpt from a pack-file with info about some textures:

format: RGBA8888
filter: Nearest,Nearest
repeat: none
  rotate: false
  xy: 2, 2
  size: 800, 480
  orig: 800, 480
  offset: 0, 0
  index: -1
  rotate: false
  xy: 804, 2
  size: 64, 384
  orig: 64, 384
  offset: 0, 0
  index: -1
  rotate: false
  xy: 2, 484
  size: 591, 373
  orig: 591, 373
  offset: 0, 0
  index: -1
  rotate: false
  xy: 870, 2
  size: 64, 256
  orig: 64, 256
  offset: 0, 0
  index: -1
share|improve this answer

ImageMagick has a command line utility that can join images into what it calls a "montage." It can be tiring getting the right command line parameters to do what you want, but it's a very powerful and flexible tool. I use it very frequently for building spritesheets.

share|improve this answer
do you have any examples of the right parameters? – Simon_Weaver Mar 11 '15 at 0:22

I have decided to open source my 2D spritesheet and animation tool. It supports automatic sprite selection, combining images, sprite grouping, and multi-sprite animation with rotation.

It is written in Java, the github repo is here:

Website for the project is:

share|improve this answer

I ended up using this Processing script. You can download Processing for free at All files need to be in the same folder, and have a filename ending in a 4 digit number.

ArrayList<PImage> images = new ArrayList


void setup() {
  String folder = "file location ...";
  String file = "file prefix ...";
  String outfile = "output.png";
  int fileCount = 30;
  int cols = 7;
  int rows = 5;

  for (int i = 1; i <= fileCount; i++) {
    String number = "" + i;
    if(number.length() == 1) number ="000" + number;
    else if(number.length() == 2) number = "00" + number;
    PImage img = loadImage(folder+file + number +".png");

  PImage img = createImage(images.get(0).width * cols, images.get(0).height * rows, ARGB);
  for (int x = 0; x < images.get(0).width; x++) {
    for (int y = 0; y < images.get(0).height; y++) {
      for (int z = 0; z < images.size(); z++) {
          x+images.get(0).width* (z%cols),
          y +images.get(0).height * int(z/cols),
  println("Saving..."); + outfile);
share|improve this answer

I use a photoshop script to make spritesheets:

It can make oldskool tile grids as well as texture atlases, and can export a custom text file containing image size and position info. It works on PC and Mac, it's open source and written to be extensible.

share|improve this answer

I don't know if I understood question correcttly but I know the software that operates with textures and makes animation, sprite sheets anf .gif animations. see

share|improve this answer

The Compass framework has a sprite generation tool.


share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.