Auto slice an image file based on transparency
Auto slice an image file based on transparency
Question
I have multiple small icons in a single file. They are separated with transparency. So I can manually select them and save individually. But this takes long time with many parts. Is it possible to automatically save each non-transparent piece to separate file?
Popular Answer
Actually, it depends on what you've got there.
If all icons reside on separat, individual layers, that's pretty easy. Go to your menu and select...
File > Scripts > Export Layers To Files
For your purposes, you'll most probably want to make sure you have the "Trim Layers" option checked.
If all your icons are on a single, transparent layer, it's easy too. You can use the regular "Save for Web & Devices" and export all slices as images in one go. To create slices, simply use the "slice tool" to select the individual icon areas.