Week 6

prev | next

Scripting

Javascript (vrmlscript/ECMAscript)

Variables: declaration, assignment
Math object
Flow control: if, while, for
Functions: declaring, calling
Debugging with print/alert

Online ECMAScript Documentation

Older VRMLScript docs

Javascript

(Use the Javascript appendix in The Annotated VRML 2.0 Reference Manual for reference...)

Basic Math
Math Object Docs (for older VRMLScript)
Value Inversion
Sine Example

Type Conversion
Color Rollover
Position Based Color
Slider Controlled Light Intensity
Faux Raytracing

State & Logic
Switch Color When Clicked
Open & Close on Rollover
Cycle Through Three Shapes

prev | next

mrl