SHARE
TWEET

Untitled

a guest Nov 14th, 2019 82 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3.  
  4. Copyright 2013, 2017, Karljohan Lundin Palmerius
  5.  
  6. This is a stubb for laborations on multi-modal display
  7. systems in the VR laboratory. It will disable the X3D
  8. navigation to allow for viewpoint calibration and tracking,
  9. and load libraries commonly used in the VR laboratory.
  10.  
  11. -->
  12. <Scene>
  13. <Group>
  14.         <PythonScript url="urn:candy:python/CorrectViewpoint.py"/>
  15.         <PythonScript url="urn:candy:python/AutoLoadSO.py"/>
  16.         <PythonScript DEF = "MFtoSF" url="urn:candy:python/MFtoSFBool.py"/>
  17.        <!--<Inline url="urn:candy:x3d/view-head-tracked-mono.x3d"/>-->
  18. <!-- <SMViewpoint screenLowerLeft="-1 -0.56 0" screenUpperRight ="1 0.56 0"/> -->
  19.         <BooleanFilter DEF="bfilt"/>
  20.        
  21. <Viewpoint   position="0 0 3"/>
  22.  
  23. <VRSound  location = "0 0 0" spatialize = "true">
  24.         <AudioClip DEF = "play" url="sound/180901__jorickhoofd__vocal-request-i-m-fine-mono-part1.wav" startTime="0" loop="false"/>
  25.     </VRSound>
  26.     <TimeTrigger DEF = "tTrig" set_boolean = ""/>
  27.  
  28. <MatrixTransform DEF="TR">
  29. <!--  Rotates the entire object  -->
  30. <Transform translation="-0.25 0 -0.5" rotation ="1 -1 0 0.5">
  31.     <!--   Stolsben     -->
  32. <Group>
  33.    
  34.     <DirectionalLight intensity="1" direction="1 -1 -2"/>
  35.         <Shape DEF="ben1">
  36.             <Cylinder radius="0.05" height ="0.6"/>
  37.             <Appearance shadow ="true">
  38.                 <FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false">
  39.                 </FrictionalSurface>
  40.             </Appearance>  
  41.         </Shape>
  42.        
  43.        
  44.         <Transform translation ="0.5 0 0">
  45.             <Shape USE = "ben1"/>
  46.         </Transform>
  47.        
  48.         <Transform translation ="0 0 0.5">
  49.             <Shape USE = "ben1"/>
  50.         </Transform>
  51.        
  52.         <Transform translation ="0.5 0 0.5">
  53.             <Shape USE = "ben1"/>
  54.         </Transform>
  55.     </Group>
  56.    
  57.     <Transform translation ="0.25 0.3 0.25">
  58.         <Shape DEF="seat">
  59.             <Box DEF = "Seat" size="0.6 0.05 0.7" isTouched ="" />
  60.             <Appearance shadow ="true" >
  61.                 <ImageTexture url="lh.jpg"/>
  62.                 <FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false">
  63.                 </FrictionalSurface>
  64.             </Appearance>
  65.         </Shape>
  66.     </Transform>
  67.    
  68. <!-- Ryggstod     -->
  69.     <Transform translation ="0.25 0.6 0">
  70.         <Shape DEF="rygg">
  71.             <Box size = "0.6 0.6 0.05" />
  72.             <Appearance shadow ="true">
  73.                 <MultiTexture DEF="MT" source="DIFFUSE" mode='"DOTPRODUCT3" "MODULATE"' >
  74.                     <ImageTexture url="NormalMaprs.png"/>
  75.                     <ImageTexture url="rs.jpg"/>
  76.                 </MultiTexture>
  77.                 <FrictionalSurface damping="500" stiffness="500" useRelativeValues="false">
  78.                 </FrictionalSurface>
  79.             </Appearance>
  80.         </Shape>
  81.     </Transform>
  82.    
  83.  
  84.     <Transform translation ="-0.05 0.93 0">
  85.         <Shape DEF="kula">
  86.             <Sphere radius="0.05"/>
  87.             <Appearance shadow ="true"><FrictionalSurface damping="500" stiffness="1000" useRelativeValues="false"></FrictionalSurface></Appearance>
  88.         </Shape>
  89.        
  90.      
  91.          
  92.         <Transform translation = "0.6 0 0">
  93.            
  94.             <Shape USE ="kula"/>
  95.         </Transform>
  96.     </Transform>
  97.    
  98.    
  99.    
  100.    
  101.     <Transform translation = "0 -0.3 0">
  102.     <Shape>
  103.         <Box size="10 0.01 10"/>
  104.         <Appearance shadow = "true"><Material diffuseColor = "1 1 1"/></Appearance>
  105.     </Shape>
  106. </Transform>
  107.    
  108.    
  109.     </Transform>
  110.    
  111.      </MatrixTransform>
  112.      
  113.    
  114.  
  115.    
  116. </Group>    
  117.    
  118.     <IMPORT inlineDEF="H3D_EXPORTS" exportedDEF="HDEV" AS="HDEV"/>
  119.  
  120.     <PythonScript
  121.       DEF="MT"
  122.       url="urn:candy:python/ManualTranslation.py">
  123.     <Transform USE="TR" containerField="references"/>
  124.   </PythonScript>
  125.    
  126.    
  127. <ROUTE fromNode="HDEV" fromField="mainButton" toNode="MT" toField="button"/>
  128. <ROUTE fromNode="HDEV" fromField="trackerPosition" toNode="MT" toField="position"/>
  129.  
  130. <ROUTE fromNode="Seat" fromField="isTouched" toNode="MFtoSF" toField="value"/>
  131. <ROUTE fromNode="MFtoSF" fromField="value" toNode="bfilt" toField="set_boolean"/>
  132. <ROUTE fromNode="bfilt" fromField="inputTrue" toNode="tTrig" toField="set_boolean"/>
  133. <ROUTE fromNode="tTrig" fromField="triggerTime" toNode="play" toField="startTime"/>
  134.  
  135.  
  136. </Scene>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top