What's new
Photoshop Gurus Forum

Welcome to Photoshop Gurus forum. Register a free account today to become a member! It's completely free. Once signed in, you'll enjoy an ad-free experience and be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

Actions Apply a Camera RAW preset to a Smart Object in an action


redflyr

New Member
Messages
4
Likes
0
So I'm building an action to stage a Camera RAW Smart Object file and get it ready for some manual HDR. I've hit a wall in my actioning with trying to apply a Camera RAW preset I made. I export the files from Lightroom as Smart Objects and in the action double click the SO and PS stops recording at "Edit Contents".

And so I ask, how might one apply a Camera RAW preset to a SO in an action?



I tried using the camera raw filter, thinking i might be clever, I wasn't, doesn't work right.
 

Paul MR

The Script Master
Messages
382
Likes
206
I am not sure I can help here as I only have CS6 and I believe you are talking about the Camera Raw Filter in CC?
If you can create an action that does what you want when the SO is opened then there may be a workaround.

What you would need to do:
Create the action when the SO is opened.
Save the following code in the Applications Presets/Scripts folder as a plain text file with a ".jsx" extension
N.B. You need to amend the code with the ActionName and the ActionSet of your action (it is case sensitive!)

Code:
#target photoshop;
app.bringToFront();


main();
function main(){
if(!documents.length) return;
if (activeDocument.activeLayer.kind == LayerKind.SMARTOBJECT){
executeAction( stringIDToTypeID('placedLayerEditContents'), undefined, DialogModes.NO );
//Amend ActionName and ActionSet to suit NB: these are case sensitive!
doAction('ActionName','ActionSet');
try{app.activeDocument.save();}catch(e){}
app.activeDocument.close(SaveOptions.DONOTSAVECHANGES);
    }
};
Now in your original action you need to call the script (instead of opening the SO)
This is done via fly out menu of the action palette and select "Insert Menu Item" then File - Scripts - select the script.

The script will open the SO, run your action update/and then close the SO.
 

redflyr

New Member
Messages
4
Likes
0
wow, thank you, this is some next level automating. I'll get into this this weekend and tell you how it goes. :)
 

Top