I hope my english is not too hard to understand.
At the moment I used instanceTo() method in nodePath to create a set of human skeleton, I just wonder is it possible to to get the x,y,z coordinate added up instead of coordinate of their own.
if i create 3 node using instanceTo()
where nodeA is instance of nodeB and nodeB is instance of nodeC
is it possible to retirive node C as (3,3,3)?
Not entirely sure what you mean, but if you reparent them to each other, it should work. (Not sure if that won’t give any circular dependencies that breaks instancing, though.)
Sorry, it seem I ask the wrong question
The skeleton data is retrieved from a BVH file and I had extracted the data as a node and represent the on screen correctly (using instanceOf()).
The problem is when I extract the node data using getTransforamtion(), I can only extract their local coordinate but not their location on screen.
I just wonder is there any method available to extract their actual coordinate on screen
You can call nodePath.getPos(render) to get the position relative to render, the top of the scene graph; this is “world coordinates”.
This is not the same thing as the position of the node on the screen, though, since that depends on the camera and the lens properties. If you really want to compute the actual position on screen, it’s more complicated. Try this thread for more information.
Kingasd am I getting right you’re reading on the fly BVH files into panda?
if it is so why don’t you import 'em in Blender and then export as .egg animations instead to make an importer inside your python script?
Thanks! That work perfectly!!!