-
Notifications
You must be signed in to change notification settings - Fork 110
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
Is there an equivalent of springBoneManager.setCenter from three-vrm v0.6 in the latest version? #1112
Comments
mmm, I'm not sure why I removed the interface. Maybe it's because the early VRM 1.0 beta versions did not have the center. For now, as a workaround, you can iterate over |
The implementation of three-vrm/packages/three-vrm/src/springbone/VRMSpringBoneManager.ts Lines 26 to 37 in 66753c3
|
@0b5vr I tried to implement something like the previous
It doesn't change much and the springs are still jumping more than usual. By trial and error, I have to add the following to make it behave more like the old version.
But still it doesn't look exactly like the old version. The spring movement looks normal this time, but the colliding behavior appears to be missing. |
Mmmmm, I thought I had fixed that behavior once before... I have to investigate this. |
@ButzYung Could you provide a demo that behaves wrong with your colliders? I have tested on my end and could not point to any issues. |
@0b5vr I don't have a demo right now, but after some further testings, I can confirm the problem comes from scaling the VRM mesh (I am scaling the mesh up by roughly 10 times, something like |
scale! got it. will try to reproduce. |
@ButzYung When do you want to change the scale of meshes? If it's in initializing, how about hitting Honestly, I found that setting the scene with scales is difficult even for me 😅 |
And also, to explain why we don't have And, we are yet to come up with any reasonable API to achieve that process so far. |
I'm trying to improve the usability of scale + SpringBone setups in a PR: |
I change the scale of the mesh right after the model is loaded, and it basically never changes again afterwards. Changing the scale before or after adding the model to |
@ButzYung I've released https://www.npmjs.com/package/@pixiv/three-vrm/v/1.0.7-alpha.0 |
I have tested with your latest
Talking about the colliding behavior, I wonder if I have a misunderstanding of how it works, or there may actually be something wrong with the current implementation in v1.0...? I have tried your https://pixiv.github.io/three-vrm/packages/three-vrm/examples/humanoidAnimation/index.html with the Alicia VRM model https://3d.nicovideo.jp/works/td32797 and dance motion from Mixamo such as this one https://www.mixamo.com/#/?page=1&query=Capoeira When Alicia dances, her legs pass through her skirt with no physical interaction, as if the skirt colliders don't exist. Is it supposed to be like that? I tried v0.6 in my own project with other motions, and the colliding behavior was visible (still far from perfect as legs passing through skirts still occur, but at least the colliding interaction is more noticable). |
@ButzYung I've pushed a new document describing spring bone behavior under scaled VRM models. Does it help? https://github.com/pixiv/three-vrm/blob/improve-springbone/docs/spring-bones-on-scaled-models.md |
@0b5vr I am using |
That's another problem we have to fix from the spec side ground-up. |
In v0.6 of three.vrm, there is the
springBoneManager.setCenter
function which allows offseting the spring bones center. This is useful in my case when I have to do something likespringBoneManager.setCenter(vrm_mesh)
to prevent the spring bones from jumping crazy (I don't know what causes the crazy spring movements. Maybe it's because
vrm_mesh
is far away from (0,0,0), or maybe it's becausevrm_mesh
is scaled).However, in v1.0 of three-vrm, this function is gone and I can't find an equivalent.
The text was updated successfully, but these errors were encountered: