<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
<title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<font size="-1"><font face="Helvetica, Arial, sans-serif">No, still
blue ...</font></font><br>
<br>
Am 15.03.2010 11:41, schrieb David E DeMarle:
<blockquote
cite="mid:e85d6c9a1003150341i4ba64c47xa87ba3ca5a45baba@mail.gmail.com"
type="cite">
<pre wrap="">scalarIsoSurface->ComputeScalarsOn();
On Mon, Mar 15, 2010 at 4:55 AM, Sebastian Gatzka
<a class="moz-txt-link-rfc2396E" href="mailto:sebastian.gatzka@stud.tu-darmstadt.de"><sebastian.gatzka@stud.tu-darmstadt.de></a> wrote:
</pre>
<blockquote type="cite">
<pre wrap="">Hello world.
After I have finally found a way of making the vtkContourFilter work I'm now
facing how to color them.
I want to color them according to the value they are having.
Example: The cutting plane displays the "right" color for the scalar data,
but the iso-surfaces (contours) are colored identically.
Have a look at the screenshot in the attachment.
So, what do I have to do, to set up the right coloring?
Here is the code I am using to create the contours:
vtkContourFilter *scalarIsoSurface = vtkContourFilter::New();
scalarIsoSurface->SetInput(sGridPointData->GetOutput());
scalarIsoSurface->SetValue(0,3);
scalarIsoSurface->SetValue(1,5);
scalarIsoSurface->Update();
vtkPolyDataNormals *sGridPolyDataNormal = vtkPolyDataNormals::New();
sGridPolyDataNormal->SetInput(scalarIsoSurface->GetOutput());
sGridPolyDataNormal->Update();
vtkPolyDataMapper *scalarIsoSurfaceMapper = vtkPolyDataMapper::New();
scalarIsoSurfaceMapper->SetInput(sGridPolyDataNormal->GetOutput());
scalarIsoSurfaceMapper->Update();
vtkActor *scalarIsoSurfaceActor = vtkActor::New();
scalarIsoSurfaceActor->SetMapper(scalarIsoSurfaceMapper);
Have a nice day.
Sebastian
_______________________________________________
Powered by <a class="moz-txt-link-abbreviated" href="http://www.kitware.com">www.kitware.com</a>
Visit other Kitware open-source projects at
<a class="moz-txt-link-freetext" href="http://www.kitware.com/opensource/opensource.html">http://www.kitware.com/opensource/opensource.html</a>
Please keep messages on-topic and check the VTK 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 subscribe/unsubscribe:
<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>
</body>
</html>