Git Product home page Git Product logo

bvhparse's Introduction

运行说明

特别注意:BVH数据一定要有Tpose,一般要么是内置骨骼为Tpose,要么是内置为Apos而第一帧为Tpose

  • 创建角色 随便找个avatar角色或者使用工程中提供的Assets/Models中的两个角色(unity-chanRin)
  • 挂载脚本 将Scripts/BVHDriver.cs拖拽到创建的角色上
  • 脚本设置
    • Bonemaps:设置关节对应关系 脚本的Bonemaps定义了unity自己的humanoid的关节与BVH数据关节的对应关系,最好按照骨骼的层级关系填写
    • FirstT:注意你的BVH文件第一帧是Tpos,或者说内置的skeleton就是T-pose,可以通过bvhacker查看(如CMU提供的BVH数据内置骨骼是A-pos,第一帧是Tpose,所以需要勾选;示例中的tmp.bvh的内置骨骼的Tpos,所以无需勾选
    • TargetAvatar:创建的角色
    • filenamebvh的路径

强调

代码中需要注意bvh可视化的结果对不对,如果不对,说明全局旋转没计算对,因为我按照ZYX的欧拉角顺序计算的全局旋转,如果是其它顺序,请重写一下BVHParser.cs里面的eul2quat函数。

还有可能由于模型缩放,unity角色的动作没问题但是位置有问题,那就需要调整scaleRatio了,请自行尝试。

bvhparse's People

Contributors

1165048017 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.