I have a setup with animation nodes. I think I misused it a little bit, since I am not using it for a continuous animation, but rather to generate a different random frame every frame. However, it is completely deterministic, since every random aspect is seeded by the current frame.

Now my problem is: In the end, I want to move around a few objects with a matrix or a transform (don't care which). It works fine in the viewport, but when rendering everything works except moving the objects (I'm also instancing some objects, assigning a material, calling scripts etc., which all seems to work).

Now I read this question, but that does not seem to be my issue since no information is preserved across frames and everything is deterministic via the seed. I found a little workaround to make it work, but it seems more like a hack: If I render my animation with the following script, it works:

def fake_render():
    scene = bpy.data.scenes["Scene"]

    for i in range(scene.frame_start, scene.frame_end + 1):
        scene.frame_current = i

It also works if I change the frame, then turn off automatic execution of the node tree and then render the frame like normally. However, I now can't render it as an animation. Any idea what could cause this behavior? How can I make it render as animation?

Edit: Some additional information: It seems to render before everything is executed. During rendering, in the viewport I can see that all the objects get instantiated at (0,0,0) as I want them to. Then, it renders, and then the objects move towards to where I want them to be.

This is the part that is not executed, everything before seems to work: This is not being executed, everything before seems to be executed.

Here you can find the .blend file. Here you can find the re-upload of the file

  • $\begingroup$ Can you provide the blend file? $\endgroup$ – Omar Emara Oct 30 '17 at 16:34
  • $\begingroup$ @OmarAhmad I edited the question to include it. $\endgroup$ – RunOrVeith Oct 30 '17 at 17:22
  • $\begingroup$ I think you are using an old version, the node tree doesn't work for me. So I may not be able to help you. What version are you using? $\endgroup$ – Omar Emara Oct 30 '17 at 19:50
  • $\begingroup$ I'm using version 2.0, is there a specific error? $\endgroup$ – RunOrVeith Oct 30 '17 at 21:46
  • $\begingroup$ All connections are gone for me. $\endgroup$ – Omar Emara Oct 31 '17 at 13:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.