Skip to main content
Version: 5.x
Supported on
Snapchat
Spectacles
Camera Kit

Animating Scene Objects

Lens Studio supports keyframe animation on scene objects—no external 3D software needed. You can animate position, rotation, and scale, control playback with transport controls, and record keyframes live in the viewport.


Quick Start: The Animate Action

Use the Animate context menu action to start animating a scene object.

  1. In the Scene Hierarchy, right-click a scene object.
  2. Choose Animate.
Scene Hierarchy context menu with "Animate" highlighted

Lens Studio then:

  • Creates an AnimationAsset with default keyframes for the object's current position, rotation, and scale.
  • Adds an AnimationPlayer component wired to the new asset via an AnimationClip.
  • Opens the Animation Curve Editor and loads the new curves.
  • Restores selection to the scene object.

If the object already has an AnimationPlayer, Lens Studio uses the existing player and its clips instead.

After running Animate, scrub through time, edit curve shapes, or record new keyframes—no manual wiring needed.


What Gets Created

CreatedDetails
AnimationAssetContains layers for position, rotation, and scale. Each starts with one keyframe at time 0.
AnimationPlayer componentAdded to the scene object with Autoplay on.
AnimationClipCreated inside the AnimationPlayer, linked to the new AnimationAsset.

See the Animation Player reference for details on each entity.


Recording Keyframes

With an AnimationPlayer on the scene object, record new keyframes by moving the object in the viewport.

Enable Recording

Click the red circle Record button in the Animation Curve Editor toolbar to toggle recording on.

Animation Curve Editor toolbar with the active Record button shown as a red dot

With the record button on:

  1. Position the scrubber—the playhead—at the desired time.
  2. Move, rotate, or scale the scene object in the Scene Editor viewport.
  3. On release, the editor writes position, rotation, and scale keyframes at the scrubber time.

Recording uses debouncing—one keyframe per drag. This keeps the undo history clean: each drag produces one undo step.

Overwriting Existing Keyframes

If a keyframe exists at the current scrubber time, the editor overwrites it. Use this to refine a captured pose.

Stopping Recording

Click Record again to turn it off. With recording off, viewport moves don't affect the curves.


Previewing the Animation

Use the transport controls to preview without leaving the editor:

ControlAction
Play / StopToggles AnimationPlayer autoplay.
Step ForwardAdvances one frame.
Step BackSteps back one frame.
Scrub rulerClick and drag the time ruler to seek to any frame.

For details on transport controls and the clips bar, see Animation Curve Editor—Transport Controls.


Editing Curves

After recording or using Animate, open the Animation Curve Editor to refine:

  • Switch from Linear to Free Bezier tangents for smooth ease-in/ease-out motion.
  • Mix tangent types per segment—for example, snap to a key then ease out.
  • Drag tangent handles to adjust speed through each keyframe.

The editor curve matches runtime exactly - Lens Studio resamples non-linear Bezier curves during playback.

Curve canvas after recording—the Z-axis track in yellow shows a smooth Bezier arc from a transform drag, while other tracks remain flat. Press Z to fit the view to the curves.
Was this page helpful?
Yes
No