<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
{font-family:Tahoma;
panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0in;
margin-bottom:.0001pt;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
{mso-style-name:msonormal;
mso-margin-top-alt:auto;
margin-right:0in;
mso-margin-bottom-alt:auto;
margin-left:0in;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
span.EmailStyle18
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;}
.MsoChpDefault
{mso-style-type:export-only;
font-family:"Calibri",sans-serif;}
@page WordSection1
{size:8.5in 11.0in;
margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal">Hi Elvis and Ken,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Thanks for the help. What it seems to start to work for me, is to use layered renderers: using two renderers, and using the first for my volume and the second for the plane. Currently I’m dealing with the depth buffer definition as I couldn’t
find its definition yet in VTK code, but so far, I could draw some extent of the translucent plane in front and the other back.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">I think that by fixing the depth buffer definition in my code, I would be able to mimic this behavior. I will poke you again if I succeed.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Cheers,<o:p></o:p></p>
<p class="MsoNormal">Pato<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><b>From:</b> Ken Martin <ken.martin@kitware.com> <br>
<b>Sent:</b> Tuesday, October 23, 2018 2:41 PM<br>
<b>To:</b> Elvis Stansvik <elvis.stansvik@orexplore.com><br>
<b>Cc:</b> patricio.sandana@synopsys.com; vtkusers@public.kitware.com<br>
<b>Subject:</b> Re: [vtkusers] Drawing custom image with depth buffer and a translucent plane<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<div>
<p class="MsoNormal">Maybe from vtkRenderer.h<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">/**<br>
* This flag is on and the GPU supports it, depth-peel volumes along with<br>
* the translucent geometry. Only supported on OpenGL2 with dual-depth<br>
* peeling. Default is false.<br>
*/<br>
vtkSetMacro(UseDepthPeelingForVolumes, bool)<br>
vtkGetMacro(UseDepthPeelingForVolumes, bool)<br>
vtkBooleanMacro(UseDepthPeelingForVolumes, bool)<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</div>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal">On Tue, Oct 23, 2018 at 1:32 PM, Elvis Stansvik <<a href="mailto:elvis.stansvik@orexplore.com" target="_blank">elvis.stansvik@orexplore.com</a>> wrote:<o:p></o:p></p>
<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">I believe this is a limitation of VTK. Translucent polygonal geometry with opacity != 1.0 can't be rendered intersected with a volume other than in a back-to-front or front-to-back manner.<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Someone correct me if I'm wrong (we'd also very much like to be able to do this).<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Elvis<o:p></o:p></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<div>
<p class="MsoNormal">Den fre 12 okt. 2018 kl 22:20 skrev Pato Sandana <<a href="mailto:patricio.sandana@synopsys.com" target="_blank">patricio.sandana@synopsys.com</a>>:<o:p></o:p></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" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Hi Everyone,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">I’m trying to draw a vtkVolume and a vtkPlaneWidget both intersecting and the vtkPlaneWidget is translucent. I cannot achieve that, either the plane is totally behind or front.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">For a vtkActor with the same box extent this works.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">I tried to get the z-buffer from the context using vtkRenderer::GetZbufferData() method, but I only get 1s. (Is this correct?)<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">I also tried to write the z-buffer data I got with vtkRenderer::SetZbuferData() method, but the plane is still behind.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Any hints how to achieve this? Thanks in advance.<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Regards,<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><b> </b><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><b>Pato Sandaña</b><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">TCAD Senior R&D Engineer<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto">Synopsys Inc. – Santiago, Chile<o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"> <o:p></o:p></p>
</div>
</div>
<p class="MsoNormal">_______________________________________________<br>
Powered by <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.kitware.com&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=XFmKip7WnJXNfMt0qWXfHTPW3KqefkWdTfPDs3YY46c&e=" target="_blank">
www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.kitware.com_opensource_opensource.html&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=LC5-bdzymVGJcfcZ8AmBvZV23ae97y-hm6Pct12_zxg&e=" 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="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.vtk.org_Wiki_VTK-5FFAQ&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=hpcCAyecmkOzC4d70a2q6Y_FYXreBDtqbJQnC5NHkXM&e=" target="_blank">
http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__markmail.org_search_-3Fq-3Dvtkusers&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=Amad8dQw8EgKfNC8jg3toPrkaQO4ZgKeMUE77DzqQLY&e=" target="_blank">
http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__public.kitware.com_mailman_listinfo_vtkusers&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=9m6365GhhGzxeN9vGEvPYTs58SJ60Il03Px2STQIVx0&e=" target="_blank">https://public.kitware.com/mailman/listinfo/vtkusers</a><o:p></o:p></p>
</blockquote>
</div>
<p class="MsoNormal" style="margin-bottom:12.0pt"><br>
_______________________________________________<br>
Powered by <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.kitware.com&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=XFmKip7WnJXNfMt0qWXfHTPW3KqefkWdTfPDs3YY46c&e=" target="_blank">
www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.kitware.com_opensource_opensource.html&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=LC5-bdzymVGJcfcZ8AmBvZV23ae97y-hm6Pct12_zxg&e=" 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="https://urldefense.proofpoint.com/v2/url?u=http-3A__www.vtk.org_Wiki_VTK-5FFAQ&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=hpcCAyecmkOzC4d70a2q6Y_FYXreBDtqbJQnC5NHkXM&e=" target="_blank">
http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="https://urldefense.proofpoint.com/v2/url?u=http-3A__markmail.org_search_-3Fq-3Dvtkusers&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=Amad8dQw8EgKfNC8jg3toPrkaQO4ZgKeMUE77DzqQLY&e=" target="_blank">
http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="https://urldefense.proofpoint.com/v2/url?u=https-3A__public.kitware.com_mailman_listinfo_vtkusers&d=DwMFaQ&c=DPL6_X_6JkXFx7AXWqB0tg&r=RTHchWjhlQtHtkpaYSjNSag78sFhFdYa6LnDJBrNgcw&m=PCPOgau_FL4YOvrfw9MA94gcF8Jg95G0zsQctmjiS-E&s=9m6365GhhGzxeN9vGEvPYTs58SJ60Il03Px2STQIVx0&e=" target="_blank">https://public.kitware.com/mailman/listinfo/vtkusers</a><o:p></o:p></p>
</blockquote>
</div>
<p class="MsoNormal"><br>
<br clear="all">
<br>
-- <o:p></o:p></p>
<div>
<div>
<div>
<div>
<div>
<p class="MsoNormal">Ken Martin PhD<o:p></o:p></p>
<div>
<p class="MsoNormal">Distinguished Engineer<br>
<span style="font-size:9.5pt">Kitware Inc.</span><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal" style="margin-bottom:12.0pt">101 East Weaver Street<br>
Carrboro, North Carolina<br>
27510 USA<o:p></o:p></p>
<div>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Tahoma",sans-serif">This communication, including all attachments, contains confidential and legally privileged information, and it is intended only for the use of the addressee. Access to this
email by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying, distribution or any action taken in reliance on it is prohibited and may be unlawful. If you received this communication in error please notify us immediately
and destroy the original message. Thank you.</span><o:p></o:p></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
</html>