[x3d-public] BVH tasks, joining forces, BVH to HAnim validation

Brutzman, Donald (Don) (CIV) brutzman at nps.edu
Sun Oct 30 11:49:34 PDT 2022


All prior noted problems fixed with X3D-Edit BVH-to-X3D conversion, thanks
for helpful reports!  Those corrections further facilitated additional
processing of this large-file-size example.

 

Updated versions of Pirouette behavior are online:

*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/PirouetteIndex.html
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/Pirouette.x3d
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/Pirouette.html
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/Pirouette.html#ROOT_hipHAnimHumanoidReport
*	http://mocap.cs.cmu.edu/search.php?subjectnumber=5
*	http://mocap.cs.cmu.edu/subjects/05/05_11.mpg

 

Pretty-print html page includes an HAnimHumanoidReport which reports the
following tree structure:

 

============================================================================
===========================

HAnimHumanoid skeleton holds X3D4 HAnim2 triplets, HAnimJoint (43) :
HAnimSegment (43) : HAnimSite (15)

============================================================================
===========================

HAnimHumanoid DEF='BvhPirouette_ROOT_hip name='ROOT_hip' loa='-1'

  humanoid_root : sacrum

    abdomen : humanoid_root_to_abdomen

    | vl5 : l5

    |   neck : vl5_to_neck

    |   | skullbase : skull

    |   |   leftEye : skullbase_to_leftEye

    |   |   rightEye : skullbase_to_rightEye

    |   rCollar : vl5_to_rCollar

    |   | rShldr : rCollar_to_rShldr

    |   |   rForeArm : rShldr_to_rForeArm

    |   |     rHand : rForeArm_to_rHand

    |   |       rThumb1 : rHand_to_rThumb1

    |   |       | rThumb2 : rThumb1_to_rThumb2

    |   |       rIndex1 : rHand_to_rIndex1

    |   |       | rIndex2 : rIndex1_to_rIndex2

    |   |       rMid1 : rHand_to_rMid1

    |   |       | rMid2 : rMid1_to_rMid2

    |   |       rRing1 : rHand_to_rRing1

    |   |       | rRing2 : rRing1_to_rRing2

    |   |       rPinky1 : rHand_to_rPinky1

    |   |         rPinky2 : rPinky1_to_rPinky2

    |   lCollar : vl5_to_lCollar

    |     lShldr : lCollar_to_lShldr

    |       lForeArm : lShldr_to_lForeArm

    |         lHand : lForeArm_to_lHand

    |           lThumb1 : lHand_to_lThumb1

    |           | lThumb2 : lThumb1_to_lThumb2

    |           lIndex1 : lHand_to_lIndex1

    |           | lIndex2 : lIndex1_to_lIndex2

    |           lMid1 : lHand_to_lMid1

    |           | lMid2 : lMid1_to_lMid2

    |           lRing1 : lHand_to_lRing1

    |           | lRing2 : lRing1_to_lRing2

    |           lPinky1 : lHand_to_lPinky1

    |             lPinky2 : lPinky1_to_lPinky2

    rButtock : humanoid_root_to_rButtock

    | rThigh : rButtock_to_rThigh

    |   rShin : rThigh_to_rShin

    |     rFoot : rShin_to_rFoot

    lButtock : humanoid_root_to_lButtock

      lThigh : lButtock_to_lThigh

        lShin : lThigh_to_lShin

          lFoot : lShin_to_lFoot

============================================================================
===========================

 

The model validates correctly for both X3D and HAnim.  There are still some
warnings but are mostly due to old-but-allowed names for joints/segments, I
should be able clean those up at some point.

 

Scaling and coordinate-axis registration are still not handled properly for
this model.  Am expecting we might experience such difficulties with each
BVH file we try to convert.  Here are some diagnostics from the converter,
inserted into the scene as comments:

 

*	<!-- 42 BVH JOINT definitions found, following a single HIERARCHY
ROOT --> 
*	<!-- BVH HIERARCHY model size computations: minX=-2.48547, maxX=0.0,
width=2.48547; minY=-3.69964, maxY=0.0, height=3.69964; minZ=-0.607171,
maxZ=12.103, depth=12.710170999999999 --> 
*	<!-- Estimated rescaling to meters based on height: scaleFactor=0.1
for modified height of 0.370m -->

 

Additional success beyond X_ITE and X3DOM: have also tested that the model
runs under Castle Game Engine view3dscene.  Image attached.  This also
confirms coordinate axis and scaling problems, I had to zoom back to see the
full animating skeleton.

 

Changes to X3D-Edit are checked in, we plan to test a pre-release version
next week.  It will appear at

*	SourceForge x3d Files:
<https://sourceforge.net/projects/x3d/files/X3D-Edit%20Pre-Release%20Testing
/> X3D-Edit Pre-Release Testing
*
https://sourceforge.net/projects/x3d/files/X3D-Edit%20Pre-Release%20Testing

 

Troubleshooting ideas are welcome on how to interpret relative sizes of X, Y
and Z values to try to orient and scale to match human dimensions.

 

