Skip to main content
Adobe Photoshop Family

8 Messages

 • 

224 Points

Wed, May 30, 2018 9:29 AM

Answered

Photoshop: How do I create a separate group for every selected layer?

I need to put each layer in my Photoshop document into its own group. 

Ideally I'd select all my layers and have a command or action that puts them each into their own respective groups that have the same names as the layers themselves. CTRL G just works for creating one single group and names it "Group #". 

I work as a compositor in animation. For every background in every scene I have up to thirty layers. These all need to be imported into Toon Boom, but Toon Boom only imports a group as a separate layer (in other words, if I have 10 layers but no groups in my PSD file, Toon Boom will merge those ten layers into one). 

Naming and organizing layers accurately is extremely important for compositing. So if anyone has a script for this or has any brilliant ideas on how to do it faster than manually, it would make a huge difference and my thanks would be most eloquently typed in this conversation! :D

Responses

Champion

 • 

623 Messages

 • 

14.6K Points

2 years ago

Short of writing a script to do it, you can record actions that use the "Select next/previous layer" hotkey instead of directly selecting a layer using your mouse and they will be repeatable on any set of layers... So

  1. select the bottom most layer
  2. start recording a new action and give it a hotkey like F6 in the dialog box that appears.
  3. Start recording
  4. ctrl/cmd-g (new group)
  5. alt/opt-] (select previous layer)
  6. stop recording
Now you should have an action that, when you start at the bottom layer, will let you just mash the F6 key 30 times.

361 Messages

 • 

6.9K Points

2 years ago

You could see if this script will work for you Photoshop CC 2018 required and it does all layers.
www.ps-bridge-scripts.talktalk.net/download/groupsFromLayers.zip

Good luck.

361 Messages

 • 

6.9K Points

Edit: I have updated the zip, there are now two scripts one does all layers and the other does selected layers.

Champion

 • 

623 Messages

 • 

14.6K Points

Thanks for the link Paul! Mind if I poke around in your code and crib some notes?

361 Messages

 • 

6.9K Points

Go ahead Max, it's just code :)

8 Messages

 • 

224 Points

This is great, saves a lot of time! The only thing I have to do now is manually place the layers in their corresponding groups. But that is a bunch less work than renaming every group manually! Thankyouuuuuuu!! <3

361 Messages

 • 

6.9K Points

That is strange, I have tested with CS3, CS5, CS6 and CC2018 and all put the layers in the corresponding layersets. 

8 Messages

 • 

224 Points

2 years ago

Dear Gentlemen,
As promised I will now proceed to express my gratitude with the utmost eloquence. You have both assisted a total stranger. I will remember this when we feast together in Valhalla and share our tales of victory. Your valor shines like a light brighter than Thor's lightning! 
Hahaha no but seriously this gives me something I can use and has given me some handy insights into actions! Thank you for your help and your clear communication :-)

361 Messages

 • 

6.9K Points

Please pass the scripts on to your  Toon Boom Pals if you think they may be of use.

8 Messages

 • 

224 Points

I totally will! I'll try to put it up on the Toon Boom Forum! I can't believe nobody else has asked for this yet... 

2 Messages

 • 

70 Points

Can you send the script if you please

2 Messages

 • 

70 Points