Insert hand for live demo.
Allows adding a hand to your THREE.js scene in one line.
Creates a default scene for you, when time is of the essence.
// At the simplest:
Leap.loop()
.use('boneHand', {
targetEl: document.body,
arm: true
});
Name | Default | Description |
---|---|---|
scene | undefined |
Accepts a THREE.scene. If undefined, a default scene will be created with some defaults (transparent canvas, three lights, mm units), and rendered on every animation frame. If null, the plugin will wait for the scene to be set explicitly at a future point. With the default scene, the renderer, camera, and scene will all be made available on the plugin scope. E.g., `myController.plugins.boneHand.scene` |
targetEl | undefined | Accepts an element, such as `document.body`. |
boneScale | 1 / 6 | The radius of the bones relative to the length of the proximal bone on the middle finger |
jointScale | 1 / 5 | The radius of the bones relative to the length of the proximal bone on the middle finger |
boneColor | (new THREE.Color).setHex(0xffffff) | |
jointColor | (new THREE.Color).setHex(0x5daa00) |