<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.0//EN" "https://www.web3d.org/specifications/x3d-3.0.dtd">
<X3D profile='Immersive' version='3.0' xmlns:xsd='http://www.w3.org/2001/XMLSchema-instance' xsd:noNamespaceSchemaLocation='https://www.web3d.org/specifications/x3d-3.0.xsd'>
  <head>
    <meta content='Swing.x3d' name='title'/>
    <meta content='This file draw the swing in the playground with animation.' name='description'/>
    <meta content='Kok Keng Ng' name='creator'/>
    <meta content='20 September 2002' name='created'/>
    <meta content='20 October 2019' name='modified'/>
    <meta content='https://www.web3d.org/x3d/content/examples/Savage/Buildings/PlayGround/Swing.x3d' name='identifier'/>
    <meta content='X3D-Edit 3.2, https://www.web3d.org/x3d/tools/X3D-Edit' name='generator'/>
    <meta content='../../license.html' name='license'/>
  </head>
  <Scene>
    <WorldInfo title='Swing.x3d'/>
    <Transform>
      <Group>
        <Transform center='0 1 0' rotation='1 0 0 0.5' translation='-2 0 0'>
          <Shape DEF='SWINGVBarGP'>
            <Cylinder radius='0.1'/>
            <Appearance>
              <Material diffuseColor='0.1 0.7 0.3' emissiveColor='0.1 0.7 0.3' shininess='0.7' specularColor='0.5 0.5 0.5'/>
              <ImageTexture url='"wood.jpg" "https://www.web3d.org/x3d/content/examples/Savage/Buildings/PlayGround/wood.jpg"'/>
            </Appearance>
          </Shape>
        </Transform>
        <Transform center='0 1 0' rotation='1 0 0 -0.5' translation='-2 0 0'>
          <Shape USE='SWINGVBarGP'/>
        </Transform>
        <Transform center='0 1 0' rotation='1 0 0 0.5' translation='2 0 0'>
          <Shape USE='SWINGVBarGP'/>
        </Transform>
        <Transform center='0 1 0' rotation='1 0 0 -0.5' translation='2 0 0'>
          <Shape USE='SWINGVBarGP'/>
        </Transform>
        <Transform rotation='0 0 1 1.57' translation='0 1 0'>
          <Shape DEF='SWINGCBarSH'>
            <Cylinder height='4.2' radius='0.1'/>
            <Appearance>
              <Material/>
            </Appearance>
          </Shape>
        </Transform>
        <Transform translation='-1 0.85 0'>
          <Group DEF='LOOPGP'>
            <Transform rotation='0 0 1 1.57' scale='0.03 0.03 0.03'>
              <Shape>
                <Appearance>
                  <Material diffuseColor='1 1 1'/>
                </Appearance>
                <Extrusion beginCap='false' convex='false' creaseAngle='1.57' crossSection='1.00 0.00 0.92 -0.38 0.71 -0.71 0.38 -0.92 0.00 -1.00 -0.38 -0.92 -0.71 -0.71 -0.92 -0.38 -1.00 -0.00 -0.92 0.38 -0.71 0.71 -0.38 0.92 0.00 1.00 0.38 0.92 0.71 0.71 0.92 0.38 1.00 0.00' endCap='false' spine='2.00 0.0 0.00 1.85 0.0 0.77 1.41 0.0 1.41 0.77 0.0 1.85 0.00 0.0 2.00 -0.77 0.0 1.85 -1.41 0.0 1.41 -1.85 0.0 0.77 -2.00 0.0 0.00 -1.85 0.0 -0.77 -1.41 0.0 -1.41 -0.77 0.0 -1.85 0.00 0.0 -2.00 0.77 0.0 -1.85 1.41 0.0 -1.41 1.85 0.0 -0.77 2.00 0.0 0.00'/>
              </Shape>
            </Transform>
          </Group>
        </Transform>
        <Transform translation='-0.5 0.85 0'>
          <Group USE='LOOPGP'/>
        </Transform>
        <Transform translation='0.5 0.85 0'>
          <Group USE='LOOPGP'/>
        </Transform>
        <Transform translation='1 0.85 0'>
          <Group USE='LOOPGP'/>
        </Transform>
        <TouchSensor DEF='SWINGSensor'/>
        <Transform/>
      </Group>
      <Transform>
        <Group>
          <Transform>
            <Transform DEF='SWINGSEAT1TX' center='0 0.85 0' rotation='1 0 0 0.0001'>
              <Group DEF='SWINGSEAT1GP'>
                <Group>
                  <Transform scale='0.5 0.5 0.5' translation='-1 0.8 0'>
                    <Group DEF='ROPELeft'>
                      <Transform rotation='1 0 0 1.57' scale='0.05 0.05 0.05'>
                        <Shape DEF='SWINRING'>
                          <Appearance DEF='ROPEApp'>
                            <Material diffuseColor='1 1 1'/>
                          </Appearance>
                          <Extrusion beginCap='false' convex='false' creaseAngle='1.57' crossSection='1.00 0.00 0.92 -0.38 0.71 -0.71 0.38 -0.92 0.00 -1.00 -0.38 -0.92 -0.71 -0.71 -0.92 -0.38 -1.00 -0.00 -0.92 0.38 -0.71 0.71 -0.38 0.92 0.00 1.00 0.38 0.92 0.71 0.71 0.92 0.38 1.00 0.00' endCap='false' spine='2.00 0.0 0.00 1.85 0.0 0.77 1.41 0.0 1.41 0.77 0.0 1.85 0.00 0.0 2.00 -0.77 0.0 1.85 -1.41 0.0 1.41 -1.85 0.0 0.77 -2.00 0.0 0.00 -1.85 0.0 -0.77 -1.41 0.0 -1.41 -0.77 0.0 -1.85 0.00 0.0 -2.00 0.77 0.0 -1.85 1.41 0.0 -1.41 1.85 0.0 -0.77 2.00 0.0 0.00'/>
                        </Shape>
                      </Transform>
                      <Transform scale='0.05 0.05 0.05' translation='0 -1.475 0'>
                        <Shape>
                          <Appearance USE='ROPEApp'/>
                          <Cylinder height='55'/>
                        </Shape>
                      </Transform>
                    </Group>
                    <Transform translation='1 0 0'>
                      <Group USE='ROPELeft'/>
                    </Transform>
                    <Transform translation='0.5 -2.85 0'>
                      <Shape>
                        <Box size='1.15 0.08 0.3'/>
                        <Appearance>
                          <Material diffuseColor='0.95 0.1 0.1' emissiveColor='0.05 0.05 0.05'/>
                        </Appearance>
                      </Shape>
                    </Transform>
                    <TouchSensor DEF='SWINGSEAT1Sensor'/>
                    <TimeSensor DEF='SWINGSEAT1Timer' cycleInterval='40'/>
                    <OrientationInterpolator DEF='SWINGSEAT1Inter' key='0 0.025 0.075 0.125 0.175 0.225 0.275 0.325 0.375 0.425 0.475 0.525 0.575 0.625 0.675 0.725 0.775 0.825 0.875 0.925 0.975 1.0' keyValue='1 0 0 0 1 0 0 0.785 1 0 0 -1.2 1 0 0 1.2 1 0 0 -1.3 1 0 0 1.3 1 0 0 -1.35 1 0 0 1.35 1 0 0 -1.2 1 0 0 1.2 1 0 0 -1.25 1 0 0 0.785 1 0 0 -1.2 1 0 0 1.2 1 0 0 -1.3 1 0 0 1.3 1 0 0 -1.35 1 0 0 1.35 1 0 0 -1.2 1 0 0 1.2 1 0 0 -1.25 1 0 0 0'/>
                  </Transform>
                </Group>
              </Group>
            </Transform>
          </Transform>
          <Transform DEF='SWINGSEAT2TX' center='0 0.85 0'>
            <Group DEF='SWINGSEAT2GP'>
              <Group>
                <Transform scale='0.5 0.5 0.5' translation='-1 0.8 0'>
                  <Transform translation='3 0 0'>
                    <Group DEF='ROPELeft2'>
                      <Transform rotation='1 0 0 1.57' scale='0.05 0.05 0.05'>
                        <Shape USE='SWINRING'/>
                      </Transform>
                      <Transform scale='0.05 0.05 0.05' translation='0 -1.37 0'>
                        <Shape>
                          <Appearance USE='ROPEApp'/>
                          <Cylinder height='50'/>
                        </Shape>
                      </Transform>
                    </Group>
                    <Transform translation='1 0 0'>
                      <Group USE='ROPELeft2'/>
                    </Transform>
                    <Transform translation='0.5 -2.6 0'>
                      <Shape>
                        <Box size='1.15 0.08 0.3'/>
                        <Appearance>
                          <Material diffuseColor='0.1 0.1 0.95' emissiveColor='0.05 0.05 0.1'/>
                        </Appearance>
                      </Shape>
                    </Transform>
                    <TouchSensor DEF='SWINGSEAT2Sensor'/>
                    <TimeSensor DEF='SWINGSEAT2Timer' cycleInterval='35'/>
                    <OrientationInterpolator DEF='SWINGSEAT2Inter' key='0 0.025 0.075 0.125 0.175 0.225 0.275 0.325 0.375 0.425 0.475 0.525 0.575 0.625 0.675 0.725 0.775 0.825 0.875 0.925 0.975 1.0' keyValue='1 0 0 0 1 0 0 0.785 1 0 0 -1.25 1 0 0 1.3 1 0 0 -1.3 1 0 0 1.35 1 0 0 -1.35 1 0 0 1.25 1 0 0 -1.25 1 0 0 1.2 1 0 0 -1.2 1 0 0 0.785 1 0 0 -1.25 1 0 0 1.3 1 0 0 -1.3 1 0 0 1.35 1 0 0 -1.35 1 0 0 1.25 1 0 0 -1.25 1 0 0 1.2 1 0 0 -1.2 1 0 0 0'/>
                  </Transform>
                </Transform>
              </Group>
            </Group>
          </Transform>
        </Group>
      </Transform>
      <Transform/>
      <ROUTE fromField='touchTime' fromNode='SWINGSensor' toField='set_startTime' toNode='SWINGSEAT1Timer'/>
      <ROUTE fromField='touchTime' fromNode='SWINGSensor' toField='set_startTime' toNode='SWINGSEAT2Timer'/>
      <ROUTE fromField='touchTime' fromNode='SWINGSEAT1Sensor' toField='set_startTime' toNode='SWINGSEAT1Timer'/>
      <ROUTE fromField='fraction_changed' fromNode='SWINGSEAT1Timer' toField='set_fraction' toNode='SWINGSEAT1Inter'/>
      <ROUTE fromField='value_changed' fromNode='SWINGSEAT1Inter' toField='set_rotation' toNode='SWINGSEAT1TX'/>
      <ROUTE fromField='touchTime' fromNode='SWINGSEAT2Sensor' toField='set_startTime' toNode='SWINGSEAT2Timer'/>
      <ROUTE fromField='fraction_changed' fromNode='SWINGSEAT2Timer' toField='set_fraction' toNode='SWINGSEAT2Inter'/>
      <ROUTE fromField='value_changed' fromNode='SWINGSEAT2Inter' toField='set_rotation' toNode='SWINGSEAT2TX'/>
    </Transform>
    <Transform>
      <Group>
        <Transform/>
        <Transform/>
      </Group>
    </Transform>
    <Transform>
      <Group/>
    </Transform>
    <Viewpoint description='Swing' position='0 0.65 6.5'/>
  </Scene>
</X3D>