@nandenjin/bvh-parser
TypeScript icon, indicating that this package has built-in type declarations

0.2.9 • Public • Published

bvh-parser

BVH Parser written in TypeScript

Version Coverage by Codecov License

This is a forked version maintained by @nandenjin. Originally written by @hitsujiwool.

🐙 GitHub | 📒 Docs | ⚒️ Playground

Usage

import { read as readBVH } from '@nandenjin/bvh'

readBVH(urlForBVHFile, function (motion) {
  // basic infomation about motion data
  motion.frameTime
  motion.numFrames

  // get lists of nodes
  motion.nodeList

  // get a node by id
  var node = motion.of('Head')

  // change node's internal state to n-th frame
  node.at(4)

  // you can exchange the order of method "at" and "of"
  var state = motion.at(4)
  node = state.of('Head')

  // node properties
  node.offsetX
  node.offsetY
  node.offsetZ
  node.rotationX
  node.rotationY
  node.rotationZ

  // node adjacent to "End Site" has properties about endOffset
  if (node.hasEnd) {
    node.endOffsetX
    node.endOffsetY
    node.endOffsetZ
  }
})

License

See LICENSE.

Dependencies (0)

    Dev Dependencies (7)

    Package Sidebar

    Install

    npm i @nandenjin/bvh-parser

    Weekly Downloads

    23

    Version

    0.2.9

    License

    MIT

    Unpacked Size

    28.9 kB

    Total Files

    12

    Last publish

    Collaborators

    • nandenjin