[x3d-public] Nearly post mortem
Joe D Williams
joedwil at earthlink.net
Fri Jul 5 15:14:50 PDT 2024
X3DJSONLD/blend/localtest/Humanoid4.x3d at master · coderextreme/X3DJSONLD (github.com) (https://github.com/coderextreme/X3DJSONLD/blob/master/blend/localtest/Humanoid4.x3d)
> This has skin that doesn't move--maybe someone can add skin weights
The skin is there, but not animated. This skin from a different skeleton. You get to do the final point to joint rigging. The most simple skin consists of triangles made from the set surface feature points. This skin uses V1 feature points and some added, but does not include all the V2 feature points. So, the skin either needs to be re-triangulated adding new V2 points, and connected to the skeleton, or, using hints from the V1 skeleton that this skin was last used on, simply assign these points to joints. Please just go ahead and add the new V2 points, then connect it up.
The x3d way of documenting this step in the"rigging" process is using the Joint node. The fields are skinCoordIndex and skinCoordWeight where the skinCoordIndex is a list of numbers in order of appearance in the Coord point list of x y z coordinates of the skin geometry and the skinCoordWeight is the 0 to 1 scaling value that is to be applied to the corresponding index. More than 1 Joint may produce a motion to the point, so the index can appear multiple times, and if multiple, the weights defined for that index should total to be max 1.
For example, for the geometry associated with left arm, assign these indexes to the left shoulder Joint with all weights=1. A roll action of the shoulder joint, 0 0 -1 1, will move those vertices away from the body, ccw to the viewer.
Most authoring tools will offer a method of defining this point to joint data where a shading graphic allows you to give a general definition of which vertices are controlled by which Joints. This will give a basis for getting the skin to operate the way you wish over a range of postures and motions you design. Whatever the process, the end result is that every point is assigned to at least one Joint. In general, the farthest from the Joint center has a higher weight and nearest has a lower weight. The actual motion of a point depends on the actual joint rotation and the radial distance of the point from the Joint center. If multiple joints, then the result is accumulated. Achieving hifi results means careful attention to the relationship of the Joint center locations with respect to the animated mesh points.
Next note that the user code form for x3d joint to point bindings is to list the index and weight in fields of the Joint node. For the closest to the metal form this data for each frame is stored where each vertex data point includes a list of values applied by each joint to be applied to that point for that frame to accomplish the motion. For this reason and others, the non-x3d authoring system may store the data in many forms, most never intended to be actually exposed and editable by the author.
However, under the covers there is always a list of these connections in some form. If you work with a reasonable number of points for your skin, distributed effectively, then some fine tuning can be done with a simple text editor and x3d player.
Thanks and Best,
Joe
----Original Message-----
From: John Carlson <yottzumm at gmail.com>
Sent: Jul 5, 2024 12:14 PM
To: Joe D Williams <joedwil at earthlink.net>, X3D Ecosystem public discussion <x3d-ecosystem at web3d.org>, Katy Schildmeyer KS APPAREL DESIGN <katy at ksappareldesign.com>, Carol McDonald <cemd2 at comcast.net>
Subject: Re: Nearly post mortem
Okay, I took some of my site billboard, that also had a skeleton and developed Humanoid4.x3d.
X3DJSONLD/blend/localtest/Humanoid4.x3d at master · coderextreme/X3DJSONLD (github.com) (https://github.com/coderextreme/X3DJSONLD/blob/master/blend/localtest/Humanoid4.x3d)
This has skin that doesn't move--maybe someone can add skin weights.
Note that I'm now getting segment and site geometry (spheres and "cylinders"), but the animation isn't right for them in Blender. So perhaps we need to study the import script:
X3DJSONLD/blend/localtest/localfinal.py at master · coderextreme/X3DJSONLD (github.com) (https://github.com/coderextreme/X3DJSONLD/blob/master/blend/localtest/localfinal.py)
This seems like quite a bit of progress taking out USE and DEF attributes. Now I can focus on what's wrong with the animation. I discovered how to hide empties, so that really helps in some cases.
John
On Thu, Jul 4, 2024 at 4:13 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
I think the back is being loaded, and the text, but it’s difficult to navigate to in Blender.
Here are examples. There’s currently two source codes, one for localLOAminus1.x3d and one for the rest.
The bat script should run everything.
https://github.com/coderextreme/X3DJSONLD/tree/master/blend/localtest
John
On Thu, Jul 4, 2024 at 11:11 AM Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)> wrote:
Hi John,
what tool gives you this error. The ifs is legal and serves as back for the menu, making it easier to click.
Joe
-----Original Message-----
From: John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)>
Sent: Jul 4, 2024 3:00 AM
To: Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)>
Subject: Re: Nearly post mortem
The problem with Jin 11f, Jin 11g, and JinConcat11f.x3d is the following IndexedFaceSet:
<IndexedFaceSet DEF='Backing' coordIndex='0 1 2 3 -1'>
<Coordinate point='-0.2 -0.25 -0.01 3 -0.25 -0.01 3 1 -0.01 -0.2 1 -0.01'/>
</IndexedFaceSet>
Commenting this out allows the file to load.
The issue is that the IndexedFaceSet specifies a quad instead of a tri. I will look into it.
Good test, Joe.
John
On Thu, Jul 4, 2024 at 1:37 AM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
This is what I'm faced with.
Error : EXCEPTION_ACCESS_VIOLATION
Address : 0x00007FF6096ED1FB
Module : blender.exe
Thread : 00003cb8
Writing: C:\Users\john\AppData\Local\Temp\blender.crash.txt
runlocalfinal.sh: line 2: 26084 Segmentation fault /c/Program\ Files/Blender\ Foundation/Blender\ 4.1/blender.exe --verbose 3 --python localfinal.py
The blender.crash.txt file is zero size.
I'm going to try to update blender.
John
On Thu, Jul 4, 2024 at 12:58 AM Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)> wrote:
Hi John,
Use this we can work on cancat later
Joe
-----Original Message-----
From: John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)>
Sent: Jul 3, 2024 9:18 PM
To: Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)>
Subject: Re: Nearly post mortem
Okay, but I will have to strip out commas, barebones loader doesn't like that.
John
On Wed, Jul 3, 2024 at 8:58 PM Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)> wrote:
> (concatenated animation version).
Forget this concat for this development for now. Your version of the code is too much and that mode is the only one to select. Your cat code is extreme and bigger than all the rest. We can work on it but for now just jin11 series for now with no concat - just too big and not integrated with rest of menu.
Thanks,
Joe
-----Original Message-----
From: John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)>
Sent: Jul 3, 2024 6:52 PM
To: Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)>
Cc: Carol McDonald <cemd2 at comcast.net (mailto:cemd2 at comcast.net)>, GPU Group <gpugroup at gmail.com (mailto:gpugroup at gmail.com)>, Katy Schildmeyer <katy at ksappareldesign.com (mailto:katy at ksappareldesign.com)>, Michalis Kamburelis <michalis.kambi at gmail.com (mailto:michalis.kambi at gmail.com)>, <x3d-ecosystem at web3d.org (mailto:x3d-ecosystem at web3d.org)>
Subject: Re: Nearly post mortem
All is well, Joe, the humanoid just needs be animated. I need to figure out why memory allocations are failing on Jin 11f mesh (concatenated animation version).
On Wed, Jul 3, 2024 at 8:44 PM Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)> wrote:
> What I have discovered in my journeys is to that locations seem to added together, such that if humanoid_root not at 0,0,0, then it gets added to sacroiliac, etc.
it is because your transform hierarchy is wrong. The translation for one is adding to another so the hierarchy is adding srong.
Joe
-----Original Message-----
From: Katy Schildmeyer <katy at ksappareldesign.com (mailto:katy at ksappareldesign.com)>
Sent: Jul 2, 2024 6:45 PM
To: John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)>
Cc: Carol McDonald <cemd2 at comcast.net (mailto:cemd2 at comcast.net)>, GPU Group <gpugroup at gmail.com (mailto:gpugroup at gmail.com)>, Joe D Williams <joedwil at earthlink.net (mailto:joedwil at earthlink.net)>, Michalis Kamburelis <michalis.kambi at gmail.com (mailto:michalis.kambi at gmail.com)>, <x3d-ecosystem at web3d.org (mailto:x3d-ecosystem at web3d.org)>
Subject: Re: Nearly post mortem
John,
Let me know if you are free tonite or tomorrow to just jump on a call with jin. I may have some ideas. Dunno if they will go against what you are trying for, but worth a review. Let me know what works for you!
Katherine Schildmeyer
KS Apparel Design & Consulting
www.ksappareldesign.com (http://www.ksappareldesign.com)
PH: 503-367-4856
*This message and accompanying documents are covered by the Electronic Communications Privacy Act, 18 U.S.C. §§ 2510-2521, and contains information intended for the specified individual(s) only. This information is confidential. Unless stated to the contrary, any opinions or comments are personal to the writer and do not represent the official view of the company. If you are not the intended recipient or an agent responsible for delivering it to the intended recipient, you are hereby notified that you have received this document in error and that any review, dissemination, copying, or the taking of action based on the contents of this information is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail, and delete the original message.
On Mon, Jul 1, 2024 at 10:43 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
I also think that HAnim export may remain viable, but will be joints+skin based, until Blender or an extension raises the game.
Any examples to the otherwise welcome.
I think we should perhaps focus on authoring tools which produce segments and sites, and provide conversion to X3D in the short term, like WinterAndSpring.
But I’ll try delta transforms first.
John
On Mon, Jul 1, 2024 at 11:21 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
If delta transforms don’t work, I’m willing to say that Joint centers won’t work without Blender bones, which probably means we should focus on joints+multiple skins (clothes), and find another tool to hook sites to segments to joints. Further development on the Blender addon should be focused on more fruitful areas, like PBR import/export, or revamping Blender itself, to suit X3D requirements (the latter is beyond my interest, skill and pay grade, I don’t do C++ debugging like a lowly paid game developer. My interest might be piqued by a 5 year, 1.25 million contract with benefits, and then I would probably die. What’s the point?) Systems which already support X3D could be employed to develop an authoring system (CGE, Sunrize, Titania, Flux???). I’d consider working with Pascal and JavaScript, pro bono. Pascal looks a lot more sane than C++.
There might be a way to hook armatures into joints, sites and segments, without Blender bones, but don’t ask me how to animate that behemoth yet. I think we’re more likely to have success converting sites and segments to Blender bones in addition to joints, but I don’t know how to hook Transforms or Groups to Blender bones, so no go. At this point, i don’t quite know how to hook armature to anything but Blender bones and mesh.
If someone can make available a blender file which shows something else, that would probably be a step forward.
One could also take the approach that animation should not be done in Blender, but I’m already hearing rumblings of KHR_interactivity being implemented.
Note that when I went for #beginner-help on Blender Discord, no one wanted to help with X3D.
If I get go ahead to convert sites and segments to Blender bones, I will go ahead with that.
The reason why our initial Blender examples worked was because the nesting of transforms went in one direction. I’m pretty sure if the centers go one way, then the reverse, one will need delta transforms or non-nested transforms. I would welcome this X3D example being developed.
Overall, it looks like I got extremely lucky that gramps worked in Blender, and I could export him.
All the problems probably go away without a hierarchy.
Anyway, after delta transforms, I’ll be looking for some direction. If they work, then I see a path forward for sites and segments.
John
On Mon, Jul 1, 2024 at 10:10 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
What I have discovered in my journeys is to that locations seem to added together, such that if humanoid_root not at 0,0,0, then it gets added to sacroiliac, etc. that is, if you go down the leg or arm, they will go upwards in Y, despite perfect location values appearing in Blender. It probably doesn’t help to do any kind of coordinate swapping or matrix_local vs matrix_world. What I will look into is doing delta transforms next, subtracting child center from parent center and assigning to delta location. Another way to solve this is provide a flat transform hierarchy.
I will check in an example which shows this—eventually.
Anyway, I’m discovering new ways to curse at AI, finally taking over from them, despite luring them with $20/month. Probably you.com (http://you.com) is better for the end user and worse for the AI provider. It just seems like you.com (http://you.com) could be blocked by the AI providers.
Blender’s not much better than AI.
John
On Mon, Jul 1, 2024 at 4:06 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
I have revamped the examples and created a bat script to run the python along with showing the examples in castle-model-viewer. Enjoy!
X3DJSONLD/blend/localtest at master · coderextreme/X3DJSONLD (github.com) (https://github.com/coderextreme/X3DJSONLD/tree/master/blend/localtest)
I'm still working on JinLOA1, showing that centers AND geometry can be loaded properly, while also nesting HAnimJoints in Blender, and ignoring joints and segments fields in HAnimHumanoid.
I feel a bit like John C. from Terminator, saving humanoids from SkyNet.
On Sat, Jun 29, 2024 at 10:08 PM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
Yes, except for JinLOA1scaled1.x3d. Don’t import with the .x3d addon, use the provided python and change the file name. The default addon does not handle ROUTEs.
I will double check the files.
John
On Sat, Jun 29, 2024 at 6:29 PM Katy Schildmeyer <katy at ksappareldesign.com (mailto:katy at ksappareldesign.com)> wrote:
John, are there supposed to be animations on these when I press play for them in blender? Otherwise I see the centers and hierarchy when I import as x3d. Will also test in c4d and etc.
Katherine Schildmeyer
KS Apparel Design & Consulting
www.ksappareldesign.com (http://www.ksappareldesign.com)
PH: 503-367-4856
*This message and accompanying documents are covered by the Electronic Communications Privacy Act, 18 U.S.C. §§ 2510-2521, and contains information intended for the specified individual(s) only. This information is confidential. Unless stated to the contrary, any opinions or comments are personal to the writer and do not represent the official view of the company. If you are not the intended recipient or an agent responsible for delivering it to the intended recipient, you are hereby notified that you have received this document in error and that any review, dissemination, copying, or the taking of action based on the contents of this information is strictly prohibited. If you have received this communication in error, please notify us immediately by e-mail, and delete the original message.
On Sat, Jun 29, 2024 at 5:18 AM John Carlson <yottzumm at gmail.com (mailto:yottzumm at gmail.com)> wrote:
I appear to have solved the problem with the Blender X3D addon (crosses fingers).
Perhaps someone is willing to do a final test before I attempt to incorporate it into a Blender addon.
I will next try the example on Hanim Jin 20c for loading into Blender.
Thanks for your support.
John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20240705/abb6c71b/attachment-0001.html>
More information about the x3d-public
mailing list