<DIV id=RTEContent>hello,</DIV>  <DIV>&nbsp;</DIV>  <DIV>I am trying to compute the volume enclosed between two surface by subtracting the z-buffers of the two surfaces. I am using parallel projection for the computation.</DIV>  <DIV>&nbsp;</DIV>  <DIV>I computed the z-buffer difference,&nbsp;This difference is relative to the viewport size set up.&nbsp;I have no idea how to convert this difference to a quantitative estimate of the voume. I have problems interpreting the z-buffer data.</DIV>  <DIV>&nbsp;</DIV>  <DIV>Firslty, how to set the orthographic projection in VTK ? i call vtkRenderer::ParallelProjectionOn and then invoke vtkRenderer::ResetCamera. Is this enough ? or is anything wrong.&nbsp; Because when i looked through the VTK code, i found glOrtho in vtkCamera::<FONT size=2>ComputePerspectiveTransform.</FONT></DIV>  <DIV>&nbsp;</DIV>  <DIV>How can i transform the z-buffer values to quantitative z-values of the geometry renderer ?</DIV>  <DIV>&nbsp;</DIV>  <DIV>I tried
 multiplying it with the inverse of the vrkCamera::GetViewTransformation matrix but it doesnt work.</DIV>  <DIV>&nbsp;</DIV>  <DIV>I also tried doing vtkCamera::ViewToWorld on the final difference but this still does not work.</DIV>  <DIV>&nbsp;</DIV>  <DIV>Can anyone tell me, how to transform the z-buffer difference to a quantitative estimate of the volume. </DIV>  <DIV>&nbsp;</DIV>  <DIV>Please Help !!!!!!!!</DIV>  <DIV>&nbsp;</DIV>  <DIV>Thanks in advance.</DIV>  <DIV>&nbsp;</DIV>  <DIV>Regards,</DIV>  <DIV>&nbsp;</DIV>  <DIV>Deepak</DIV>  <DIV>&nbsp;</DIV>  <DIV>&nbsp;</DIV>  <DIV>&nbsp;</DIV>  <DIV>**************************************************************************************************</DIV>  <DIV>&nbsp;</DIV>  <DIV>Here is the loop that computes the z-difference:</DIV>  <DIV>&nbsp;</DIV>  <DIV><FONT color=#0000ff size=2>  <div>double</FONT><FONT size=2> dblSphereVolume = 0.0;</FONT></div>  <div><FONT size=2>&nbsp;</div>  <div></FONT><FONT color=#0000ff
 size=2>for</FONT><FONT size=2>( </FONT><FONT color=#0000ff size=2>int</FONT><FONT size=2> i = 0 ; i &lt; wx ; i++ )</div>  <div>{</div>  <BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">  <div></FONT><FONT color=#0000ff size=2>for</FONT><FONT size=2>( </FONT><FONT color=#0000ff size=2>int</FONT><FONT size=2> j = 0 ; j &lt; wy ; j++ )</div>  <div>{</div>  <BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">  <div></FONT><FONT color=#0000ff size=2>long</FONT><FONT size=2> index = i * j;</div>  <div></FONT><FONT color=#0000ff size=2>float</FONT><FONT size=2> coons_depth, sphere_depth;</FONT></div>  <div><FONT size=2>&nbsp;</div>  <div></div>  <div></FONT><FONT color=#008000 size=2>// get hemi-sphere z</div></FONT><FONT size=2>  <div>sphere_depth = pSphereZBuffer[index];</div>  <div>&nbsp;</div>  <div></div>  <div></FONT><FONT color=#008000 size=2>// get z of the base plane of the hemisphere</FONT></div>  <div>&nbsp;</div>  <div><FONT size=2>coons_depth = pCoonsZBuffer[index];</div>  <div></div>
  <div></FONT><FONT color=#0000ff size=2></FONT>&nbsp;</div>  <div><FONT color=#0000ff size=2>double</FONT><FONT size=2> diff = ( coons_depth - sphere_depth );</div>  <div>dblSphereVolume += diff;</div></BLOCKQUOTE>  <div>}</div></BLOCKQUOTE>  <div>}</div>  <div>&nbsp;</div>  <div>printf( "\ncomputed Sphere volume = %f\n" , dblSphereVolume );</div></FONT></DIV><p>
        
                <hr size=1>Yahoo! Shopping<br> 
Find Great Deals on Holiday Gifts at <a href="http://us.rd.yahoo.com/mail_us/footer/shopping/*http://shopping.yahoo.com/;_ylc=X3oDMTE2bzVzaHJtBF9TAzk1OTQ5NjM2BHNlYwNtYWlsdGFnBHNsawNob2xpZGF5LTA1 
">Yahoo! Shopping</a>