You have to find out the "port ID's" for the input data (only way I've
found so far is digging through source), and do things like this:<br>
<br>
filter->SetInputArrayToProcess(id, 0, 0, 0, "fieldname");<br>
<br>
Look in the constructor for the class.. Seems that the ContourFilter only supports 1 port: port 0 is the Scalar Field.<br>
I went through this for the vtkGlyph3D class last week, it supports 4 ports:<br>
port - Data<br>
0 Scalars to use for scaling<br>
1 Vector for aligning glyphs<br>
2 Normals<br>
3 Scalars to use for color<br>
<br><br><div><span class="gmail_quote">On 5/3/05, <b class="gmail_sendername">Jon Blower</b> <<a href="mailto:jdb@mail.nerc-essc.ac.uk">jdb@mail.nerc-essc.ac.uk</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi all,<br><br>Further to my earlier post of today, I have converted some code to use<br>vtkContourFilter instead of the now-deprecated vtkKitwareContourFilter.<br>However, the code used the .SelectInputScalars(String) method of
<br>vtkKitwareContourFilter, which is not present in vtkContourFilter. I've had<br>a quick look and I can't find an obvious replacement. Is there another<br>method I can use instead of SelectInputScalars() to tell the contourFilter
<br>which dataset to use out of a file?<br><br>Thanks in advance,<br>Jon<br><br>--------------------------------------------------------------<br>Dr
Jon
Blower Tel:
+44 118 378 5213 (direct line)<br>Technical Director Tel: +44 118 378 8741 (ESSC)<br>Reading e-Science Centre Fax: +44 118 378 6413<br>ESSC
Email: <a href="mailto:jdb@mail.nerc-essc.ac.uk">jdb@mail.nerc-essc.ac.uk</a><br>University of Reading<br>3 Earley Gate<br>Reading RG6 6AL, UK<br>--------------------------------------------------------------<br><br>_______________________________________________
<br>This is the private VTK discussion list.<br>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><br>Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</a><br></blockquote></div><br><br><br>-- <br>Randall Hand<br><a href="http://www.yeraze.com">http://www.yeraze.com</a>