X3D Model Documentation: TumbleGroup.x3d

  1  <?xml version="1.0" encoding="UTF-8"?>
  2  <!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.3//EN" "https://www.web3d.org/specifications/x3d-3.3.dtd">
  3  <X3D profile='Immersive' version='3.3 xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-3.3.xsd'>
  4       <head>
  5            <meta name='titlecontent='TumbleGroup.x3d'/>
  6            <meta name='descriptioncontent='Tumble group: this file contains a Prototype declaration to manage a group of shapes, tumbling them in X, Y, and Z directions.'/>
  7            <meta name='creatorcontent='David R. Nadeau'/>
  8            <meta name='translatorcontent='Don Brutzman'/>
  9            <meta name='createdcontent='1 July 1998'/>
 10            <meta name='translatedcontent='2 February 2014'/>
 11            <meta name='modifiedcontent='20 October 2019'/>
 12            <meta name='referencecontent='Loader.x3d'/>
 13            <meta name='referencecontent='One.x3d'/>
 14            <meta name='referencecontent='Two.x3d'/>
 15            <meta name='referencecontent='Three.x3d'/>
 16            <meta name='referencecontent='Boxes.x3d'/>
 17            <meta name='referencecontent='originals/tumgrp.wrl'/>
 18            <meta name='referencecontent='http://www.siggraph.org/s98'/>
 19            <meta name='referencecontent='http://www.siggraph.org/s98/conference/courses/18.html'/>
 20            <meta name='referencecontent='http://www.sdsc.edu/~moreland/courses/Siggraph98/vrml97/slides/mt0465.htm'/>
 21            <meta name='referencecontent='http://www.sdsc.edu/~moreland/courses/Siggraph98/vrml97/slides/mt0469.htm'/>
 22            <meta name='referencecontent='http://www.sdsc.edu/~moreland/courses/Siggraph98/vrml97/vrml97.htm'/>
 23            <meta name='referencecontent='https://www.web3d.org/x3d/content/examples/X3dResources.html'/>
 24            <meta name='identifiercontent='https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Siggraph98Course/TumbleGroup.x3d'/>
 25            <meta name='generatorcontent='Vrml97ToX3dNist, http://ovrt.nist.gov/v2_x3d.html'/>
 26            <meta name='generatorcontent='X3D-Edit, https://savage.nps.edu/X3D-Edit'/>
 27            <meta name='licensecontent='../license.html'/>
 28       </head>
<!--

<!-- Event Graph ROUTE Table shows event connections. -->

<!-- to top Index for DEF nodes: XClock, XRot, XRotIt, YClock, YRot, YRotIt, ZClock, ZRot, ZRotIt

