<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content=text/html;charset=ISO-8859-1>
<META content="MSHTML 6.00.2900.2769" name=GENERATOR></HEAD>
<BODY text=#000000 bgColor=#ffffff>
<DIV dir=ltr align=left><SPAN class=039422820-11112005><FONT face=Arial 
size=2>Hello Sylvain, thanks a lot for your help in this 
matter.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=039422820-11112005><FONT face=Arial 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV dir=ltr align=left><SPAN class=039422820-11112005><FONT face=Arial 
size=2>Well, i finally can do the thing of the "extend", but i get to another 
problem... i obtain the image that i attach to this message, but i need to be 
otherwise, i mean, the "hole" part to be "tapped" and the outside part to be 
open... i hope i express well, cause the english are not my natural 
language.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=039422820-11112005><IMG 
src="cid:039422820@11112005-0366"></SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=es dir=ltr align=left><SPAN 
class=039422820-11112005><FONT face=Arial 
size=2>Thanks&nbsp;</FONT></SPAN></DIV>
<DIV class=OutlookMessageHeader lang=es dir=ltr align=left><SPAN 
class=039422820-11112005>&nbsp;</SPAN></DIV>
<DIV class=OutlookMessageHeader lang=es dir=ltr align=left>
<HR tabIndex=-1>
</DIV>
<DIV class=OutlookMessageHeader lang=es dir=ltr align=left><FONT face=Tahoma 
size=2><B>De:</B> Sylvain Jaume [mailto:sylvain.jaume@kitware.com] 
<BR><B>Enviado el:</B> Miércoles, 09 de Noviembre de 2005 13:24<BR><B>Para:</B> 
OnezerO<BR><B>CC:</B> vtkusers@vtk.org<BR><B>Asunto:</B> Re: [vtkusers] 3D 
Rendering of an sliced object<BR></FONT><BR></DIV>
<DIV></DIV>Hi OnezerO,<BR><BR>You can find the manpages for every VTK class 
here:<BR><A class=moz-txt-link-freetext 
href="http://www.vtk.org/doc/nightly/html/classes.html">http://www.vtk.org/doc/nightly/html/classes.html</A><BR><BR>and 
here for vtkContourFilter:<BR><A class=moz-txt-link-freetext 
href="http://www.vtk.org/doc/nightly/html/classvtkContourFilter.html">http://www.vtk.org/doc/nightly/html/classvtkContourFilter.html</A><BR><BR>For 
more information, check the VTK book:<BR><A class=moz-txt-link-freetext 
href="http://www.kitware.com/products/vtktextbook.html">http://www.kitware.com/products/vtktextbook.html</A><BR><BR>Cheers,<BR>Sylvain<BR><BR>OnezerO 
wrote: 
<BLOCKQUOTE 
cite=mid!&amp;!AAAAAAAAAAAYAAAAAAAAAA+S3wvdslBOiEBSFuwDKifCgAAAEAAAAHSeuV+O8h9Hv3qg8IGjEx4BAAAAAA==@gmail.com 
type="cite"><PRE wrap="">Meanwhile i do this, do you know where i can find the theory of the
vtkContour, to add to my final report.

Saludos,
OnezerO 

-----Mensaje original-----
De: Sylvain Jaume [<A class=moz-txt-link-freetext href="mailto:sylvain.jaume@kitware.com">mailto:sylvain.jaume@kitware.com</A>] 
Enviado el: Martes, 08 de Noviembre de 2005 17:46
Para: OnezerO
CC: <A class=moz-txt-link-abbreviated href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A>
Asunto: Re: [vtkusers] 3D Rendering of an sliced object

Hi OnezerO,

What is wrong with showing part of a cube during your final examination?
Alternatively you could try this:

double scalarRange[2];
importer-&gt;GetOutput()-&gt;GetScalarRange(scalarRange);

[snip]

imageConstantPad-&gt;SetConstant(scalarRange[0]);

Cheers,
Sylvain

OnezerO wrote:

  </PRE>
  <BLOCKQUOTE type="cite"><PRE wrap="">Ok, but the extent thing dindt work, even make another kind of image, 
like a part of a cube, didnt, work

-----Mensaje original-----
De: Sylvain Jaume [<A class=moz-txt-link-freetext href="mailto:sylvain.jaume@kitware.com">mailto:sylvain.jaume@kitware.com</A>]
Enviado el: Martes, 08 de Noviembre de 2005 17:04
Para: OnezerO
CC: <A class=moz-txt-link-abbreviated href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A>
Asunto: Re: [vtkusers] 3D Rendering of an sliced object

Hi OnezerO,

Before your final examination, make these changes to your code:

// executing the filter
m_vtkImporter-&gt;Update();

// getting the extent of the input image m_vtkImporter-&gt;GetWholeExtent( 
extent );

// creating the extent for an image that has one more 'slice'
// in the 6 directions around the input image

        extent[0]--;
        extent[1]++;
        extent[2]--;
        extent[3]++;
        extent[4]--;
        extent[5]++;

