[x3d-public] Discussion: containerField for x3d.py XML export

John Carlson yottzumm at gmail.com
Sun Sep 24 14:25:57 PDT 2023


The solution for the skeleton vs joints sort fields ordering is to sort
MFNode fields only with skeleton first, and then sort without skeleton.
Then you can add joints field safely.

Then they will print out in the correct order.

John

On Sun, Sep 24, 2023 at 4:14 PM John Carlson <yottzumm at gmail.com> wrote:

> Note that I’ve also added a way to print out HAnimHumanoid joints field to
> x3d.py
>
> Here the python with skeleton field
>
>
> https://www.web3d.org/x3d/content/examples/HumanoidAnimation/Specifications/KoreanCharacterMotionAnnexD01Jin.py
>
> Convert this to XML, I guess, or I will provide other XML later.   You’ll
> want to add a joints field for testing purposes.
>
> Also print out VRML and make sure it works.
>
> The goal is no warnings.
>
> Thanks!
>
> John
> On Sun, Sep 24, 2023 at 3:58 PM John Carlson <yottzumm at gmail.com> wrote:
>
>> I suggest taking the HAnim pt2 annex D .x3d example, here,
>>
>> https://www.web3d.org/x3d/content/examples/HumanoidAnimation/Specifications/KoreanCharacterMotionAnnexD01JinIndex.html
>> convert to  Python .py then convert the python to XML by editing the python
>> program, write out the XML to .x3d .  Then load the .x3d into view3dscene.
>>
>> Btw, sourceforge x3d code is locked down again.
>>
>> John
>> On Sun, Sep 24, 2023 at 3:39 PM John Carlson <yottzumm at gmail.com> wrote:
>>
>>> If it wasn’t clear, i was going to add a “containerField” optional
>>> parameter to some XML() methods in x3d.py
>>>
>>> I put in containerField into where view3dscene complains and the problem
>>> goes away, I know exactly what the problem is.  I will provide a file
>>> later, sorry for the delay.
>>>
>>> The goal is to do no editing except for meta statements.
>>>
>>> On Sun, Sep 24, 2023 at 2:47 PM Brutzman, Donald (Don) (CIV) <
>>> brutzman at nps.edu> wrote:
>>>
>>>> Thanks for continued troubleshooting.
>>>>
>>>>
>>>>
>>>> Please do not do anything with containerField handling in x3d.py since
>>>> it is unique to XML encoding.
>>>>
>>>>
>>>>
>>>> If you encounter any incorrect handling, please provide a regular issue
>>>> report that notes
>>>>
>>>>    - Model, in .x3d/.x3dv and also .py
>>>>    - Error or warning that was encountered, relevant tools, etc.
>>>>
>>>>
>>>>
>>>> I can then isolate the problem and fix it.  When errors do occur, it is
>>>> usually an error in the scene, but sometimes a simple omission of some sort
>>>> somewhere deep in the code autogeneration of the library.
>>>>
>>>>
>>>>
>>>> p.s. also thanks for your recent issue reports on X3DJSAIL, very
>>>> helpful.  I have made a number of improvements this weekend, hoping to
>>>> publish tonight.
>>>>
>>>>
>>>>
>>>> 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:* John Carlson <yottzumm at gmail.com>
>>>> *Sent:* Sunday, September 24, 2023 11:34 AM
>>>> *To:* Brutzman, Donald (Don) (CIV) <brutzman at nps.edu>; Michalis
>>>> Kamburelis <michalis.kambi at gmail.com>; Peitso, Loren (CIV) <
>>>> lepeitso at nps.edu>; X3D Graphics public mailing list <
>>>> x3d-public at web3d.org>
>>>> *Subject:* Discussion: containerField for x3d.py XML export
>>>>
>>>>
>>>>
>>>> First of all, great work on x3d.py, Loren and Don, I feel like I am
>>>> polishing a diamond.
>>>>
>>>>
>>>>
>>>> I am considering adding the containerField attribute (not field) to XML
>>>> output in x3d.py. This is mainly to support requirements of view3dscene.
>>>> It complains if I don’t add the containerField attributes in HAnim
>>>> (skeleton and joints containerFields, maybe more)—the default, children, is
>>>> not an acceptable to view3dscene.  Also, not having a skin containerField
>>>> is weird when dropping arbitrary Shape nodes into a HAnimHumanoid.
>>>>
>>>>
>>>>
>>>> Does adding the containerField attribute seem like a good idea, or
>>>> should I push back on browser vendors?
>>>>
>>>>
>>>>
>>>> I plan to do something like I do for VRML when printing out joints and
>>>> skeleton fields etc.  I won’t print out the containerField for obvious
>>>> fields, i have a list of these somewhere…geometry, appearance, material,
>>>> etc
>>>>
>>>>
>>>>
>>>> Should I allow the x3d.py app programmer to add a containerField
>>>> attribute, or should I compute it as best i can, and save browser vendors
>>>> the pain?
>>>>
>>>>
>>>>
>>>> I think what this means is passing an optional parameter to some
>>>> each.XML() method calls.
>>>>
>>>>
>>>>
>>>> After writing this message, the answer seems obvious.
>>>>
>>>>
>>>>
>>>> Comments?
>>>>
>>>>
>>>>
>>>> John
>>>>
>>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20230924/2024e52c/attachment.html>


More information about the x3d-public mailing list