[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [x3d-public] containerField



Mirko Gontek wrote:
hi all,
i have two questions. first, there are "fields" in x3d which do not occur in
the specification. e.g. "containerField" in MetadataString:
<MetadataString name="myName" reference="name" containerField="xyz"/>
but according to the spec "containerField" is not a field:
MetadataString : X3DNode, X3DMetadataObject { SFNode [in,out] metadata NULL [X3DMetadataObject]
SFString [in,out] name ""
SFString [in,out] reference ""
MFString [in,out] value []
}
why this?
and second, how can i access these fields with sai? i'd like to create a
MetadataSet which looks like this:
<MetadataSet>
<MetadataString name="myName" reference="name" containerField="value"/>
<MetadataString name="myType" reference="type" containerField="value"/>
</MetadataSet>
i could not find any information about what containerField actually is, but
apparently the containerField is required (i adopted it from the conformance
examples). could you give me a hint? and how can i access containerField?

containerField is only needed in the XML encoding. Sometimes you need this field to tell the parser what field the node goes into. The most common case is Collision. There you need to specify whether a field is part of the proxy or children field.


<Collision>
   <Shape containerField="proxy"><Box /></Shape>
   <Shape>
       <IndexedFaceSet ...
   </Shape>
</Collision>

without the containerField the Box would have gone into the children field of the collision node instead of the proxy field.

You never need SAI access to this.

--
Alan Hudson

President Yumetech, Inc.                               www.yumetech.com
President Web3D Consortium                             www.web3d.org
206 340 8900
-------------------------------------------------------------------------
for list subscription/unsubscription,
go to http://www.web3d.org/cgi-bin/public_list_signup/lwgate/listsavail.html