Determining the Position of Wrist (and others)

Tech support and suggestions forum. If you only have a basic question on how to get started, please use the "newbies" forum in the community section.

Moderator: joepal

Determining the Position of Wrist (and others)

Postby CFJH » Mon Jan 25, 2021 12:53 pm

Hello,

In my povray development I need to get the exact position of the wrist after modelling and posing a model (e.g. to apply a watch to the wist).

Currently I'm trying to parse the skeleton (seperatly exported do a .bvh-file). I'm using the "default" skeleton. My problem is, that the model doesn't match to the skeleton after modelling (changing the height and other properties).

How does the modelling change/modify the skeleton, how can I re-implement this in a script outside makehuman ?
Hoe can i determine the exact position/orientation of wrist, neck, ankle (...) ?
Jürgen
www.wetterstation-porta.info
CFJH
 
Posts: 14
Joined: Sat Nov 30, 2013 12:34 pm
Location: Germany

Re: Determining the Position of Wrist (and others)

Postby joepal » Mon Jan 25, 2021 2:16 pm

My suggestion is to not go via the skeleton.

The base mesh (actually also the proxies) has fixed vertex indices. That is, you can know that vertex 3898 is placed on the inside of right arm's wrist.

On the wrist, you can pick a bunch of vertices on the circumference, calculate the mean position and from that conclude where the lower arm bone's tail is.

This will work irregardless of what skeleton or pose you use.

vertex_indices.png


A slightly more advanced way is to go for the joint cubes. These are hidden geometry which should coincide with the head/tail of all bones in the default rig. If you look in the base mesh's source (https://raw.githubusercontent.com/makeh ... s/base.obj), you can see that there is for example a "joint-r-elbow" group. The mean of the positions of the vertices in this group is the elbow joint. However, this requires that you imported the mesh including helpers, which might be cumbersome for other reasons.

As a side note, Blender has a python function for figuring out where a posed bone is. A PoseBone's properties "head" and "tail" are always the world location of the start and end of a bone. But I have no clue if you have a similar function available somewhere in your pipeline.
Joel Palmius (LinkedIn)
MakeHuman Infrastructure Manager
http://www.palmius.com/joel
joepal
 
Posts: 4473
Joined: Wed Jun 04, 2008 11:20 am


Return to Bugs, problems and feature requests

Who is online

Users browsing this forum: No registered users and 1 guest