[x3d-public] Proto field default value question
Andreas Plesch
andreasplesch at gmail.com
Thu Jun 4 10:30:51 PDT 2020
While adding limited Proto functionality to x3dom, I came across the
question what to do in in the situation where a node in a ProtoBody
has an IS field connection to a ProtoField with an initial value, but
also has a field value for the same field. Here is an example:
<ProtoInterface>
<field accessType='inputOutput' name='color' type='SFColor' value='0,0,0'/>
...
<ProtoBody>
<Material diffuseColor='1,0,0'>
<IS>
<connect protoField='color' nodeField='diffuseColor' />
...
Is the initial color 0,0,0 (black) or 1,0,0 (red) ?
This ambiguity occurs only in the XML encoding.
https://www.web3d.org/documents/specifications/19776-1/V3.3/Part01/concepts.html#IS_ConnectStatementSyntax
is quiet on this. The intention is probably to use the ProtoInterface
default value.
Is that correct ?
-Andreas
--
Andreas Plesch
Waltham, MA 02453
More information about the x3d-public
mailing list