Christopher R. green
Forum Replies Created
-
Well, most of them 🙂
Thank you kindly! -
Christopher R. green
October 18, 2011 at 3:44 pm in reply to: Easily turning opacity on or off over framesI’m rather fond of setting the first few keyframes then using the expression:
loopOut("cycle");-cg
p.s. and when i say ‘few’, i mean the first 3 keyframes
-
Christopher R. green
February 13, 2011 at 7:27 am in reply to: Scale Multiple Compositions, not by percentThanks for the kind words, Walter. I usually feel that I barely keep up some sort of geek-cred.
I think it’s time to update one of those scripts soon …
-
Just to let you and others know, the text script has been updated to work with CS5.
I’ll be checking other scripts in the coming days.
-cg
-
Christopher R. green
January 12, 2011 at 1:08 am in reply to: AE CS5 crashes every single time I attempt to renderTo get some clues, you might open the Console app (/Applications/Utilities/) and dig around in the Console Messages (log) and System log.
The crash may have generated a message, although those messages can be pretty cryptic.
It may be an OpenGL issue. Try turning it off (prefs/previews) and see if that changes anything.Was there anything else installed between CS4 and CS5 before you started this render? (Including fonts)
Have other renders worked in CS5?
-cg
-
Here is the full script, no-panel version (copy and paste into text editor, save as text with “.jsx” file extension):
// Based on Dan Ebbert's script at motionscript.com
// crg_Text_from_File.jsx
// v2: added user interface, top-down layer order
// v3: added 'live leading' feature, and makes sure text layers are at top
// This script reads a user specified text file and
// either makes one text layer with all the text,
// or creates and places a bunch of text layers, one for each line
// read from the text file. Includes a few 'text layout' options.
// And yes, I'm still using the amazing jEdit (jedit.org -- not to be confused with similarly named apps) to write my scripts.var win = new Window('dialog', 'Text Import Options',[300,100,553,410]);
var w = buildUI();
if (w != null) {
w.show();
}function doBigOppBool(windo, bool) {
windo.lineSpaLbl.enabled = !bool;
windo.lineSpaAmtLbl.enabled = !bool;
windo.dnBtn.enabled = !bool;
windo.upBtn.enabled = !bool;
windo.dnTenBtn.enabled = !bool;
windo.upTenBtn.enabled = !bool;
windo.liveLeadCheck.value = false;
windo.liveLeadCheck.enabled = !bool;
}function buildUI() {
if (win != null) {
//win.textOpsPnl = win.add('panel', [10,35,244,221], '');
win.oneFileCheck = win.add('checkbox', [52,8,202,28], 'Import as One Layer');
win.oneFileCheck.onClick = function () { doBigOppBool(win, this.value); };win.lineSpaLbl = win.add('statictext', [70,42,180,63], 'Line Spacing:');
win.lineSpaLbl.justify = "center";
win.lineSpaAmtLbl = win.add('statictext', [105,68,145,90], '10');
win.lineSpaAmtLbl.justify = "center";win.dnBtn = win.add('button', [72,65,102,87], '-', {name:'dn1'});
win.dnBtn.onClick = function () {changeSpaNumber(win.lineSpaAmtLbl, -1); };
win.upBtn = win.add('button', [149,65,179,87], '+', {name:'up1'});
win.upBtn.onClick = function () {changeSpaNumber(win.lineSpaAmtLbl, 1); };
win.dnTenBtn = win.add('button', [17,65,67,87], '-10', {name:'dn101'});
win.dnTenBtn.onClick = function () {changeSpaNumber(win.lineSpaAmtLbl, -10); };
win.upTenBtn = win.add('button', [184,65,234,87], '+10', {name:'up101'});
win.upTenBtn.onClick = function () {changeSpaNumber(win.lineSpaAmtLbl, 10); };
win.topSpaLbl = win.add('statictext', [70,102,180,124], 'Space from Top:');
win.topSpaLbl.justify = "center";win.topSpaAmtLbl = win.add('statictext', [105,128,145,150], '10');
win.topSpaAmtLbl.justify = "center";
win.dnBtn2 = win.add('button', [72,125,102,147], '-', {name:'dn2'});
win.dnBtn2.onClick = function () {changeSpaNumber(win.topSpaAmtLbl, -1); };
win.upBtn2 = win.add('button', [149,125,179,147], '+', {name:'up2'});
win.upBtn2.onClick = function () {changeSpaNumber(win.topSpaAmtLbl, 1); };
win.dnTenBtn2 = win.add('button', [17,125,67,147], '-10', {name:'dn102'});
win.dnTenBtn2.onClick = function () {changeSpaNumber(win.topSpaAmtLbl, -10); };
win.upTenBtn2 = win.add('button', [184,125,234,147], '+10', {name:'up102'});
win.upTenBtn2.onClick = function () {changeSpaNumber(win.topSpaAmtLbl, 10); };
win.leftSpaLbl = win.add('statictext', [70,162,180,184], 'Space from Left:');
win.leftSpaLbl.justify = "center";win.leftSpaAmtLbl = win.add('statictext', [105,188,145,210], '10');
win.leftSpaAmtLbl.justify = "center";
win.dnBtn3 = win.add('button', [72,185,102,207], '-', {name:'dn3'});
win.dnBtn3.onClick = function () {changeSpaNumber(win.leftSpaAmtLbl, -1); };
win.upBtn3 = win.add('button', [149,185,179,207], '+', {name:'up3'});
win.upBtn3.onClick = function () {changeSpaNumber(win.leftSpaAmtLbl, 1); };
win.dnTenBtn3 = win.add('button', [17,185,67,207], '-10', {name:'dn103'});
win.dnTenBtn3.onClick = function () {changeSpaNumber(win.leftSpaAmtLbl, -10); };
win.upTenBtn3 = win.add('button', [184,185,234,207], '+10', {name:'up103'});
win.upTenBtn3.onClick = function () {changeSpaNumber(win.leftSpaAmtLbl, 10); };win.liveLeadCheck = win.add('checkbox', [52,8+223,202,28+223], 'Add "Live Leading"');
win.okBtn = win.add('button', [160,267,240,289], 'OK', {name:'OK'});
win.okBtn.onClick = function () {main(win);this.parent.close(1)};
win.cancBtn = win.add('button', [66,267,146,289], 'Cancel', {name:'Cancel'});
win.cancBtn.onClick = function () {this.parent.close(0)};
}
return win
}function main(winDough) {
inManyLayers = !winDough.oneFileCheck.value;
withLiveLeading = winDough.liveLeadCheck.value;// create undo group
app.beginUndoGroup("Text from File");// Prompt user to select text file
var myFile = fileGetDialog("Select a text file to open.", "");//, "TEXT txt");
if (myFile != null){
// create project if necessaryvar proj = app.project;
if (!proj) proj = app.newProject();
var activeItem = proj.activeItem;
var compBG = [.8,.8,.8] // comp background color// create new comp named 'text_comp'
// or use the selected comp
if (activeItem != null && (activeItem instanceof CompItem)){
var myComp = activeItem;} else {
//8.5x11 inches @ 72dpi
var compW = 612; // comp width
var compH = 792; // comp heightvar compL = 15; // comp length (seconds)
var compRate = 24; // comp frame ratevar myItemCollection = app.project.items;
var myComp = myItemCollection.addComp('text_comp',compW,compH,1,compL,compRate);
}
myComp.bgColor = compBG;
lineSpa = 12;if (inManyLayers) {
lineSpa = parseFloat(winDough.lineSpaAmtLbl.text);
}
topSpa = parseFloat(winDough.topSpaAmtLbl.text);leftSpa = parseFloat(winDough.leftSpaAmtLbl.text);
// open file
var fileOK = myFile.open("r","TEXT","????");
if (fileOK){var allText = "";
var o = 1;
var addForLead = 0;// read text lines
// until end-of-file is reached
var textCollection = new Array();while (!myFile.eof){
write("Reading and writing line #" + o + " ... ");
text = myFile.readln();
// script will likely throw amusing error*
// if line is empty
// * "having to focus on ourselves"
if (text == "") { text = "\r" ;}if (inManyLayers) {
// if user chose 'many layers' option, make new text layer each iteration
thisText = myComp.layers.addText(text);
thisText.property("Position").setValue([(leftSpa), ( (lineSpa * o) + topSpa)]);
if (o != 1) {thisText.moveAfter(myComp.layer(o));}// I figure, why use the memory if we don't need to:
if (withLiveLeading) { textCollection[(o-1)] = thisText; }} else {
// if user chose 'one layer' option, keep appending text variable:
allText = (allText + text + "\r");
}
o = (o + 1);
clearOutput();
}
clearOutput();if (! inManyLayers) {
// if user chose 'one layer' option, now make one text layer:
bigTextLayer = myComp.layers.addText(allText);
bigTextLayer.property("Position").setValue([leftSpa, topSpa]);
}
// close the file before exiting
myFile.close();if (withLiveLeading) {
//add null
leadingNull = myComp.layers.addNull();
leadingNull.name = "Leading Control (Adjust Y Pos)";
leadingNull.property("position").setValue([0,0]);//give text expression for adjustable line spacing
for (t = 0; t < (textCollection.length);t++) {
textCollection[t].property("position").expression =
"v=value;\r[value[0], (value[1]+index-2)+thisComp.layer(\"Leading Control (Adjust Y Pos)\").transform.position[1]*(index-2)];";
}
alert("Adjust the leading (line spacing) by adjusting the top layer's Y position.\r (don't forget, kids: \"Leading\" rhymes with \"heading\"!)");
}
} else {
alert("File open failed!");
}
}else{
alert("No text file selected.");
}app.endUndoGroup();
}function changeSpaNumber(theField, amt) {
i = parseFloat(theField.text);
i = (i + parseFloat(amt));
theField.text = i;
}
-
You must be on Windows. There is a Windows bug that either the folks at Adobe or the folks at Microsoft never fixed which makes objects in panels in jsx user interfaces not work. I forgot to make a non-panel version of this script. I’ll have to upload that tonight. On a more serious note, it appears the script may crash AE (OSX) when using the ‘live leading’ feature if the text file contains certain characters. I haven’t diagnosed that yet.
Having CS4 and CS5 on the same machine shouldn’t be a problem.All you would need to do to make the script work for you on Windows (with all options available) is to put two forward slashes (//) in front of this line:
win.textOpsPnl = win.add('panel', [10,35,244,221], '');so that it looks like this:
//win.textOpsPnl = win.add('panel', [10,35,244,221], '');or delete the line altogether.
Important: Just make sure that you edit and save the file as plain text, NOT rtf or anything else!
Best of luck and thanks for the info
-cg
-
Hi Ashley.
Just by luck I caught this post. Unfortunately I don’t have access to CS5 right now. I’m wondering if there is still some way of diagnosing the problem. Perhaps we can begin by you telling me what if anything happens when you run the script. Does it do anything at all?-Chris
-
Christopher R. green
December 8, 2010 at 9:45 pm in reply to: Maya Scene exported to After Effects too small for Lights[Isaac Wolfram] “Is there anyway to scale up the nulls and camera in after effects? or is there anyway to improve the export out of maya so it is larger in AE?”
There are 3 things you can do.
1) As far as I know, you can change the units/scale settings in Maya. If you don’t have access to that, …
2) You can create expressions to multiply all the positions, thus expanding the world. You could have a controller layer with a scale control that multiplies all the positions ‘outward’. I’ve done this and it works. You could keep the project like that, or then, for all those layers, do a ‘convert expressions to keyframes’ and, for all the non-animated (static) layers, delete the keyframes, and delete the expressions for those and for the animated stuff. What you then have is a scaled up scene in ae. You can also expand the scale of objects similarly if you need to.
3) Hack the ma file. If this idea freaks you out a little but you’d like to try it, send me the file and I’ll give it a shot for you. Shouldn’t take long for me to make a hacked version and send it back to you. If that interests you, send me an email at crgreen [at] crgreen dot com.
good luck!
-cg
-
[Renee Matthews] “Can someone please enlighten me on how to do this?”
Methodically! Seriously, though, you should start by determining how many tracked objects there are, how they interact/disappear/etc., then make a solid (which can be comp size, or maybe a little larger of largest blurred object in frame) that will act as your proto-blurrer. By this I mean a semi-transparent solid (named something like “blur-0”) that you keep intact and duplicate for each tracking job (each blurred object). Duplicating it should name the duplicate “blur-1”, the next “blur-2”, etc.
So, you duplicate the proto-blurrer, and this will be an adjustment layer — but not yet! Keep it a normal solid for now …
So you start with your first tracked object, actually name the tracker “1” or something, keep a log of each. When that track is done, you ‘apply’ the track to the appropriate blurrer, then check to make sure it sticks to the object in frame. You may have to adjust size/anchor point of the solid. Then make the layer 100% opacity and turn it into an adjustment layer and apply whatever obscuration fx to the adjustment layer. Repeat for each track.
This is, of course, a quick overview of a (one) process. Season to taste.Some objects may be tricky the way they scale, distort, disappear, etc., and you may need to separate some because of the way they interact/disappear, and you may have to do quite a bit of tweaking and adjusting. Being methodical and keeping a log of what goes where will help.
-crg