Hello,<br><br>I am using vtkProgrammableFilter to drag a node of a mesh using mouse.. And i need this functionality<br>to be implemented at any cost.. Below is my code..<br><br>// --- code to build unstructured grid is written before..<br><br>// -- now follows main code.<br><br>vtkDataSetSurfaceFilter *sf = vtkDataSetSurfaceFilter::New();<br>sf->SetInput(uGrid);<br><br>vtkProgrammableFilter *pgf = vtkProgrammableFilter::New();<br>pgf->SetInputConnection( sf->GetOutputPort());<br>// pgf->SetInput(uGrid);<br>pgf->SetExecuteMethod( adjustPoints, pgf );<br><br>vtkSmartPointer< vtkCallbackCommand> _callback = vtkSmartPointer<vtkCallbackCommand>::New();<br>_callback->SetCallback(moveCBFunction);<br>_callback->SetClientData(pgf);<br><br>renderWindowInteractor->AddObserver(vtkCommand::MouseMoveEvent, _callback);<br><br>vtkDataSetMapper *dmapp = vtkDataSetMapper::New();<br>dmapp->SetInputConnection( pgf->GetOutputPort());<br><br>vtkActor *pac
tor = vtkActor::New();<br>pactor->SetMapper(dmapp);<br><br>pRenderer->AddActor(pactor);<br><br><br>Now this code works very well.. But after adding a new cell to this grid, and i say, <br><br>pactor->Modified(), <br><br>The new cell is not visible..<br><br>If i uncomment this <br><br>// pgf->SetInput(uGrid);<br><br>statement, and comment<br><br>pgf->SetInputConnection( sf->GetOutputPort());<br><br>statement, then the new cell gets displayed..<br><br>In other words, I want both functionalities to be implemented. i.e.<br>- After adding new cell, it should be displayed in renderwindow, and<br>- must be able to drag a vertex(node) in the mesh<br><br>So how can i do this..?? Why does pgf behave like this..?? Is it because, uGrid is unstructured and<br>output of "sf" is a polydata..?? Am confused...<br><br>Someone guide me..<br><br>Thanks<br><br>Regards<br>Rakesh Patil<br><br><br><br><div style="border-top: 1px dashed rgb(204, 204, 204); border-bottom: 1px dashed
rgb(204, 204, 204); padding: 5px;"><a target=\"_blank\" target="\"_blank\"" href="http://mail.in.com/mails/new_reg.php?utm_source=invite&utm_medium=outgoing" style="font: 13px arial; color: rgb(30, 86, 161); text-decoration: none;">Dear <b>VTK !</b> Get Yourself a cool, short <b>@in.com</b> Email ID now!</a></div>