<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.0//EN" "http://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 =' http://www.web3d.org/specifications/x3d-3.0.xsd '>
<head>
<meta name='titlecontent='HiddenViewpointPrototype.x3d'/>
<meta name='descriptioncontent="Prototype to produce hidden viewpoints that becomes active (binds) upon pointer selection to reveal an interesting view, with an optionally label. Especially cool is deselecting: the user returns to wherever the previous viewpoint was. Numerous HiddenViewpoints can be used without cluttering up the browser's viewpoint description list."/>
<meta name='creatorcontent='Don Brutzman'/>
<meta name='createdcontent='1 May 2001'/>
<meta name='modifiedcontent='8 April 2012'/>
<meta name='Imagecontent='HiddenViewpointTest-WaypointInterpolator.png'/>
<meta name='Imagecontent=' https://savage.nps.edu/Savage/Tools/Animation/HiddenViewpointTest-WaypointInterpolator.png '/>
<meta name='referencecontent='WaypointInterpolatorExample.x3d'/>
<meta name='identifiercontent=' https://savage.nps.edu/Savage/Tools/Animation/HiddenViewpointPrototype.x3d '/>
<meta name='generatorcontent='X3D-Edit 3.2, https://savage.nps.edu/X3D-Edit'/>
<meta name='licensecontent=' ../../license.html'/>
</head>
<!-- -->
<Scene>
<ProtoDeclare name='HiddenViewpointappinfo='Hidden viewpoint becomes active (binds) upon pointer selection to reveal an interesting view with an optionally label'>
<ProtoInterface>
<field name='positiontype='SFVec3fvalue='0 0 0accessType='inputOutput'/>
<field name='rotationtype='SFRotationvalue='0 1 0 0accessType='inputOutput'/>
<field name='sensorRadiustype='SFFloatvalue='1accessType='initializeOnly'/>
<field name='activatetype='SFBoolaccessType='inputOnly'/>
<field name='labeltype='MFStringaccessType='inputOutput'/>
<field name='labelOffsettype='SFVec3fvalue='0 -1 0accessType='inputOutput'/>
<field name='labelFontSizetype='SFFloatvalue='1accessType='initializeOnly'/>
<field name='labelColortype='SFColorvalue='0.8 0.8 0.8accessType='inputOutput'/>
</ProtoInterface>
<ProtoBody>
<!-- Touchable Sphere to bind a labeled local viewpoint while clicked... -->
<Transform DEF='LocationTransform'>
<IS>
<connect nodeField='translationprotoField='position'/>
<connect nodeField='centerprotoField='position'/>
<connect nodeField='rotationprotoField='rotation'/>
</IS>
<Shape>
<Sphere DEF='TransparentSphere'>
<IS>
<connect nodeField='radiusprotoField='sensorRadius'/>
</IS>
</Sphere>
<Appearance>
<Material transparency='1'/>
</Appearance>
</Shape>
<!-- ROUTE information for InvisibleTouchSensorNoDescription node:  [from isActive to HiddenViewNoDescription.set_bind ] -->
<TouchSensor DEF='InvisibleTouchSensorNoDescription'/>
<Transform DEF='HiddenViewpointTransform'>
<IS>
<connect nodeField='translationprotoField='labelOffset'/>
</IS>
<!-- No description is provided for HiddenViewpoint so that it does NOT appear in the viewpoint list. -->
<!-- ROUTE information for HiddenViewNoDescription node:  [from InvisibleTouchSensorNoDescription.isActive to set_bind ] -->
<Viewpoint DEF='HiddenViewNoDescriptionposition='0 0 4'>
<IS>
<connect nodeField='set_bindprotoField='activate'/>
</IS>
</Viewpoint>
</Transform>
<LOD DEF='LabelTextLODrange='8'>
<Group>
<Transform DEF='LabelTransform'>
<IS>
<connect nodeField='translationprotoField='labelOffset'/>
</IS>
<Shape>
<Text DEF='LabelText'>
<IS>
<connect nodeField='stringprotoField='label'/>
</IS>
<FontStyle DEF='LabelFontStylejustify='"MIDDLE" "MIDDLE"'>
<IS>
<connect nodeField='sizeprotoField='labelFontSize'/>
</IS>
</FontStyle>
</Text>
<Appearance>
<Material DEF='TextMaterialdiffuseColor='0 0 0'>
<IS>
<connect nodeField='emissiveColorprotoField='labelColor'/>
</IS>
</Material>
<!-- emissiveColor used for TextMaterial so that label is visible regardless. Thus diffuseColor set to (0 0 0) so that default value (0.8 0.8 0.8) doesn't wash out emissive. -->
</Appearance>
</Shape>
</Transform>
</Group>
<WorldInfo info='"null node"'/>
</LOD>
</Transform>
<ROUTE fromNode='InvisibleTouchSensorNoDescriptionfromField='isActivetoNode='HiddenViewNoDescriptiontoField='set_bind'/>
</ProtoBody>
</ProtoDeclare>
<!-- ====================================== -->
<Viewpoint description='HiddenViewpoint launchposition='0 0 12'/>
<Anchor description='WaypointInterpolator exampleparameter='"target=_blank"'
  url=' "WaypointInterpolatorExample.x3d" "https://savage.nps.edu/Savage/Tools/Animation/WaypointInterpolatorExample.x3d" "WaypointInterpolatorExample.wrl" "https://savage.nps.edu/Savage/Tools/Animation/WaypointInterpolatorExample.wrl" '>
<Shape>
<Text string='"Click on this text to see" "HiddenViewpoint example use" "" "then click beneath origin axes" "in WaypointInterpolator" "example scene"'>
<FontStyle justify='"MIDDLE" "MIDDLE"'/>
</Text>
<Appearance>
<Material diffuseColor='1 1 0.2'/>
</Appearance>
</Shape>
</Anchor>
</Scene>
</X3D>
<!--

Index for ProtoDeclare definition : HiddenViewpoint

Index for DEF nodes : HiddenViewNoDescription, HiddenViewpointTransform, InvisibleTouchSensorNoDescription, LabelFontStyle, LabelText, LabelTextLOD, LabelTransform, LocationTransform, TextMaterial, TransparentSphere

Index for Viewpoint images : Viewpoint_1, HiddenViewNoDescription
-->

<!-- 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> -->

<!-- Additional help information about X3D scenes: X3D Resources, X3D Scene Authoring Hints and X3D Tooltips -->