Creative COW SIGN IN :: SPONSORS :: ABOUT US :: CONTACT US
ADOBE AFTER EFFECTS: HomeForumBasicsExpressionsTutorialsPodcastsMotion GraphicsTrainingCinema 4DFAQ

Re: Render error when attempting to render renamed psd file

Cow Forums : Adobe After Effects Expressions
VIEW POSTS   •   ADD A NEW POST   •   SEARCH   •   CHANGE FORUM
Respond to this post   •   Return to posts index   •   Read entire thread


Re: Render error when attempting to render renamed psd file
by Xinlai Ni on Nov 6, 2009 at 7:29:54 pm

First of all, Photoshop template expects the file name to be something like: rendered[#####].psd, so the rendering program can fill in the sequence index - even if you only render 1 frame. So if you change your last line to
renderItem.outputModules[1].file = new File(retPathObj.fullName + '/' + theComp.name + '_' + i.toString() + '-[#####].psd')
It should work, except it adds 00000 to every output frame.
By the way, you can greatly simplify your code by using the renderItem.skipFrames attribute - if you set renderItem.skipFrames = 1, every other frame will be rendered, if 2, every 3rd frame is rendered. So discarding your loop, you'll have something like:
var renderItem = app.project.renderQueue.items.add(theComp);
renderItem.timeSpanStart = 0;
renderItem.timeSpanDuration = theComp.duration;
renderItem.skipFrames = 5; // render every 6th frame
renderItem.outputModules[1].applyTemplate("Photoshop");
renderItem.outputModules[1].file = new File(retPathObj.fullName + '/' + theComp.name + '-[#####].psd')


This way, you only have 1 render item which outputs all sampled frames for you.

Xinlai Ni
Software Engineer, Google Inc.


Respond to this post   •   Return to posts index   •   Read entire thread


Current Message Thread:




Note: If you are a registered user please click here to login before posting.

Your post will not be accepted if your name and email address are not registered in our database. Click here if you do not have an account.

Name
E-Mail Address
Subject
E-Mail me when someone responds
Just This Message   Entire Thread   None  

Message:



Note: The following are HTML characters and may cause parts of your post to disappear if not used correctly: < > &
To include any portion of the post in your response, highlight the desired text and hit the "Q" key. Read more...



Please post Expressions Code in the box below:


Add your message signature


 


Note: By clicking "Post Direct" button above, you are agreeing to the Creative Cow's Code of Conduct.



FORUMSTUTORIALSMAGAZINETRAININGVIDEOS - REELSPODCASTSEVENTSSERVICESNEWSLETTERNEWSBLOGS

© CreativeCOW.net All rights are reserved.

[Top]