Skip to Content

Resting in the park

Three walkers stop on the grass to kneel, sit and squat; she stays and the two men walk on.

Loading the take.

Each person is a chain of typed actions from @automovie/motions. This is what an agent writes for the scene; Composing motion explains the parts.

import type { IAutoMovieMotionHumanBody, IAutoMovieMotionHumanPerformance } from "@automovie/interface";
import { HumanChain, HumanHabit, HumanPerformance, HumanPose, HumanStance } from "@automovie/motions";

// hal: body m1, at (-1.2, -2) m, facing 0°, trained
const hal = HumanChain.subject("hal")
  .act("walk", { to: { x: -1.2, y: 0, z: 0 } })
  .act("kneel", { kind: "one", hold: 2, rise: true })
  .registered("neckRoll", { count: 1 })
  .act("look", {
      target: { kind: "person", subject: "ida", region: "face" },
      cue: "seen",
    })
  .act("gesture", { kind: "nod" })
  .act("walk", { to: { x: -1.2, y: 0, z: 2 } });

// ida: body f1, at (0, 2.6) m, facing 180°, trained
const ida = HumanChain.subject("ida")
  .act("walk", { to: { x: 0, y: 0, z: 0.6 } })
  .registered("fanSelf", {})
  .act("look", {
      target: { kind: "person", subject: "hal", region: "face" },
      cue: "seen",
    })
  .act("gesture", { kind: "nod" })
  .registered("sitSideways", {});

// jon: body m2, at (2.8, -1.7) m, facing 330°, trained
const jon = HumanChain.subject("jon")
  .act("walk", { to: { x: 1.8, y: 0, z: 0 } })
  .act("crouch", { depth: "full", heels: "up", hold: 2 })
  .act("gesture", { kind: "touchFace" })
  .registered("checkWatch", {})
  .act("walk", { to: { x: 1.8, y: 0, z: 2 } });

const scene = hal.with(ida, jon);

// The lexicon's laws this scene's rows perform, registered with the performance.
const laws = [HumanStance.neckRoll, HumanHabit.fanSelf, HumanPose.sitSideways, HumanHabit.checkWatch];

// Each body id's motion body, prepared from the site's measures.
declare const bodies: Record<string, IAutoMovieMotionHumanBody>;

const input: IAutoMovieMotionHumanPerformance.IInput = {
  seed: "park-rest",
  performers: [
    { subject: "hal", body: bodies["m1"]!, at: { x: -1.2, y: 0, z: -2 }, yaw: 0, proficiency: { level: "trained" } },
    { subject: "ida", body: bodies["f1"]!, at: { x: 0, y: 0, z: 2.6 }, yaw: 180, proficiency: { level: "trained" } },
    { subject: "jon", body: bodies["m2"]!, at: { x: 2.8, y: 0, z: -1.7 }, yaw: 330, proficiency: { level: "trained" } },
  ],
  composition: scene.node,
  laws,
};
const performance = new HumanPerformance(input);