We also have some preliminary BVH and MOCAP references as follows.  Further
links and ideas are always welcome.

 

*	X3D Scene Authoring Hints, Motion Capture (MOCAP)
*
https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#MOCAP

 

Have fun "walking the walk" with X3D and HAnim!  8)

 

all the best, Don

-- 

Don Brutzman  Naval Postgraduate School, Code USW/Br        brutzman at nps.edu

Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA    +1.831.656.2149

X3D graphics, virtual worlds, Navy robotics https://
faculty.nps.edu/brutzman

 

From: Brutzman, Donald (Don) (CIV) <brutzman at nps.edu> 
Sent: Friday, October 28, 2022 7:07 AM
To: Joseph D Williams <joedwil at earthlink.net>; John Carlson
<yottzumm at gmail.com>
Cc: X3D Graphics public mailing list <x3d-public at web3d.org>; Brutzman,
Donald (Don) (CIV) <brutzman at nps.edu>
Subject: RE: [x3d-public] BVH tasks, joining forces, BVH to HAnim validation

 

Hi Joe - thanks for analysis.

 

Intent is to produce compliant HAnim if at all possible.  Am mimicking
whatever is provided by BVH model using HAnim nodes.

 

Please note that BVH files are often dissimilar in model structure.  If you
see a better HAnim tree structure we ought to map to, great, please advise.
Will try to produce better tree diagrams - diagnostics follow.


Also needed: how can we figure out better default viewpoints?

 

At a minimum we ought to be able to have X3D Schematron diagnose whether
results are compliant X3D HAnim LOA-0,1, 2, 3, or 4.  Here are current
errors/diagnostics.

 

*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/PirouetteIndex.html
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/Pirouette.x3d

 

 

Performing DTD validation...

Checking
file:/C:/x3d-code/www.web3d.org/x3d/content/examples/HumanoidAnimation/Motio
nAnimation/Pirouette.x3d...

Attribute value "BvhPirouette_hip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

Attribute value "BvhPirouette__tip" of type ID must be unique within the
document.

XML DTD validation: fail!

 

[I think I see how to fix that in the converter, a DEF name is missing in
the middle of each of the __ entries above.  Will try this weekend.]

 

Performing X3D Schematron check...

[..] didn't come back, unfortunately

 

 

I think we are getting memory errors with this very large file.  Am hoping
to produce a Pirouette version of the pretty-print tree, similar to

 

*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/BvhConversion1Index.html
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/BvhConversion1.html
*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation
/BvhConversion1.html#HipsHAnimHumanoidReport

 

all the best, Don

-- 

Don Brutzman  Naval Postgraduate School, Code USW/Br        brutzman at nps.edu
<mailto:brutzman at nps.edu> 

Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA    +1.831.656.2149

X3D graphics, virtual worlds, Navy robotics https://
faculty.nps.edu/brutzman

 

From: Joseph D Williams <joedwil at earthlink.net
<mailto:joedwil at earthlink.net> > 
Sent: Friday, October 28, 2022 3:58 AM
To: John Carlson <yottzumm at gmail.com <mailto:yottzumm at gmail.com> >;
Brutzman, Donald (Don) (CIV) <brutzman at nps.edu <mailto:brutzman at nps.edu> >;
X3D Graphics public mailing list <x3d-public at web3d.org
<mailto:x3d-public at web3d.org> >
Subject: RE: [x3d-public] BVH tasks, joining forces, vim plugin

 

The only problem I am having with these examples is that the skeleton is not
x3d Hanim. 

It is simplified legacy version, undefined by hanim, left in the bvh dust by
reason of reality. 

The example varies from Hanim differing mainly, but not exclusively, in the
simplification of the spine and its role in controlling shoulder and head
motions  This skeleton is not bad, but just too simple to show more
realistic complex motions, like throwing something. It represents a noble
relic in steps toward a deliverable humanoid. 

 

Anyway, Please consider that the target playback skeleton is Not any bvh
skeleton that happens to be described in whatever bvh file we are
leveraging. For any bvh conversion the target should be a 'standard' loa4
skeleton along with converted x3d hanim user code for skeleton and
animations. (Note: Define some standard simple names/numbers for loa4
joints-segments-sites to reduce text).

Likewise, if an x3d tool exports x3d to bvh, it should be a 'standard'
skeleton (with uniform time steps). 

This gives the author full control of the skeleton and the animations and
makes the stuff usable and actually reusable. 

 

I think this is a necessary when the goal is generation of transportable
animations, only really possible using a 'standard' Hanim character. Again,
the example skeleton I see there is just fine for some stuff, like standing
around, but when you have to get real, then  you won't have to play long to
see limits. 

 

More historical fun with hanim and x3d and yes, even bvh. 

bvh to hanim to gltf 

Reminds me that the x3d Hanim animation repository would naturally deliver a
'standard' animation set aimed at a 'standard' loa4 skeleton, and the
delivery format would naturally be gltf. 

 

Thanks, 

Joe

 

 

