[x3d-public] Please generate an array for -geometry here, it's an MFNode. in X3dToJson.xslt

John Carlson yottzumm at gmail.com
Tue Apr 24 22:19:08 PDT 2018


Don, there are places where the -geometry field should be an MFNode in the
JSON files in the X3D resources examples.   Thanks!

On Mon, Apr 23, 2018, 3:57 PM John Carlson <yottzumm at gmail.com> wrote:

> don, did this get fixed?  thanks
>
> On Apr 18, 2018, at 1:11 AM, John Carlson <yottzumm at gmail.com> wrote:
>
>     <Transform translation='1.0 1.0 0.0'>
>       <Shape>
>         <Appearance>
>           <Material DEF='INDICATOR-MATERIAL' emissiveColor='0.0 0.0 1.0'/>
>         </Appearance>
>         <Sphere radius='0.2'/>
>       </Shape>
>     </Transform>
>     <RigidBodyCollection DEF='BODY-COLLECTION'>
>       <RigidBody DEF='BODY-1' containerField='bodies'
> finiteRotationAxis='0 1 0' position='0.0 2.0 0.0'>
>         <CollidableShape USE='BALL-GEOM' containerField='geometry'/>
>       </RigidBody>
>     </RigidBodyCollection>
>
> Here’s what it ends up in JSON:
>
> { "RigidBodyCollection":
>             {
>               "@DEF":"BODY-COLLECTION",
>               "-bodies":[
>                 { "RigidBody":
>                   {
>                     "@DEF":"BODY-1",
>                     "@position":[0.0,2.0,0.0],
>                     "-geometry":
>                       { "CollidableShape":
>                         {
>                           "@USE":"BALL-GEOM"
>                         }
>                       }
>                   }
>                 }
>               ]
>             }
>           },
>
>
> Is this valid?  The object model says it is.  However the autogenerated
> JSON schema doesn’t pass.  Looking at the object model again, it says
> geometry is an MFNode.   Therefore x3dToJson.xslt should generate an array,
> not an object.
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://web3d.org/pipermail/x3d-public_web3d.org/attachments/20180425/b2c84121/attachment-0001.html>


More information about the x3d-public mailing list