2

I need some help here :( I want to know if it is possible to have a script export my layer groups as individual PNG files?

Let say im creating a texture map for a rock, so I save the photoshop document as Rock.psd

Now I want to export each texture group as the photoshop document name with an prefix for each layer group.

Example: Albedo layer group as Rock_AM.png Diffuse layer group as Rock_CM.png Specular layer group as Rock_SM.png Roughness layer group as Rock_RM.png Gloss layer group as Rock_GM.png Metalness layer group as Rock_MM.png Displacement layer group as Rock_DM.png Normal layer group as Rock_NM.png Self Illumination layer group as Rock_IM.png

Can that be possible? But if a layer group is empty I will like the layer group to be ignored. I want only export the layer groups that has layers inside.

enter image description here

Any help or guide please?

Thx, Alex

0

If you are using CS6 or older try this: http://www.peruho.com/web-design/export-your-assets-using-cut-and-slice-me/ It'll give you the options that photoshop cc gives you automatically (name a layer .png and then export it as such)

1

If you are using cc this doesnt even need a script.

Set.png behind the name of the group (Displacement.png) and then go to File > extract assets. This will extract the group as a singel png file

  • 1
    Hi JVS, I checked but had no luck. Where is the extract assets lockated? – Alex M. Feb 19 '15 at 0:05
  • Hi Alex, you need to be in Image > RGB mode for Extract Assets to work. But I do think your question is still a good point, and I will forward this workflow to the team that is working on Layers Panel. (I work on Photoshop but for exporting assets workflow) – Divya Manian Feb 19 '15 at 6:19
  • 1
    Also if you could email me manian@adobe.com about why you would want to use layer groups in this workflow, I would appreciate it very much. We are working on making Photoshop as easy to use as possible, so your help in making that possible would be much appreciated! – Divya Manian Feb 19 '15 at 6:51
1

I would use Comps for this. If you have the different versions you want already separated into groups/folders in Photoshop, all you have to do is create Comps of them. It's a couple of extra steps, but the automation that follows is worth it. In my situation I had multiple layers contained within each group/folder & this is what I did. This also assumes you've already given each group/folder an unique name:

Open both the Layers and Layer Comps panels. Double click on the first layer's name and Ctrl + C to copy it. Over in the comps panel, click the Create New Layer Comp icon (bottom of panel). Name the new comp the same as your first group. Continue that for all remaining groups. Then choose File > Export > Layer Comps to Files. You will get a dialog where you can copy/paste the path from the Windows Explorer path to the folder where you want the exported files to go or browse to it and give the files a common prefix name. The suffix will be the comp layer name. Then hit run.

I would like to see a script for just exporting the groups but there does not appear to be one built in, yet.

-1

This couldn't be easier, in Photoshop CC at least.

  1. Select a layer group (or multiple layer groups).
  2. Right click --> 'Export as' (or Quick Export as PNG)
  3. Set the options and save location
  • 1
    this might be an option to export manually a few groups, but seems OP is asking for a more automatic solution to export several groups at once. – Luciano Jan 23 '17 at 9:41
  • DanB's option helped me a lot! Maybe there's a way to select all Groups only - then this would be the fastest approach i guess! Greetz – Sebastian Mar 13 '17 at 18:43

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