<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.3//EN" "https://www.web3d.org/specifications/x3d-3.3.dtd">
<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 '>
<head>
<meta name='titlecontent='CircleFishPrototype.x3d'/>
<meta name='descriptioncontent='This is a prototype for a CircleFish, which is also used by CircleFishLod. Default fish size: length is 1 m (Y-axis), max Height is 1 m (Z-axis), max Width is 10 cm (X-axis).'/>
<meta name='creatorcontent='Ildeniz Duman'/>
<meta name='translatorcontent='Scott Tufts'/>
<meta name='createdcontent='1 May 1998'/>
<meta name='translatedcontent='11 December 2001'/>
<meta name='modifiedcontent='20 October 2019'/>
<meta name='identifiercontent=' https://X3dGraphics.com/examples/X3dForWebAuthors/KelpForestExhibit/CircleFishPrototype.x3d '/>
<meta name='generatorcontent='X3D-Edit 3.3, https://savage.nps.edu/X3D-Edit'/>
<meta name='licensecontent=' ../license.html'/>
</head>
<!-- -->
<Scene>
<WorldInfo title='CircleFishPrototype.x3d'/>
<ProtoDeclare name='CircleFishappinfo='Simple model of a fish swimming in a circle'>
<ProtoInterface>
<field name='skinTextureUrltype='MFStringaccessType='inputOutput'/>
<field name='fishScaletype='SFVec3fvalue='1 1 1accessType='inputOutput'/>
<field name='fishColortype='SFColorvalue='0.5 0.5 0.5accessType='inputOutput'/>
<field name='finColortype='SFColorvalue='0.5 0.5 0.5accessType='inputOutput'/>
<field name='positionKeytype='MFFloatvalue='0.0 0.125 0.25 0.375 0.5 0.625 0.750 0.875 1accessType='inputOutput'/>
<field name='positionKeyValuetype='MFVec3fvalue='1.5 2 0 1.5 0 -1.0 0 -1 -1.0 -1.5 0 -1.0 -1.5 2 0 -1.5 0 1.0 0 -2 1.0 1.5 0 1.0 1.5 2 0accessType='inputOutput'/>
<field name='orientationKeytype='MFFloatvalue='0.0 0.25 0.5 0.750 1accessType='inputOutput'/>
<field name='orientationKeyValuetype='MFRotationvalue='0 1 0 0 0 1 0 -1.57 0 1 0 -3.14 0 1 0 -4.71 0 1 0 -6.28accessType='inputOutput'/>
<field name='orbitTimetype='SFTimevalue='90accessType='inputOutput'/>
</ProtoInterface>
<ProtoBody>
<!-- ROUTE information for Way node:  [from CirclefishPath.value_changed to set_translation ] [from CircleFishAngle.value_changed to set_rotation ] -->
<Transform DEF='Way'>
<Transform rotation='1 0 0 1.395'>
<Transform DEF='FishTransform'>
<IS>
<connect nodeField='scaleprotoField='fishScale'/>
</IS>
<Shape>
<Appearance>
<Material DEF='FishColor'>
<IS>
<connect nodeField='diffuseColorprotoField='fishColor'/>
</IS>
</Material>
<ImageTexture DEF='FishTexture'>
<IS>
<connect nodeField='urlprotoField='skinTextureUrl'/>
</IS>
</ImageTexture>
</Appearance>
<!-- ROUTE information for FishBodyExtrusion node:  [from Waggler.value_changed to set_spine ] -->
<Extrusion DEF='FishBodyExtrusioncreaseAngle='0.57crossSection='-0.1 1.0 0.1 1 0.5 0.5 0.5 -0.5 0.1 -1 -0.1 -1 -0.5 -0.5 -0.5 0.5 -0.1 1scale='0.03 0.03 0.05 0.3 0.05 0.45 0.1 0.5 0.05 0.45 0.05 0.2 0.03 0.4spine='0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0 0.2 0 0 0 0'/>
</Shape>
<Shape>
<Appearance DEF='FinSkin'>
<Material DEF='FinColortransparency='0.2'>
<IS>
<connect nodeField='diffuseColorprotoField='finColor'/>
</IS>
</Material>
</Appearance>
</Shape>
<Transform translation='0.015 0.8 -0.2'>
<Shape DEF='Eye'>
<Appearance>
<Material diffuseColor='0.5 0.5 0.5shininess='1specularColor='0.3 0.3 0.3'/>
</Appearance>
<Sphere radius='0.03'/>
</Shape>
</Transform>
<Transform translation='-0.015 0.8 -0.2'>
<Shape USE='Eye'/>
</Transform>
<Transform scale='1 1 0.7translation='0 0.98 0'>
<Shape USE='Eye'/>
</Transform>
<!-- ROUTE information for LeftPectoral node:  [from LeftPectoralRotation.value_changed to set_rotation ] -->
<Transform DEF='LeftPectoraltranslation='0.04 0.4 0.3'>
<Shape>
<Appearance USE='FinSkin'/>
<IndexedFaceSet solid='falsecoordIndex='0 1 2 -1'>
<Coordinate point='0 0 0 0 0.2 0 0.2 0.1 0'/>
</IndexedFaceSet>
</Shape>
</Transform>
<!-- ROUTE information for RightPectoral node:  [from RightPectoralRotation.value_changed to set_rotation ] -->
<Transform DEF='RightPectoraltranslation='-0.04 0.4 0.3'>
<Shape>
<Appearance USE='FinSkin'/>
<IndexedFaceSet solid='falsecoordIndex='0 1 2 -1'>
<Coordinate point='0 0 0 0 0.2 0 -0.2 0.1 0'/>
</IndexedFaceSet>
</Shape>
</Transform>
</Transform>
</Transform>
<Group DEF='AnimationGroup'>
<!-- ROUTE information for Timer node:  [from fraction_changed to Waggler.set_fraction ] [from fraction_changed to LeftPectoralRotation.set_fraction ] [from fraction_changed to RightPectoralRotation.set_fraction ] -->
<TimeSensor DEF='TimercycleInterval='5loop='true'/>
<!-- ROUTE information for Waggler node:  [from Timer.fraction_changed to set_fraction ] [from value_changed to FishBodyExtrusion.set_spine ] -->
<CoordinateInterpolator DEF='Wagglerkey='0.0 0.15 0.28 0.4 0.55 0.7 0.85 1keyValue='0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0 0.2 0 0 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0.05 0.3 0 0.1 0.2 0 0.2 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0 0.2 0 0 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 -0.05 0.3 0 -0.1 0.2 0 -0.2 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0.0 0.2 0 0 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0.05 0.3 0 0.1 0.2 0 0.2 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0 0.2 0 0 0 0 0 1 0 0 0.8 0 0 0.6 0 0 0.5 0 0 0.3 0 0 0.2 0 0 0 0'/>
<ROUTE fromNode='TimerfromField='fraction_changedtoNode='WagglertoField='set_fraction'/>
<ROUTE fromNode='WagglerfromField='value_changedtoNode='FishBodyExtrusiontoField='set_spine'/>
<!-- ROUTE information for LeftPectoralRotation node:  [from Timer.fraction_changed to set_fraction ] [from value_changed to LeftPectoral.set_rotation ] -->
<OrientationInterpolator DEF='LeftPectoralRotationkey='0 0.3 0.7 1keyValue='0 1 0 -.349 0 1 0 0 0 1 0 0 0 1 0 -.349'/>
<ROUTE fromNode='TimerfromField='fraction_changedtoNode='LeftPectoralRotationtoField='set_fraction'/>
<ROUTE fromNode='LeftPectoralRotationfromField='value_changedtoNode='LeftPectoraltoField='set_rotation'/>
<!-- ROUTE information for RightPectoralRotation node:  [from Timer.fraction_changed to set_fraction ] [from value_changed to RightPectoral.set_rotation ] -->
<OrientationInterpolator DEF='RightPectoralRotationkey='0 0.3 0.7 1keyValue='0 1 0 .349 0 1 0 0 0 1 0 0 0 1 0 .349'/>
<ROUTE fromNode='TimerfromField='fraction_changedtoNode='RightPectoralRotationtoField='set_fraction'/>
<ROUTE fromNode='RightPectoralRotationfromField='value_changedtoNode='RightPectoraltoField='set_rotation'/>
<!-- ROUTE information for OrbitClock node:  [from fraction_changed to CirclefishPath.set_fraction ] [from fraction_changed to CircleFishAngle.set_fraction ] -->
<TimeSensor DEF='OrbitClockloop='true'>
<IS>
<connect nodeField='cycleIntervalprotoField='orbitTime'/>
</IS>
</TimeSensor>
<!-- ROUTE information for CirclefishPath node:  [from OrbitClock.fraction_changed to set_fraction ] [from value_changed to Way.set_translation ] -->
<PositionInterpolator DEF='CirclefishPath'>
<IS>
<connect nodeField='keyprotoField='positionKey'/>
<connect nodeField='keyValueprotoField='positionKeyValue'/>
</IS>
</PositionInterpolator>
<!-- ROUTE information for CircleFishAngle node:  [from OrbitClock.fraction_changed to set_fraction ] [from value_changed to Way.set_rotation ] -->
<OrientationInterpolator DEF='CircleFishAngle'>
<IS>
<connect nodeField='keyprotoField='orientationKey'/>
<connect nodeField='keyValueprotoField='orientationKeyValue'/>
</IS>
</OrientationInterpolator>
<ROUTE fromNode='OrbitClockfromField='fraction_changedtoNode='CirclefishPathtoField='set_fraction'/>
<ROUTE fromNode='OrbitClockfromField='fraction_changedtoNode='CircleFishAngletoField='set_fraction'/>
<ROUTE fromNode='CirclefishPathfromField='value_changedtoNode='WaytoField='set_translation'/>
<ROUTE fromNode='CircleFishAnglefromField='value_changedtoNode='WaytoField='set_rotation'/>
</Group>
</Transform>
</ProtoBody>
</ProtoDeclare>
<!-- ==================== -->
<ProtoInstance name='CircleFish'/>
</Scene>
</X3D>
<!--

Index for ProtoDeclare definition : CircleFish

Index for DEF nodes : AnimationGroup, CircleFishAngle, CirclefishPath, Eye, FinColor, FinSkin, FishBodyExtrusion, FishColor, FishTexture, FishTransform, LeftPectoral, LeftPectoralRotation, OrbitClock, RightPectoral, RightPectoralRotation, Timer, Waggler, Way
-->

<!-- Color key: <X3dNode DEF='idName' field='value'/> matches <XmlElement DEF='idName' attribute='value'/>
(Light blue background: behavior node) (Grey background: inserted documentation) (Magenta background: X3D Extensibility)
    <Prototype name='ProtoName'> <field name='fieldName'/> </Prototype> -->

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