<div dir="ltr">Yes, the example data files are usually small, because they have to be delivered over the network. I don't think there is anything to prevent a large file from working locally - are you seeing particular errors with your data file? It could be it is just slow to load. Also, I was getting a blank window with some of the ParaView Glance examples with the nightly build - you might try the 'stable' build instead, which worked for me. <a href="https://kitware.github.io/paraview-glance/">https://kitware.github.io/paraview-glance/</a><div><br></div><div>I don't know why you are seeing the error in the paraview macro - it could be a version mismatch. I am not sure which version of ParaView is required.</div></div><br><div class="gmail_quote"><div dir="ltr">On Wed, Jul 11, 2018 at 10:29 AM Alexey Pechnikov <<a href="mailto:pechnikov@mobigroup.ru">pechnikov@mobigroup.ru</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Aron,</div><div><br></div><div>Thank you for the links! I just want to try it. As sample I have large enough 3D grid (~100MB) that I want to show it by vtk-js. I don't know how to work with large files by vtk-js... maybe need I use small reducted dataset for 3D preview and load full slices from server?</div><div><br></div><div><span style="font-size:12.8px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">I found aneurism.vti viewer at <a href="https://kitware.github.io/paraview-glance/nightly" target="_blank">https://kitware.github.io/paraview-glance/nightly</a> It looks very interesting but the used datafile is small here.</span></div><div><br></div><div><br></div>Sorry, the script doesn't work as Paraview macro:<div><br></div><div>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">ERROR: In /Users/kitware/dashboards/buildbot-slave/8275bd07/build/superbuild/paraview/src/VTK/Rendering/OpenGL2/vtkShaderProgram.cxx, line 445</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">vtkShaderProgram (0x60c00058d5b0): 1: #version 150</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">2: #ifdef GL_ES</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">3: #if __VERSION__ == 300</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">4: #define varying in</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">5: #ifdef GL_FRAGMENT_PRECISION_HIGH</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">6: precision highp float;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">7: precision highp sampler2D;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">8: precision highp sampler3D;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">9: #else</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">10: precision mediump float;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">11: precision mediump sampler2D;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">12: precision mediump sampler3D;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">13: #endif</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">14: #define texelFetchBuffer texelFetch</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">15: #define texture1D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">16: #define texture2D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">17: #define texture3D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">18: #endif // 300</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">19: #else // GL_ES</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">20: #define highp</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">21: #define mediump</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">22: #define lowp</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">23: #if __VERSION__ == 150</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">24: #define varying in</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">25: #define texelFetchBuffer texelFetch</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">26: #define texture1D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">27: #define texture2D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">28: #define texture3D texture</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">29: #endif</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">30: #if __VERSION__ == 120</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">31: #extension GL_EXT_gpu_shader4 : require</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">32: #endif</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">33: #endif // GL_ES</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">34: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">35: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">36: /*=========================================================================</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">37: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">38: Program: Visualization Toolkit</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">39: Module: raycasterfs.glsl</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">40: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">41: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">42: All rights reserved.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">43: See Copyright.txt or <a href="http://www.kitware.com/Copyright.htm" target="_blank">http://www.kitware.com/Copyright.htm</a> for details.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">44: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">45: This software is distributed WITHOUT ANY WARRANTY; without even</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">46: the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">47: PURPOSE. See the above copyright notice for more information.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">48: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">49: =========================================================================*/</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">50: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">51: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">52: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">53: /// Inputs</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">54: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">55: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">56: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">57: /// 3D texture coordinates form vertex shader</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">58: varying vec3 ip_textureCoords;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">59: varying vec3 ip_vertexPos;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">60: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">61: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">62: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">63: /// Outputs</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">64: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">65: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">66: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">67: vec4 g_fragColor = vec4(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">68: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">69: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">70: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">71: /// Uniforms, attributes, and globals</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">72: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">73: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">74: vec3 g_dataPos;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">75: vec3 g_dirStep;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">76: vec4 g_srcColor;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">77: vec4 g_eyePosObj;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">78: bool g_exit;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">79: bool g_skip;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">80: float g_currentT;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">81: float g_terminatePointMax;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">82: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">83: out vec4 fragOutput0;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">84: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">85: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">86: uniform sampler3D in_volume[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">87: uniform vec4 in_volume_scale[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">88: uniform vec4 in_volume_bias[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">89: uniform int in_noOfComponents;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">90: uniform int in_independentComponents;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">91: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">92: uniform sampler2D in_noiseSampler;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">93: #ifndef GL_ES</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">94: uniform sampler2D in_depthSampler;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">95: #endif</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">96: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">97: // Camera position</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">98: uniform vec3 in_cameraPos;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">99: uniform mat4 in_volumeMatrix[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">100: uniform mat4 in_inverseVolumeMatrix[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">101: uniform mat4 in_textureDatasetMatrix[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">102: uniform mat4 in_inverseTextureDatasetMatrix[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">103: uniform mat4 in_textureToEye[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">104: uniform vec3 in_texMin[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">105: uniform vec3 in_texMax[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">106: uniform mat4 in_cellToPoint[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">107: // view and model matrices</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">108: uniform mat4 in_projectionMatrix;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">109: uniform mat4 in_inverseProjectionMatrix;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">110: uniform mat4 in_modelViewMatrix;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">111: uniform mat4 in_inverseModelViewMatrix;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">112: varying mat4 ip_inverseTextureDataAdjusted;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">113: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">114: // Ray step size</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">115: uniform vec3 in_cellStep[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">116: uniform vec2 in_scalarsRange[4];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">117: uniform vec3 in_cellSpacing[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">118: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">119: // Sample distance</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">120: uniform float in_sampleDistance;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">121: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">122: // Scales</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">123: uniform vec2 in_windowLowerLeftCorner;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">124: uniform vec2 in_inverseOriginalWindowSize;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">125: uniform vec2 in_inverseWindowSize;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">126: uniform vec3 in_textureExtentsMax;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">127: uniform vec3 in_textureExtentsMin;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">128: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">129: // Material and lighting</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">130: uniform vec3 in_diffuse[4];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">131: uniform vec3 in_ambient[4];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">132: uniform vec3 in_specular[4];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">133: uniform float in_shininess[4];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">134: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">135: // Others</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">136: uniform bool in_useJittering;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">137: vec3 g_rayJitter = vec3(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">138: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">139: uniform vec2 in_averageIPRange;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">140: uniform vec3 in_lightAmbientColor[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">141: uniform vec3 in_lightDiffuseColor[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">142: uniform vec3 in_lightSpecularColor[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">143: vec4 g_lightPosObj;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">144: vec3 g_ldir;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">145: vec3 g_vdir;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">146: vec3 g_h;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">147: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">148: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">149: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">150: const float g_opacityThreshold = 1.0 - 1.0 / 255.0;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">151: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">152: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">153: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">154: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">155: int clippingPlanesSize; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">156: vec3 objRayDir; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">157: mat4 textureToObjMat;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">158: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">159: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">160: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">161: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">162: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">163: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">164: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">165: //VTK::GradientCache::Dec</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">166: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">167: //VTK::Transfer2D::Dec</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">168: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">169: uniform sampler2D in_opacityTransferFunc_0[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">170: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">171: float computeOpacity(vec4 scalar) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">172: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">173: return texture2D(in_opacityTransferFunc_0[0], vec2(scalar.w, 0)).r; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">174: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">175: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">176: vec4 computeGradient(in vec3 texPos, in int c, in sampler3D volume, in int index)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">177: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">178: return vec4(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">179: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">180: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">181: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">182: uniform sampler2D [1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">183: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">184: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">185: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">186: vec4 computeLighting(vec4 color, int component) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">187: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">188: vec4 finalColor = vec4(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">189: finalColor = vec4(color.rgb, 0.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">190: finalColor.a = color.a; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">191: return finalColor; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">192: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">193: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">194: uniform sampler2D in_colorTransferFunc_0[1];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">195: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">196: vec4 computeColor(vec4 scalar, float opacity) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">197: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">198: return computeLighting(vec4(texture2D(in_colorTransferFunc_0[0], </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">199: vec2(scalar.w, 0.0)).xyz, opacity), 0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">200: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">201: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">202: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">203: vec3 computeRayDirection() </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">204: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">205: return normalize(ip_vertexPos.xyz - g_eyePosObj.xyz); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">206: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">207: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">208: //VTK::Picking::Dec</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">209: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">210: //VTK::RenderToImage::Dec</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">211: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">212: //VTK::DepthPeeling::Dec</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">213: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">214: /// We support only 8 clipping planes for now</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">215: /// The first value is the size of the data array for clipping</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">216: /// planes (origin, normal)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">217: uniform float in_clippingPlanes[49];</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">218: uniform float in_scale;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">219: uniform float in_bias;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">220: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">221: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">222: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">223: /// Helper functions</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">224: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">225: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">226: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">227: /**</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">228: * Transform window coordinate to NDC.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">229: */</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">230: vec4 WindowToNDC(const float xCoord, const float yCoord, const float zCoord)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">231: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">232: vec4 NDCCoord = vec4(0.0, 0.0, 0.0, 1.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">233: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">234: NDCCoord.x = (xCoord - in_windowLowerLeftCorner.x) * 2.0 *</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">235: in_inverseWindowSize.x - 1.0;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">236: NDCCoord.y = (yCoord - in_windowLowerLeftCorner.y) * 2.0 *</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">237: in_inverseWindowSize.y - 1.0;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">238: NDCCoord.z = (2.0 * zCoord - (gl_DepthRange.near + gl_DepthRange.far)) /</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">239: gl_DepthRange.diff;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">240: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">241: return NDCCoord;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">242: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">243: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">244: /**</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">245: * Transform NDC coordinate to window coordinates.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">246: */</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">247: vec4 NDCToWindow(const float xNDC, const float yNDC, const float zNDC)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">248: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">249: vec4 WinCoord = vec4(0.0, 0.0, 0.0, 1.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">250: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">251: WinCoord.x = (xNDC + 1.f) / (2.f * in_inverseWindowSize.x) +</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">252: in_windowLowerLeftCorner.x;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">253: WinCoord.y = (yNDC + 1.f) / (2.f * in_inverseWindowSize.y) +</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">254: in_windowLowerLeftCorner.y;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">255: WinCoord.z = (zNDC * gl_DepthRange.diff +</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">256: (gl_DepthRange.near + gl_DepthRange.far)) / 2.f;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">257: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">258: return WinCoord;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">259: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">260: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">261: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">262: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">263: /// Ray-casting</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">264: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">265: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">266: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">267: /**</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">268: * Global initialization. This method should only be called once per shader</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">269: * invocation regardless of whether castRay() is called several times (e.g.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">270: * vtkDualDepthPeelingPass). Any castRay() specific initialization should be</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">271: * placed within that function.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">272: */</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">273: void initializeRayCast()</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">274: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">275: /// Initialize g_fragColor (output) to 0</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">276: g_fragColor = vec4(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">277: g_dirStep = vec3(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">278: g_srcColor = vec4(0.0);</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">279: g_exit = false;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">280: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">281: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">282: // Get the 3D texture coordinates for lookup into the in_volume dataset </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">283: g_dataPos = ip_textureCoords.xyz; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">284: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">285: // Eye position in dataset space </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">286: g_eyePosObj = in_inverseVolumeMatrix[0] * vec4(in_cameraPos, 1.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">287: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">288: // Getting the ray marching direction (in dataset space); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">289: vec3 rayDir = computeRayDirection(); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">290: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">291: // Multiply the raymarching direction with the step size to get the </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">292: // sub-step size we need to take at each raymarching step </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">293: g_dirStep = (ip_inverseTextureDataAdjusted * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">294: vec4(rayDir, 0.0)).xyz * in_sampleDistance; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">295: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">296: // 2D Texture fragment coordinates [0,1] from fragment coordinates. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">297: // The frame buffer texture has the size of the plain buffer but </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">298: // we use a fraction of it. The texture coordinate is less than 1 if </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">299: // the reduction factor is less than 1. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">300: // Device coordinates are between -1 and 1. We need texture </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">301: // coordinates between 0 and 1. The in_noiseSampler and in_depthSampler </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">302: // buffers have the original size buffer. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">303: vec2 fragTexCoord = (gl_FragCoord.xy - in_windowLowerLeftCorner) * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">304: in_inverseWindowSize; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">305: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">306: if (in_useJittering) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">307: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">308: float jitterValue = texture2D(in_noiseSampler, fragTexCoord).x; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">309: g_rayJitter = g_dirStep * jitterValue; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">310: g_dataPos += g_rayJitter; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">311: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">312: else </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">313: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">314: g_dataPos += g_dirStep; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">315: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">316: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">317: // Flag to deternmine if voxel should be considered for the rendering </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">318: g_skip = false;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">319: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">320: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">321: // Flag to indicate if the raymarch loop should terminate </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">322: bool stop = false; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">323: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">324: g_terminatePointMax = 0.0; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">325: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">326: #ifdef GL_ES </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">327: vec4 l_depthValue = vec4(1.0,1.0,1.0,1.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">328: #else </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">329: vec4 l_depthValue = texture2D(in_depthSampler, fragTexCoord); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">330: #endif </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">331: // Depth test </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">332: if(gl_FragCoord.z >= l_depthValue.x) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">333: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">334: discard; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">335: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">336: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">337: // color buffer or max scalar buffer have a reduced size. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">338: fragTexCoord = (gl_FragCoord.xy - in_windowLowerLeftCorner) * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">339: in_inverseOriginalWindowSize; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">340: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">341: // Compute max number of iterations it will take before we hit </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">342: // the termination point </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">343: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">344: // Abscissa of the point on the depth buffer along the ray. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">345: // point in texture coordinates </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">346: vec4 terminatePoint = WindowToNDC(gl_FragCoord.x, gl_FragCoord.y, l_depthValue.x); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">347: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">348: // From normalized device coordinates to eye coordinates. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">349: // in_projectionMatrix is inversed because of way VT </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">350: // From eye coordinates to texture coordinates </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">351: terminatePoint = ip_inverseTextureDataAdjusted * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">352: in_inverseVolumeMatrix[0] * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">353: in_inverseModelViewMatrix * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">354: in_inverseProjectionMatrix * </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">355: terminatePoint; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">356: terminatePoint /= terminatePoint.w; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">357: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">358: g_terminatePointMax = length(terminatePoint.xyz - g_dataPos.xyz) / </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">359: length(g_dirStep); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">360: g_currentT = 0.0;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">361: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">362: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">363: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">364: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">365: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">366: //VTK::RenderToImage::Init</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">367: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">368: //VTK::DepthPass::Init</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">369: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">370: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">371: /**</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">372: * March along the ray direction sampling the volume texture. This function</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">373: * takes a start and end point as arguments but it is up to the specific render</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">374: * pass implementation to use these values (e.g. vtkDualDepthPeelingPass). The</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">375: * mapper does not use these values by default, instead it uses the number of</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">376: * steps defined by g_terminatePointMax.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">377: */</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">378: vec4 castRay(const float zStart, const float zEnd)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">379: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">380: //VTK::DepthPeeling::Ray::Init</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">381: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">382: //VTK::DepthPeeling::Ray::PathCheck</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">383: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">384: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">385: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">386: /// For all samples along the ray</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">387: while (!g_exit)</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">388: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">389: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">390: g_skip = false;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">391: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">392: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">393: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">394: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">395: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">396: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">397: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">398: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">399: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">400: //VTK::PreComputeGradients::Impl</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">401: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">402: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">403: if (!g_skip) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">404: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">405: vec4 scalar = texture3D(in_volume[0], g_dataPos); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">406: scalar.r = scalar.r * in_volume_scale[0].r + in_volume_bias[0].r; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">407: scalar = vec4(scalar.r); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">408: g_srcColor = vec4(0.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">409: g_srcColor.a = computeOpacity(scalar); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">410: if (g_srcColor.a > 0.0) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">411: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">412: g_srcColor = computeColor(scalar, g_srcColor.a); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">413: // Opacity calculation using compositing: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">414: // Here we use front to back compositing scheme whereby </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">415: // the current sample value is multiplied to the </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">416: // currently accumulated alpha and then this product </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">417: // is subtracted from the sample value to get the </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">418: // alpha from the previous steps. Next, this alpha is </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">419: // multiplied with the current sample colour </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">420: // and accumulated to the composited colour. The alpha </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">421: // value from the previous steps is then accumulated </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">422: // to the composited colour alpha. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">423: g_srcColor.rgb *= g_srcColor.a; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">424: g_fragColor = (1.0f - g_fragColor.a) * g_srcColor + g_fragColor; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">425: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">426: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">427: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">428: //VTK::RenderToImage::Impl</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">429: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">430: //VTK::DepthPass::Impl</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">431: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">432: /// Advance ray</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">433: g_dataPos += g_dirStep;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">434: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">435: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">436: if(any(greaterThan(g_dataPos, in_texMax[0])) || </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">437: any(lessThan(g_dataPos, in_texMin[0]))) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">438: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">439: break; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">440: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">441: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">442: // Early ray termination </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">443: // if the currently composited colour alpha is already fully saturated </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">444: // we terminated the loop or if we have hit an obstacle in the </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">445: // direction of they ray (using depth buffer) we terminate as well. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">446: if((g_fragColor.a > g_opacityThreshold) || </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">447: g_currentT >= g_terminatePointMax) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">448: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">449: break; </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">450: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">451: ++g_currentT;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">452: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">453: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">454: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">455: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">456: return g_fragColor;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">457: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">458: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">459: /**</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">460: * Finalize specific modes and set output data.</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">461: */</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">462: void finalizeRayCast()</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">463: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">464: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">465: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">466: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">467: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">468: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">469: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">470: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">471: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">472: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">473: // Special coloring mode which renders the voxel index in fragments that </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">474: // have accumulated certain level of opacity. Used during the selection </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">475: // pass vtkHardwareSelection::ID_MID24. </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">476: if (g_fragColor.a > 3.0/ 255.0) </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">477: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">478: uvec3 volumeDim = uvec3(in_textureExtentsMax - in_textureExtentsMin); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">479: uvec3 voxelCoords = uvec3(volumeDim * g_dataPos); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">480: // vtkHardwareSelector assumes index 0 to be empty space, so add uint(1). </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">481: uint idx = volumeDim.x * volumeDim.y * voxelCoords.z + </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">482: volumeDim.x * voxelCoords.y + voxelCoords.x + uint(1); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">483: idx = ((idx & 0xff000000) >> 24); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">484: fragOutput0 = vec4(float(idx % uint(256)) / 255.0, </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">485: float((idx / uint(256)) % uint(256)) / 255.0, </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">486: float(idx / uint(65536)) / 255.0, 1.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">487: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">488: else </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">489: { </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">490: fragOutput0 = vec4(0.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">491: } </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">492: return;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">493: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">494: g_fragColor.r = g_fragColor.r * in_scale + in_bias * g_fragColor.a;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">495: g_fragColor.g = g_fragColor.g * in_scale + in_bias * g_fragColor.a;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">496: g_fragColor.b = g_fragColor.b * in_scale + in_bias * g_fragColor.a;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">497: fragOutput0 = g_fragColor;</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">498: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">499: //VTK::RenderToImage::Exit</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">500: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">501: //VTK::DepthPass::Exit</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">502: }</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">503: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">504: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">505: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">506: /// Main</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">507: ///</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">508: //////////////////////////////////////////////////////////////////////////////</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">509: void main()</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">510: {</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">511: </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">512: initializeRayCast(); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">513: castRay(-1.0, -1.0); </span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">514: finalizeRayCast();</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">515: }</span></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">ERROR: In /Users/kitware/dashboards/buildbot-slave/8275bd07/build/superbuild/paraview/src/VTK/Rendering/OpenGL2/vtkShaderProgram.cxx, line 446</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">vtkShaderProgram (0x60c00058d5b0): ERROR: 0:483: '&' does not operate on 'unsigned int' and 'int'</span></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">ERROR: In /Users/kitware/dashboards/buildbot-slave/8275bd07/build/superbuild/paraview/src/VTK/Rendering/VolumeOpenGL2/vtkOpenGLGPUVolumeRayCastMapper.cxx, line 3169</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">vtkOpenGLGPUVolumeRayCastMapper (0x7fc085e21f60): Shader failed to compile</span></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">Traceback (most recent call last):</span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)"> File "<string>", line 450, in <module></span></p>
<p style="margin:0px;white-space:pre-wrap"><span style="font-family:Courier;font-size:13pt;color:rgb(128,0,0)">AttributeError: 'vtkCommonDataModelPython.vtkImageData' object has no attribute 'GetPoints'</span></p>
<p style="margin:0px;font-family:Courier;font-size:13pt;color:rgb(128,0,0);white-space:pre-wrap"><br></p><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">2018-07-11 21:08 GMT+07:00 Aron Helser <span dir="ltr"><<a href="mailto:aron.helser@kitware.com" target="_blank">aron.helser@kitware.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Adding back the mailing list....<div><br></div><div>Alexey,</div><div>Do you have a particular goal, or do you just want to try out vtk-js? If you just want to see what it can do, it is used the rendering in ParaView Glance, which you can try out here:</div><div><a href="https://kitware.github.io/paraview-glance/nightly/" target="_blank">https://kitware.github.io/paraview-glance/nightly/</a><br></div><div>It will load several different data formats, or just start with the example datasets. As you can see, vtk-js is used for real and useful projects.</div><div><br></div><div>For just VTK-js, the example applications like the OBJ viewer: <a href="https://kitware.github.io/vtk-js/examples/OBJViewer.html" target="_blank">https://kitware.github.io/vtk-js/examples/OBJViewer.html</a></div><div>are a good starting point - there are several that will load different formats of data.</div><div><br></div><div>The script I pointed you at is a ParaView macro, which means that after running the ParaView application, you add it by going to the Macro menu and choosing 'Add new macro...'</div><div><br></div><div>Regards,</div><div>Aron</div></div><div class="m_2944799589630577414HOEnZb"><div class="m_2944799589630577414h5"><br><div class="gmail_quote"><div dir="ltr">On Wed, Jul 11, 2018 at 9:59 AM Alexey Pechnikov <<a href="mailto:pechnikov@mobigroup.ru" target="_blank">pechnikov@mobigroup.ru</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Aron,<div><br></div><div>That script doesn't work in python2/python3 (there is no paraview extension) and it doesn't work in internal Paraview Python shell. Maybe do you know some working way? Or do you mean I need to write my own script using this one instead of normal documentation? Is vtk-js used by somebody or it's only just to fun unuseful project? Maybe I don't need to try it actually.</div></div><div class="gmail_extra"><br><div class="gmail_quote">2018-07-11 20:16 GMT+07:00 Aron Helser <span dir="ltr"><<a href="mailto:aron.helser@kitware.com" target="_blank">aron.helser@kitware.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi Alexey,<div>This example: <a href="https://kitware.github.io/vtk-js/examples/StandaloneSceneLoader.html" target="_blank">https://kitware.github.io/vtk-js/examples/StandaloneSceneLoader.html</a></div><div>references this macro from vtk-js: Utilities/ParaView/export-scene-macro.py</div><div>It can be used to export a scene from ParaView for consumption by vtk-js. </div><div><br></div><div>I know there are other ways to do it as well, but that was the easiest.</div><div>HTH,</div><div>Aron</div></div><br><div class="gmail_quote"><div><div class="m_2944799589630577414m_-4439136373360282098m_6752255536829370604h5"><div dir="ltr">On Wed, Jul 11, 2018 at 5:54 AM Alexey Pechnikov <<a href="mailto:pechnikov@mobigroup.ru" target="_blank">pechnikov@mobigroup.ru</a>> wrote:<br></div></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="m_2944799589630577414m_-4439136373360282098m_6752255536829370604h5"><div dir="ltr">Hi,<div><br></div><div>I couldn't find any documentation or tool to do it. Google doesn't know anything about "vti-web" data format. VTK/VTI and other VTK formats are not allowed I see. Is disassembling example datasets and build own tools the only possible way?!<br clear="all"><div><br></div>-- <br><div class="m_2944799589630577414m_-4439136373360282098m_6752255536829370604m_728893885673327684m_181269064484301796gmail_signature"><div dir="ltr"><div>Best regards, Alexey Pechnikov.<br></div></div></div>
</div></div></div></div>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">https://public.kitware.com/mailman/listinfo/vtkusers</a><br>
</blockquote></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_2944799589630577414m_-4439136373360282098m_6752255536829370604gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Best regards, Alexey Pechnikov.<br></div></div></div>
</div>
</blockquote></div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="m_2944799589630577414gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>Best regards, Alexey Pechnikov.<br></div></div></div>
</div>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">https://public.kitware.com/mailman/listinfo/vtkusers</a><br>
</blockquote></div>