#VRML V2.0 utf8 # Ass. 4 MULTIMEDIA AUTHORING 2007-2008 WorldInfo { title "Product" info ["(C) Copyright 2007 V.G. Stolte & " "Nick Peterman"] } Viewpoint { position 2.5 -2 30 } NavigationInfo { headlight TRUE type "EXAMINE" } NavigationInfo { type [ "EXAMINE", "ANY" ] } EXTERNPROTO logo [ field SFColor textcolor field SFFloat doorzichtigheid ] ["logo.wrl"] Transform { translation 20 8 2 #rotation 1 0 0 -1.1 #scale 0.5 0.5 0.5 children [ logo { textcolor 1 1 1 } ] } EXTERNPROTO stand [ field SFColor textcolor field SFFloat doorzichtigheid ] ["stand.wrl"] DEF Triangle Transform { #translation 7 -2 2 # rotation 1 0 0 -1.1 #scale 0.5 0.5 0.5 children [ stand { textcolor 1 1 1 } ] } # CODE FOR THE TIMER DEF Clock TimeSensor { cycleInterval 10 loop TRUE } # CODE FOR THE INTERPOLATOR MAKING THE ROTATION DEF Spin OrientationInterpolator { key [0.0 0.5 1.0] keyValue [0.0 1.0 0.0 0.0, 0.0 1.0 0.0 -3.14, 0.0 1.0 0.0 -6.28] } # ROUTES NEEDED FOR ROTATION ROUTE Clock.fraction_changed TO Spin.set_fraction ROUTE Spin.value_changed TO Triangle.set_rotation SpotLight { on TRUE direction 1.0 -1.0 -1.0 location -10.0 10.0 10.0 color 1.0 0.1 0.1 } SpotLight { on TRUE direction -1.0 -1.0 -1.0 location 10.0 10.0 10.0 color 1.0 0.1 0.1 } DirectionalLight { on TRUE direction 0.0 -1.0 1.0 intensity 0.1 } DirectionalLight { on TRUE direction 0.0 1.0 1.0 intensity 0.1 }