Table of Contents Previous Directory Summary Directory Viewpoint Slideshow Javadoc for translated java source Next Directory Summary X3D Resources

X3D Example Archives: VRML 2 Sourcebook, Chapter 09 Sensing Viewer

Authors can design interactivity into a scene that responds to user actions.

A scene can sense when the viewer's cursor is over a shape, has touched a shape, or is dragging atop a shape. A scene can also trigger animations on a viewer's touch, enabling the viewer to move and rotate shapes. There are four main action sensor types: TouchSensor senses touch, SphereSensor senses drags in a spherical way, CylinderSensor senses drags cylindrically, and PlaneSensor senses drags around a plane.

These X3D scenes are adapted directly from the original VRML 2.0 Sourcebook chapter examples. Also available: Introduction to VRML97 SIGGRAPH98 course notes.

Figure 09.6 Sphere Sensor With Axes
  18 X3D Models       X3D Model Descriptions
Figure09_1SpinningCubeTouchSensor Figure 09 1 Spinning Cube Touch Sensor A cube that spins when the cursor moves over it. Also see Figure 9.2 for comparison.
Figure09_1SpinningCubeTouchSensorWithAxes Figure 09 1 Spinning Cube Touch Sensor With Axes A cube that spins when the cursor moves over it, with coordinate axes superimposed to show X3D/VRML directions. Also see Figure 9.2 for comparison.
Figure09_2SpinningCubeTouchSensorClicked Figure 09 2 Spinning Cube Touch Sensor Clicked A cube that spins when the viewer touches it. Also see Figure 9.1 for comparison.
Figure09_2SpinningCubeTouchSensorClickedWithAxes Figure 09 2 Spinning Cube Touch Sensor Clicked With Axes A cube that spins when the viewer touches it, with coordinate axes superimposed to show X3D/VRML directions. Also see Figure 9.1 for comparison.
Figure09_3ConePlaneSensor Figure 09 3 Cone Plane Sensor A Cone that translates in the vertical XY plane when the viewer drags it. Also see Figure 9.4 for comparison.
Figure09_3ConePlaneSensorWithAxes Figure 09 3 Cone Plane Sensor With Axes A Cone that translates in the vertical XY plane when the viewer drags it, with coordinate axes superimposed to show X3D/VRML directions. Also see Figure 9.4 for comparison.
Figure09_4ConePlaneSensorConstrained Figure 09 4 Cone Plane Sensor Constrained A cone that translates within a limited range of the XZ plane when the viewer drags it. Also see Figure 9.3 for comparison.
Figure09_4ConePlaneSensorConstrainedWithAxes Figure 09 4 Cone Plane Sensor Constrained With Axes A cone that translates within a limited range of the XZ plane when the viewer drags it, with coordinate axes superimposed to show X3D/VRML directions. Also see Figure 9.3 for comparison.
Figure09_5FourStackingBlocks Figure 09 5 Four Stacking Blocks Four stacking blocks, select and drag to see each of them.
Figure09_5FourStackingBlocksWithAxes Figure 09 5 Four Stacking Blocks With Axes Four stacking blocks, select and drag to see each of them. Coordinate axes are superimposed to show X3D/VRML directions.
Figure09_6SphereSensor Figure 09 6 Sphere Sensor Two shapes that rotate when the viewer drags them, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_6SphereSensorWithAxes Figure 09 6 Sphere Sensor With Axes Two shapes that rotate when the viewer drags them, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_7CylinderSensor Figure 09 7 Cylinder Sensor Two shapes that rotate about an axis when the viewer drags them, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_7CylinderSensorWithAxes Figure 09 7 Cylinder Sensor With Axes Two shapes that rotate about an axis when the viewer drags them, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_8ClickDragTouchSensorPlaneSensor Figure 09 8 Click Drag Touch Sensor Plane Sensor Two shapes that rotate about an axis when the viewer drags them, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_8ClickDragTouchSensorPlaneSensorWithAxes Figure 09 8 Click Drag Touch Sensor Plane Sensor With Axes A cube that spins when the cursor moves over it and translates when the cursor drags it, with coordinate axes superimposed to show X3D/VRML directions.
Figure09_9DeskLamp Figure 09 9 Desk Lamp A desk lamp with arm angles that can be adjusted using nested sensors.
Figure09_9DeskLampWithAxes Figure 09 9 Desk Lamp With Axes A desk lamp with arm angles that can be adjusted using nested sensors, with coordinate axes superimposed to show X3D/VRML directions.

Online at https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter09SensingViewer

Validate XHTML 1.1

Master source-code model archive is under subversion control at
https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Chapter09SensingViewer

The X3D Resources: Examples page and Savage Developers Guide provide more information about the production of this archive.

Table of Contents Previous Directory Summary Directory Viewpoint Slideshow Javadoc for translated java source Next Directory Summary X3D Resources