Index for ProtoDeclare definition: TumbleGroup
-->
 29       <Scene>
 30            <WorldInfo title='TumbleGroup.x3d'/>
 31            <ProtoDeclare name='TumbleGroup'>
 32                 <ProtoInterface>
 33                      <field name='xTumbleIntervaltype='SFTimevalue='3.0accessType='initializeOnly'/>
 34                      <field name='childrentype='MFNodeaccessType='initializeOnly'>
 35                           <!-- ProtoInstance needs to initialize children with a fieldValue -->
 36                      </field>
 37                      <field name='zTumbleIntervaltype='SFTimevalue='5.0accessType='initializeOnly'/>
 38                      <field name='translationtype='SFVec3fvalue='0.0 0.0 0.0accessType='initializeOnly'/>
 39                      <field name='yTumbleIntervaltype='SFTimevalue='1.0accessType='initializeOnly'/>
 40                 </ProtoInterface>
 41                 <ProtoBody>
 42 
                    <!-- ROUTE information for XRot node:  [from XRotIt.value_changed to set_rotation ] -->
                    <Transform DEF='XRot'>
 43 
                         <!-- ROUTE information for YRot node:  [from YRotIt.value_changed to set_rotation ] -->
                         <Transform DEF='YRot'>
 44 
                              <!-- ROUTE information for ZRot node:  [from ZRotIt.value_changed to set_rotation ] -->
                              <Transform DEF='ZRot'>
 45                                     <IS>
 46                                          <connect nodeField='translationprotoField='translation'/>
 47                                          <connect nodeField='childrenprotoField='children'/>
 48                                     </IS>
 49                                </Transform>
 50                           </Transform>
 51                      </Transform>
 52 
                    <!-- ROUTE information for XClock node:  [from fraction_changed to XRotIt.set_fraction ] -->
                    <TimeSensor DEF='XClockloop='truestartTime='1.0'>
 53                           <IS>
 54                                <connect nodeField='cycleIntervalprotoField='xTumbleInterval'/>
 55                           </IS>
 56                      </TimeSensor>
 57 
                    <!-- ROUTE information for YClock node:  [from fraction_changed to YRotIt.set_fraction ] -->
                    <TimeSensor DEF='YClockloop='truestartTime='1.0'>
 58                           <IS>
 59                                <connect nodeField='cycleIntervalprotoField='yTumbleInterval'/>
 60                           </IS>
 61                      </TimeSensor>
 62 
                    <!-- ROUTE information for ZClock node:  [from fraction_changed to ZRotIt.set_fraction ] -->
                    <TimeSensor DEF='ZClockloop='truestartTime='1.0'>
 63                           <IS>
 64                                <connect nodeField='cycleIntervalprotoField='zTumbleInterval'/>
 65                           </IS>
 66                      </TimeSensor>
 67 
                    <!-- ROUTE information for XRotIt node:  [from XClock.fraction_changed to set_fraction ] [from value_changed to XRot.set_rotation ] -->
                    <OrientationInterpolator DEF='XRotItkey='0.0 0.25 0.5 0.75 1.0keyValue='1.0 0.0 0.0 0.0 1.0 0.0 0.0 1.57 1.0 0.0 0.0 3.14 1.0 0.0 0.0 4.71 1.0 0.0 0.0 6.28'/>
 68 
                    <!-- ROUTE information for YRotIt node:  [from YClock.fraction_changed to set_fraction ] [from value_changed to YRot.set_rotation ] -->
                    <OrientationInterpolator DEF='YRotItkey='0.0 0.25 0.5 0.75 1.0keyValue='0.0 1.0 0.0 0.0 0.0 1.0 0.0 1.57 0.0 1.0 0.0 3.14 0.0 1.0 0.0 4.71 0.0 1.0 0.0 6.28'/>
 69 
                    <!-- ROUTE information for ZRotIt node:  [from ZClock.fraction_changed to set_fraction ] [from value_changed to ZRot.set_rotation ] -->
                    <OrientationInterpolator DEF='ZRotItkey='0.0 0.25 0.5 0.75 1.0keyValue='0.0 0.0 1.0 0.0 0.0 0.0 1.0 1.57 0.0 0.0 1.0 3.14 0.0 0.0 1.0 4.71 0.0 0.0 1.0 6.28'/>
 70                      < ROUTE  fromNode='XClock' fromField='fraction_changed' toNode='XRotIt' toField='set_fraction'/>
 71                      < ROUTE  fromNode='YClock' fromField='fraction_changed' toNode='YRotIt' toField='set_fraction'/>
 72                      < ROUTE  fromNode='ZClock' fromField='fraction_changed' toNode='ZRotIt' toField='set_fraction'/>
 73                      < ROUTE  fromNode='XRotIt' fromField='value_changed' toNode='XRot' toField='set_rotation'/>
 74                      < ROUTE  fromNode='YRotIt' fromField='value_changed' toNode='YRot' toField='set_rotation'/>
 75                      < ROUTE  fromNode='ZRotIt' fromField='value_changed' toNode='ZRot' toField='set_rotation'/>
 76                 </ProtoBody>
 77            </ProtoDeclare>
 78            <!-- Display scene instructions for viewing an example scene with a corresponding prototype instance -->
 79            <Background skyColor='0 0.333333 0.66667'/>
 80            <Anchor description='select text to view parent scene'   url=' "Loader.x3d" "https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Siggraph98Course/Loader.x3d" "Loader.wrl" "https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Siggraph98Course/Loader.wrl" '>
 81                 <Shape>
 82                      <Text string='"The TumbleGroup.x3d scene holds" "a prototype declaration" "" "Select this text to view example usage" "in Loader.x3d scene"'>
 83                           <FontStyle justify='"MIDDLE" "MIDDLE"style='BOLD'/>
 84                      </Text>
 85                      <Appearance>
 86                           <Material diffuseColor='1 0.9 0.4'/>
 87                      </Appearance>
 88                 </Shape>
 89                 <!-- Invisible box behind text makes selection easier -->
 90                 <Shape>
 91                      <Box size='12 5 0.1'/>
 92                      <Appearance>
 93                           <Material transparency='1'/>
 94                      </Appearance>
 95                 </Shape>
 96            </Anchor>
 97       </Scene>
 98  </X3D>
<!--

<!-- Event Graph ROUTE Table shows event connections. -->

<!-- to top Index for DEF nodes: XClock, XRot, XRotIt, YClock, YRot, YRotIt, ZClock, ZRot, ZRotIt

Index for ProtoDeclare definition: TumbleGroup
-->
X3D Tooltips element index: Anchor, Appearance, Background, Box, connect, field, FontStyle, head, IS, Material, meta, OrientationInterpolator, ProtoBody, ProtoDeclare, ProtoInterface, ROUTE, Scene, Shape, Text, TimeSensor, Transform, WorldInfo, X3D, accessType and type, XML data types, field types

Event Graph ROUTE Table entries with 6 ROUTE connections total, showing X3D event-model relationships for this scene.

Each row shows an event cascade that may occur during a single timestamp interval between frame renderings, as part of the X3D execution model.

XClock
TimeSensor
fraction_changed
SFFloat

ROUTE
event to
(1)
XRotIt
OrientationInterpolator
set_fraction
SFFloat
then
 
 
 
XRotIt
OrientationInterpolator
value_changed
SFRotation

ROUTE
event to
(2)
XRot
Transform
set_rotation
SFRotation

YClock
TimeSensor
fraction_changed
SFFloat

ROUTE
event to
(1)
YRotIt
OrientationInterpolator
set_fraction
SFFloat
then
 
 
 
YRotIt
OrientationInterpolator
value_changed
SFRotation

ROUTE
event to
(2)
YRot
Transform
set_rotation
SFRotation

ZClock
TimeSensor
fraction_changed
SFFloat

ROUTE
event to
(1)
ZRotIt
OrientationInterpolator
set_fraction
SFFloat
then
 
 
 
ZRotIt
OrientationInterpolator
value_changed
SFRotation

ROUTE
event to
(2)
ZRot
Transform
set_rotation
SFRotation


Anchor
description='select text to view parent scene' 
User-interaction hint for this node. 

-->
<!-- Online at
https://www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Siggraph98Course/TumbleGroupIndex.html -->
<!-- Version control at
https://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examples/Vrml2Sourcebook/Siggraph98Course/TumbleGroup.x3d -->

<!-- Color legend: X3D terminology <X3dNode DEF='idName' field='value'/> matches XML terminology <XmlElement DEF='idName' attribute='value'/>
(Light-blue background: event-based behavior node or statement) (Grey background inside box: inserted documentation) (Magenta background: X3D Extensibility)
    <ProtoDeclare name='ProtoName'> <field name='fieldName'/> </ProtoDeclare> -->

to top <!-- For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources, and X3D Scene Authoring Hints. -->