Installation
Install Klipp and pick the right entry point.
pnpm add @pmndrs/klippThe core and each integration have their own entry point. Each one only needs the libraries it adapts to, all of them optional peer dependencies:
Vectors in the core are plain arrays from math: [x, y, z] and [x, y, z, w]. Add it to your dependencies to use its vec3 and quat functions. Constants like BlendCurves always come from the core.
Usage
import { Klipp, FollowBody, HardLookAtAim, targetPose, BlendCurves } from '@pmndrs/klipp';
pnpm add threeimport { BlendCurves } from '@pmndrs/klipp';
import { KlippThree, FollowBodyThree, HardLookAtAimThree } from '@pmndrs/klipp/three';
pnpm add three react @react-three/fiberimport { BlendCurves } from '@pmndrs/klipp';
import { Klipp, VirtualCamera, Body, Aim } from '@pmndrs/klipp/react';
Your first camera builds a complete scene with each of them.