1

I am trying to create an action in photoshop which duplicate the selected layer and decrease its opacity 0.5 less than the selected layer.

I tried to record action but its always sets fixed opacity which was at the time of recording action.

Do anyone have idea on achieving above thing, please help me.

1
  • 1
    Javascript could also work here.
    – Lucian
    Feb 24 '17 at 6:00
1

I don't think you can achieve that using Actions, your best bet is creating a Script for that. You can use purely Script for this, but if you still want to incorporate Actions into it (as the trigger), you can set the Action to use a Script after duplicating the current layer.

Open up a text editor, give it any name you want (the Script's name is the same as the filename), and paste this in:

#target photoshop

app.activeDocument.activeLayer.opacity = app.activeDocument.activeLayer.opacity / 2;

Save it as a .js or .jsx in your Scripts' folder (X:\~\Adobe\Adobe Photoshop XX\Presets\Scripts), and you can select Insert Menu Item from the Action menu to insert the script after the duplicate action.

Should look something like this.

0

Assuming you want a half of the previous opacity:

Go to the new layer and wipe the whole area once with a big solid eraser that has opacity=50%

The drawbacks:

  • permanet change, the opacity slider cannot take it back
  • works only for bitmap image layers

Other possiblities:

  • add a 50% grey layer mask, apply it as you remove the mask or
  • have originally a solid white layer mask, reduce the brightness of the mask 50% in the new layer

The last one is the most undestructive method and it applies also with adjustment layers

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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