<div dir="auto">I think Don wants me to post a retraction,  I’ll do this.</div><div dir="auto"><br></div><div dir="auto">1.  I’ve only identified DEF/USE field reordering issues in HAnimHumanoid and HAnimSegment.   I haven’t tested the rest of X3D.   That’s Don’s job.  He does it well.</div><div dir="auto"><br></div><div dir="auto">a. I have identified HAnimSegment problems with models from my repository, only recently converted to JSON and run through my test harness.  There were differences when I generated x3d-tidy vs X3dToJson.xslt, but only X3dJson.xslt worked with the rest of my harness.  The JSON was correct in both cases.</div><div dir="auto"><br></div><div dir="auto"><br></div><div dir="auto"><div style="font-size:inherit"><a href="https://github.com/coderextreme/ci2had/tree/main/resources" style="font-size:inherit">https://github.com/coderextreme/ci2had/tree/main/resources</a></div><br></div><div dir="auto">The files are originally sourced from FacialAnimation archives, modified by hand written python.  My license is Apache for python, but you can apply the Web3D Consortium license to the models or the Python source code.</div><div dir="auto"><br></div><div dir="auto">The main issue was the sorting of HAnimSegment.coord and HAnimSegment.children.</div><div dir="auto"><br></div><div dir="auto">b.  The HAnimHumanoid DEF/USE reordering issues were due to X3DPSAIL generation from a Blender exporter, but I also experienced problems in the archive as well (well, not in the Python, but .x3d encoded files generated from the Python), which I assume are now fixed.  I haven’t tested them recently.</div><div dir="auto"><br></div><div dir="auto">2.  I have made a partial effort to create stylesheet fixes and Python fixes with AI that apply to all .x3d files generated from X3DJSAIL and X3DPSAIL, but I’ve been busy today.  The code is in the hands of people to do the right thing.</div><div dir="auto"><br></div><div dir="auto">Again, apologies to post to the main list, and especially to Don!</div><div dir="auto"><br></div><div dir="auto">John </div><div dir="auto"><span><br></span></div><div dir="auto"><span><br></span></div><div dir="auto"><span><br></span></div><div dir="auto"><span>On Fri, Mar 27, 2026 at 10:19 AM John Carlson <<a href="mailto:yottzumm@gmail.com">yottzumm@gmail.com</a>> wrote:</span><div class="gmail_quote gmail_quote_container" dir="auto"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)"><div dir="auto">To be clear:</div><div dir="auto"><br></div><div dir="auto">.x3d->x3d-tidy->.x3dj->X3DJSONLD->DOM->Serializer->Java, etc.->X3DJSAIL/stylesheets->XML, JSON, (more?) probably won’t work in many cases, due to DEF/USE reordering within SFNode field reordering.  I am not saying the .x3dj files are bad files.</div><div dir="auto"><br></div><div><div style="font-size:inherit" dir="auto"><span style="font-size:inherit;font-style:normal;font-weight:400;letter-spacing:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration:none;float:none;display:inline!important;color:rgb(0,0,0)">x3d->X3dToJson.xslt->.json->X3DJSONLD->DOM->Serializer->Java, etc.->X</span><span style="font-size:inherit">3DJSAIL/stylesheets->XML, JSON, (more?) probably will work.</span></div><div style="font-size:inherit" dir="auto"><span style="font-size:inherit"><br></span></div><div style="font-size:inherit" dir="auto">Using Canonical form might solve this issue.  But what is canonical JSON?</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">Specific ordering issues that that have come up include head statements, HAnimHumanoid and HAnimSegment nodes.</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">Please try to ensure that the authors ordering is preserved, or use canonical form.</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">Note that X3DJSONLD *should* act like a pass through.  But further work to achieve canonical form may be desired.</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">X3DJSAIL/stylesheets should stick with canonical form, if it uses it, but warn of potential DEF/USE reordering, if it can’t handle DEF/USE reordering under canonicalization.</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">x3d-tidy should also stick with canonical form, or not modify canonical form or alternatively, author’s intent.</div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto">Does this seem reasonable?</div></div><div><div style="font-size:inherit" dir="auto"><br></div><div style="font-size:inherit" dir="auto"><span style="font-size:inherit">John</span><br></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;padding-left:1ex;border-left-color:rgb(204,204,204)">
</blockquote></div></div>
</blockquote></div></div>