Skip to Content

Partner dance

A couple spins, she turns under his arm, they walk a promenade and she closes in.

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, HumanEmblem, HumanPartner, HumanPerformance, HumanSportWorkout } from "@automovie/motions";

// lea: body m1, at (0, 0) m, facing 0°, trained
const lea = HumanChain.subject("lea")
  .registered("closedHold", { hold: 0.4 })
  .registered("spin", {})
  .act("gesture", {
      kind: "raiseHand",
      side: "left",
      hold: 0.6,
      effort: { time: -0.5 },
    }, "dance-arch")
  .registered("danceLead", { to: { x: 0, y: 0, z: 2.2 } }, "dance-walk")
  .registered("handOnHeart", {})
  .act("gesture", { kind: "nod" });

// fol: body f1, at (0, 0.45) m, facing 180°, trained
const fol = HumanChain.subject("fol")
  .registered("closedHold", { hold: 0.4 })
  .registered("spin", {})
  .registered("underarmTurn", {})
  .sync({ of: "dance-arch", event: "strokeStart" })
  .act("step", { direction: "left", steps: 1 })
  .act("walk", { to: { x: -0.5, y: 0, z: 2 }, face: 0 })
  .sync({ of: "dance-walk", event: "start" })
  .act("approach", {
      target: { kind: "person", subject: "lea", region: "upperArmRight" },
      side: "right",
      at: 0.2,
    })
  .registered("danceHold", {
      target: { kind: "person", subject: "lea", region: "shoulderRight" },
    });

const scene = lea.with(fol);

// The lexicon's laws this scene's rows perform, registered with the performance.
const laws = [HumanSportWorkout.closedHold, HumanSportWorkout.spin, HumanPartner.danceLead, HumanEmblem.handOnHeart, HumanSportWorkout.underarmTurn, HumanPartner.danceHold];

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

const input: IAutoMovieMotionHumanPerformance.IInput = {
  seed: "dance",
  performers: [
    { subject: "lea", body: bodies["m1"]!, at: { x: 0, y: 0, z: 0 }, yaw: 0, proficiency: { level: "trained" } },
    { subject: "fol", body: bodies["f1"]!, at: { x: 0, y: 0, z: 0.45 }, yaw: 180, proficiency: { level: "trained" } },
  ],
  composition: scene.node,
  laws,
};
const performance = new HumanPerformance(input);