<div>I mailed a post but looks like it dod not make it to the list.</div>
<div> </div>
<div>My goal is to create a surface with nx by ny grid blocks using some x, y, z data. I am trying to use the ThinPlateSpline. I looked thru the Tcl code (ie in hybrid floder) but I still am unable to display my results.</div>
<div> </div>
<div>It will be very helpful if someone can point me to some other existing code.</div>
<div> </div>
<div>Thanks.</div>
<div>-Eric<br><br></div>
<div class="gmail_quote">On Sun, Jan 24, 2010 at 8:49 PM, Eric Barn <span dir="ltr"><<a href="mailto:ebarn100@gmail.com">ebarn100@gmail.com</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">
<div>All,</div>
<div>I am trying to display some points/Grid using ThinPlatespline as in the code below. But I donot see the map in the viewer. I see the same map if I use delauny2D.</div>
<div> </div>
<div>I really appreciate your help on it.</div>
<div> </div>
<div>-Eric</div>
<div> </div>
<div> // Generate a 10 x 10 grid of points<br>vtkPoints *points = vtkPoints::New();<br>vtkPoints *pointsT = vtkPoints::New();<br> for(unsigned int x = 0; x < 10; x++)<br> {<br> for(unsigned int y = 0; y < 10; y++)<br>
{<br> points->InsertNextPoint(x + vtkMath::Random(-.250, 0.25),<br> y + vtkMath::Random(-.250, 0.25),<br> vtkMath::Random(0.0,.50));// 0);<br> }<br>
}<br> <br> vtkPolyData *aPolyData = vtkPolyData::New();<br> aPolyData->SetPoints(points);</div>
<div> vtkThinPlateSplineTransform* tpst = vtkThinPlateSplineTransform::New();<br> tpst->SetSourceLandmarks(points);<br> tpst->SetBasisToR();</div>
<div> vtkGeneralTransform* tpstconcat = vtkGeneralTransform::New();<br> tpstconcat->SetInput(tpst);<br> tpstconcat->Concatenate(tpst->GetInverse());<br> tpstconcat->Concatenate(tpst);</div>
<div><br> vtkTransformPolyDataFilter *transformer= vtkTransformPolyDataFilter::New();<br> transformer->SetInput(aPolyData);<br> transformer->SetTransform(tpstconcat);//tpst);</div>
<div><br>// vtkPolyDataMapper *mapperPoly = vtkPolyDataMapper::New();<br> vtkDataSetMapper *mapperPoly = vtkDataSetMapper::New();<br> mapperPoly->SetInput(transformer->GetOutput());//outputPolyData);</div>
<div><br> surfaceActor = vtkActor::New();<br> surfaceActor->SetMapper(mapperPoly);</div>
<div> vtkWindow1->GetRenderer()->AddActor(surfaceActor);<br> </div></blockquote></div><br>