<div dir="ltr">Thanks Kenji for trying out. Its not clear in the log why the build shader code crashed. <div>Also, I realized that you using Java bindings. Would it be possible to re-create this issue</div><div>with a small sample code and you send it to me? We do have two component and 4 component</div><div>test (dependent and independent). Please have a look here: <a href="https://github.com/Kitware/VTK/blob/master/Rendering/Volume/Testing/Cxx/TestGPURayCastTwoComponentsIndependent.cxx">https://github.com/Kitware/VTK/blob/master/Rendering/Volume/Testing/Cxx/TestGPURayCastTwoComponentsIndependent.cxx</a></div><div><br></div><div>and </div><div><br></div><div><a href="https://github.com/Kitware/VTK/blob/master/Rendering/Volume/Testing/Cxx/TestGPURayCastTwoComponentsDependent.cxx">https://github.com/Kitware/VTK/blob/master/Rendering/Volume/Testing/Cxx/TestGPURayCastTwoComponentsDependent.cxx</a><br></div><div><br></div><div><br></div><div>Thanks,</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Dec 7, 2015 at 3:41 PM, Kenji Tsumura <span dir="ltr"><<a href="mailto:kenji.tsumura@neosoftmedical.com" target="_blank">kenji.tsumura@neosoftmedical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="EN-US" link="blue" vlink="purple">
<div>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Hi Aashish,</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Thank you.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">I tried with vtkGPUVolumeRayCastMapper.
</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">An error occurs without setting IndependentComponentsOff.</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">It seems the error occurs in vtkOpenGLGPUVolumeRayCastMapper::BuildShader (See the attached file).</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d">Kenji</span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1f497d"> </span></p>
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Aashish Chaudhary [mailto:<a href="mailto:aashish.chaudhary@kitware.com" target="_blank">aashish.chaudhary@kitware.com</a>]
<br>
<b>Sent:</b> Monday, December 07, 2015 1:54 PM<br>
<b>To:</b> Kenji Tsumura<br>
<b>Cc:</b> <a href="mailto:vtkusers@vtk.org" target="_blank">vtkusers@vtk.org</a><br>
<b>Subject:</b> Re: [vtkusers] vtkVolumeProperty IndependentComponents On and Off</span></p><div><div class="h5">
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal"> </p>
<div>
<p class="MsoNormal">On Mon, Dec 7, 2015 at 12:19 PM, Kenji Tsumura <<a href="mailto:kenji.tsumura@neosoftmedical.com" target="_blank">kenji.tsumura@neosoftmedical.com</a>> wrote:</p>
<div>
<div>
<p class="MsoNormal">Hello,</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">I have 3D cardiac MRI data (magnitude data and velocity data), and would like to display the volume rendering of the two data.</p>
<p class="MsoNormal">I create vtkVolume with two components (first one is velocity data and second one is magnitude data) and use vtkSmartVolumeMapper.</p>
<p class="MsoNormal">When I set IndependentComponentsOn to the volume property, I can see what I want (refer to the first figure).</p>
<p class="MsoNormal">But this setting disables GPU rendering and it is slow.</p>
</div>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">I don't remember vtkSmartVolumeMapper has this logic, I will have a look. In the old GPU raycast mapper, there was some issue with independent components so may be that is the reason that smart volume mapper switched to fixed point ray
cast. </p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<div>
<p class="MsoNormal">Is there a particular reason you are using vtkSmartVolumeMapper? You can directly use GPUVolume RayCastMapper</p>
</div>
<div>
<p class="MsoNormal"> </p>
</div>
<blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<p class="MsoNormal">My understanding is that I have to use IndependentComponentsOff to make the mapper use GPU rendering.</p>
<p class="MsoNormal">When I set IndependentComponentsOff, only one color transfer function, and only one scalar opacity function to the volume property,</p>
<p class="MsoNormal">the magnitude data (the second component) is also color-coded (refer to the second figure).</p>
<p class="MsoNormal">I thought this contradicts the method comments of IndependentComponentsOn/ IndependentComponentsOff.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">“For 2 component data, the first is passed through the first color transfer function and the second component is passed through the first opacity transfer function.”</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Am I missing something?</p>
<p class="MsoNormal">Can I make the volume rendering look the same as using two components?</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">Thank you,</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">BTY, I use v6.3.0, OpenGL2.</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">-- </p>
<p class="MsoNormal">Kenji Tsumura</p>
<p class="MsoNormal"> </p>
<p class="MsoNormal">“The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you
are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited. If you have received this communication in error, please return it to the sender immediately and delete the original
message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.</p>
</div>
<p class="MsoNormal">Disclaimer: The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you
are hereby notified that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited. If you have received this communication in error, please return it to the sender immediately and delete the original
message and any copy of it from your computer system. If you have any questions concerning this message, please contact the sender.
</p>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" 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" 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" target="_blank">
http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a></p>
</blockquote>
</div>
<p class="MsoNormal"><br>
<br clear="all">
</p>
<div>
<p class="MsoNormal"> </p>
</div>
<p class="MsoNormal">-- </p>
<div>
<div>
<p class="MsoNormal"><i><span style="font-family:"Trebuchet MS","sans-serif"">| Aashish Chaudhary
<br>
| Technical Leader <br>
| Kitware Inc. </span></i></p>
<div>
<p class="MsoNormal"><i><span style="font-family:"Trebuchet MS","sans-serif"">| </span><a href="http://www.kitware.com/company/team/chaudhary.html" target="_blank">http://www.kitware.com/company/team/chaudhary.html</a></i></p>
</div>
</div>
</div>
</div>
</div>
</div></div></div><div><div class="h5">
Disclaimer: The information contained in this communication may be confidential, is intended only for the use of the recipient(s) named above, and may be legally privileged. If the reader of this message is not the intended recipient, you are hereby notified
that any dissemination, distribution, or copying of this communication, or any of its contents, is strictly prohibited. If you have received this communication in error, please return it to the sender immediately and delete the original message and any copy
of it from your computer system. If you have any questions concerning this message, please contact the sender.
</div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><font face="trebuchet ms, sans-serif"><i>| Aashish Chaudhary <br>| Technical Leader <br>| Kitware Inc. <br></i></font><div><i><font face="trebuchet ms, sans-serif">| </font><a href="http://www.kitware.com/company/team/chaudhary.html" target="_blank">http://www.kitware.com/company/team/chaudhary.html</a></i></div></div></div>
</div>