Skip to content

Instantly share code, notes, and snippets.

@aescripts
Created November 27, 2017 23:34
Embed
What would you like to do?
Kiyaga edwin #AfterEffects #Script #KBar Create solid named background with a ramp effect
//Create solid named background with a ramp effect
myComp = app.project.activeItem;
app.beginUndoGroup("Add Ramp")
mySolid = myComp.layers.addSolid([0,.8,.4], "BG", myComp.width, myComp.height,1);
mySolid.startTime = 0
myEffect = mySolid.property("Effects").addProperty("Ramp");
app.endUndoGroup();
@aescripts
Copy link
Author

"Ramp" needs to be changed to "Gradient Ramp" from CC 2016 on... they changed the name of the effect.

myComp = app.project.activeItem;
app.beginUndoGroup("Add Gradient Ramp")
mySolid = myComp.layers.addSolid([0,.8,.4], "BG", myComp.width, myComp.height,1);
mySolid.startTime = 0
myEffect = mySolid.property("Effects").addProperty("Gradient Ramp");
app.endUndoGroup();

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment