I've got about 200 objects for which I want to insert location/rotation keyframes.
Is there a way to add a keyframe for all of the selected objects?
Blender Stack Exchange is a question and answer site for people who use Blender to create 3D graphics, animations, or games. It only takes a minute to sign up.Sign up to join this community
Assuming you're talking about actual objects (not a mix of objects and armature bones), the easiest thing would be to select all of the objects and, from within the 3D View, press
I and choose LocRot. That will insert a key for location and rotation on all selected objects.
If your needs are more nuanced, you may want to consider building a custom keying set. In that, you can specify any number of different properties from any number of objects (and non-objects... like World properties) and key them all at the same time. If you're interested in taking that route, then Getting to Grips with Keying Sets is a good start.
As Fweeb said, the standard way of handling this is using Keying Sets. Accessible in the 3D View under Object > Animation > Insert Keyframe… (
I). There's a limited set by default but custom ones can be added. For more info see: Can I personalize the insert keyframe menu?
Any time a task would be repetitive to do by hand, scripting is a good choice. Here's a quick example of how to insert a keyframe to all the objects in a selection:
import bpy for obj in bpy.context.selected_objects: obj.scale = 0.5 # Set Z scale. obj.keyframe_insert(data_path="scale", index=2) # Keyframe it.
If creating the same animation on all object, you can animate just the active object and then link the action to the rest of the selection: Object > Make links… (Ctrl+L) > Animation Data). If you wish to later mix in some unique animation, turn the action into a NLA strip before linking.
There is this commercial add-on, Key Selected Objects, if you want to add/delete keys for multiple objects from the user interface.: