Recomposer

Turns, rolls and zooms the finished shot.

A final touch on a shot the Body and Aim already built: turn it a little, roll it into a dutch angle, or zoom in. The Body and Aim keep working as they are, so the camera still follows and frames its targets, with the change on top. Animate the settings for effects like a slow dutch in a cutscene.

zoomScale scales the field of view, or the orthographic size, the shot has when it runs, for example from Lens or FollowZoom. With an orthographic camera, add it after GroupFraming to scale the size it fits too.

Settings

SettingDescriptionDefault
tiltTurns the camera around its own horizontal axis, in degrees. Positive looks down, like PanTilt.0
panTurns the camera around referenceUp, in degrees. Positive turns right, like PanTilt.0
dutchRolls the camera around its view direction, in degrees. Positive leans it to the right.0
zoomScaleMultiplies the field of view and orthographicSize: below 1 zooms in, above 1 zooms out. Never below 0.01, and the field of view stays at most 179.1

Usage

import { RecomposerExtension } from '@pmndrs/klipp';

const recomposer = new RecomposerExtension({ dutch: 12, zoomScale: 0.9 });
camera.addExtension(recomposer);

// any time later
recomposer.dutch = 12 * Math.sin(time);