| 1 |
<?xml version="1.0" encoding="UTF-8"?>
|
| 2 |
<!DOCTYPE X3D PUBLIC "ISO//Web3D//DTD X3D 3.0//EN" "https://www.web3d.org/specifications/x3d-3.0.dtd">
|
| 3 | <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'> |
| 4 | <head> |
| 5 | <meta name='title' content=' ViewPositionOrientationExample.x3d '/> |
| 6 | <meta name='creator' content='Leonard Daly and Don Brutzman'/> |
| 7 | <meta name='translator' content='Don Brutzman'/> |
| 8 | <meta name='created' content='1 November 2000'/> |
| 9 | <meta name='modified' content='28 January 2024'/> |
| 10 | <meta name='description' content='As user navigates, display local position and orientation in the console output window. Various other output formats also available.'/> |
| 11 | <meta name='reference' content=' ViewPositionOrientationPrototype.x3d '/> |
| 12 | <meta name='reference' content=' https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter14Prototypes/WhereAmIExample.x3d '/> |
| 13 | <meta name='reference' content=' https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter14Prototypes/WhereAmIPrototype.x3d '/> |
| 14 | <meta name='reference' content='http://www.realism.com/Web3D/Examples#WhereAmI'/> |
| 15 | <meta name='reference' content='http://www.realism.com/vrml/Example/WhereAmI/WhereAmI_Proto.wrl'/> |
| 16 | <meta name='identifier' content=' https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/ViewPositionOrientationExample.x3d '/> |
| 17 | <meta name='generator' content='X3D-Edit 3.3, https://www.web3d.org/x3d/tools/X3D-Edit'/> |
| 18 | <meta name='license' content='../../license.html'/> |
| 19 | </head> |
| 20 | <Scene> |
| 21 | <!-- Copy the ExternProtoDeclare and ProtoInstance for ViewPositionOrientation at the top of your scene graph to add this functionality into other worlds. --> |
| 22 | <WorldInfo title='ViewPositionOrientationExample.x3d'/> |
| 23 | <ExternProtoDeclare name='ViewPositionOrientation' appinfo='ViewPositionOrientation provides provides console output of local position and orientation as user navigates' url=' "ViewPositionOrientationPrototype.x3d#ViewPositionOrientation" "../../../Savage/Tools/Authoring/ViewPositionOrientationPrototype.x3d#ViewPositionOrientation" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/ViewPositionOrientationPrototype.x3d#ViewPositionOrientation" "ViewPositionOrientationPrototype.wrl#ViewPositionOrientation" "../../../Savage/Tools/Authoring/ViewPositionOrientationPrototype.wrl#ViewPositionOrientation" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/ViewPositionOrientationPrototype.wrl#ViewPositionOrientation" '> |
| 24 |
<field name='enabled' type='SFBool' accessType='inputOutput'
appinfo='Whether or not ViewPositionOrientation sends output to console'/> |
| 25 |
<field name='traceEnabled' type='SFBool' accessType='initializeOnly'
appinfo='Output internal trace messages for debugging this node, intended for developer use only'/> |
| 26 |
<field name='set_traceEnabled' type='SFBool' accessType='inputOnly'
appinfo='Ability to turn output tracing on/off at runtime'/> |
| 27 |
<field name='position_changed' type='SFVec3f' accessType='outputOnly'
appinfo='Output local position'/> |
| 28 |
<field name='orientation_changed' type='SFRotation' accessType='outputOnly'
appinfo='Output local orientation'/> |
| 29 |
<field name='outputViewpointString' type='MFString' accessType='outputOnly'
appinfo='MFString value of new Viewpoint, suitable for use in string field of a Text node'/> |
| 30 | </ExternProtoDeclare> |
| 31 | <ProtoInstance name='ViewPositionOrientation' DEF='ConsoleOutputViewPositionOrientation'> |
| 32 | <fieldValue name='enabled' value='true'/> |
| 33 | </ProtoInstance> |
| 34 | <!-- The rest of this example scene follows. --> |
| 35 | <Viewpoint description='ViewPositionOrientation example' orientation='-0.6 0.8 0 0.8961' position='20 15 20'/> |
| 36 | <Billboard> |
| 37 | <Transform translation='0 4 2'> |
| 38 | <Shape> |
| 39 | <Text string='"Open console output window and" "navigate to see changing values for" "Viewpoint position and orientation"'> |
| 40 | <FontStyle justify='"MIDDLE" "MIDDLE"'/> |
| 41 | </Text> |
| 42 | <Appearance> |
| 43 | <Material diffuseColor='0.4 0.8 0.6' shininess='0.8'/> |
| 44 | </Appearance> |
| 45 | </Shape> |
| 46 | </Transform> |
| 47 | <Transform translation='0 3.5 1.8'> |
| 48 | <Shape> |
| 49 | <Box size='14 4 0.1'/> |
| 50 | <Appearance> |
| 51 | <Material diffuseColor='1 1 1'/> |
| 52 | </Appearance> |
| 53 | </Shape> |
| 54 | </Transform> |
| 55 | </Billboard> |
| 56 | <Inline url=' "../../../Savage/Tools/Authoring/GridXZ_20x20Fixed.x3d" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/GridXZ_20x20Fixed.x3d" "../../../Savage/Tools/Authoring/GridXZ_20x20Fixed.wrl" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/GridXZ_20x20Fixed.wrl" '/> |
| 57 | <Transform scale='11 11 11'> |
| 58 | <Inline url=' "../../../Savage/Tools/Authoring/CoordinateAxes.x3d" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/CoordinateAxes.x3d" "../../../Savage/Tools/Authoring/CoordinateAxes.wrl" "https://www.web3d.org/x3d/content/examples/Savage/Tools/Authoring/CoordinateAxes.wrl" '/> |
| 59 | </Transform> |
| 60 | </Scene> |
| 61 | </X3D> |
Event Graph ROUTE Table with 0 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.
|
ConsoleOutputViewPositionOrientation
ProtoInstance ViewPositionOrientation |
No direct ROUTE connection found for events to/from this node. This ProtoInstance contains SFNode/MFNode fieldValue declarations with direct access to other nodes, and thus has potential to produce run-time animation. |
<!--
Color-coding 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)
<ProtoInstance name='ProtoName'>
<field
name='fieldName'/> </ProtoInstance>
-->
<!--
For additional help information about X3D scenes, please see X3D Tooltips, X3D Resources, and X3D Scene Authoring Hints.
-->