[X3D-Ecosystem] XML is dead for x3.py

John Carlson yottzumm at gmail.com
Mon Aug 25 18:01:39 PDT 2025


Okay.  I was wrong.

The awk script is applied to the x3d.py as Andreas said.  Not to the
stylesheet.

Apologies, I hadn't tried.  Now I know.

Thanks,

John

On Mon, Aug 25, 2025 at 7:12 PM John Carlson <yottzumm at gmail.com> wrote:

> Okay. I've applied the awk script to
>
> x3d / Code / [r37479]
> /www.web3d.org/x3d/stylesheets/X3duomToX3dPythonPackage.xslt
> <https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/stylesheets/X3duomToX3dPythonPackage.xslt>
>
> And
>
> x3d / Code / [r37479] /www.web3d.org/x3d/stylesheets/python/x3d.py
> <https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/stylesheets/python/x3d.py>
>
> Here are the diffs.  If you need the modified x3d.py or stylesheet, let me
> know.
>
> AFAICT, the awk scripts between the main branch and the kwargs branch were
> identical.
>
> I'm going to pursue the containerField issue first, I don't know what's
> necessary to produce a x3d.py with kwargs in it.  I've got something to
> sort the skeleton field first, that's my primary concern.
>
> Thanks!
>
> John
>
> On Mon, Aug 25, 2025 at 10:15 AM Andreas Plesch <andreasplesch at gmail.com>
> wrote:
>
>> Here are my attempts to add containerField output:
>>
>> https://github.com/andreasplesch/x3d-python-mod/tree/main
>>
>> The awk script modifies x3d.py and is very brittle.
>>
>> It looks like I chose an MIT license which essentially means no
>> restrictions of any kind but happy to do whatever may be necessary.
>>
>> This modifications will add a containerField attribute to all nodes
>> (other than children?) which is probably considered too noisy. Perhaps
>> there could be postprocessing to check for defaults.
>>
>> Here is a cool live environment to play with x3d.py which includes the
>> files:
>>
>>
>> https://mybinder.org/v2/gh/spyder-ide/binder-environments/spyder-stable?urlpath=git-pull%3Frepo%3Dhttps%3A%2F%2Fgithub.com%2Fandreasplesch%2Fx3d-python-mod%26urlpath%3Ddesktop%26branch%3Dmain
>>
>> Just copy x3dcf.py into the test directory.
>>
>> Separately, the kwargs branch also includes an effort to preserve node
>> order from the python arguments in the xml output which is important for
>> DEF/USE.
>>
>> Cheers, -Andreas
>>
>>
>>
>>
>> On Mon, Aug 25, 2025 at 2:15 AM John Carlson <yottzumm at gmail.com> wrote:
>>
>>> I’m having major problems with having to hand edit X3D XML HAnim files
>>> output from x3d.py (X3DPSAIL) to that need to have containerField
>>> attributes for them to render.
>>>
>>> Sure, I could probably do a patch of the stylesheet,
>>>
>>> https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/stylesheets/X3duomToX3dPythonPackage.xslt following
>>> Andreas’ lead.
>>>
>>> But really we want these changes upstreamed.  Can someone arrange with
>>> Andreas to license his code for inclusion in x3d.py?
>>>
>>> Meanwhile, I will probably choose to use VRML output, with my patch
>>> which converts the children field to the appropriate field: skin, joints,
>>> skeleton, etc.
>>>
>>> Bye, bye, XML. Hello, VRML.
>>>
>>> John
>>>
>>
>>
>> --
>> Andreas Plesch
>> Waltham, MA 02453
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-ecosystem_web3d.org/attachments/20250825/37ec9af3/attachment.html>


More information about the X3D-Ecosystem mailing list