Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Copyright 2013, 2017, Karljohan Lundin Palmerius
- This is a stubb for laborations on multi-modal display
- systems in the VR laboratory. It will disable the X3D
- navigation to allow for viewpoint calibration and tracking,
- and load libraries commonly used in the VR laboratory.
- -->
- <Scene>
- <Group>
- <PythonScript url="urn:candy:python/CorrectViewpoint.py"/>
- <PythonScript url="urn:candy:python/AutoLoadSO.py"/>
- <PythonScript DEF = "MFtoSF" url="urn:candy:python/MFtoSFBool.py"/>
- <!--<Inline url="urn:candy:x3d/view-head-tracked-mono.x3d"/>-->
- <!-- <SMViewpoint screenLowerLeft="-1 -0.56 0" screenUpperRight ="1 0.56 0"/> -->
- <BooleanFilter DEF="bfilt"/>
- <Viewpoint position="0 0 3"/>
- <VRSound location = "0 0 0" spatialize = "true">
- <AudioClip DEF = "play" url="sound/180901__jorickhoofd__vocal-request-i-m-fine-mono-part1.wav" startTime="0" loop="false"/>
- </VRSound>
- <TimeTrigger DEF = "tTrig" set_boolean = ""/>
- <MatrixTransform DEF="TR">
- <!-- Rotates the entire object -->
- <Transform translation="-0.25 0 -0.5" rotation ="1 -1 0 0.5">
- <!-- Stolsben -->
- <Group>
- <DirectionalLight intensity="1" direction="1 -1 -2"/>
- <Shape DEF="ben1">
- <Cylinder radius="0.05" height ="0.6"/>
- <Appearance shadow ="true">
- <FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false">
- </FrictionalSurface>
- </Appearance>
- </Shape>
- <Transform translation ="0.5 0 0">
- <Shape USE = "ben1"/>
- </Transform>
- <Transform translation ="0 0 0.5">
- <Shape USE = "ben1"/>
- </Transform>
- <Transform translation ="0.5 0 0.5">
- <Shape USE = "ben1"/>
- </Transform>
- </Group>
- <Transform translation ="0.25 0.3 0.25">
- <Shape DEF="seat">
- <Box DEF = "Seat" size="0.6 0.05 0.7" isTouched ="" />
- <Appearance shadow ="true" >
- <ImageTexture url="lh.jpg"/>
- <FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false">
- </FrictionalSurface>
- </Appearance>
- </Shape>
- </Transform>
- <!-- Ryggstod -->
- <Transform translation ="0.25 0.6 0">
- <Shape DEF="rygg">
- <Box size = "0.6 0.6 0.05" />
- <Appearance shadow ="true">
- <MultiTexture DEF="MT" source="DIFFUSE" mode='"DOTPRODUCT3" "MODULATE"' >
- <ImageTexture url="NormalMaprs.png"/>
- <ImageTexture url="rs.jpg"/>
- </MultiTexture>
- <FrictionalSurface damping="500" stiffness="500" useRelativeValues="false">
- </FrictionalSurface>
- </Appearance>
- </Shape>
- </Transform>
- <Transform translation ="-0.05 0.93 0">
- <Shape DEF="kula">
- <Sphere radius="0.05"/>
- <Appearance shadow ="true"><FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false"></FrictionalSurface></Appearance>
- </Shape>
- <Transform translation = "0.6 0 0">
- <Shape USE ="kula"/>
- </Transform>
- </Transform>
- <Transform translation = "0 -0.3 0">
- <Shape>
- <Box size="10 0.01 10"/>
- <Appearance shadow = "true"><Material diffuseColor = "1 1 1"/></Appearance>
- </Shape>
- </Transform>
- </Transform>
- </MatrixTransform>
- </Group>
- <IMPORT inlineDEF="H3D_EXPORTS" exportedDEF="HDEV" AS="HDEV"/>
- <PythonScript
- DEF="MT"
- url="urn:candy:python/ManualTranslation.py">
- <Transform USE="TR" containerField="references"/>
- </PythonScript>
- <ROUTE fromNode="HDEV" fromField="mainButton" toNode="MT" toField="button"/>
- <ROUTE fromNode="HDEV" fromField="trackerPosition" toNode="MT" toField="position"/>
- <ROUTE fromNode="Seat" fromField="isTouched" toNode="MFtoSF" toField="value"/>
- <ROUTE fromNode="MFtoSF" fromField="value" toNode="bfilt" toField="set_boolean"/>
- <ROUTE fromNode="bfilt" fromField="inputTrue" toNode="tTrig" toField="set_boolean"/>
- <ROUTE fromNode="tTrig" fromField="triggerTime" toNode="play" toField="startTime"/>
- </Scene>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement