I have a keyframed animation of many moving objects and I want to add a little bit of random wiggle to the rotation and position of them. Is this possible? If so, how can I do it?
1 Answer
You will have to put these nodes into a loop to use the effect on multiple objects. To get different motions for every object you have to link the Index output of the Loop Input node with the Seed input of the Wiggle Vector node.
Make sure that you disable "Use Current Transforms" in the Object Transforms Input node. Otherwise the objects will move away when you stop the playback. You find the setting in the advanced node settings panel on the right.
The basic idea here is that you evaluate the fCurve to get the location the cube would normally have (the Transforms Input node does that). Then you create an additional vector that wiggles around the origin with a maximum amplitude (0.5 in the image above).
By adding both vectors together you get an offset on top of the original keyframed position. The last node sets the new location on the object and overwrites the keyframed position.
-
$\begingroup$ Thanks a lot ! It works almost as I want now, except I want the wiggle to be random for every single object. Now they wiggle all the same. (guess I need to put one more loop in the loop? ) Another problem, when I stop animation playback, objects start to move away. Is there a better fix to this, than disabling the X Y Z in the output node? Also as I saw in your previous AN versions there was a button for list node - add from selection. I have a lot of objects in my project. Is there an alternative for that button in the new AN ? Here`s what I did youtube.com/watch?v=2RpxELzK4MI $\endgroup$ Dec 4, 2015 at 12:10
-
$\begingroup$ I edited my answer. About the "From Selection" button: yes there is an alternative. I guess in your version you will find this button in the advanced node settings of the Create List Node. In even newer versions this button will be in the node again, but that is for later.. Another good way to manage many objects is to put them into a group (ctrl-g) and to use the "Objects from Group" node. $\endgroup$ Dec 4, 2015 at 12:37
-
$\begingroup$ nice, much thanks for educating me. I also need to keyframe the wiggle amount. As I understand it
s Blender
s limitation, that I can`t see node keyframes in dope sheet? $\endgroup$ Dec 4, 2015 at 12:49 -
$\begingroup$ yes it is a Blender limitation. For more details you should make a new question :) $\endgroup$ Dec 4, 2015 at 12:55
s no option to control noise intensity for all objects with one global parameter. And I can
t create keyframes for noise strength in graph editor - I need the wiggle only at moments when objects are moving, that`s why I need to keyframe it. $\endgroup$