I’ve built a blender scene of a Rubik’s Cube to create animations of different move sequences for solving the cube. I’ve got a lot of sequences to create, so I need the simplest way possible to create each animation. However, I’m finding that animating rotation is a nightmare.

When I rotate one side of the cube (nine pieces around the cube’s centre), I’m struggling to get the individual pieces to behave. With XYZ Euler, the first couple of rotations are fine, but on the third rotation the pieces spin about into position. With Quaternion WXYZ, the pieces separate slightly.

I’ve also tried creating Child Of constraints, but it’s too much work as rotating one side means that I have to create keyframes for setting the influence of the parent to 1 for the nine pieces and then again to set the influence to 0. It takes an age.

Here’s a link to my blend file using XYZ Euler: https://www.dropbox.com/s/pp8iztzkz5mr5ki/Cube_XYZ_Euler.blend

I got the idea to use Quaternion rotation from this video, which also uses the same method for performing the rotations as me: http://www.youtube.com/watch?feature=player_detailpage&v=4fs01zdvtg0#t=855 The URL jumps to 14:15 which shows exactly how I’m doing my rotations. However, it works for the guy in the video!

In the video description is a link to the blend file. When you load this blend file and play it, the rotations look perfect (using Quaternion rotation). However, if you delete all the keyframes and start rotating it yourself, the pieces start to separate. Is this because the blend file was created on an older version of blender where the rotation worked better?

I feel like I’m close to getting it, but just missing one last piece of information. It’s driving me insane!

I’d really appreciate some help on this, as I’ve been struggling for days on it now and I need to move on.


2 Answers 2


Actually, even the video recorder himself didn't get the expected result during the video (see 18:24 of that video).

To make an expected Rubik's cube animation, it is important to keep below points in mind:

  • Setting rotation mode to Quaternion for all cubes are highly recommended for expected result. Otherwise you have to key among the Euler modes, which makes it more difficult.
  • Make sure the F-Curve key interpolations for all rotation channels are set to Linear, otherwise it just works weird.
  • Make sure to have the selected cubes keyed BEFORE rotating them.

A comparison file based on your scene. FYI. Hope it helps.

enter image description here

  • $\begingroup$ I thought the answer lay somewhere around the F-Curves, but I did try setting to linear without effect, so I obviously done something wrong. I take it I need to select all the rotations in the graph editor/dope sheet, Key->Interpolation Mode->Linear? Also, is that right, I need a keyframe for every piece of the cube, not just the pieces that have moved and the ones that are about to move? $\endgroup$ Feb 3, 2014 at 9:22
  • $\begingroup$ Hi, the answer just updated. $\endgroup$ Feb 3, 2014 at 9:26
  • 1
    $\begingroup$ Yes, Interpolation mode can be switched in the menu, or press T for shortcut. And, if you want to make Linear as the default key interpolation, you can make it as default in the User Preferences setting, but you have to restart blender to make it work. $\endgroup$ Feb 3, 2014 at 9:32
  • $\begingroup$ Thanks, this worked perfectly. I have no idea why I couldn't get this to work when I messed around with the interpolation mode myself. $\endgroup$ Feb 3, 2014 at 12:48
  • $\begingroup$ I'm just thinking; if I'm using linear interpolation, how difficult is it to create ease in and ease out, something that's easy with bezier? Would it mean inserting extra keyframes just after and before the main keyframes and manually create the easing? $\endgroup$ Feb 3, 2014 at 12:52

You definitely need to use Quaternion rotation, but you don't have to use linear interpolation. If you set it to Bezier and set the handles to Automatic, then select all in the Graph window, then hit Shift+S, you can select Flatten Handles, which will help fix the problem of different cubies moving at different rates than their neighbors.

You should also add keyframes for all cubies whenever you record a turn, so that all the handles are the same widths. These two things together will completely solve your F-Curve troubles.

You should also move the individual centers of your cubies to the center of the whole cube, so they rotate correctly, and so that the only keyframes you'll need are those of Rotation.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .