Hi,<br><br>Have you tried implementing what i told you.???<br><br><font color="#000000"><font color="#000000"><span style="font-size: 10pt; font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;; color: black;">scalarIsoSurface-&gt;GenerateValues( 10, 
sGrid-&gt;GetScalarRange() );</span></font></font><br><br>this will solve your problem... As i told u before, there is no other prob i could figure out other than this.. GenerateValues takes three parameters, i.e.<br><br>1. Number of contour lines,<br>2. min. value(of range)<br>3. max value(of range)<br><br>It also takes two parameters.. in this case 2nd parameter is double array consisting two elements..<br><br>Thanks<br><br>Regards<br>Rakesh Patil<br><blockquote><br>---------- Original message ----------<br>From:Sebastian Gatzka&lt; sebastian.gatzka@stud.tu-darmstadt.de &gt;<br>Date: 12 Mar 10 15:40:22<br>Subject:  Re: [vtkusers] Fwd: Re:AW: vtkContourFilter not workingonvtkStructuredGrid<br>To: vtkusers <vtkusers@vtk.org><br><br>



Hi again.<br>
<br>
Attached you will find the code that should produce the iso surface,
but displays nothing.<br>
I even tried to apply the vtkAssignAttribute <a target=\"_blank\" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:frinxor@gmail.com">frinxor@gmail.com</a>
suggested ...<br>
Nothing changes.<br>
<br>
Hope you will find the mistake.<br>
Have a nice day.<br>
Sebastian<br>
<br>
Am 10.03.2010 15:50, schrieb Rakesh Patil:
<font color="#000000"></font><blockquote cite="mid:1268232644.af44c4c56f385c43f2529f9b1b018f6a@mail.in.com" type="cite"><font color="#000000"> <br>
Well, i dont think anything is wrong<br>
  <br>
According to this,<br>
  <br>
<a target=\"_blank\" target="\&quot;_blank\&quot;" 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>
vtkContourFilter is a filter that takes as input any dataset and
generates on output isosurfaces and/or isolines. So that is not a
problem..<br>
  <br>
Can u just get you final code what u have coded..??<br>
  <br>
Thanks<br>
  <br>
Regards<br>
Rakesh Patil<br>
  <font color="#000000"></font></font><blockquote><font color="#000000"><font color="#000000"><br>
---------- Original message ----------<br>
From:Sebastian Gatzka&lt; <a target=\"_blank\" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:sebastian.gatzka@stud.tu-darmstadt.de">sebastian.gatzka@stud.tu-darmstadt.de</a> &gt;<br>
Date: 10 Mar 10 17:43:19<br>
Subject: [vtkusers] Fwd: Re:AW: vtkContourFilter not working
onvtkStructuredGrid<br>
To: <a target=\"_blank\" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</a><br>
    <br>
    <font size="-1"><font face="Helvetica, Arial, sans-serif">No, this
doesn't work out.<br>
I put Update()'s at every (possible) object but nothing happens.<br>
    <br>
Even chaning SetValue() and GenerateValues() doesn't change that.<br>
So maybe there is something wrong with the data?!<br>
    <br>
I have a structured grid (called sGrid) and the scalar values are
defined at the cell centers:<br>
    <br>
sGrid-&gt;GetCellData()-&gt;SetScalars(T);<br>
    <br>
But I just pass the sGrid to the </font></font><span style="font-size: 10pt; font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;; color: black;">vtkContourFilter
    </span><br>
    <font size="-1"><font face="Helvetica, Arial, sans-serif"><br>
    </font></font><small><font face="Courier New, Courier, monospace"><span style="font-size: 10pt; font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;; color: black;">vtkContourFilter
*scalarIsoSurface
vtkContourFilter::New();<br>
scalarIsoSurface-&gt;SetInput(sGrid);</span></font></small><br>
    <br>
    <small><font face="Helvetica, Arial, sans-serif">May this be the
problem?</font></small><br>
    <font size="-1"><font face="Helvetica, Arial, sans-serif"><br>
    </font></font><br>
-------- Original-Nachricht --------
    <table class="moz-email-headers-table" border="0" cellpadding="0" cellspacing="0">
      <tbody>
        <tr>
          <th nowrap="nowrap" align="RIGHT" valign="BASELINE">Betreff: </th>
          <td>Re:AW: [vtkusers] vtkContourFilter not working on
