THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 24/11/2011 at 08:30, xxxxxxxx wrote:
Originally posted by xxxxxxxx
If I understand, you expect the problem comes from the render process not taking into account the change made to the camera, right ?
No, the camera change is fine. I just want that frame to be rendered over and over. I know, logically if I do that I'm just writing over the same file but was hoping to have it increment the file number.
Originally posted by xxxxxxxx
Have you tried to call doc- >AnimateDocument(0) after doc- >SetTime() and before EventAdd() ?
And I'm just curious, how do you got the non-active document with COFFEE ?
That didn't seem to help. As for non-active, I guess I wasn't doing it. Thought I had done that but guess not. Here is a condensed version of my code:
main(doc,op)
{
//bunch of code to get my coffee tag and the align to spline tag
//now the time stuff
var t = doc->GetTime();
var f = t->GetFrame(30);
//float that says start of align to spline
var start = myTag#ID_USERDATA:1;
//float that says end of align to spline
var finish = myTag#ID_USERDATA:2;
//number of steps needed
var frames = myTag#ID_USERDATA:3;
//the frame I want to catpture from multiple angles
var renderFrame = myTag#ID_USERDATA:4;
if(f > renderFrame)
{
var frameStep = (finish - start) / frames;
if(myTag#ALIGNTOSPLINETAG_POSITION < finish)
{
myTag#ALIGNTOSPLINETAG_POSITION = myTag#ALIGNTOSPLINETAG_POSITION + frameStep;
}
if(myTag#ALIGNTOSPLINETAG_POSITION > finish)
{
myTag#ALIGNTOSPLINETAG_POSITION = finish;
println("finished");
}
else
{
t->SetFrame(renderFrame,30);
doc->SetTime(t);
doc->AnimateDocument(0);
EventAdd();
}
}
}
So it moves the camera by 'frameStep' each time it enters the frame. My problem is that instead of jumping to renderFrame, it keeps going forward.