I have a lot of spritesheets that are poorly formatted that I want to decompose, or split out into many small images, one for each sprite. If I can do that, I can use my custom texture packer tool to build my game assets with.

My development tools are XNA and C# targetting Windows. How can I decompose the images?

  • 1
    \$\begingroup\$ you could load them up in paint and do as you wish : D \$\endgroup\$
    – Kestami
    Sep 11, 2012 at 14:56
  • \$\begingroup\$ Texture2D.GetData/SetData and some relatively simple maths. Depends on how the data is formatted. Follow it up with SaveAsPng. \$\endgroup\$ Sep 11, 2012 at 15:26
  • \$\begingroup\$ Paint = pain :) \$\endgroup\$ Sep 11, 2012 at 15:39
  • \$\begingroup\$ I'm not to sure how to do the simple math though \$\endgroup\$ Sep 11, 2012 at 15:40

3 Answers 3


Try Sprite Decomposer or Sprite Vortex, I believe both of them have automatic sprite cutting based on alpha.

  • 1
    \$\begingroup\$ Excellent! Sprite Vortex was the app I was looking for. \$\endgroup\$ Sep 11, 2012 at 16:14
  • 1
    \$\begingroup\$ Sprite Decomposer IS NOT WORKING ON MAC OS 10.9 \$\endgroup\$ Jul 26, 2014 at 4:59
  • \$\begingroup\$ I forked Sprite Decomposer and ported it to QT5 for modern OS X support. Please check out the github repo with pre-built binaries available at its sourceforge home \$\endgroup\$
    – eriknelson
    Jan 1, 2015 at 21:03

Two methods come to mind, depending on the number of fragments that you want to create:

Either Paint, as noted in the comments. Easily faster than coding something up if you have a small-ish number of spritesheets and/or if you are missing most of the mappings.

Or you could write a little XNA program that goes something like this:

  • \$\begingroup\$ I do not have the mappings unfortunately \$\endgroup\$ Sep 11, 2012 at 15:42
  • \$\begingroup\$ @RaymondHolmboe Then you need to provide more detail. Is there any way that a program could distinguish one texture map from another automatically, or do all sub-textures have the same size, or whatever? If you have more info, please add it to your question, otherwise I don't see how you can solve it other than with Paint. \$\endgroup\$
    – Hackworth
    Sep 11, 2012 at 15:55

You need to ether go to Adobe fireworks or Paint

But if your doing paint your also going to need paint.net! becuase if you use paint its going to have a background so once you open that sprite in paint.net you can take the background away its really simple but if your worryed about textures like in games you have to make your own.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .