#VRML V2.0 utf8 Group { children [ Transform { translation -4 0 0 children [ Shape { # création d'une sphere pour matérialiser la sphere invisible du sphereSensor appearance Appearance { material Material { diffuseColor 1 0 0 } } geometry Sphere {} } DEF SpSensor SphereSensor {} ] } Transform { # Noeud transform pour multiplier par 2 les mouvements du curseur scale 2 2 2 children [ Shape { # la shepre sur laquelle va se déplacer la boule # représentant la position sur curseur sur la sphere rouge appearance Appearance { material Material { diffuseColor 0 1 1 transparency .8 } } geometry Sphere {} } # Le noeud transform pour controler la position de la boule bleue DEF boulebleue Transform { translation 0 0 0 children [ Shape { # la petite boule bleue appearance Appearance { material Material { diffuseColor 0 0 1 } } geometry Sphere { radius 0.2 } } ] } ] } ] } # On prend la position du curseur sur la boule rouge et on déplace la boulebleue ROUTE SpSensor.trackPoint_changed TO boulebleue.set_translation