[x3d-public] X3DJSAIL route issue exception messages
Don Brutzman
brutzman at nps.edu
Wed May 3 01:58:44 PDT 2017
this kind of functionality (looking for defined fields) is implemented in Script, but not yet in ComposedShader. TODO.
scene excerpt:
<ComposedShader DEF='cobweb' language="GLSL">
<field name='set_cube' type='SFInt32' accessType='inputOnly' value='0'></field>
<field name='set_chromaticDispertion' accessType='initializeOnly' type='SFVec3f' value='0.98 1.0 1.033'></field>
<field name='set_bias' type='SFFloat' accessType='inputOnly' value='0.5'></field>
<field name='set_scale' type='SFFloat' accessType='inputOnly' value='0.5'></field>
<field name='set_power' type='SFFloat' accessType='inputOnly' value='2'></field>
<field name='set_a' type='SFFloat' accessType='inputOnly' value='10'></field>
<field name='set_b' type='SFFloat' accessType='inputOnly' value='1'></field>
<field name='set_c' type='SFFloat' accessType='inputOnly' value='20'></field>
<field name='set_d' type='SFFloat' accessType='inputOnly' value='20'></field>
<field name='set_tdelta' type='SFFloat' accessType='inputOnly' value='0'></field>
<field name='set_pdelta' type='SFFloat' accessType='inputOnly' value='0'></field>
<ShaderPart url='"cobweb_flowers_input.vs" "http://coderextreme.net/X3DJSONLD/cobweb_flowers_input.vs"' containerField='parts' type='VERTEX'></ShaderPart>
<ShaderPart url='"pc_input_flowers.fs" "http://coderextreme.net/X3DJSONLD/pc_input_flowers.fs"' containerField='parts' type='FRAGMENT'></ShaderPart>
</ComposedShader>
<ROUTE fromNode='Animate' fromField='a_changed' toNode='cobweb' toField='set_a'/>
<ROUTE fromNode='Animate' fromField='b_changed' toNode='cobweb' toField='set_b'/>
<ROUTE fromNode='Animate' fromField='c_changed' toNode='cobweb' toField='set_c'/>
<ROUTE fromNode='Animate' fromField='d_changed' toNode='cobweb' toField='set_d'/>
On 5/2/2017 3:06 AM, yottzumm at gmail.com wrote:
> I don’t know how to fix these errors. Comments or patched X3D XML files are welcome. Attached. One has a field on a Composed Shader.
>
> $ cat flowers7.runerr.txt
>
> org.web3d.x3d.sai.InvalidFieldValueException: ROUTE details: FROM Animate.a_changed (Script.SFFloat.outputOnly) TO cobweb.set_a (ComposedShader.ERROR_UNKNOWN_FIELD_TYPE.ERROR_UNKNOWN_FIELD_ACCESSTYPE)
>
> ROUTE has source-destination type mismatch, fromField='a_changed' source and toField='set_a' destination have different types. ROUTE toField (destination) event can only have accessType='inputOutput' or accessType='inputOnly'.
>
> at org.web3d.x3d.jsail.Core.ROUTEObject.validate(ROUTEObject.java:720)
>
> at org.web3d.x3d.jsail.Core.SceneObject.validate(SceneObject.java:606)
>
> at org.web3d.x3d.jsail.Core.X3DObject.validate(X3DObject.java:1855)
>
> at org.web3d.x3d.jsail.Core.X3DObject.toFileJSON(X3DObject.java:746)
>
> at flowers7.main(flowers7.java:79)
>
> Exception in thread "main" org.web3d.x3d.sai.InvalidFieldValueException: ROUTE details: FROM Animate.a_changed (Script.SFFloat.outputOnly) TO cobweb.set_a (ComposedShader.ERROR_UNKNOWN_FIELD_TYPE.ERROR_UNKNOWN_FIELD_ACCESSTYPE)
>
> ROUTE has source-destination type mismatch, fromField='a_changed' source and toField='set_a' destination have different types. ROUTE toField (destination) event can only have accessType='inputOutput' or accessType='inputOnly'.
>
> at org.web3d.x3d.jsail.Core.ROUTEObject.validate(ROUTEObject.java:720)
>
> at org.web3d.x3d.jsail.Core.SceneObject.validate(SceneObject.java:606)
>
> at org.web3d.x3d.jsail.Core.X3DObject.validate(X3DObject.java:1855)
>
> at org.web3d.x3d.jsail.Core.X3DObject.toFileJSON(X3DObject.java:746)
>
> at flowers7.main(flowers7.java:79)
>
> $ cat x3dconnectorProto.runerr.txt
>
> org.web3d.x3d.sai.InvalidFieldValueException: ROUTE details: FROM G1.translation_changed (Transform.SFVec3f.inputOutput) TO connector1.set_startpoint (ProtoInstance.ERROR_UNKNOWN_FIELD_TYPE.ERROR_UNKNOWN_FIELD_ACCESSTYPE)
>
> ROUTE has source-destination type mismatch, fromField='translation_changed' source and toField='set_startpoint' destination have different types. ROUTE toField (destination) event can only have accessType='inputOutput' or accessType='inputOnly'.
>
> at org.web3d.x3d.jsail.Core.ROUTEObject.validate(ROUTEObject.java:720)
>
> at org.web3d.x3d.jsail.Core.SceneObject.validate(SceneObject.java:606)
>
> at org.web3d.x3d.jsail.Core.X3DObject.validate(X3DObject.java:1855)
>
> at org.web3d.x3d.jsail.Core.X3DObject.toFileJSON(X3DObject.java:746)
>
> at x3dconnectorProto.main(x3dconnectorProto.java:79)
>
> Exception in thread "main" org.web3d.x3d.sai.InvalidFieldValueException: ROUTE details: FROM G1.translation_changed (Transform.SFVec3f.inputOutput) TO connector1.set_startpoint (ProtoInstance.ERROR_UNKNOWN_FIELD_TYPE.ERROR_UNKNOWN_FIELD_ACCESSTYPE)
>
> ROUTE has source-destination type mismatch, fromField='translation_changed' source and toField='set_startpoint' destination have different types. ROUTE toField (destination) event can only have accessType='inputOutput' or accessType='inputOnly'.
>
> at org.web3d.x3d.jsail.Core.ROUTEObject.validate(ROUTEObject.java:720)
>
> at org.web3d.x3d.jsail.Core.SceneObject.validate(SceneObject.java:606)
>
> at org.web3d.x3d.jsail.Core.X3DObject.validate(X3DObject.java:1855)
>
> at org.web3d.x3d.jsail.Core.X3DObject.toFileJSON(X3DObject.java:746)
>
> at x3dconnectorProto.main(x3dconnectorProto.java:79)
>
all the best, Don
--
Don Brutzman Naval Postgraduate School, Code USW/Br brutzman at nps.edu
Watkins 270, MOVES Institute, Monterey CA 93943-5000 USA +1.831.656.2149
X3D graphics, virtual worlds, navy robotics http://faculty.nps.edu/brutzman
More information about the x3d-public
mailing list