View Full Version : Adobe AfterEffects CS6 scripting
ArtemusMaximus
02-06-2014, 20:58
Does anyone have experience with scripting in Adobe AfterEffects CS6?
I created a composition as a template, now I want to copy-to-new composition, update name of composition and update text in 2 text layers. Composition name and text are stored in a list (Excel, csv, txt - whatever will make it easier).
ArtemusMaximus
02-06-2014, 23:49
Does anyone have experience with scripting in Adobe AfterEffects CS6?
I created a composition as a template, now I want to copy-to-new composition, update name of composition and update text in 2 text layers. Composition name and text are stored in a list (Excel, csv, txt - whatever will make it easier).
Well, digging through manuals, guides and Google for 2 hours has paid off. created script that updated what I needed in seconds instead of 7-8 hours manually :)
This experience definitely made me appreciate the work involved for the credits at the end of the movie. There is a lot of work to add over 350 names to the credit roll (thats what I am working on)
Don't leave us hanging :). How did you do it?
ArtemusMaximus
06-06-2014, 12:33
Don't leave us hanging :). How did you do it?
I wasn't sure if anyone cared :). I will add info when I get home.
ArtemusMaximus
06-06-2014, 19:07
Don't leave us hanging :). How did you do it?
Background:
this part of the project is for the ending credits for dance school year end show video that I am working on. This year I wanted to do something interesting with credits and decided to do them in AfterEffects. There are over 300 kids, so I quickly realized that doing all of them manually will take a while.
Setup:
Each Dance title is in it's own composition
Each dancers name is in it's own composition
Each Dance compilation (dance title and dancer's names) is in it's own composition
Process:
I created a "_template" for the dancers name. copied & paste as many times as there names. "_" so that copies will paste at the beginning of the Project List.
Compiled list of dancers in Excel.
created formula to make the corresponding code.
actual code snippet is here:
var myProperty = "Source Text";
var myComp = app.project.item(1); var CompName = "ArtemusMaximus"; var Text1 = "Artemus"; var Text2 = "Maximus";myComp.name = CompName; myComp.layer(2).property(myProperty).setValue(Text 1); myComp.layer(3).property(myProperty).setValue(Text 2);
var myComp = app.project.item(1); var CompName = "Chief Delphi"; var Text1 = "Chief"; var Text2 = "Delphi";myComp.name = CompName; myComp.layer(2).property(myProperty).setValue(Text 1); myComp.layer(3).property(myProperty).setValue(Text 2);
Because it's JavaScript based I was able to flatten code into one line and made Excel formula much easier to create. So "pretty" code would look like this:
var myProperty = "Source Text";
var myComp = app.project.item(1);
var CompName = "ArtemusMaximus";
var Text1 = "Artemus";
var Text2 = "Maximus";
myComp.name = CompName;
myComp.layer(2).property(myProperty).setValue(Text 1);
myComp.layer(3).property(myProperty).setValue(Text 2);
var myComp = app.project.item(1);
var CompName = "Chief Delphi";
var Text1 = "Chief";
var Text2 = "Delphi";
myComp.name = CompName;
myComp.layer(2).property(myProperty).setValue(Text 1);
myComp.layer(3).property(myProperty).setValue(Text 2);
Here I created test credits. Nothing fancy, but it's better than before:
https://www.youtube.com/watch?v=n8_FXIuH9iQ
ArtemusMaximus
12-06-2014, 00:39
Don't leave us hanging :). How did you do it?
See, I told you. Nobody cares LOL
See, I told you. Nobody cares LOL
I would be willing to bet that your post will be visited by plenty of people from random Google searches looking for a solution to the same problem you had.
If you have knowledge to share, why not share it? What help is it to keep it all to yourself? :)
ArtemusMaximus
14-06-2014, 13:09
I would be willing to bet that your post will be visited by plenty of people from random Google searches looking for a solution to the same problem you had.
If you have knowledge to share, why not share it? What help is it to keep it all to yourself? :)
True, but it does help to know that it is useful to someone and time spent on sharing information is not wasted :).
Thanks for your post Keaton!
ArtemusMaximus
03-07-2014, 11:54
A little update.
Doing credits this way while looking good, it does require fair amount of computing power to render. 3 sets of credits took over 72 hours to render.
vBulletin® v3.6.4, Copyright ©2000-2017, Jelsoft Enterprises Ltd.