// creating the extended image, so the input image is padded with zeros 
// i.e. black voxels vtkImageConstantPad  *m_vtkConstant = 
vtkImageConstantPad::New(); m_vtkConstant-&gt;SetInput(
m_vtkImporter-&gt;GetOutput() ); m_vtkConstant-&gt;SetOutputWholeExtent( 
extent );


Cheers,
Sylvain

OnezerO wrote:

 

    </PRE>
    <BLOCKQUOTE type="cite"><PRE wrap="">Can you explain me that uses of this "extent"? 
Because if this get to work i have to present this in a final 
examination and i have to know how to works every part of the code 
Thanks

-----Mensaje original-----
De: Sylvain Jaume [<A class=moz-txt-link-freetext href="mailto:sylvain.jaume@kitware.com">mailto:sylvain.jaume@kitware.com</A>]
Enviado el: Martes, 08 de Noviembre de 2005 13:41
Para: OnezerO
CC: <A class=moz-txt-link-abbreviated href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A>
Asunto: Re: [vtkusers] 3D Rendering of an sliced object

Hi OnezerO,

Could you try the code I sent you in my previous email (see below)?

Cheers,
Sylvain

OnezerO wrote:



   

      </PRE>
      <BLOCKQUOTE type="cite"><PRE wrap="">Dont work

I did that:
ConnectPipelines(m_itkExporter , m_vtkImporter );
m_vtkImporter-&gt;Update();     

vtkImageConstantPad  *m_vtkConstant = vtkImageConstantPad::New(); 
m_vtkConstant-&gt;SetInput( m_vtkImporter-&gt;GetOutput() );

vtkContourFilter *m_vtkContour = vtkContourFilter::New(); 
m_vtkContour-&gt;SetInput( m_vtkConstant-&gt;GetOutput() );

The 3d image obtained its equals to the previous one


You say i should try this extent thing ?
-----Mensaje original-----
De: Sylvain Jaume [<A class=moz-txt-link-freetext href="mailto:sylvain.jaume@kitware.com">mailto:sylvain.jaume@kitware.com</A>]
Enviado el: Martes, 08 de Noviembre de 2005 13:06
Para: OnezerO
CC: <A class=moz-txt-link-abbreviated href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A>
Asunto: Re: [vtkusers] 3D Rendering of an sliced object

Hi OnezerO,

The filter vtkImageConstantPad is in the Imaging directory:
<A class=moz-txt-link-freetext href="http://www.vtk.org/doc/nightly/html/classvtkImageConstantPad.html">http://www.vtk.org/doc/nightly/html/classvtkImageConstantPad.html</A>

int extent[6];
image-&gt;GetWholeExtent( extent )

extent[0]--;
extent[1]++;
extent[2]--;
extent[3]++;
extent[4]--;
extent[5]++;

vtkImageConstantPad *constantPad = vtkImageConstantPad::New();
constantPad-&gt;SetInput(image);
constantPad-&gt;SetOutputWholeExtent(extent);

vtkContourFilter *contourFilter = vtkContourFilter::New();
contourFilter-&gt;SetInput(constantPad-&gt;GetOutput());

Cheers,
Sylvain

OnezerO wrote:



  

     

        </PRE>
        <BLOCKQUOTE type="cite"><PRE wrap="">i didnt find this filter :(

-----Mensaje original-----
De: Sylvain Jaume [<A class=moz-txt-link-freetext href="mailto:sylvain.jaume@kitware.com">mailto:sylvain.jaume@kitware.com</A>]
Enviado el: Martes, 08 de Noviembre de 2005 12:15
Para: OnezerO
CC: <A class=moz-txt-link-abbreviated href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</A>
Asunto: Re: [vtkusers] 3D Rendering of an sliced object

Hi OnezerO,

Did you use vtkConstantPadFilter before applying vtkContourFilter as 
it was answered previously?

Cheers,
Sylvain

OnezerO wrote:



 

    

       

          </PRE>
          <BLOCKQUOTE type="cite"><PRE wrap="">Hello, i'm send this post again because i think that i dont explain 
my problem very well... I have a series of images that represents a 
3d figure, this images was preprocesing with itk i'm receiving it 
with a Importer from vtk, i pass the data throught a Contourfilter 
and then by a SmoothFilter, the resulting 3d images has openings 
upside and downside, i wanna close this holes... how i do it???

Regards


-------------------------------------------------------------------
-
-
-
-
-

_______________________________________________
This is the private VTK discussion list. 
Please keep messages on-topic. Check the FAQ at: 
<A class=moz-txt-link-freetext href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</A> Follow this link to
      

         

            </PRE></BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE><PRE wrap="">subscribe/unsubscribe:


   

      </PRE>
      <BLOCKQUOTE type="cite">
        <BLOCKQUOTE type="cite">
          <BLOCKQUOTE type="cite"><PRE wrap=""><A class=moz-txt-link-freetext href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</A>




   

      

         

            </PRE></BLOCKQUOTE><PRE wrap=""> 

    

       

          </PRE></BLOCKQUOTE><PRE wrap="">  

     

        </PRE></BLOCKQUOTE><PRE wrap="">   

      </PRE></BLOCKQUOTE><PRE wrap=""> 

    </PRE></BLOCKQUOTE><PRE wrap=""><!---->

  </PRE></BLOCKQUOTE></BODY></HTML>