<div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif">Hi all</div><div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif">
<br></div><div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif">In one of our application, we need to perform a fusion between interventional fluoroscopic images and preoperative CT scan. <br>
In order to achieve this, a reverse perspective ray cast volume rendering is needed. This means we have to reverse the way x-ray are thrown (from the focal point to the camera, and not the opposite).<br>The main principle is explained <a href="http://imgur.com/SmnDwPn" style="color:rgb(17,85,204)" target="_blank">on this figure</a> (found on this article: <a href="http://link.springer.com/content/pdf/10.1007%2F978-3-642-21504-9_2.pdf" style="color:rgb(17,85,204)" target="_blank">http://link.springer.com/content/pdf/10.1007%2F978-3-642-21504-9_2.pdf</a> )</div>
<div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif"><br></div><div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif">
We were able to achieve this with the vtkFixedVolumeRayCastMapper, by switching the lines 1788 and 1792 on the file vtkFixedVolumeRayCastMapper.cxx of vtk 5.10.1</div><div style="color:rgb(34,34,34);font-size:12.727272033691406px;font-family:arial,sans-serif">
<div>the code : </div><div>/*********************************************************************/</div><div> viewRay[2] = 0.0;</div><div><div> vtkVRCMultiplyPointMacro( viewRay, rayStart,</div><div> this->ViewToVoxelsArray );</div>
</div><div> viewRay[2] = this->RayCastImage->GetZBufferValue(x,y);</div><div>/*********************************************************************/</div><div>became :</div><div>/*********************************************************************/</div>
<div><div> viewRay[2] = this->RayCastImage->GetZBufferValue(x,y);</div><div> vtkVRCMultiplyPointMacro( viewRay, rayStart,</div><div> this->ViewToVoxelsArray );</div><div> viewRay[2] = 0.0;</div>
</div><div>/*********************************************************************/</div><div><br></div><div>The resulting images are these ones :<br>* <a href="http://imgur.com/Aoe9VxV,HfiwFU3,uaki4f6,UFXS9pH#0" style="color:rgb(17,85,204)" target="_blank">Normal-Perspective View 1</a></div>
<div>* <a href="http://imgur.com/Aoe9VxV,HfiwFU3,uaki4f6,UFXS9pH#1" style="color:rgb(17,85,204)" target="_blank">Reverse-Perspective View 1</a></div><div><div>* <a href="http://imgur.com/Aoe9VxV,HfiwFU3,uaki4f6,UFXS9pH#2" style="color:rgb(17,85,204)" target="_blank">Normal-Perspective View 2</a></div>
<div>* <a href="http://imgur.com/Aoe9VxV,HfiwFU3,uaki4f6,UFXS9pH#3" style="color:rgb(17,85,204)" target="_blank">Reverse-Perspective View 2</a></div></div><div><br></div><div>Which is exactly what we are trying to do.</div>
<div><br></div><div>Now we want to do the same with the vtkGPUVolumeRayCastMapper. I've tried to hack the following files, especially the function trace() and incrementalRayDirection() without success</div><div>vtkGPUVolumeRayCastMapper_CompositeFS.glsl</div>
<div>vtkGPUVolumeRayCastMapper_HeaderFS.glsl</div><div>vtkGPUVolumeRayCastMapper_PerspectiveProjectionFS.glsl</div><div><br></div><div>Does anyone has a clue on this ?<br><br></div><div>Thanks for reading, sorry for the frenglish</div>
</div><div><br></div>-- <br>------------------------------------------------------------------<br>Simon Esneault<div>13 rue Vasselot<br>35000 Rennes, France<br>Tel : 06 64 61 30 94<br>Mail : <a href="mailto:simon.esneault@gmail.com" target="_blank">simon.esneault@gmail.com</a><br>
------------------------------------------------------------------</div>