Add adjustment layer + rename it + preset

Hi!

Firstly, thank you, what a great tool!

I tried creating an automation that would…

  1. Run a script. This script adds a camera, then an adjustment layer with pseudo effects to control the camera. The adjustment layer is called CAMERA CONTROLLER. That script is called “Camera Controller”, from here: Camera Controller
  2. Adds an adjustment layer
  3. Renames the newly created adjustment layer
  4. Applies a “user” animation preset to the adjustment layer.

Unfortunately, I ran into two issues:

  • The renaming part of the automation renamed both the newly created adjustment layer, AND the adjustment layer created in the first step by the script.
  • I don’t know how to add a preset to the layer using automation toolkit :sweat_smile: perhaps it’s not possible but I’m not sure

Is it possible to just rename that newly created adjustment layer without affecting any other adjustment layers in the comp? Is it possible to add one of my user presets?

Not sure if I should ask this question in a separate conversation, but is it possible to add keyframes to a property at specific points of a layer, with a specific value? For example, I’d like to add a keyframe with a value of 5 at playhead to the “Tilt” property in the CAMERA CONTROLLER layer created in step one of the automation. Then 20 frames later another keyframe with a value of 5.

Anyway, I realize this is probably quite complicated, and I understand if it’s not possible but just asking in case it’s possible and I just can’t figure it out…

Thanks again!

AR

1 Like

Hi Ariel, thank you and welcome to the forum!

I will try to answer all your questions but I should first tell you that everything you mention is possible to create with Automation Toolkit without too much effort.
I will explain the process step by step and will also include the Automation Files for you to download.

  1. I guess you figured out that you can run scripts using the “menu command” project action, this is the correct way but there will be a problem with the “undo” and it will create an error, there is an easy fix for this issue, you can delete the lines “app.beginUndoGroup(“Create rigged camera”);” and “app.endUndoGroup();” from the script file or just download the my modified version of the script without these lines(only this change). download here -
  2. In the latest update I have added a new action to the items called “add adjustment layer”.
    this action adds a new adjustment layer with a custom predefined name at index 1 of the composition,
    in order to use this action first you have to loop over the “layers in the active comp” and then create inside the loop a new variable and change it’s type to Item(item can be a composition) then you have to select the loop and then the property “containing comp”, this variable now will be the active composition, you can now add an action after the loop and select the comp variable then select the action “add adjustment layer”, you can type the name of the new adjustment layer too.
  3. You can name your adjustment layer in the last step.
  4. You can apply an animation preset to a layer using the layer action “apply animation preset” and type the name of the preset, first you need to loop over the layers in the active comp and then add an if automation line and ask if the layer index property is equal to 1, so this will apply the preset only on the layer at the index of 1, inside the if add an action automation line and select the loop, then select the action “apply animation preset” and type the name of your preset.

Your last question about adding keyframes to effect’s property is more difficult to explain step by step,
I created a tutorial about this subject - https://youtu.be/pspx0mFCudY
this process involve looping on the effects of the layers, then loop on the properties of this specific effect named “Camera Controller” , finding the property called “Tilt”, changing the time of the property to the time indicator of the composition(the time of the new keyframe), add a keyframe with the value of 5, changing the time of the property again to the time indicator of the comp + 1 / frame rate * 20 (frame count) this will calculate the current time + 20 frames based on the frame rate, then add a keyframe again with the value of 5.
I think that the best way for you to learn is to look inside the automation and try to examine how it works based on my explanation.

Please feel free to open more topics and ask more questions,
Thanks,
Alon

Camera Controller Automations + the modified “Camera Controller.jsx” script - Camera Controller.zip (8.7 KB)
(make sure to use the latest version of Automation Toolkit).

Wow thank you so much for such prompt reply, and for going as far as making the automation, modifying the script and explaining everything.

I’m starting to understand how complex automations work much better now, and like you said between your explanation and that video, I was able to make sense out of most of it. Don’t know how I missed that tutorial before.

Anyway, thanks again for this and all your other efforts!

Update: One thing I’d like to understand better is copy and paste. I don’t know how to move around the lines of automation. For example, I wanted to swap the two steps. First add the adjustment layer, add the preset and keyframes, and then run the camera controller script. Not an important change especially for this automation, but I still couldn’t figure out how to copy and paste them. Drag and drop might be nice, perhaps I’ll put that on the requests section. Maybe even adding a cut, not just copy.

Thanks again!

AR

@arielreyes001 I know how much effort it takes to learn a new and complex tool and also learning how to create automations can be challenging, I really appreciate anyone who come up with his own ideas and trying to make them a reality so I want to help as much as I can, it’s really my pleasure!

For your question,
there is not one correct way to move automation lines around,

  1. the best way is not having to move them around too much and think about the order of the automation before creating it but this is not always possible.
  2. The second way is to delete and recreate lines in the right order.
  3. The third way is using the copy and paste, but you should know that if you copy some of the lines, and other lines using some of the variables or loops, removing these lines will break the connections of the other lines, you should select the lines you want to copy(with shift or control) then click the copy button, click the paste and choose with the blue arrows where to paste them.

A “cut” function could be handy in some cases so I will look into implementing this in feature update (the copy and paste functions have only been added recently too).
Drag and Drop won’t be possible in the current iteration of automation toolkit because automation toolkit is a script and not extension.
Thanks,
Alon