-
Notifications
You must be signed in to change notification settings - Fork 111
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[1.0] Add Humanoid helper #987
Conversation
this._boneAxesMap = new Map(); | ||
|
||
Object.values(humanoid.humanBones).forEach((bone) => { | ||
if (bone) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ここ、boneはfalsyになることあるんですね。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
そんなことないですね。if文外してしまいます。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Array.from(this._boneAxesMap.entries()).forEach(([bone, axes]) => { | ||
bone.node.updateWorldMatrix(true, false); | ||
|
||
bone.node.matrixWorld.decompose(_v3A, _quatA, _v3B); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
decomposeしたけど_v3aと_quatAは特に使っていない。
後で直接matrixWorldをコピーしている。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
レビューしました!この部分の修正だけでしたら再レビューは不要と思います。
Add a type assertion instead The type assertion is not needed if we use later versions of TypeScript. Remove it later
Description
This PR adds
VRMHumanoidHelper
which visualizes humanoid bones.This PR was originally done in #889 but since Humanoid Rig changes are going to be difficult I separated the humanoid helper changes into this PR.