Dynamic Generation of VRML nodes - The world
#VRML V2.0 utf8
DEF GEN_ROOT Transform{
children[ DEF GEN_TOUCH TouchSensor {}
Shape { geometry Sphere{} } ] }
DEF GENSCRIPT Script {
url “DynamicGen.class”
eventIn SFTime touched
eventOut MFNode addSphere }
ROUTE GEN_TOUCH.touchTime TO GENSCRIPT.touched
ROUTE GENSCRIPT.addSphere TO GEN_ROOT.addChildren
Previous slide
Next slide
Back to first slide
View graphic version