When I use self.node.setHpr the joints lose normal connection (as shown in the image below).
But the documentation says that the joints only rotate, not move the position.
I would like to ask if this is a bug of the program or panda3d or fbx file?
Or how can I make his arm rotate properly?
Hmm… I decided to try some quick tests on my own end, using the code given above (with minor modifications, primarily due to my not having the model in question).
In my case, I found that the model generally did not show the issue that you’ve been seeing.
However, I was able to get an odd-looking result–if not as extreme as yours–by using a model in which the bones of the skeleton were separate from each other. That is, not merely parented-but-disconnected, but not parented to each other at all.
And this makes some sense: without a parent, the bones can move freely, and will presumably each and all rotate around the origin of the armature, rather than around the end of their parent as per usual (as they have no parent).
So, perhaps this is the problem in your case: that your model’s skeleton has its bones separate, rather than parented to each other.
Hi, thanks for your reply and sorry for the late reply.
After many days of cross-examination, I found that other models can control each joint smoothly. And these models can also be used and manipulated smoothly in the unity engine. This strange cross-comparison result confuses me, can I upload my model for you to test?
Well, have you examined the model’s joints in your modelling program, to see whether they’re separate (i.e. not parented in a hierarchy)? That remains my best guess as to why you’re seeing this problem.
Hmm… I haven’t worked with that output, so I’m not confident in saying this, but it does look like there’s a hierarchy in place there, indeed.
I don’t know then, I’m afraid. Perhaps indeed it might be worth posting the model to see whether I or someone else manages to find a problem within it, as long as you’re comfortable with having the model be public.
(An alternative might be to try to create a simple testing-model that exhibits the same problem.)
All right, I don’t know whether this will help, but for testing purposes I’ve constructed a simple model that–I hope!–more or less matches your joint-hierarchy. It’s by no means a particularly good model, let me say–but it’s not meant to be: it’s meant only to be a means to testing.
I would be interested to know whether you see the same problem with this model that you see with the one that you’ve been using.
You should find it at the link below. (Once you’ve downloaded it I’ll likely delete it from that location.)
Hmm–that’s interesting! That suggests that either there’s a problem with the original model, or that there’s something in it that Panda is tripping over (perhaps an unsupported feature, or a problem with the joints, or something else besides)…
Wow… That’s a bad news.
So do you have any recommended way to get the human model?
I found that many human models will be judged not to be character models by panda…