templates/gallery3D/gallery3D_inline.html.twig line 1

Open in your IDE?
  1.         {% for message in app.flashes('notice') %}
  2.         <div class="flash-notice">
  3.             <div class='notice'>{{ message }}</div>
  4.         </div>
  5.         {% endfor %}
  6.         {% for message in app.flashes('error') %}
  7.             <div class="flash-error">
  8.                 <div class='error'>{{ message }}</div>
  9.             </div>
  10.         {% endfor %}
  11.         {#    {% block title %}{{ gallery3D.gallery3DName }}{% endblock %}#}
  12.         {#    we setup images for 3D space #}
  13.         {% set gallery3DInfo = [] %}
  14.         {% set gallery3DInfo = gallery3DInfo|merge({'image_size_horisontal': '4.8 3.2 0.1'}) %}
  15.         {% set gallery3DInfo = gallery3DInfo|merge({'frame_size_horisontal': '5.2 3.6 0.1'}) %}
  16.         {% set gallery3DInfo = gallery3DInfo|merge({'image_size_vertical': '3.2 4.8 0.1'}) %}
  17.         {% set gallery3DInfo = gallery3DInfo|merge({'frame_size_vertical': '3.6 5.2 0.1'}) %}
  18.         {#    we prepare textures #}
  19.         {% set textureArray = [] %}
  20.         {% set textureArray = textureArray|merge({'logo-texture-1': ''}) %}        
  21.         {% set textureArray = textureArray|merge({'floor-texture-1': ''}) %}
  22.         {% set textureArray = textureArray|merge({'floor-texture-2': ''}) %}
  23.         {% set textureArray = textureArray|merge({'ceil-texture-1': ''}) %}
  24.         {% set textureArray = textureArray|merge({'wall-texture-1': ''}) %}
  25.         {% set textureArray = textureArray|merge({'wall-texture-2': ''}) %}
  26.         {% set textureArray = textureArray|merge({'background-front': ''}) %}
  27.         {% set textureArray = textureArray|merge({'background-back': ''}) %}
  28.         {% set textureArray = textureArray|merge({'background-left': ''}) %}
  29.         {% set textureArray = textureArray|merge({'background-right': ''}) %}
  30.         {% set textureArray = textureArray|merge({'image-help-1': ''}) %}
  31.         {% set textureArray = textureArray|merge({'button-play': ''}) %}
  32.         {% set textureArray = textureArray|merge({'button-home': ''}) %}
  33.         {% set textureArray = textureArray|merge({'button-help': ''}) %}
  34.         {% set textureArray = textureArray|merge({'button-exit-1': ''}) %}
  35.         {% set textureArray = textureArray|merge({'gallery-logo': ''}) %}
  36.         {% set textureArray = textureArray|merge({'cart-texture-1': ''}) %}
  37.         {% set textureArray = textureArray|merge({'info-texture-1': ''}) %}
  38.         {% set textureArray = textureArray|merge({'bg-texture-1': ''}) %}
  39.         {% set textureArray = textureArray|merge({'bg-texture-2': ''}) %}
  40.         {% set textureArray = textureArray|merge({'bg-texture-3': ''}) %}
  41.         {% set textureArray = textureArray|merge({'bg-texture-4': ''}) %}
  42.         {% if textureItemCollection is not defined %} 
  43.             {% set textureItemCollection = [] %}
  44.         {% endif %}
  45.         {% for textureItem in textureItemCollection %}
  46.             {% if 'http' in textureItem.galleryItemFile %}
  47.                 {% set texturePath = textureItem.galleryItemFile %}
  48.             {% else %} 
  49.                 {% set texturePath = userDirs['web'] ~ '/images/' ~ textureItem.galleryItemFile %}
  50.             {% endif %}
  51.             {% if textureItem.galleryItemName is defined and textureItem.galleryItemName != '' %}
  52.                 {% set textureKey = textureItem.galleryItemName %}
  53.     {#                {% set textureArray[textureKey] = texturePath %}#}
  54.                 {% set textureArray = textureArray|merge({(textureKey): (texturePath)}) %}
  55.             {% endif %}
  56.         {% endfor %}
  57.         {% if isFullscreen is defined and isFullscreen %}
  58.             {% set resizeButton = 'button_fullscreen' %}
  59.             {% set isFullscreen = true %}
  60.             {% set screenHeight = '90vh' %}
  61.         {% else %}
  62.             {% set resizeButton = 'button_defaultscreen' %}
  63.             {% set isFullscreen = false %}
  64.             {% set screenHeight = '323px' %}
  65.         {% endif %}    
  66.         <!-- X3D  -->
  67.         <div style="width: 100vw; height: {{ screenHeight }}; display:block; right:0; left:0; box-sizing: border-box; position: absolute; left: 0; right: 0; background-color: Black;" id="x3d" class="x3d_container">
  68.                 <!-- menu -->
  69.                 
  70.               <div style="position: absolute; left: 0px; width: 100%; height: 40px; display:inline-block; border-right: 1px solid #EA5B0C; background-color: #222; opacity: 0.5; font-family: helvetica, sans-serif; font-weight: bold; font-size: 10px; color: #EA5B0C; padding-left:5px; z-index: 3;" class="x3d_menu" id="x3d_menu">
  71.                     
  72.                     <div style="margin-right:7px;padding-top:2px; display:inline-block; text-align: center;">
  73.                         <div><big>3D</big></div>
  74.                         <div><small>menu</small></div>
  75.                     </div>                    
  76.                     <div style="margin-right:7px; display:inline-block" id="x3d_menu_viewpoint_home">
  77.                         <button id="button_viewpoint_home" onclick="changeViewpoint('x3d_viewpoint_home')" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px;  background-image: url( '/images/x3dmenu_home.png' ); background-size: 31px 31px; height: 33px; width: 33px; border: 1px solid silver; border-radius:17px;" title="Home Viewpoint"></button>
  78.                 </div>    
  79.               <div style="margin-right:7px; display:inline-block" id="x3d_menu_tour">
  80.                 <button id="gallery_button_viewpoint" onclick="changeViewpoint('x3d_viewpoint_tour')" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px;  background-image: url( '/images/x3dmenu_walk.png' ); background-size: 31px 31px; height: 31px; width: 31px; border: 1px solid silver; border-radius:17px;" title="Tour"></button>
  81.                 </div>
  82.               {% for galleryItem in galleryItemCollection %}
  83.                   {% set itemId = galleryItem.galleryItemId %}
  84.                   {% set viewpoint = 'gallery_viewpoint_' ~ itemId %}
  85.                   <div style="margin-right:7px; display:inline-block" id="gallery_menu_viewpoint_{{ itemId }}">
  86.                 <button id="gallery_button_viewpoint_{{ itemId }}" onclick="changeViewpoint('gallery_viewpoint_{{ itemId }}')" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; color: white;padding:2px;  background-image: url( '/images/x3dmenu_eye.png' ); background-size: 31px 31px; height: 33px; width: 33px;  border: 1px solid silver; border-radius:17px;" title="Gallery item {{ itemId }}" class="x3d_menu_button_viewpoint"></button>
  87.                 </div>
  88.               {% endfor %}
  89.               <div style="margin-right:7px; display:inline-block" id="x3d_menu_defaultscreen">
  90.                 <button id="button_defaultscreen" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px;  background-image: url( '/images/x3dmenu_defaultscreen.png' ); background-size: 31px 31px; height: 33px; width: 33px; border: 1px solid silver; border-radius:17px;" title="default screen"></button>
  91.               </div>
  92.               <div style="margin-right:7px; display:inline-block" id="x3d_menu_fullscreen">
  93.                 <button id="button_fullscreen" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px; background-image: url( '/images/x3dmenu_fullscreen.png' ); background-size: 31px 31px; height: 33px; width: 33px; border: 1px solid silver; border-radius:17px;" title="full screen"></button>
  94.                 </div>
  95.               </div>
  96.               <div style="position: absolute; right: 0px; width: 0px; height: 100%; display:block; border-left: 1px solid #EFEFEF; background-color: #222; opacity: 0.8; text-align:left; font-family: helvetica, sans-serif; font-weight: bold; font-size: 10px; color: #FFF; padding-top:5px; padding-left:8px; padding-right:15px; z-index: 1;" id="x3d_item_detail">
  97.                   <div style="margin-top:1px" id="x3d_item_detail_close" style="tex-align: left; float: left;">
  98.                         <button id="button_item_detail_close" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px;  background-image: url( '{{ textureArray['button-exit-1'] }}' ); background-size: 31px 31px; height: 33px; width: 33px;" title="default screen"></button>
  99.                   </div>
  100.                   <div id="x3d_item_name" style="font-weight: bold; font-size: 22px; margin-top:8px"></div>
  101.                   <div style="margin-top:8px">
  102.                       <span id="x3d_item_description" style="font-weight: normal; font-size: 16px"></span>
  103.                   </div>        
  104.                   <div style="margin-top:6px" id="x3d_item_detail_close2" style="tex-align: left; float: left;">
  105.                         <button id="button_item_detail_close2" style="font-family: helvetica, sans-serif; font-weight: normal; font-size: 10px; background-color: black; border: 1px solid #333; color: white;padding:2px;  background-image: url( '{{ textureArray['button-exit-1'] }}' ); background-size: 31px 31px; height: 33px; width: 33px;" title="default screen"></button>
  106.                   </div>                                        
  107.               </div>
  108.                 <x3d width='100%' height="{{ screenHeight }}" id="x3d_section" class="x3d" style="height: {{ screenHeight }}; background-color: #222;">
  109.                 <scene id="x3d_scene">
  110.                 <NavigationInfo headlight="true" visibilityLimit="0.0" type='"EXAMINE", "ANY"' avatarSize="0.25, 1.75, 0.75"></NavigationInfo>
  111.                 {% if gallery3D.isStartGuide is defined and gallery3D.isStartGuide == true %}
  112.                     <Transform DEF='TourAvatarWrapper' id='TourAvatarWrapper'>
  113.                         <viewpoint orientation='0 1 0 -0.2' position='0 3 0' DEF='x3d_viewpoint_tour' id='x3d_viewpoint_tour'></viewpoint>
  114.                     </Transform>
  115.                 {% endif %}
  116.                 <Transform DEF='AvatarWrapper' id='AvatarWrapper'>
  117.                     <viewpoint orientation='0 1 0 -0' position='-5 3 7' DEF='x3d_viewpoint_1' id='x3d_viewpoint_1'></viewpoint>
  118.                 </Transform>
  119.                 <viewpoint orientation='0 1 0 1' position='-10 3 0'  id='x3d_viewpoint_2'></viewpoint>
  120.                 <viewpoint orientation='0 1 0 0.5' position='-10 3 -13'  id='x3d_viewpoint_3'></viewpoint>
  121.                 <viewpoint orientation='0 1 0 -0' position='0 3 11'  id='x3d_viewpoint_home'></viewpoint>
  122.                 {% if gallery3D.isStartGuide is defined and gallery3D.isStartGuide == false %}
  123.                     <Transform DEF='TourAvatarWrapper' id='TourAvatarWrapper'>
  124.                         <viewpoint orientation='0 1 0 -0.2' position='0 3 0' DEF='x3d_viewpoint_tour' id='x3d_viewpoint_tour'></viewpoint>
  125.                     </Transform>    
  126.                 {% endif %}        
  127.                 <DirectionalLight ambientIntensity='0.835991' direction='0.584419 0.286636 0.75914'></DirectionalLight>
  128.                 
  129.                 {% if gallery3D.preferredBackgroundSkyColor is defined and gallery3D.preferredBackgroundSkyColor != '' %}
  130.                     {% set preferredBackgroundSkyColor = gallery3D.preferredBackgroundSkyColor %}
  131.                 {% else %}
  132.                     {% set preferredBackgroundSkyColor = '0.8 0.8 0.2 0.8 0.8 0.2 0.1 0.1 0.6 0.1 0.1 0.6 0.1 0.25 0.8 0.6 0.6 0.9' %}
  133.                 {% endif %}    
  134.                 {% if gallery3D.preferredBackgroundGroundColor is defined and gallery3D.preferredBackgroundGroundColor != '' %}
  135.                     {% set preferredBackgroundGroundColor = gallery3D.preferredBackgroundGroundColor %}
  136.                 {% else %}
  137.                     {% set preferredBackgroundGroundColor = '0.2 0.2 0 0.3 0.3 0 0.5 0.5 0.3 0.1 0.3 0.4 0 0.2 0.4' %}
  138.                 {% endif %}                    
  139.                 
  140.                 <Background groundColor='{{ preferredBackgroundGroundColor }}' skyAngle='0.04 0.05 0.1 1.309 1.570' skyColor='{{ preferredBackgroundSkyColor }}'></Background>                
  141.                 
  142.               <Transform DEF='ImagesBox' translation='0 0 0' rotation='0 1 0 -0.13117953405799'>
  143.               {% set xPos = -15 %}
  144.               {% set zPos = 2 %}
  145.               {% set yRotation = 1.6 %}
  146.               {% set imageCount = 0 %}
  147.               {% set imagePanelWidth = 5.2 %}
  148.               {% set frontWallImageCount = 4 %}
  149.               {% set imageTotalCount = galleryItemCollection|length %}
  150.               {% set sideWallImageCount = ((imageTotalCount - frontWallImageCount)/2) %}
  151.               {% set zPosFrontWall = null %}
  152.  
  153.               {% for galleryItem in galleryItemCollection %}
  154.                       {% if (imageCount < (sideWallImageCount-1)) %}
  155.                           {% set zPos = zPos - imagePanelWidth %}
  156.                           {% set yRotation = 1.6 %}
  157.                           {% set xPosViewPoint = -7 %}
  158.                           {% set zPosViewPoint = zPos %}
  159.                           {% set zPosFrontWall = zPos %}
  160.                       {% elseif (imageCount < (sideWallImageCount + frontWallImageCount)) %}
  161.                           {% set xPos = xPos + imagePanelWidth %}
  162.                           {% set yRotation = 0 %}
  163.                           {% set xPosViewPoint = xPos %}
  164.                           {% set zPosViewPoint = -((sideWallImageCount * 4) - 5) %}
  165.                           {% set zPos = zPosFrontWall - 2 %}
  166.                       {% else %}    
  167.                           {% set zPos = zPos + imagePanelWidth %}
  168.                           {% set xPos = 15 %}
  169.                           {% set yRotation = -1.6 %}
  170.                           {% set xPosViewPoint = 9 %}
  171.                           {% set zPosViewPoint = zPos %}
  172.                           {% set zPosFrontWall = zPos %}
  173.                       {% endif %}
  174.                       {% set fileID = galleryItem.galleryItemId %}
  175.                       {% set itemId = galleryItem.galleryItemId %}
  176.                       {% if 'http' in galleryItem.galleryItemFile %}
  177.                           {% set path = galleryItem.galleryItemFile %}
  178.                           {% set pathObj = galleryItem.galleryItemFile %}
  179.                       {% else %}        
  180.                           {% set path = userDirs['web'] ~ '/images/' ~ galleryItem.galleryItemFile %}
  181.                           {% set pathObj = userDirs['web'] ~ '/images/' ~ galleryItem.galleryItemFile %}
  182.                       {% endif %}
  183.                       {% set image = path %}
  184.                     {% set img = imagecreatefromstring(file_get_contents(image)) %}
  185.                     {% set imgObj = imagecreatefromstring(file_get_contents(pathObj)) %}
  186.                     {% if ImageSX(imgObj) > ImageSY(imgObj) %} 
  187.                         {% set boxSize = gallery3DInfo['image_size_horisontal'] %}
  188.                         {% set frameSize = gallery3DInfo['frame_size_horisontal'] %}
  189.                     {% else %}
  190.                         {% set boxSize = gallery3DInfo['image_size_vertical'] %}
  191.                         {% set frameSize = gallery3DInfo['frame_size_vertical'] %}
  192.                     {% endif %}
  193.                 <viewpoint orientation='0 1 0 {{ yRotation }}' position='{{ xPosViewPoint }} 3.5 {{ zPosViewPoint }}' id='gallery_viewpoint_{{ fileID }}'></viewpoint>
  194.                 <Transform rotation='0 1 0 {{ yRotation }}' translation='{{ xPos }} 3.3 {{ zPos }}'>
  195.                 
  196.                   <Transform>
  197.                     <Shape onclick="changeViewpoint('gallery_viewpoint_{{ itemId }}')">
  198.                       <Appearance>
  199.                         <Material></Material>
  200.                         <ImageTexture url="{{ path }}"></ImageTexture>
  201.                       </Appearance>
  202.                       <Box size='{{ boxSize }}'></Box>
  203.                     </Shape>
  204.                     <TouchSensor DEF='Image1Sensor'></TouchSensor>
  205.                   </Transform>
  206.                   <Transform translation='0 0 -0.1'>
  207.                     <Shape>
  208.                       <Appearance>
  209.                         <Material diffuseColor='0 0 0' transparency='0.3'></Material>
  210.                       </Appearance>
  211.                       <Box size='{{ frameSize }}'></Box>
  212.                     </Shape>
  213.                   </Transform>
  214.                 </Transform> 
  215.                 <Transform rotation='0 1 0 {{ yRotation }}' translation='{{ xPos }} 1.3 {{ zPos }}'>    
  216.                     
  217.                     {% set menuX = 0 %}
  218.                     {% if galleryItem.clickURL is defined and galleryItem.clickURL != '' %}
  219.                         <!-- browse url button -->
  220.                         <Anchor
  221.                             description='{{ 'system.browse_url'|trans }}'
  222.                             id = 'img_url_{{ galleryItem.galleryItemId }}'
  223.                             url='{{ galleryItem.clickURL }}'
  224.                             parameter = 'target=_blank'>
  225.                             <Transform translation='{{ (menuX - 0.8) }} -0.85 0'>
  226.                               <Shape>
  227.                                 <Appearance>
  228.                                    <Material diffuseColor='0 1 0'></Material>
  229.                                    <ImageTexture url='{{ textureArray['browseurl-texture-1'] }}'></ImageTexture>
  230.                                        <TextureTransform scale='1 1'></TextureTransform>
  231.                                 </Appearance>
  232.                                 <Box size='1.7 0.7 0.1'></Box>
  233.                               </Shape>
  234.                             </Transform> 
  235.                         </Anchor>
  236.                         {% set menuX = menuX + 0.55 %}
  237.     
  238.                        {% endif %}
  239.                        {% if galleryItem.galleryItemDescription is defined and galleryItem.galleryItemDescription != '' %}
  240.                       <!--  more info button -->
  241.                         <Transform translation='{{ (menuX + 0.3) }} -0.85 0'>
  242.                           <Shape onclick="getGaleryItemDetail('{{ galleryItem.galleryItemName }}','{{ galleryItem.galleryItemDescription }}')">
  243.                             <Appearance>
  244.                                <Material diffuseColor='0 1 0'></Material>
  245.                                <ImageTexture url='{{ textureArray['info-texture-1'] }}'></ImageTexture>
  246.                                    <TextureTransform scale='1 1'></TextureTransform>
  247.                             </Appearance>
  248.                             <Box size='1.7 0.7 0.1'></Box>
  249.                           </Shape>
  250.                         </Transform> 
  251.                         {% set menuX = menuX + 0.55 %}
  252.  
  253.                        {% endif %}
  254.                 </Transform> 
  255.                   {% set imageCount = imageCount + 1 %}
  256.               {% endfor %}
  257.               
  258.                 <!-- logo 1 -->
  259.                 <Group DEF='Animation_header'>
  260.                   <TimeSensor DEF='LogoTimer'
  261.                       cycleInterval='24'
  262.                       loop='true'
  263.                       isActive='true'></TimeSensor>
  264.                   <OrientationInterpolator DEF='BoxRotationInterpolator'
  265.                       key='0, 0.25, 0.5, 0.75, 1'
  266.                       keyValue='0 0 1 0, 0 -1 0 1.5707963267949, 0 -1 0 3.14159253438051, 0 1 0 1.57079644600419, 0 0 1 0'></OrientationInterpolator>
  267.                 </Group>
  268.                 
  269.                 <Transform translation='0 8.5 -5' >
  270.                       <Shape >
  271.                         <Appearance >
  272.                           <Material diffuseColor='0.1 0.1 0.1'>
  273.                           </Material>
  274.                         </Appearance>
  275.                         <Cylinder height='0.3' radius='1.5' >
  276.                         </Cylinder>
  277.                       </Shape>
  278.                 </Transform>                
  279.                 
  280.                 <Transform DEF='ExamineSensor' translation='0 7 -5'>
  281.                   <Shape onclick="changeViewpoint('x3d_viewpoint_tour')">
  282.                     <Appearance>
  283.                       <Material ambientIntensity='0.1'></Material>
  284.                       <ImageTexture url='{{ textureArray['logo-texture-1'] }}'></ImageTexture>
  285.                       <TextureTransform scale='1 1'></TextureTransform>
  286.                     </Appearance>
  287.                     <Box size='3 3 3'></Box>
  288.                   </Shape>
  289.                 </Transform>            
  290.                 <TimeSensor DEF='userTime1' cycleInterval='25' cycleTime='1' elapsedTime='0' enabled='true' first='true' firstCycle='0.0' fraction_changed='0' isActive='false' isPaused='false' loop='false' metadata='X3DMetadataObject' pauseTime='0' resumeTime='0' startTime='0' stopTime='0' time='0' ></TimeSensor>
  291.                 <PositionInterpolator DEF='UserTranslation1' key='0 0.3 0.5 0.8 1.0' keyValue='-12 0.5 0 -2 0.5 {{ -((sideWallImageCount * 4) - 6) }} 12 0.5 {{ -((sideWallImageCount * 4) - 6) }} 12 0.5 0 -12 0.5 0'/></PositionInterpolator>
  292.                 <TimeSensor DEF='CLOCK' cycleInterval='{{ (imageTotalCount * 4) }}' loop='true' enabled='true'></TimeSensor>
  293.                 
  294.                 <!-- floor -->
  295.                 <Shape>
  296.                   <Appearance>
  297.                     <Material ambientIntensity='0.1'/></Material>
  298.                     <ImageTexture url='{{ textureArray['floor-texture-1'] }}'></ImageTexture>
  299.                     <TextureTransform scale='15 15'></TextureTransform>
  300.                   </Appearance>
  301.                   <IndexedFaceSet solid='false' coordIndex='0 1 2 3 -1'>
  302.                     <Coordinate point='-20 0 15.3 20 0 15.3 20 0 -70 -20 0 -70'></Coordinate>
  303.                   </IndexedFaceSet>
  304.                 </Shape>
  305.                 <!-- ceil -->
  306.                 <Shape>
  307.                   <Appearance>
  308.                     <Material ambientIntensity='0.1'></Material>
  309.                     <ImageTexture url='{{ textureArray['ceil-texture-1'] }}'></ImageTexture>
  310.                     <TextureTransform scale='15 15'></TextureTransform>
  311.                   </Appearance>
  312.                   <IndexedFaceSet solid='false' coordIndex='0 1 2 3 -1'>
  313.                     <Coordinate point='-20 8.9 15.3 20 8.9 15.3 20 8.9 -70 -20 8.9 -70'></Coordinate>
  314.                   </IndexedFaceSet>
  315.                 </Shape>
  316.                 <!-- back wall -->
  317.                 <Transform translation='0 4.6 15.3'>
  318.                   <Shape>
  319.                     <Appearance>
  320.                       <Material ambientIntensity='0.1'></Material>
  321.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  322.                       <TextureTransform scale='7 2'></TextureTransform>
  323.                     </Appearance>
  324.                     <Box size='40 9.2 0.4'></Box>
  325.                   </Shape>
  326.                 </Transform>
  327.                 <!-- front wall - bottom -->
  328.                 <Transform translation='0 0.8 -69.8'>
  329.                   <Shape>
  330.                     <Appearance>
  331.                       <Material ambientIntensity='0.1'></Material>
  332.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  333.                       <TextureTransform scale='15 0.7'></TextureTransform>
  334.                     </Appearance>
  335.                     <Box size='40 2.2 0.4'></Box>
  336.                   </Shape>
  337.                 </Transform>
  338.                 <!-- front wall - top -->
  339.                 <Transform translation='0 8.4 -69.8'>
  340.                   <Shape>
  341.                     <Appearance>
  342.                       <Material ambientIntensity='0.1'></Material>
  343.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  344.                       <TextureTransform scale='15 0.7'></TextureTransform>
  345.                     </Appearance>
  346.                     <Box size='40 2.2 0.4'></Box>
  347.                   </Shape>
  348.                 </Transform>
  349.                 <!-- front left column -->
  350.                 <Transform translation='-20 4.6 -69.8'>
  351.                   <Shape>
  352.                     <Appearance>
  353.                       <Material ambientIntensity='0.1'></Material>
  354.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  355.                       <TextureTransform scale='0.5 2'/>
  356.                     </Appearance>
  357.                     <Box size='1.5 9.2 1.5'></Box>
  358.                   </Shape>
  359.                 </Transform>
  360.                 <!-- front right column -->
  361.                 <Transform translation='-20 4.6 -25.8'>
  362.                   <Shape>
  363.                     <Appearance>
  364.                       <Material ambientIntensity='0.1'></Material>
  365.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  366.                       <TextureTransform scale='0.5 2'/>
  367.                     </Appearance>
  368.                     <Box size='1.5 9.2 1.5'></Box>
  369.                   </Shape>
  370.                 </Transform>
  371.                 <!-- left column -->
  372.                 <Transform translation='20 4.6 -69.8'>
  373.                   <Shape>
  374.                     <Appearance>
  375.                       <Material ambientIntensity='0.1'></Material>
  376.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  377.                       <TextureTransform scale='0.5 2'/>
  378.                     </Appearance>
  379.                     <Box size='1.5 9.2 1.5'></Box>
  380.                   </Shape>
  381.                 </Transform>
  382.                 <!-- left column --> 
  383.                 <Transform translation='20 4.6 -25.8'>
  384.                   <Shape>
  385.                     <Appearance>
  386.                       <Material ambientIntensity='0.1'></Material>
  387.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  388.                       <TextureTransform scale='0.5 2'/>
  389.                     </Appearance>
  390.                     <Box size='1.5 9.2 1.5'></Box>
  391.                   </Shape>
  392.                 </Transform>
  393.                 <!-- right side wall -->
  394.                 <Transform translation='-20 0.8 -27.2'>
  395.                   <Shape>
  396.                     <Appearance>
  397.                       <Material ambientIntensity='0.1'></Material>
  398.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  399.                       <TextureTransform scale='15 0.7'></TextureTransform>
  400.                     </Appearance>
  401.                     <Box size='0.4 2.2 85'></Box>
  402.                   </Shape>
  403.                 </Transform>
  404.                 <!-- left side wall -->                
  405.                 <Transform translation='-20 8.4 -27.2'>
  406.                   <Shape>
  407.                     <Appearance>
  408.                       <Material ambientIntensity='0.1'></Material>
  409.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  410.                       <TextureTransform scale='15 0.7'></TextureTransform>
  411.                     </Appearance>
  412.                     <Box size='0.4 2.2 85'></Box>
  413.                   </Shape>
  414.                 </Transform>
  415.                 <Transform translation='0 0.25 -67.5'>
  416.                   <Shape>
  417.                     <Appearance>
  418.                       <Material diffuseColor='0 0 0'/>
  419.                       <ImageTexture url='""'/>
  420.                       <TextureTransform scale='15 2'/>
  421.                     </Appearance>
  422.                     <Box size='30 0.5 5'></Box>
  423.                   </Shape>
  424.                 </Transform>
  425.                 <Transform translation='0 0.25 -64.995'>
  426.                   <Shape>
  427.                     <Appearance>
  428.                       <Material diffuseColor='0 0 0'/>
  429.                     </Appearance>
  430.                     <Box size='30 0.5 0.01'></Box>
  431.                   </Shape>
  432.                 </Transform>
  433.                 <!-- Left side floor below images -->
  434.                 <Transform translation='-18.3 0.25 -27.2'>
  435.                   <Shape>
  436.                     <Appearance>
  437.                       <Material diffuseColor='0 0 0'/>
  438.                       <ImageTexture url='""'/>
  439.                       <TextureTransform scale='2 15'/>
  440.                     </Appearance>
  441.                     <Box size='4 0.5 85'></Box>
  442.                   </Shape>
  443.                 </Transform>
  444.                 <Transform translation='20 0.8 -27.2'>
  445.                   <Shape>
  446.                     <Appearance>
  447.                       <Material ambientIntensity='0.1'></Material>
  448.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  449.                       <TextureTransform scale='15 0.7'></TextureTransform>
  450.                     </Appearance>
  451.                     <Box size='0.4 2.2 85'></Box>
  452.                   </Shape>
  453.                 </Transform>
  454.                 <Transform translation='20 8.4 -27.2'>
  455.                   <Shape>
  456.                     <Appearance>
  457.                       <Material ambientIntensity='0.1'></Material>
  458.                       <ImageTexture url='{{ textureArray['wall-texture-1'] }}'></ImageTexture>
  459.                       <TextureTransform scale='15 0.7'></TextureTransform>
  460.                     </Appearance>
  461.                     <Box size='0.4 2.2 85'></Box>
  462.                   </Shape>
  463.                 </Transform>
  464.                 <!-- Right side floor below images -->
  465.                 <Transform translation='17.3 0.25 -27.2'>
  466.                   <Shape>
  467.                     <Appearance>
  468.                       <Material diffuseColor='0 0 0'/>
  469.                       <ImageTexture url='""'/>
  470.                       <TextureTransform scale='2 15'/>
  471.                     </Appearance>
  472.                     <Box size='5 0.5 85'></Box>
  473.                   </Shape>
  474.                 </Transform>
  475.                 <Transform translation='14.8 0.25 -27.2'>
  476.                   <Shape>
  477.                     <Appearance>
  478.                       <Material DEF='backgroundPanel' diffuseColor='0 0 0'/>
  479.                     </Appearance>
  480.                     <Box size='0.01 0.5 85'></Box>
  481.                   </Shape>
  482.                 </Transform>
  483.             
  484.               </Transform>
  485.             <Route fromNode="CLOCK" fromField ="fraction_changed" toNode="UserTranslation1" toField="set_fraction"> </Route> 
  486.             <Route fromNode="UserTranslation1" fromField ="value_changed" toNode="TourAvatarWrapper" toField="translation"> </Route>  
  487.         </scene>
  488.       </x3d>
  489.     </div>
  490.         
  491.         <script>
  492.             //we setup full screen 3d canvas
  493.             // var buttonResizeScreen = document.getElementById("button_defaultscreen");
  494.       //       buttonResizeScreen.click(); // this will trigger the click event
  495.               {% if isFullscreen is defined and isFullscreen %}
  496.                 {% set resizeButton = 'button_defaultscreen' %}
  497.             {% else %}
  498.                 $( document ).ready(function() {
  499.                 // alert( "ready!" );
  500.                     document.getElementById("button_defaultscreen").click(); 
  501.                 });
  502.             {% endif %}    
  503.         </script>
  504.