{ "X3D": {
"encoding":"UTF-8",
"@profile":"Immersive",
"@version":"3.3",
"@xsd:noNamespaceSchemaLocation":"https://www.web3d.org/specifications/x3d-3.3.xsd",
"JSON schema":"https://www.web3d.org/specifications/x3d-4.0-JSONSchema.autogenerated.json",
"head": {
"meta": [
{
"@name":"title",
"@content":"CameraExamples.x3d"
},
{
"@name":"description",
"@content":"Camera, CameraShot and CameraMove examples that demonstrate storyboard capabilities and precise camera operation. This is a developmental effort for potential X3D Specification improvement."
},
{
"@name":"documentation",
"@content":"Two demos are found in the scene, click the \"red text\" on left or right to start. (a) SimpleShotsTest shows Zoom in/out, Pan left/right, Boom up/down, Tilt left/right, with each is defined by a CameraShot collecting a series of CameraMovements. (b) AimPointTest gradually slews the camera view to look at the sliding cube, then follows it around before returning to original viewpoint."
},
{
"@name":"creator",
"@content":"Don Brutzman and Jeff Weekley"
},
{
"@name":"created",
"@content":"18 June 2009"
},
{
"@name":"modified",
"@content":"20 January 2020"
},
{
"@name":"TODO",
"@content":"Schematron rules, backed up by initialize() checks"
},
{
"@name":"reference",
"@content":"BeyondViewpointCameraNodesWeb3D2009.pdf"
},
{
"@name":"MovingImage",
"@content":"CameraExamplesDemo.mp4"
},
{
"@name":"reference",
"@content":"https://www.web3d.org/x3d/specifications/ISO-IEC-FDIS-19775-1.2-X3D-AbstractSpecification/Part01/components/navigation.html"
},
{
"@name":"subject",
"@content":"Camera nodes for Viewpoint navigation control"
},
{
"@name":"reference",
"@content":"CameraPrototypes.x3d"
},
{
"@name":"reference",
"@content":"CameraExamplesConsoleLog.txt"
},
{
"@name":"reference",
"@content":"http://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examples/Basic/development/CameraExamples.avi"
},
{
"@name":"reference",
"@content":"https://www.web3d.org/x3d/content/examples/Basic/UniversalMediaMaterials/gridBack.x3d"
},
{
"@name":"identifier",
"@content":"https://www.web3d.org/x3d/content/examples/Basic/development/CameraExamples.x3d"
},
{
"@name":"reference",
"@content":"http://sourceforge.net/p/x3d/code/HEAD/tree/www.web3d.org/x3d/content/examples/Basic/development/CameraExamples.x3d"
},
{
"@name":"generator",
"@content":"X3D-Edit 3.3, https://savage.nps.edu/X3D-Edit"
},
{
"@name":"license",
"@content":"../license.html"
},
{
"@name":"translated",
"@content":"14 October 2023"
},
{
"@name":"generator",
"@content":"X3dToJson.xslt, https://www.web3d.org/x3d/stylesheets/X3dToJson.html"
},
{
"@name":"reference",
"@content":"X3D JSON encoding: https://www.web3d.org/wiki/index.php/X3D_JSON_Encoding"
}
]
},
"Scene": {
"-children":[
{
"#comment":"=============== Camera =============="
},
{ "WorldInfo":
{
"@title":"CameraExamples.x3d"
}
},
{ "ExternProtoDeclare":
{
"@name":"Camera",
"@appinfo":"Camera node provides direct control of scene view to enable cinematic camera animation shot by shot and move by move along with still digital-photography settings for offline rendering of camera images",
"@url":["CameraPrototypes.x3d#Camera","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.x3d#Camera","CameraPrototypes.wrl#Camera","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.wrl#Camera"],
"field": [
{
"@name":"description",
"@accessType":"inputOutput",
"@appinfo":"Text description to be displayed for this Camera",
"@type":"SFString"
},
{
"@name":"position",
"@accessType":"inputOutput",
"@appinfo":"Camera position in local transformation frame, which is default prior to first CameraShot initialPosition getting activated",
"@type":"SFVec3f"
},
{
"@name":"orientation",
"@accessType":"inputOutput",
"@appinfo":"Camera rotation in local transformation frame, which is default prior to first CameraShot initialPosition getting activated",
"@type":"SFRotation"
},
{
"@name":"fieldOfView",
"@accessType":"inputOutput",
"@appinfo":"pi/4",
"@type":"SFFloat"
},
{
"@name":"set_fraction",
"@accessType":"inputOnly",
"@appinfo":"input fraction drives interpolators",
"@type":"SFFloat"
},
{
"@name":"set_bind",
"@accessType":"inputOnly",
"@appinfo":"input event binds or unbinds this Camera",
"@type":"SFBool"
},
{
"@name":"bindTime",
"@accessType":"outputOnly",
"@appinfo":"output event indicates when this Camera is bound",
"@type":"SFTime"
},
{
"@name":"isBound",
"@accessType":"outputOnly",
"@appinfo":"output event indicates whether this Camera is bound or unbound",
"@type":"SFBool"
},
{
"@name":"nearClipPlane",
"@accessType":"inputOutput",
"@appinfo":"Vector distance to near clipping plane corresponds to NavigationInfo.avatarSize[0]",
"@type":"SFFloat"
},
{
"@name":"farClipPlane",
"@accessType":"inputOutput",
"@appinfo":"Vector distance to far clipping plane corresponds to NavigationInfo.visibilityLimit",
"@type":"SFFloat"
},
{
"@name":"shots",
"@accessType":"inputOutput",
"@appinfo":"Array of CameraShot nodes which in turn contain CameraMovement nodes",
"@type":"MFNode"
},
{
"@name":"headlight",
"@accessType":"inputOutput",
"@appinfo":"Whether camera headlight is on or off",
"@type":"SFBool"
},
{
"@name":"headlightColor",
"@accessType":"inputOutput",
"@appinfo":"Camera headlight color",
"@type":"SFColor"
},
{
"@name":"headlightIntensity",
"@accessType":"inputOutput",
"@appinfo":"Camera headlight intensity",
"@type":"SFFloat"
},
{
"@name":"filterColor",
"@accessType":"inputOutput",
"@appinfo":"Camera filter color that modifies virtual lens capture",
"@type":"SFColor"
},
{
"@name":"filterTransparency",
"@accessType":"inputOutput",
"@appinfo":"Camera filter transparency that modifies virtual lens capture",
"@type":"SFFloat"
},
{
"@name":"upVector",
"@accessType":"inputOutput",
"@appinfo":"upVector changes modify camera orientation (and possibly vice versa)",
"@type":"SFVec3f"
},
{
"@name":"fStop",
"@accessType":"inputOutput",
"@appinfo":"Focal length divided effective aperture diameter indicating width of focal plane",
"@type":"SFFloat"
},
{
"@name":"focusDistance",
"@accessType":"inputOutput",
"@appinfo":"Distance to focal plane of sharpest focus",
"@type":"SFFloat"
},
{
"@name":"isActive",
"@accessType":"outputOnly",
"@appinfo":"Mark start/stop with true/false output respectively useful to trigger external animations",
"@type":"SFBool"
},
{
"@name":"totalDuration",
"@accessType":"outputOnly",
"@appinfo":"Total duration of contained enabled CameraShot (and thus CameraMovement) move durations",
"@type":"SFTime"
},
{
"@name":"offlineRender",
"@accessType":"inputOutput",
"@appinfo":"OfflineRender node",
"@type":"SFNode"
},
{
"@name":"traceEnabled",
"@accessType":"initializeOnly",
"@appinfo":"enable console output to trace script computations and prototype progress",
"@type":"SFBool"
}
],
"-children":[
{
"#comment":"Viewpoint-related fields, NavigationInfo-related fields and Camera-unique fields"
}
]
}
},
{
"#comment":"=============== CameraShot =============="
},
{ "ExternProtoDeclare":
{
"@name":"CameraShot",
"@appinfo":"CameraShot collects a specific set of CameraMovement animations that make up an individual shot",
"@url":["CameraPrototypes.x3d#CameraShot","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.x3d#CameraShot","CameraPrototypes.wrl#CameraShot","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.wrl#CameraShot"],
"field": [
{
"@name":"description",
"@accessType":"inputOutput",
"@appinfo":"Text description to be displayed for this CameraShot",
"@type":"SFString"
},
{
"@name":"enabled",
"@accessType":"inputOutput",
"@appinfo":"Whether this CameraShot can be activated",
"@type":"SFBool"
},
{
"@name":"moves",
"@accessType":"inputOutput",
"@appinfo":"Set of CameraMovement nodes",
"@type":"MFNode",
"-children":[
{
"#comment":"initializing CameraMovement nodes are inserted here by scene author using ProtoInstance"
}
]
},
{
"@name":"initialPosition",
"@accessType":"inputOutput",
"@appinfo":"Setup to reinitialize camera position for this shot",
"@type":"SFVec3f"
},
{
"@name":"initialOrientation",
"@accessType":"inputOutput",
"@appinfo":"Setup to reinitialize camera rotation for this shot",
"@type":"SFRotation"
},
{
"@name":"initialAimPoint",
"@accessType":"inputOutput",
"@appinfo":"Setup to reinitialize aimpoint (relative location for camera direction) for this shot",
"@type":"SFVec3f"
},
{
"@name":"initialFieldOfView",
"@accessType":"inputOutput",
"@appinfo":"pi/4",
"@type":"SFFloat"
},
{
"@name":"initialFStop",
"@accessType":"inputOutput",
"@appinfo":"Focal length divided effective aperture diameter indicating width of focal plane",
"@type":"SFFloat"
},
{
"@name":"initialFocusDistance",
"@accessType":"inputOutput",
"@appinfo":"Distance to focal plane of sharpest focus",
"@type":"SFFloat"
},
{
"@name":"shotDuration",
"@accessType":"outputOnly",
"@appinfo":"Subtotal duration of contained CameraMovement move durations",
"@type":"SFTime"
},
{
"@name":"isActive",
"@accessType":"outputOnly",
"@appinfo":"Mark start/stop with true/false output respectively useful to trigger external animations",
"@type":"SFBool"
},
{
"@name":"traceEnabled",
"@accessType":"initializeOnly",
"@appinfo":"enable console output to trace script computations and prototype progress",
"@type":"SFBool"
}
]
}
},
{
"#comment":"=============== CameraMovement =============="
},
{ "ExternProtoDeclare":
{
"@name":"CameraMovement",
"@appinfo":"CameraMovement defines a single camera movement animation",
"@url":["CameraPrototypes.x3d#CameraMovement","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.x3d#CameraMovement","CameraPrototypes.wrl#CameraMovement","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.wrl#CameraMovement"],
"field": [
{
"@name":"description",
"@accessType":"inputOutput",
"@appinfo":"Text description to be displayed for this CameraMovement",
"@type":"SFString"
},
{
"@name":"enabled",
"@accessType":"inputOutput",
"@appinfo":"Whether this CameraMovement can be activated",
"@type":"SFBool"
},
{
"@name":"duration",
"@accessType":"inputOutput",
"@appinfo":"Duration in seconds for this move",
"@type":"SFFloat"
},
{
"@name":"goalPosition",
"@accessType":"inputOutput",
"@appinfo":"Goal camera position for this move",
"@type":"SFVec3f"
},
{
"@name":"goalOrientation",
"@accessType":"inputOutput",
"@appinfo":"Goal camera rotation for this move",
"@type":"SFRotation"
},
{
"@name":"tracking",
"@accessType":"inputOutput",
"@appinfo":"Whether or not camera direction is tracking towards the aimPoint",
"@type":"SFBool"
},
{
"@name":"goalAimPoint",
"@accessType":"inputOutput",
"@appinfo":"Goal aimPoint for this move, ignored if tracking=false",
"@type":"SFVec3f"
},
{
"@name":"goalFieldOfView",
"@accessType":"inputOutput",
"@appinfo":"Goal fieldOfView for this move",
"@type":"SFFloat"
},
{
"@name":"goalFStop",
"@accessType":"inputOutput",
"@appinfo":"Focal length divided effective aperture diameter indicating width of focal plane",
"@type":"SFFloat"
},
{
"@name":"goalFocusDistance",
"@accessType":"inputOutput",
"@appinfo":"Distance to focal plane of sharpest focus",
"@type":"SFFloat"
},
{
"@name":"isActive",
"@accessType":"outputOnly",
"@appinfo":"Mark start/stop with true/false output respectively useful to trigger external animations",
"@type":"SFBool"
},
{
"@name":"traceEnabled",
"@accessType":"initializeOnly",
"@appinfo":"enable console output to trace script computations and prototype progress",
"@type":"SFBool"
}
]
}
},
{
"#comment":"=============== OfflineRender =============="
},
{ "ExternProtoDeclare":
{
"@name":"OfflineRender",
"@appinfo":"OfflineRender defines a parameters for offline rendering of Camera animation output to a movie file (or possibly a still shot)",
"@url":["CameraPrototypes.x3d#OfflineRender","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.x3d#OfflineRender","CameraPrototypes.wrl#OfflineRender","https://www.web3d.org/x3d/content/examples/Basic/development/CameraPrototypes.wrl#OfflineRender"],
"field": [
{
"@name":"description",
"@accessType":"inputOutput",
"@appinfo":"Text description to be displayed for this OfflineRender",
"@type":"SFString"
},
{
"@name":"enabled",
"@accessType":"inputOutput",
"@appinfo":"Whether this OfflineRender can be activated",
"@type":"SFBool"
},
{
"@name":"frameRate",
"@accessType":"inputOutput",
"@appinfo":"Frames per second recorded for this rendering",
"@type":"SFFloat"
},
{
"@name":"frameSize",
"@accessType":"inputOutput",
"@appinfo":"Size of frame in number of pixels width and height",
"@type":"SFVec2f"
},
{
"@name":"pixelAspectRatio",
"@accessType":"inputOutput",
"@appinfo":"Relative dimensions of pixel height/width typically 1.33 or 1",
"@type":"SFFloat"
},
{
"@name":"set_startTime",
"@accessType":"inputOnly",
"@appinfo":"Begin render operation",
"@type":"SFTime"
},
{
"@name":"progress",
"@accessType":"outputOnly",
"@appinfo":"Progress performing render operation (0..1)",
"@type":"SFFloat"
},
{
"@name":"renderCompleteTime",
"@accessType":"outputOnly",
"@appinfo":"Render operation complete",
"@type":"SFTime"
},
{
"@name":"movieFormat",
"@accessType":"initializeOnly",
"@appinfo":"Format of rendered output movie (mpeg mp4 etc.), use first supported format",
"@type":"MFString"
},
{
"@name":"imageFormat",
"@accessType":"initializeOnly",
"@appinfo":"Format of rendered output images (png jpeg gif tiff etc.) use first supported format",
"@type":"MFString"
},
{
"@name":"traceEnabled",
"@accessType":"initializeOnly",
"@appinfo":"enable console output to trace script computations and prototype progress",
"@type":"SFBool"
}
],
"-children":[
{
"#comment":"TODO non-photorealistic rendering (NPR) parameters"
}
]
}
},
{
"#comment":"=============== Lights, camera, action! =============="
},
{ "DirectionalLight":
{
"@direction":[0,-1,0],
"@global":true,
"@intensity":0.8
}
},
{ "NavigationInfo":
{
"@type":"\"EXAMINE\" \"FLY\" \"ANY\""
}
},
{ "Viewpoint":
{
"@description":"Camera test scene entry view",
"@position":[0,2,12]
}
},
{ "Viewpoint":
{
"@description":"Camera test scene from above",
"@orientation":[1,0,0,-1.57079],
"@position":[0,150,0]
}
},
{
"#comment":"Keep prototype instances in same file while developing, then move later"
},
{
"#comment":"We will create examples matching those in the paper"
},
{
"#comment":"=============== Camera.SimpleShotsTest =============="
},
{ "ProtoInstance":
{
"@name":"Camera",
"@DEF":"Camera.SimpleShotsTest",
"fieldValue": [
{
"@name":"description",
"@value":"SimpleShotsTest for camera Zoom Dolly Pan Boom and Tilt"
},
{
"@name":"headlight",
"@value":true
},
{
"@name":"position",
"@value":[-4,4,10]
},
{
"@name":"shots",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"Zoom",
"fieldValue": [
{
"@name":"description",
"@value":"Simple shot of Camera Zoom"
},
{
"@name":"initialPosition",
"@value":[-50,1,-10]
},
{
"@name":"initialOrientation",
"@value":[0,1,0,0]
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Zoom In"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-50,1,-15]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Zoom Out"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-50,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Pause"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-50,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
}
]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"Dolly",
"fieldValue": [
{
"@name":"description",
"@value":"Simple shot of Camera Dolly"
},
{
"@name":"initialPosition",
"@value":[-40,1,-10]
},
{
"@name":"initialOrientation",
"@value":[0,1,0,0]
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"DollyMove1",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Dolly from Right to Left"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-45,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Dolly from Left to Right"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-40,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Pause"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-40,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
}
]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"Pan",
"fieldValue": [
{
"@name":"description",
"@value":"Simple shot of Camera Pan left right and back to center"
},
{
"@name":"initialPosition",
"@value":[-30,1,-10]
},
{
"@name":"initialOrientation",
"@value":[0,1,0,0]
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"PanLeft",
"fieldValue": [
{
"@name":"description",
"@value":"Pan Left"
},
{
"@name":"duration",
"@value":2
},
{
"@name":"goalPosition",
"@value":[-30,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0.4]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"PanRight",
"fieldValue": [
{
"@name":"description",
"@value":"Pan Right"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-30,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,-0.4]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Pan back to Center"
},
{
"@name":"duration",
"@value":2
},
{
"@name":"goalPosition",
"@value":[-30,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Pause"
},
{
"@name":"duration",
"@value":2
},
{
"@name":"goalPosition",
"@value":[-30,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
}
]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"CameraBoom",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Boom"
},
{
"@name":"initialPosition",
"@value":[-20,1,-10]
},
{
"@name":"initialOrientation",
"@value":[0,1,0,0]
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"CameraBoomUp",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Boom Up"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-20,5,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"BoomDown",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Boom Down"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-20,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"BoomPause",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Pause"
},
{
"@name":"duration",
"@value":2
},
{
"@name":"goalPosition",
"@value":[-20,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
]
}
}
]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"CameraTilt",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt"
},
{
"@name":"initialPosition",
"@value":[-10,1,-10]
},
{
"@name":"initialOrientation",
"@value":[0,0,1,0]
},
{
"@name":"traceEnabled",
"@value":true
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Pause"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"TiltDown",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Left"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,0.785]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"TiltPause",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Pause"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,0.785]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Right"
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,-0.785]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Pause"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,-0.785]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"TiltReset",
"fieldValue": [
{
"@name":"description",
"@value":"Camera Tilt Reset"
},
{
"@name":"duration",
"@value":1
},
{
"@name":"goalPosition",
"@value":[-10,1,-10]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,0]
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"TiltUp",
"fieldValue": [
{
"@name":"description",
"@value":"Return to home"
},
{
"@name":"duration",
"@value":2
},
{
"@name":"goalPosition",
"@value":[0,2,12]
},
{
"@name":"goalOrientation",
"@value":[0,0,1,0]
}
]
}
}
]
}
]
}
}
]
}
]
}
},
{ "Group":
{
"@DEF":"AnimationGroup.SimpleShots",
"-children":[
{ "TimeSensor":
{
"@DEF":"CameraTimer.SimpleShots"
}
},
{
"#comment":"initialize clock to match totalDuration of combined Shot Moves"
},
{ "ROUTE":
{
"@fromField":"totalDuration",
"@fromNode":"Camera.SimpleShotsTest",
"@toField":"cycleInterval",
"@toNode":"CameraTimer.SimpleShots"
}
},
{
"#comment":"TimeSensor animates the CameraClock since that maintains the computed PositionInterpolator and OrientationInterpolator"
},
{ "ROUTE":
{
"@fromField":"fraction_changed",
"@fromNode":"CameraTimer.SimpleShots",
"@toField":"set_fraction",
"@toNode":"Camera.SimpleShotsTest"
}
},
{ "Transform":
{
"@DEF":"Trigger.SimpleShots",
"@translation":[-4,4,0],
"-children":[
{ "BooleanFilter":
{
"@DEF":"TextTouchActive.SimpleShotsFilter"
}
},
{ "TouchSensor":
{
"@DEF":"TextTouch.SimpleShots",
"@description":"touch to animate Camera SimpleShotsTest"
}
},
{ "ROUTE":
{
"@fromField":"inputTrue",
"@fromNode":"TextTouchActive.SimpleShotsFilter",
"@toField":"set_bind",
"@toNode":"Camera.SimpleShotsTest"
}
},
{ "ROUTE":
{
"@fromField":"isActive",
"@fromNode":"TextTouch.SimpleShots",
"@toField":"set_boolean",
"@toNode":"TextTouchActive.SimpleShotsFilter"
}
},
{ "ROUTE":
{
"@fromField":"touchTime",
"@fromNode":"TextTouch.SimpleShots",
"@toField":"startTime",
"@toNode":"CameraTimer.SimpleShots"
}
},
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Click to animate","SimpleShotsTest"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@DEF":"ArtDeco5",
"@ambientIntensity":0.24,
"@diffuseColor":[0.945455,0.318988,0.321717],
"@shininess":0.01,
"@specularColor":[0.072727,0.021705,0.010732],
"-children":[
{
"#comment":"Universal Media Library: ArtDeco 5"
}
]
}
}
}
}
}
},
{
"#comment":"Simplify intersection test for user selecting text"
},
{ "Shape":
{
"@DEF":"TransparentBox",
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@transparency":1
}
}
}
},
"-geometry":
{ "Box":
{
"@size":[6,2,0.0001]
}
}
}
}
]
}
}
]
}
},
{ "Group":
{
"@DEF":"SimpleShotsTargets",
"-children":[
{ "Transform":
{
"@DEF":"TargetBoxZoom",
"@translation":[-50,1,-20],
"-children":[
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["images/CameraMoveZoom.png","https://www.web3d.org/x3d/content/examples/Basic/development/images/CameraMoveZoom.png"]
}
}
}
}
}
},
{ "Transform":
{
"@translation":[0,2,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Zoom in, out"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
}
}
}
}
}
]
}
}
]
}
},
{ "Transform":
{
"@DEF":"TargetBoxDolly",
"@translation":[-40,1,-20],
"-children":[
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["images/CameraMoveDolly.png","https://www.web3d.org/x3d/content/examples/Basic/development/images/CameraMoveDolly.png"]
}
}
}
}
}
},
{ "Transform":
{
"@translation":[0,2,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Dolly left, right"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
}
}
}
}
}
]
}
}
]
}
},
{ "Transform":
{
"@DEF":"TargetBoxPan",
"@translation":[-30,1,-20],
"-children":[
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["images/CameraMovePan.png","https://www.web3d.org/x3d/content/examples/Basic/development/images/CameraMovePan.png"]
}
}
}
}
}
},
{ "Transform":
{
"@translation":[0,2,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Pan left, right"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
}
}
}
}
}
]
}
}
]
}
},
{ "Transform":
{
"@DEF":"TargetBoxBoom",
"@translation":[-20,1,-20],
"-children":[
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["images/CameraMoveBoom.png","https://www.web3d.org/x3d/content/examples/Basic/development/images/CameraMoveBoom.png"]
}
}
}
}
}
},
{ "Transform":
{
"@translation":[0,2,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Boom up, down"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
}
}
}
}
}
]
}
}
]
}
},
{ "Transform":
{
"@DEF":"TargetBoxTilt",
"@translation":[-10,1,-20],
"-children":[
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["images/CameraMoveTilt.png","https://www.web3d.org/x3d/content/examples/Basic/development/images/CameraMoveTilt.png"]
}
}
}
}
}
},
{ "Transform":
{
"@translation":[0,2,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Tilt left, right"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
}
}
}
}
}
]
}
}
]
}
}
]
}
},
{
"#comment":"=============== Camera.AimPointTest =============="
},
{ "ProtoInstance":
{
"@name":"Camera",
"@DEF":"Camera.AimPointTest",
"fieldValue": [
{
"@name":"description",
"@value":"AimPointTest for moving camera tracking moving target"
},
{
"@name":"position",
"@value":[4,4,10]
},
{
"@name":"shots",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraShot",
"@DEF":"Shot5",
"fieldValue": [
{
"@name":"description",
"@value":"#3 Tracking shot"
},
{
"@name":"initialPosition",
"@value":[6,6,10]
},
{
"@name":"initialOrientation",
"@value":[0,1,0,0]
},
{
"@name":"moves",
"-children":[
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"MoveAimPoint3.1",
"fieldValue": [
{
"@name":"description",
"@value":"AimPoint 3.1 moving BoxPath"
},
{
"@name":"tracking",
"@value":true
},
{
"@name":"duration",
"@value":8
},
{
"@name":"goalPosition",
"@value":[6,6,10]
}
],
"-children":[
{
"#comment":"goalAimPoint modified by ROUTE to match moving Box"
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"MoveAimPoint3.2",
"fieldValue": [
{
"@name":"description",
"@value":"AimPoint 3.2 pan right while tracking"
},
{
"@name":"tracking",
"@value":true
},
{
"@name":"duration",
"@value":8
},
{
"@name":"goalPosition",
"@value":[40,6,12]
}
],
"-children":[
{
"#comment":"goalAimPoint modified by ROUTE to match moving Box"
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"MoveAimPoint3.3",
"fieldValue": [
{
"@name":"description",
"@value":"AimPoint 3.3 boom up while tracking"
},
{
"@name":"tracking",
"@value":true
},
{
"@name":"duration",
"@value":3
},
{
"@name":"goalPosition",
"@value":[40,20,13]
}
],
"-children":[
{
"#comment":"goalAimPoint modified by ROUTE to match moving Box"
}
]
}
},
{ "ProtoInstance":
{
"@name":"CameraMovement",
"@DEF":"MoveAimPoint3.4",
"fieldValue": [
{
"@name":"description",
"@value":"AimPoint 3.4 restore camera back to home"
},
{
"@name":"tracking",
"@value":true
},
{
"@name":"duration",
"@value":5
},
{
"@name":"goalPosition",
"@value":[4,4,10]
},
{
"@name":"goalAimPoint",
"@value":[4,4,0]
},
{
"@name":"goalOrientation",
"@value":[0,1,0,0]
}
],
"-children":[
{
"#comment":"can test tracking or not using these values"
}
]
}
}
]
}
]
}
}
]
}
]
}
},
{ "Group":
{
"@DEF":"AnimationGroup.AimPointTest",
"-children":[
{ "TimeSensor":
{
"@DEF":"CameraTimer.AimPointTest"
}
},
{
"#comment":"initialize clock to match totalDuration of combined Shot Moves"
},
{ "ROUTE":
{
"@fromField":"totalDuration",
"@fromNode":"Camera.AimPointTest",
"@toField":"cycleInterval",
"@toNode":"CameraTimer.AimPointTest"
}
},
{
"#comment":"TimeSensor animates the CameraClock since that maintains the computed PositionInterpolator and OrientationInterpolator"
},
{ "ROUTE":
{
"@fromField":"fraction_changed",
"@fromNode":"CameraTimer.AimPointTest",
"@toField":"set_fraction",
"@toNode":"Camera.AimPointTest"
}
},
{ "Transform":
{
"@DEF":"Trigger.AimPointTest",
"@translation":[4,4,0],
"-children":[
{ "BooleanFilter":
{
"@DEF":"TextTouchActive.AimPointFilter"
}
},
{ "TouchSensor":
{
"@DEF":"TextTouch.AimPointTest",
"@description":"touch to animate Camera AimPointTest"
}
},
{ "ROUTE":
{
"@fromField":"inputTrue",
"@fromNode":"TextTouchActive.AimPointFilter",
"@toField":"set_bind",
"@toNode":"Camera.AimPointTest"
}
},
{ "ROUTE":
{
"@fromField":"isActive",
"@fromNode":"TextTouch.AimPointTest",
"@toField":"set_boolean",
"@toNode":"TextTouchActive.AimPointFilter"
}
},
{ "ROUTE":
{
"@fromField":"touchTime",
"@fromNode":"TextTouch.AimPointTest",
"@toField":"startTime",
"@toNode":"CameraTimer.AimPointTest"
}
},
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["Click to animate","AimPointTest"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@USE":"ArtDeco5"
}
}
}
}
}
},
{ "Shape":
{
"@USE":"TransparentBox"
}
}
]
}
}
]
}
},
{
"#comment":"TODO build a test once implemented"
},
{ "ProtoInstance":
{
"@name":"OfflineRender"
}
},
{
"#comment":"=============== animate a camera shape to visualize view changes =============="
},
{ "Transform":
{
"@DEF":"CameraShapeTransform",
"@translation":[0,0.5,0],
"-children":[
{
"#comment":"move CameraShape using active Camera"
},
{ "ROUTE":
{
"@fromField":"position_changed",
"@fromNode":"Camera.SimpleShotsTest",
"@toField":"translation",
"@toNode":"CameraShapeTransform"
}
},
{ "ROUTE":
{
"@fromField":"orientation_changed",
"@fromNode":"Camera.SimpleShotsTest",
"@toField":"rotation",
"@toNode":"CameraShapeTransform"
}
},
{ "ROUTE":
{
"@fromField":"position",
"@fromNode":"Camera.AimPointTest",
"@toField":"translation",
"@toNode":"CameraShapeTransform"
}
},
{ "ROUTE":
{
"@fromField":"orientation_changed",
"@fromNode":"Camera.AimPointTest",
"@toField":"rotation",
"@toNode":"CameraShapeTransform"
}
},
{ "Transform":
{
"@DEF":"CameraOffsetTransform",
"@translation":[0,0,0.25],
"-children":[
{ "TouchSensor":
{
"@DEF":"CameraShapeTouched"
}
},
{ "Inline":
{
"@DEF":"CameraShape",
"@url":["CameraShape.x3d","https://www.web3d.org/x3d/content/examples/Basic/development/CameraShape.x3d"]
}
},
{ "Shape":
{
"@DEF":"SightLine",
"-geometry":
{ "IndexedLineSet":
{
"@coordIndex":[0,1],
"-coord":
{ "Coordinate":
{
"@point":[0,0,0,0,0,-100]
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@emissiveColor":[0.8,0.8,0.4]
}
}
}
}
}
}
]
}
},
{
"#comment":"Display frustum to show camera view within the scene, toggled by user selecting CameraShape"
},
{ "ExternProtoDeclare":
{
"@name":"ViewFrustum",
"@appinfo":"Display view frustum associated with a given pair of Viewpoint NavigationInfo nodes",
"@url":["../../X3dForWebAuthors/Chapter14Prototypes/ViewFrustumPrototype.x3d#ViewFrustum","https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter14Prototypes/ViewFrustumPrototype.x3d#ViewFrustum","../../X3dForWebAuthors/Chapter14Prototypes/ViewFrustumPrototype.wrl#ViewFrustum","https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter14Prototypes/ViewFrustumPrototype.wrl#ViewFrustum"],
"field": [
{
"@name":"ViewpointNode",
"@accessType":"initializeOnly",
"@appinfo":"required: insert Viewpoint DEF or USE node for view of interest",
"@type":"SFNode"
},
{
"@name":"NavigationInfoNode",
"@accessType":"initializeOnly",
"@appinfo":"required: insert NavigationInfo DEF or USE node of interest",
"@type":"SFNode"
},
{
"@name":"visible",
"@accessType":"inputOutput",
"@appinfo":"whether or not frustum geometry is rendered",
"@type":"SFBool"
},
{
"@name":"lineColor",
"@accessType":"inputOutput",
"@appinfo":"RGB color of ViewFrustum outline, default value 0.9 0.9 0.9",
"@type":"SFColor"
},
{
"@name":"frustumColor",
"@accessType":"inputOutput",
"@appinfo":"RGB color of ViewFrustum hull geometry, default value 0.8 0.8 0.8",
"@type":"SFColor"
},
{
"@name":"transparency",
"@accessType":"inputOutput",
"@appinfo":"transparency of ViewFrustum hull geometry, default value 0.5",
"@type":"SFFloat"
},
{
"@name":"aspectRatio",
"@accessType":"inputOutput",
"@appinfo":"assumed ratio height/width, default value 0.75",
"@type":"SFFloat"
},
{
"@name":"trace",
"@accessType":"initializeOnly",
"@appinfo":"debug support, default false",
"@type":"SFBool"
}
]
}
},
{ "ProtoInstance":
{
"@name":"ViewFrustum",
"@DEF":"ViewFrustumNode",
"fieldValue": [
{
"@name":"ViewpointNode",
"-children":[
{ "Viewpoint":
{
"@DEF":"FrustumViewpoint",
"@description":"viewpoint for ViewFrustum",
"@position":[0,0,0]
}
}
]
},
{
"@name":"NavigationInfoNode",
"-children":[
{ "NavigationInfo":
{
"@DEF":"TestNavigationInfo",
"@transitionType":["ANIMATE"],
"@visibilityLimit":100
}
}
]
},
{
"@name":"visible",
"@value":false
},
{
"@name":"lineColor",
"@value":[0.9,0.9,0.9]
},
{
"@name":"frustumColor",
"@value":[0.8,0.8,0.8]
},
{
"@name":"transparency",
"@value":0.95
}
]
}
},
{ "BooleanToggle":
{
"@DEF":"ViewFrustumToggle"
}
},
{ "ROUTE":
{
"@fromField":"isActive",
"@fromNode":"CameraShapeTouched",
"@toField":"set_boolean",
"@toNode":"ViewFrustumToggle"
}
},
{ "ROUTE":
{
"@fromField":"toggle",
"@fromNode":"ViewFrustumToggle",
"@toField":"set_visible",
"@toNode":"ViewFrustumNode"
}
}
]
}
},
{
"#comment":"=============== add checkerboard, axes and other things to look at while animating =============="
},
{ "Background":
{
"@skyColor":[0.282353,0.380392,0.470588]
}
},
{ "Transform":
{
"@rotation":[1,0,0,-1.57079],
"@scale":[10,10,10],
"-children":[
{ "Shape":
{
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@ambientIntensity":0.01,
"@diffuseColor":[1.0,1.0,1.0],
"@shininess":0.05
}
}
}
},
"-geometry":
{ "IndexedFaceSet":
{
"@colorIndex":[0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0],
"@colorPerVertex":false,
"@coordIndex":[0,8,9,1,-1,1,9,10,2,-1,2,10,11,3,-1,3,11,12,4,-1,4,12,13,5,-1,5,13,14,6,-1,6,14,15,7,-1,8,16,17,9,-1,9,17,18,10,-1,10,18,19,11,-1,11,19,20,12,-1,12,20,21,13,-1,13,21,22,14,-1,14,22,23,15,-1,16,24,25,17,-1,17,25,26,18,-1,18,26,27,19,-1,19,27,28,20,-1,20,28,29,21,-1,21,29,30,22,-1,22,30,31,23,-1,24,32,33,25,-1,25,33,34,26,-1,26,34,35,27,-1,27,35,36,28,-1,28,36,37,29,-1,29,37,38,30,-1,30,38,39,31,-1,32,40,41,33,-1,33,41,42,34,-1,34,42,43,35,-1,35,43,44,36,-1,36,44,45,37,-1,37,45,46,38,-1,38,46,47,39,-1,40,48,49,41,-1,41,49,50,42,-1,42,50,51,43,-1,43,51,52,44,-1,44,52,53,45,-1,45,53,54,46,-1,46,54,55,47,-1,48,56,57,49,-1,49,57,58,50,-1,50,58,59,51,-1,51,59,60,52,-1,52,60,61,53,-1,53,61,62,54,-1,54,62,63,55,-1],
"@normalPerVertex":false,
"@solid":false,
"-coord":
{ "Coordinate":
{
"@point":[-5.25,5.25,0.0,-3.75,5.25,0.0,-2.25,5.25,0.0,-0.75,5.25,0.0,0.75,5.25,0.0,2.25,5.25,0.0,3.75,5.25,0.0,5.25,5.25,0.0,-5.25,3.75,0.0,-3.75,3.75,0.0,-2.25,3.75,0.0,-0.75,3.75,0.0,0.75,3.75,0.0,2.25,3.75,0.0,3.75,3.75,0.0,5.25,3.75,0.0,-5.25,2.25,0.0,-3.75,2.25,0.0,-2.25,2.25,0.0,-0.75,2.25,0.0,0.75,2.25,0.0,2.25,2.25,0.0,3.75,2.25,0.0,5.25,2.25,0.0,-5.25,0.75,0.0,-3.75,0.75,0.0,-2.25,0.75,0.0,-0.75,0.75,0.0,0.75,0.75,0.0,2.25,0.75,0.0,3.75,0.75,0.0,5.25,0.75,0.0,-5.25,-0.75,0.0,-3.75,-0.75,0.0,-2.25,-0.75,0.0,-0.75,-0.75,0.0,0.75,-0.75,0.0,2.25,-0.75,0.0,3.75,-0.75,0.0,5.25,-0.75,0.0,-5.25,-2.25,0.0,-3.75,-2.25,0.0,-2.25,-2.25,0.0,-0.75,-2.25,0.0,0.75,-2.25,0.0,2.25,-2.25,0.0,3.75,-2.25,0.0,5.25,-2.25,0.0,-5.25,-3.75,0.0,-3.75,-3.75,0.0,-2.25,-3.75,0.0,-0.75,-3.75,0.0,0.75,-3.75,0.0,2.25,-3.75,0.0,3.75,-3.75,0.0,5.25,-3.75,0.0,-5.25,-5.25,0.0,-3.75,-5.25,0.0,-2.25,-5.25,0.0,-0.75,-5.25,0.0,0.75,-5.25,0.0,2.25,-5.25,0.0,3.75,-5.25,0.0,5.25,-5.25,0.0]
}
},
"-color":
{ "Color":
{
"@color":[0.435294,0.741176,0,0,0.560784,0.580392]
}
}
}
}
}
}
]
}
},
{ "Transform":
{
"@scale":[3,3,3],
"@translation":[0,0.25,0],
"-children":[
{ "Inline":
{
"@DEF":"CoordinateAxes",
"@url":["../../X3dForWebAuthors/Chapter03Grouping/CoordinateAxes.x3d","../../Savage/Tools/Authoring/CoordinateAxes.x3d","https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter03Grouping/CoordinateAxes.x3d","https://savage.nps.edu/Savage/Tools/Authoring/CoordinateAxes.x3d","../../X3dForWebAuthors/Chapter03Grouping/CoordinateAxes.wrl","../../Savage/Tools/Authoring/CoordinateAxes.wrl","https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter03Grouping/CoordinateAxes.wrl","https://savage.nps.edu/Savage/Tools/Authoring/CoordinateAxes.wrl"]
}
}
]
}
},
{ "Transform":
{
"@DEF":"MovingBoxTransform",
"-children":[
{ "PositionInterpolator":
{
"@DEF":"BoxPath",
"@key":[0,0.25,0.5,0.75,1],
"@keyValue":[-5,1,5,45,1,5,45,1,-45,-5,1,-45,-5,1,5]
}
},
{ "TimeSensor":
{
"@DEF":"BoxTimer",
"@cycleInterval":10,
"@loop":true
}
},
{ "ROUTE":
{
"@fromField":"value_changed",
"@fromNode":"BoxPath",
"@toField":"translation",
"@toNode":"MovingBoxTransform"
}
},
{ "ROUTE":
{
"@fromField":"value_changed",
"@fromNode":"BoxPath",
"@toField":"goalAimPoint",
"@toNode":"MoveAimPoint3.1"
}
},
{ "ROUTE":
{
"@fromField":"value_changed",
"@fromNode":"BoxPath",
"@toField":"goalAimPoint",
"@toNode":"MoveAimPoint3.2"
}
},
{ "ROUTE":
{
"@fromField":"value_changed",
"@fromNode":"BoxPath",
"@toField":"goalAimPoint",
"@toNode":"MoveAimPoint3.3"
}
},
{ "ROUTE":
{
"@fromField":"fraction_changed",
"@fromNode":"BoxTimer",
"@toField":"set_fraction",
"@toNode":"BoxPath"
}
},
{ "Shape":
{
"-geometry":
{ "Box":
{
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
}
},
"-texture":
{ "ImageTexture":
{
"@url":["../earth-topo.png","https://www.web3d.org/x3d/content/examples/Basic/earth-topo.png"]
}
}
}
}
}
}
]
}
},
{
"#comment":"================ CrossHair visualization for center of screen ================"
},
{ "ExternProtoDeclare":
{
"@name":"CrossHair",
"@appinfo":"CrossHair prototype provides a heads-up display (HUD) crosshair at the view center, which is useful for assessing NavigationInfo lookAt point",
"@url":["../../Savage/Tools/HeadsUpDisplays/CrossHairPrototype.x3d#CrossHair","https://savage.nps.edu/Savage/Tools/HeadsUpDisplays/CrossHairPrototype.x3d#CrossHair","../../Savage/Tools/HeadsUpDisplays/CrossHairPrototype.wrl#CrossHair","https://savage.nps.edu/Savage/Tools/HeadsUpDisplays/CrossHairPrototype.wrl#CrossHair"],
"field": [
{
"@name":"enabled",
"@accessType":"initializeOnly",
"@appinfo":"whether CrissHair orititype is enabled or not",
"@type":"SFBool"
},
{
"@name":"set_enabled",
"@accessType":"inputOnly",
"@appinfo":"control whether enabled/disabled",
"@type":"SFBool"
},
{
"@name":"markerColor",
"@accessType":"inputOutput",
"@appinfo":"color of CrossHair marker",
"@type":"SFColor"
},
{
"@name":"scale",
"@accessType":"inputOutput",
"@appinfo":"size of CrossHair in meters",
"@type":"SFVec3f"
},
{
"@name":"positionOffsetFromCamera",
"@accessType":"inputOutput",
"@appinfo":"distance in front of HUD viewpoint",
"@type":"SFVec3f"
}
]
}
},
{ "ProtoInstance":
{
"@name":"CrossHair",
"@DEF":"CrossHairInstance",
"fieldValue": [
{
"@name":"enabled",
"@value":true
},
{
"@name":"markerColor",
"@value":[1,0.5,0]
},
{
"@name":"scale",
"@value":[1,1,1]
},
{
"@name":"positionOffsetFromCamera",
"@value":[0,0,-6]
}
]
}
},
{
"#comment":"turn on CrossHairInstance when animated camera viewpoints are bound"
},
{ "ROUTE":
{
"@fromField":"isBound",
"@fromNode":"Camera.SimpleShotsTest",
"@toField":"set_enabled",
"@toNode":"CrossHairInstance"
}
},
{ "ROUTE":
{
"@fromField":"isBound",
"@fromNode":"Camera.AimPointTest",
"@toField":"set_enabled",
"@toNode":"CrossHairInstance"
}
},
{
"#comment":"turn off CrossHairInstance when animated camera viewpoints are unbound "
},
{
"#comment":"=============== TODO Launch Prototype Example =============="
},
{ "Anchor":
{
"@description":"launch CameraExample scene",
"@parameter":["target=_blank"],
"@url":["CameraExample.x3d","https://www.web3d.org/x3d/content/examples/Basic/development/CameraExample.x3d","CameraExample.wrl","https://www.web3d.org/x3d/content/examples/Basic/development/CameraExample.wrl"],
"-children":[
{ "Transform":
{
"@translation":[0,-3,0],
"-children":[
{ "Shape":
{
"-geometry":
{ "Text":
{
"@string":["CameraPrototype","defines a prototype","","Click on this text to see","CameraExample scene"],
"-fontStyle":
{ "FontStyle":
{
"@justify":["MIDDLE","MIDDLE"],
"@size":0.5
}
}
}
},
"-appearance":
{ "Appearance":
{
"-material":
{ "Material":
{
"@diffuseColor":[1,1,0.2]
}
}
}
}
}
}
]
}
}
]
}
}
]
}
}
}