The camera

A scene is filmed through a frame. With the multicamera on, that frame is a camera you can move and zoom while the video plays: it closes in on a term, travels to a formula written far away, pulls back to show everything.

The camera closes in on c², which is indicated; travels to the square root, written outside the first frame; pulls back to show both; and returns to where it started.

Turning the multicamera on

Choose View ▸ Multicamera, press Alt+M, or press the camera button of the Preview’s toolbar. The scene gets a camera, in Manim’s own frame to begin with. It is part of the project: it is saved with it, and turning it on is one undo step.

Two things change on screen:

In the world view:

Fit shows everything of the camera at once. Preferences ▸ Show the camera’s route and Preferences ▸ Dim what the camera leaves out hide the line and the dimming.

A camera move

A move takes the camera from the frame it is in to another, over a time. To make one:

  1. Put the playhead where the move should start.
  2. Press + in the header of the Camera row (Add camera move). A block of one second appears, and the playhead jumps to its end.
  3. In the Preview, drag the camera to where the move should arrive. Take it by its edge, its name or the cross of its centre; drag a corner to zoom.
Add camera move at 1.5 s; then the camera is dragged to the right and made smaller by a corner: the move now ends there.

In the world view the pointer takes the camera’s rectangles only. The formulas are drawn and left alone: pointing at one outlines nothing, and a click or a drag on one neither selects nor moves it, so a press meant for the camera never takes the formula under it. A line under the scene says so. To select and move the formulas, hold F (below), look through the camera (below) or select their clips on the timeline. A click beside the rectangles clears the selection, and the view is panned and zoomed as in any Preview.

While you drag, the rectangle sticks to the formulas, to the other rectangles and to Manim’s frame, and to the grid when it is shown; hold Ctrl to suspend that, and Shift to move along one axis only. The arrow keys nudge the selected rectangle by 0.01 (with Shift, 0.1).

Moving a formula in the world view

Sometimes a formula has to be put where the camera will be, and the camera’s rectangles are only drawn in the world view. Hold F: while the key is down the pointer takes the formulas there, as it does in any Preview. A click selects one, a drag moves it, Shift shows its handles, Alt picks its glyphs and a right-click opens its menu. The camera’s rectangles are the ones left alone meanwhile. Let the key go and the pointer is the camera’s again; a drag you had started goes on until you release the button.

The key does nothing while the scene plays, in a text field or with a menu or a dialog open.

Frames one over another

When the camera goes to the same place more than once, each move to a frame of its own, the rectangles of those frames lie one over another, and a press takes the one on top. To move one that is underneath:

  1. Right-click its move on the Camera row and choose Isolate in the Preview. Only the rectangle of the frame that move goes to answers the pointer now. It is drawn over the others, which are faint, and the block of the move wears a dashed ring.
  2. Drag the rectangle, scale it by a corner or nudge it with the arrow keys.
  3. Press Stop isolating, in the corner of the Preview, or Esc. Every rectangle answers again. The same entry ends the Preview’s right-click menus and the menu of the move.
The Preview in the world view with one pink dashed rectangle drawn strong, with a handle at each corner, over a faint camera and faint rectangles; the button Stop isolating in the corner; on the Camera row, the first move with a dashed ring.
The first move isolated: (1) the rectangle of its frame, the only one that answers; (2) the camera and the other rectangles, faint; (3) Stop isolating; (4) the block of the isolated move.

A move that goes to a target camera isolates that target camera’s rectangle, and one that goes to the start, the frame of 0 s. Isolating is a way of looking: it changes nothing of the project, and it ends when its move is deleted.

The block of a move

On the Camera row a move is a block, and it behaves like an animation block: drag it along the time, stretch it by its edges, right-click it to Isolate it in the Preview (above), to Duplicate it or to Delete it. Right-click the row to add a move where you clicked. Its label says where it goes:

LabelThe move goes to
→ 200 %a frame of its own, named by its zoom (100 % is Manim’s frame)
→ Resultthe target camera with that name
→ Startthe frame of 0 s
The timeline with the Camera row under the ruler: four blocks of moves, and a hatched band under each across the tracks.
The Camera row: (1) its name, its padlock and +; (2) a move; (3) the locked region under a move.

With a move selected, the Animations panel shows its Start, Duration and Easing, and where it Goes to: A frame of its own, with its X, Y and Zoom; a target camera; or Start (the frame at 0 s).

Nothing else animates while the camera moves

A camera move has its time to itself. Under each move a hatched band crosses every track: the locked region.

An object may appear or disappear without an animation during a move: that is no animation.

Target cameras

A target camera is a frame with a name that moves can go to. Several moves can share one, and moving it changes them all.

The right-click menu of a target camera in the Preview: Move camera here, Rename…, Delete.
The menu of the target camera Result.

Deleting a target camera that moves go to asks first. Those moves stay: each keeps going where the target camera was, to a frame of its own.

A click on the name of the Camera row shows the camera in the Animations panel: the frame it rests in at the playhead, and the list of target cameras.

The camera view

The world view shows the camera from outside. Press V, or the viewfinder button beside the camera’s, or choose View ▸ Camera view, to look through it: the Preview shows what the video will show at the playhead, and playing shows the moves. The rectangles are left out, and the pointer is the formulas’ again: select them, move them and edit them as ever. V again goes back to the world.

V looks through the camera; the scene plays as the video will; V returns to the world.

Each view keeps a zoom and a pan of its own.

From the keyboard

KeysWhat they do
Alt+MMulticamera on or off
VCamera view on or off
F, heldIn the world view, the pointer takes the formulas instead of the camera’s rectangles
EscStop isolating a move
DeleteDelete the selected move, or the selected target camera
Ctrl+DDuplicate the selected move into the first place it fits after it
Alt+←, Alt+→Nudge the selected move a frame (with Shift, five)
Arrow keys, in the PreviewNudge the selected rectangle 0.01 (with Shift, 0.1)

On the Camera row, Tab reaches the moves after the row’s buttons, the arrow keys go from move to move, and Enter opens the menu of the focused one.

Turning it off

The multicamera stays on while the camera has target cameras or moves: delete them first, and a notice says so if you try. The padlock of the Camera row locks the camera instead: its moves and rectangles can be selected, not changed.

In the exported Python and the video

The video is filmed through the camera, and so is the exported scene. A ManimCE scene becomes a MovingCameraScene. In both libraries each move is a self.play(…) of its own on the camera’s frame (cam = self.camera.frame), and a move back to the start is Restore(cam). A ManimGL scene whose camera zooms starts with a few lines that make strokes scale with the zoom as ManimCE draws them (ManimGL 1.7.2 or later). See The generated Python.

Try it