<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="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<meta name=ProgId content=Word.Document>
<meta name=Generator content="Microsoft Word 9">
<meta name=Originator content="Microsoft Word 9">
<link rel=File-List href="cid:filelist.xml@01C79C91.06D7B7A0">
<link rel=Edit-Time-Data href="cid:editdata.mso@01C79C91.06D7B7A0">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><!--[if gte mso 9]><xml>
<o:OfficeDocumentSettings>
<o:DoNotRelyOnCSS/>
</o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:View>Normal</w:View>
<w:Zoom>0</w:Zoom>
<w:DocumentKind>DocumentEmail</w:DocumentKind>
<w:EnvelopeVis/>
</w:WordDocument>
</xml><![endif]-->
<style>
<!--
/* Font Definitions */
@font-face
{font-family:Wingdings;
panose-1:5 0 0 0 0 0 0 0 0 0;
mso-font-charset:2;
mso-generic-font-family:auto;
mso-font-pitch:variable;
mso-font-signature:0 268435456 0 0 -2147483648 0;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;
text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
{color:blue;
text-decoration:underline;
text-underline:single;}
p.MsoAutoSig, li.MsoAutoSig, div.MsoAutoSig
{margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
p
{margin-right:0in;
mso-margin-top-alt:auto;
mso-margin-bottom-alt:auto;
margin-left:0in;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
pre
{margin:0in;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
tab-stops:45.8pt 91.6pt 137.4pt 183.2pt 229.0pt 274.8pt 320.6pt 366.4pt 412.2pt 458.0pt 503.8pt 549.6pt 595.4pt 641.2pt 687.0pt 732.8pt;
font-size:10.0pt;
font-family:"Courier New";
mso-fareast-font-family:"Courier New";
mso-bidi-font-family:"Times New Roman";}
span.EmailStyle15
{mso-style-type:personal-compose;
mso-ansi-font-size:10.0pt;
mso-ascii-font-family:Arial;
mso-hansi-font-family:Arial;
mso-bidi-font-family:Arial;
color:black;}
@page Section1
{size:8.5in 11.0in;
margin:1.0in 1.25in 1.0in 1.25in;
mso-header-margin:.5in;
mso-footer-margin:.5in;
mso-paper-source:0;}
div.Section1
{page:Section1;}
/* List Definitions */
@list l0
{mso-list-id:2139453660;
mso-list-type:hybrid;
mso-list-template-ids:-1111178844 742394326 -1547279274 -1176568272 353019554 660357120 -792195018 1821540884 -1511199530 1381142212;}
@list l0:level1
{mso-level-number-format:bullet;
mso-level-text:\F0B7;
mso-level-tab-stop:.5in;
mso-level-number-position:left;
text-indent:-.25in;
mso-ansi-font-size:10.0pt;
font-family:Symbol;}
ol
{margin-bottom:0in;}
ul
{margin-bottom:0in;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=blue style='tab-interval:.5in'>
<div class=Section1>
<div style='border:none;border-bottom:double windowtext 2.25pt;padding:0in 0in 1.0pt 0in'><pre
style='border:none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;
mso-padding-alt:0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'>Hi David,</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'>I am using vtkPolyDataToImageStencil, and saw an earlier email thread as below.</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'>Most of the time I am getting good results but have same issue as Jesus. Would it be possible for you to send me a copy of another vtkPolyDataToImageStencil class you mentioned in your post?</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'>Thanks in advance,</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'>Frank Gao</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre style='border:
none;mso-border-bottom-alt:double windowtext 2.25pt;padding:0in;mso-padding-alt:
0in 0in 1.0pt 0in'><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre></div>
<pre><font size=2 color=black face="Courier New"><span style='font-size:10.0pt;
mso-bidi-font-family:"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>Hi Jesus,</span></font><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>The vtkPolyDataToImageStencil does use a scanline approach, and the way </span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>it works is that it uses vtkOBBTree to find out where the scanline </span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>intersects the polydata.<span style="mso-spacerun: yes"> </span>Let's just say that this isn't the best way to </span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>rasterize a polydata, and it doesn't work very well with sharp points.<span style="mso-spacerun: yes"> </span></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>I'm the original author of the class, so I take responsibility for its </span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>less-than-robust implementation.</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>My company has another vtkPolyDataToImageStencil class that uses a </span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>different algorithm, I will send it to you so that you can try it out.<span style="mso-spacerun: yes"> </span></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>It is definitely more robust than the current VTK one.</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'> - David</span></font><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>Jesús Spínola wrote:</span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> Hello,</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> I'm using the vtkPolyDataToImageStencil class to cut parts of a </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> dataset. It works fine for several polygons but I have a case with a </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> star-shaped polygon with a strange result. I've attached several </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> images with the resuts ( <a
href="http://hades.udg.es/%7Echus/images.tar.bz2">http://hades.udg.es/~chus/images.tar.bz2</a> </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <<a
href="http://hades.udg.es/%7Echus/images.tar.bz2">http://hades.udg.es/%7Echus/images.tar.bz2</a>> )</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> For example, when I make the stencil with an hexahedron the result is </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> ok ( see noStencilHexahedron.png and stencilHexahedron.png, that's </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> before cutting and after cutting with the stencil, respectively ).</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> But when constructing another kind of polygon I get a strange result. </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> First I thought the coordinates I was giving were wrong, so I created </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> and actor with the same polydata to see if it was wrong, but the actor </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> is rendered as I expected, so the polydata is ok. You can see the </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> original image before cutting is noStencilstarShape.png. After cutting </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> with the stencil I get stencilOnlyStarShape.png. Then you can see the </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> polygon created for the stencil in this image </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencilWithPolyDataStarShape.png.</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> The original dicom images i used for this examples are: </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <a
href="http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p05.dcm">http://www.creatis.insa-lyon.fr/~jpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p05.dcm</a> </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <<a
href="http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p05.dcm">http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p05.dcm</a>> </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> for the hexahedron and </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <a
href="http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p09.dcm">http://www.creatis.insa-lyon.fr/~jpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p09.dcm</a> </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <<a
href="http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p09.dcm">http://www.creatis.insa-lyon.fr/%7Ejpr/PUBLIC/gdcm/gdcmSampleData/imgdisplay_testcases/dish_p09.dcm</a>> </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> for the star shape.</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> The coordinates for the star shape ( refering to pixels coordinates, </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> where 1,1 is the first pixel ) are</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (133, 257)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (199, 233)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (169, 169)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (233, 199)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (257, 133)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (281, 199)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (345, 169)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (315, 233)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (381, 257)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (315, 281)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (345, 345)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (281, 315)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (257, 381)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (233, 315)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (169, 345)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> (199, 281)</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> My code looks like this ( it's the same for the hexahedron and for the </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> star shape )</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> int vertices = getNumberOfVerticesOfThePolygon();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vtkPoints *points = vtkPoints::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vtkCellArray *vertexs = vtkCellArray::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vertexs->InsertNextCell( vertices + 1 );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> int polyX, polyY;</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> double x, y;</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> for( int i = 0; i < vertices; i++ )</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> {</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>getPolygonVertex( i, polyX, polyY ) )</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span></span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>// to transform the pixel coordinates to world points coordinates</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>x = origin[0] + (polyX-1.0)*spacing[0];</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>y = origin[1] + ( polyY-1.0)*spacing[1];</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>points->InsertPoint( i , x, y, 0.0 );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span>vertexs->InsertCellPoint( i );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> }</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> // to close the polygon</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vertexs->InsertCellPoint( 0 );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vtkPolyData *polyData = vtkPolyData::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> polyData->SetPoints( points );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> polyData->SetLines( vertexs );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vtkLinearExtrusionFilter *extruder = vtkLinearExtrusionFilter::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> extruder->SetScaleFactor(1);</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> extruder->SetExtrusionTypeToNormalExtrusion();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> extruder->SetVector( 0 , 0 , 1 );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> extruder->SetInput( polyData );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> m_polygonalPolyDataStencil = vtkPolyDataToImageStencil::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> m_polygonalPolyDataStencil->SetInput( extruder->GetOutput() );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> extruder->Delete();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencil = vtkImageStencil::New();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencil->SetInput( m_imageData ); // m_imageData is of type </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> vtkImageData, contains the original dicom dataset</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencil->ReverseStencilOn();</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencil->SetBackgroundValue( m_backgroundValue );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> stencil->SetStencil( m_rectangularPolyDataStencil->GetOutput() );</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> ....</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> m_imageViewer->SetInput( stencil->GetOutput() ); // m_imageViewer is </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> of type vtkImageViewer2</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> I want to know if this is because of an error of my code or if it's </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> due to some bug in the implicated classes.</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> As a side note, other workmates that are using this class had also </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> problems like this on the sharpen vertexs of the polygons. Maybe it's </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> because the algorithm is a kind of scanline method and when the same </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> pixel in the polygon is the begin and the end of the region that it </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> encloses the algorithm fails.</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> Thanks in advance!</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> ------------------------------------------------------------------------</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>></span></font><i><font color=black><span
style='mso-bidi-font-family:"Courier New";color:black;mso-color-alt:windowtext;
font-style:italic'><o:p></o:p></span></font></i></pre><pre><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> _______________________________________________</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> This is the private VTK discussion list. </span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> Please keep messages on-topic. Check the FAQ at: <a
href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</a></span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> Follow this link to subscribe/unsubscribe:</span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'> <a
href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</a></span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'>><i><span style='font-style:italic'><span style="mso-spacerun: yes"> </span></span></i></span></font><i><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext;font-style:italic'><o:p></o:p></span></font></i></pre><pre><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;mso-bidi-font-family:
"Courier New";color:black'><![if !supportEmptyParas]> <![endif]></span></font><font
color=black><span style='mso-bidi-font-family:"Courier New";color:black;
mso-color-alt:windowtext'><o:p></o:p></span></font></pre>
<div class=MsoNormal align=center style='text-align:center'><font size=3
color=black face="Times New Roman"><span style='font-size:12.0pt;color:black'>
<hr size=2 width="100%" align=center>
</span></font></div>
<!--endarticle--><font size=3 color=black face="Times New Roman"><span
style='font-size:12.0pt;font-family:"Times New Roman";mso-fareast-font-family:
"Times New Roman";color:black;mso-ansi-language:EN-US;mso-fareast-language:
EN-US;mso-bidi-language:AR-SA'>
<ul type=disc>
<!--threads-->
<li class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;
mso-list:l0 level1 lfo1;tab-stops:list .5in'>Previous message: <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/090179.html">[vtkusers]
Possible Bug in vtkPolyDataToImageStencil </a><font color=black><span
style='color:black;mso-color-alt:windowtext'><o:p></o:p></span></font></li>
<li class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;
mso-list:l0 level1 lfo1;tab-stops:list .5in'>Next message: <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/090175.html">[vtkusers]
vtkTrivialProducer/vtkXMLImageDataReader question </a><font color=black><span
style='color:black;mso-color-alt:windowtext'><o:p></o:p></span></font></li>
<li class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;
mso-list:l0 level1 lfo1;tab-stops:list .5in'><b><span style='font-weight:
bold'>Messages sorted by:</span></b> <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/date.html#90180">[
date ]</a> <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/thread.html#90180">[
thread ]</a> <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/subject.html#90180">[
subject ]</a> <a
href="http://public.kitware.com/pipermail/vtkusers/2007-March/author.html#90180">[
author ]</a> <font color=black><span style='color:black;mso-color-alt:
windowtext'><o:p></o:p></span></font></li>
</ul>
</span></font>
<div class=MsoNormal align=center style='text-align:center'><font size=3
color=black face="Times New Roman"><span style='font-size:12.0pt;color:black'>
<hr size=2 width="100%" align=center>
</span></font></div>
<p class=MsoNormal><font size=3 color=black face="Times New Roman"><span
style='font-size:12.0pt;color:black'><a
href="http://www.vtk.org/mailman/listinfo/vtkusers">More information about the
vtkusers mailing list</a></span></font><span class=EmailStyle15><font size=2
color=black face=Arial><span style='font-size:10.0pt;mso-bidi-font-size:12.0pt;
font-family:Arial'><o:p></o:p></span></font></span></p>
</div>
</body>
</html>