vtkStructuredGrid</td>
        </tr>
        <tr>
          <th nowrap="nowrap" align="RIGHT" valign="BASELINE">Datum: </th>
          <td>Sat, 06 Mar 2010 09:34:59 +0530</td>
        </tr>
        <tr>
          <th nowrap="nowrap" align="RIGHT" valign="BASELINE">Von: </th>
          <td>Rakesh Patil <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-rfc2396E" href="mailto:rakeshthp@in.com">&lt;rakeshthp@in.com&gt;</a></td>
        </tr>
        <tr>
          <th nowrap="nowrap" align="RIGHT" valign="BASELINE">Antwort
an: </th>
          <td>Rakesh Patil <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-rfc2396E" href="mailto:rakeshthp@in.com">&lt;rakeshthp@in.com&gt;</a></td>
        </tr>
        <tr>
          <th nowrap="nowrap" align="RIGHT" valign="BASELINE">An: </th>
          <td>Sebastian Gatzka <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-rfc2396E" href="mailto:sebastian.gatzka@stud.tu-darmstadt.de">&lt;sebastian.gatzka@stud.tu-darmstadt.de&gt;</a></td>
        </tr>
      </tbody>
    </table>
    <br>
    <br>
Hi Sebastian,<br>
    <br>
I see there is a small mistake over there in your code..<br>
    <br>
As far as my knowledge is concerned, <br>
    <br>
    <span style="font-size: 10pt; font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;; color: black;">scalarIsoSurface-&gt;GenerateValues(0,0.1);<br>
    <br>
This statement should produce error. Coz, according to the
documentation given here<br>
    <br>
    <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" href="http://www.vtk.org/doc/release/5.4/html/a00323.html">http://www.vtk.org/doc/release/5.4/html/a00323.html</a><br>
    <br>
GenerateValues takes two parameters if and only if second parameter is
a double array comprising of two elements min and max range.<br>
    <br>
Even if this code executes without any error, then also no output will
be produced, because the first argument you are passing is 0. First
parameter tells the number of contours to be generated, Second
parameter tells within what range these contours should be plotted.<br>
    <br>
What i guess is, either you change it that statement t o<br>
    <br>
scalarIsoSurface-&gt;SetValue(0, 0.1);<br>
    <br>
or<br>
    <br>
scalarIsoSurface-&gt;GenerateValues( n, sGrid-&gt;GetScalarRange() );<br>
    <br>
where n is number of lines you want, say 1, 5, 10, 12... whatever...<br>
    <br>
And then say update.. <br>
    <br>
Am i correct David Sir..??<br>
    <br>
Thanks <br>
    <br>
Regards<br>
    <br>
Rakesh Patil<br>
    </span>
    <font color="#000000"></font></font></font><blockquote><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"><br>
---------- Original message ----------<br>
From:"Sebastian Gatzka"&lt; <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:sebastian.gatzka@stud.tu-darmstadt.de">sebastian.gatzka@stud.tu-darmstadt.de</a>
&gt;<br>
Date: 05 Mar 10 22:50:50<br>
Subject: AW: [vtkusers] vtkContourFilter not working on
vtkStructuredGrid<br>
To: "'Rakesh Patil'" <rakeshthp@in.com><br>
      <br>
      </rakeshthp@in.com></font>
      </font></font></font><div class="Section1"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);" lang="EN-US"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">Hm. The -&gt;Update() did not work
