How to animate Object Data Properties?

I can animate a cube so that from frame 1 to frame 100 it moves along the y axis.

Doing so creates an action, by default named CubeAction visible in the outliner, nested under Cube.

What would I do if I want the top face of the cube to be scaled down at frame 100?

Is there any way of keyframing that? I guess it would mean keyframing Cube’s Object Data Properties, represented in the outliner by the green triangle. I can’t see a way of doing that.

In contrast, considering a similar problem with a light, it’s possible to keyframe both location and the Color.

Looking at the outliner, 2 actions seem to be created, LightAction nested under Light and LightAction.001 nested under Light>Light, which I’m guessing from the icon’s green colour indicates that LightAction.001 applies to the Object Data Properties.

Generating an animation of the light changing both position and colour confirms that it works as expected.

Returning to the cube animation, is it possible to keyframe changes to the mesh, such as scaling down the top face?

You cannot keyframe anything in Edit Mode, which means you can’t directly animate moving vertices around.

You can however do this by using shape keys. You can find them in the Object Data properties tab:

Object Data


Make sure your object is in the default state so to speak (no changes in geometry) then add a shape key:

Base Key

2

This will hold the “base state” of your model, then add another one:

Key 1

3

This is the shape key we will use to change the shape of the mesh, with it selected go to edit mode and scale the top face of your cube:

Cube Edit

You may notice that once you exit Edit Mode the shape snaps back to “base” look, this is because by default when we add a key it has a weight of zero, you can change how much a key affects the shape by adjusting the Value slider underneath it:

Value Slider

5

This slider is also keyframable so you can use it for animation.


As a side note, shape keys can be exported and are what we also often use in games for character creators, but can be used for many other things too.

3 Likes

@VVruba thanks.

Very interesting.

I can push those KeyActions onto the NLA stack, just like previous type of action I was using. The larger project I’m working on uses objects with various animations exported from blender in gltf. I’ve just tested such an export by opening the gltf file in a viewer and yes, I can see the KeyAction.

That’s given me enough options to play with for at least a month!

1 Like

Something I forgot to mention, you can also blend multiple shape keys together and extrapolate them beyond 1 and 0.

2 Likes

There is also handy addon called AnimAll, that lets you directly animate in edit mode:
AnimAll0001-0030

This shows up in dope sheet:


And it occupies top of NLA stack and can be pushed down, but I dont have any experience with NLA, so dont know if its the normal workflow, as it looks a little strange to my.

4 Likes

Thanks @Medial

as I don’t fully understand how all these tools work together, I’m trying to avoid adding any extra addons into the mix right now.

When, and if, I get to understand it, I’ll take a look at that addon.

2 Likes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Privacy & Terms