From: John Carlson <mailto:yottzumm at gmail.com> 
Sent: Thursday, October 27, 2022 7:16 AM
To: Brutzman, Donald (Don) (CIV) <mailto:brutzman at nps.edu> ; X3D Graphics
public mailing list <mailto:x3d-public at web3d.org> 
Subject: Re: [x3d-public] BVH tasks, joining forces, vim plugin

 

Okay, X3D-Edit is now on sourceforge.

 

On Thu, Oct 27, 2022 at 8:33 AM John Carlson <yottzumm at gmail.com
<mailto:yottzumm at gmail.com> > wrote:

I will try to confirm savage.nps.edu <http://savage.nps.edu>  today, and try
to download a new version of x3d-edit.

 

If there's still a problem, i will provide screenshots.

 

John

 

On Wed, Oct 26, 2022 at 8:29 PM Brutzman, Donald (Don) (CIV)
<brutzman at nps.edu <mailto:brutzman at nps.edu> > wrote:

John: thanks, I just tested, X3D-Edit converted successfully (with warning
about very large file) and result validated for me.  Haven't viewed the
scene animation in X3D yet.

 

Am running a full build on HAnim examples and will upload/announce on
x3d-public when this example is ready.

 

Preliminary results in sourceforge at

 

*
https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examp
les/HumanoidAnimation/MotionAnimation/
<https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fsourcefor
ge.net%2Fp%2Fx3d%2Fcode%2FHEAD%2Ftree%2Fwww.web3d.org%2Fx3d%2Fcontent%2Fexam
ples%2FHumanoidAnimation%2FMotionAnimation%2F&data=05%7C01%7Cbrutzman%40nps.
edu%7Ca06a1f9ed8f944de0ab508dab8d34b25%7C6d936231a51740ea9199f7578963378e%7C
0%7C0%7C638025517114464469%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQI
joiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C2000%7C%7C%7C&sdata=07ZpN6%2BOyd
AP82u9Uab6VCVdL8foVHDRixqYcIvL3KI%3D&reserved=0> 
*	see Pirhouette.bvh  Pirhouette.bvh.txt  Pirhouette.x3d

 

Results will be going to

 

*
https://www.web3d.org/x3d/content/examples/HumanoidAnimation/MotionAnimation

 

Question: were you able to find the original pirouette.bvh used by three.js
in the CMU repository?  Or elsewhere on Web?  The github three.js site does
not appear to give any provenance information for this model (and BVH file
format does not have a place to put that).

 

Onward we go.

 

all the best, Don

-- 

Don Brutzman  Naval Postgraduate School, Code USW/Br        brutzman at nps.edu
<mailto:brutzman at nps.edu> 

Watkins 270,  MOVES Institute, Monterey CA 93943-5000 USA    +1.831.656.2149

X3D graphics, virtual worlds, Navy robotics https://
faculty.nps.edu/brutzman <http://faculty.nps.edu/brutzman> 

 

From: John Carlson <yottzumm at gmail.com <mailto:yottzumm at gmail.com> > 
Sent: Wednesday, October 26, 2022 2:59 PM
To: Brutzman, Donald (Don) (CIV) <brutzman at nps.edu <mailto:brutzman at nps.edu>
>; Michalis Kamburelis <michalis.kambi at gmail.com
<mailto:michalis.kambi at gmail.com> >; Joe D Williams <joedwil at earthlink.net
<mailto:joedwil at earthlink.net> >; Nicholas Polys <npolys at vt.edu
<mailto:npolys at vt.edu> >
Subject: Fwd: BVH tasks, joining forces, vim plugin

 

NPS WARNING: *external sender* verify before acting.

 

Joe, Nicholas, can you help with debugging conversion of this pirouette.bvh
in X3D-Edit?  There's a ton of stack trace from X3D-Edit when one tries the
first two options from the X3D-Edit menu.  I'm unsure if the .bvh file
currently works on michalis' convert.php page (may be worth a look as well,
looked like .bvh was not accepted model type.

I believe this may be the bvh file:

 

https://github.com/mrdoob/three.js/blob/dev/examples/models/bvh/pirouette.bv
h
<https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.co
m%2Fmrdoob%2Fthree.js%2Fblob%2Fdev%2Fexamples%2Fmodels%2Fbvh%2Fpirouette.bvh
&data=05%7C01%7Cbrutzman%40nps.edu%7Ca06a1f9ed8f944de0ab508dab8d34b25%7C6d93
6231a51740ea9199f7578963378e%7C0%7C0%7C638025517114464469%7CUnknown%7CTWFpbG
Zsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C2
000%7C%7C%7C&sdata=L4TJxdnpsrBagaSecYzIUJryektfRZ2InFR3BMhAsIk%3D&reserved=0
> 

 

I will go looking for more .bvh files in three.js

 

GL,

 

John

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20221030/3921a6c1/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: BvhPirouetteView3dsceneScalingCoordinateAxesProblems.png
Type: image/png
Size: 86122 bytes
Desc: not available
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20221030/3921a6c1/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5353 bytes
Desc: not available
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20221030/3921a6c1/attachment-0001.p7s>


More information about the x3d-public mailing list