out.<o:p></o:p></font></font></font></font></span></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);" lang="EN-US"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">What can be wrong? How can the data
be not fed correctly?<o:p></o:p></font></font></font></font></span></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span style="font-size: 11pt; font-family: &quot;Calibri&quot;,&quot;sans-serif&quot;; color: rgb(31, 73, 125);" lang="EN-US"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></span></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"><b><span style="font-size: 10pt; font-family: &quot;Tahoma&quot;,&quot;sans-serif&quot;;">Von:</span></b><span style="font-size: 10pt; font-family: &quot;Tahoma&quot;,&quot;sans-serif&quot;;"> Rakesh
Patil
[<a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-freetext" href="mailto:rakeshthp@in.com">mailto:rakeshthp@in.com</a>]
      <br>
      <b>Gesendet:</b> Freitag, 5. M¤rz 2010 16:25<br>
      <b>An:</b> David Doria<br>
      <b>Cc:</b> Sebastian Gatzka; <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</a><br>
      <b>Betreff:</b> Re: [vtkusers] vtkContourFilter not working on
vtkStructuredGrid<o:p></o:p></span></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"><br>
Ya, I had also done the same mistake... I had ommitted that update
statement..
By putting that update statement is should definitley work.. (only if
data is
fed correctly)<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal" style="margin-bottom: 12pt;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"><br>
---------- Original message ----------<br>
From:David Doria&lt; <a target=\"_blank\" moz-do-not-send="true" target="\&quot;_blank\&quot;" class="moz-txt-link-abbreviated" href="mailto:daviddoria+vtk@gmail.com">daviddoria+vtk@gmail.com</a>
&gt;<br>
Date: 05 Mar 10 19:26:03<br>
Subject: Re: [vtkusers] vtkContourFilter not working on
vtkStructuredGrid<br>
To: Sebastian Gatzka <o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">On Fri, Mar 5, 2010 at
8:41 AM, Sebastian Gatzka
&lt;<a target=\"_blank\" moz-do-not-send="true" href="mailto:sebastian.gatzka@stud.tu-darmstadt.de" target="\&quot;_blank\&quot;">sebastian.gatzka@stud.tu-darmstadt.de</a>&gt;
wrote:<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span style="font-size: 10pt; font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;; color: black;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">Hello.<br>
      <br>
I really can't tell why my code is not gernerating the iso-surface.<br>
I have a structured grid (sGrid) filled with scalars.<br>
      <br>
I call the contour filter<br>
      <br>
vtkContourFilter *scalarIsoSurface vtkContourFilter::New();<br>
scalarIsoSurface-&gt;SetInput(sGrid);<br>
scalarIsoSurface-&gt;GenerateValues(0,0.1);<br>
      <br>
Compute the normal<br>
      <br>
vtkPolyDataNormals *sGridPolyDataNormal vtkPolyDataNormals::New();<br>
sGridPolyDataNormal-&gt;SetInput(scalarIsoSurface-&gt;GetOutput());<br>
      <br>
Put them into a poly data mapper<br>
      <br>
vtkPolyDataMapper *scalarIsoSurfaceMapper vtkPolyDataMapper::New();<br>
scalarIsoSurfaceMapper-&gt;SetInput(sGridPolyDataNormal-&gt;GetOutput());<br>
      <br>
and into an actor<br>
      <br>
vtkActor *scalarIsoSurfaceActor = vtkActor::New();<br>
scalarIsoSurfaceActor-&gt;SetMapper(scalarIsoSurfaceMapper);<br>
      <br>
which is passed on to the scene<br>
      <br>
ren1-&gt;AddActor(scalarIsoSurfaceActor);<br>
      <br>
and NOTHING happens.<br>
      <br>
Any ideas what I have missed, or whats wrong?<br>
      <br>
Sebastian</font></font></font></font></span><o:p></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">You probably have a
call to Render() after the
code you sent
us, which I believe updates the whole pipeline. Whenever I have
something that
is totally empty, I go back and put an Update() call on every object
that is
updatable.<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span class="apple-style-span"><span style="font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">scalarIsoSurface-&gt;GenerateValues(0,0.1);</font></font></font></font></span></span><o:p></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><span class="apple-style-span"><span style="font-family: &quot;Helvetica&quot;,&quot;sans-serif&quot;;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">scalarIsoSurface-&gt;Update();</font></font></font></font></span></span><o:p></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">before I dig too deep.<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><o:p><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font></font></font></font></o:p></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">If that doesn't change
anything, try to create a
demo
involving some simple data (using a vtk*Source if you can, so we can
reproduce
it without needing your dataset). Then send us the smallest compilable
code
that demonstrates the problem.<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><p class="MsoNormal" style="margin-bottom: 12pt;"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"><br clear="all">
Thanks,<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font>
      </font></font></font><div><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000"> </font>
      </font></font></font><p class="MsoNormal"><font color="#000000"><font color="#000000"><font color="#000000"><font color="#000000">David<o:p></o:p></font></font></font></font></p>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></div>
<font color="#000000"><font color="#000000"><font color="#000000">      <font color="#000000"> </font></font></font></font></blockquote>
<font color="#000000"><font color="#000000">  </font></font></blockquote>
<font color="#000000"></font></blockquote>
</vtkusers@vtk.org></blockquote>