<div dir="ltr">Hello !<br>I have a VTK question that has cost me time <br>and a lot of hair ;)<br><br>I am defining poly data, a mapper and an actor.<br>Now, when I change the underlying poly-Data, the graphical representation <br>
does not change :<br><br>vtkPoints* l_pts = vtkPoints::New();<br><br> l_pts->InsertPoint(0,0.0,0.0,-1.0);<br> l_pts->InsertPoint(1,0.0,0.0,-1.0);<br> l_pts->InsertPoint(2,0.0,0.0,-1.0);<br> l_pts->InsertPoint(3,0.0,0.0,-1.0);<br>
<br> vtkCellArray* l_cells = vtkCellArray::New();<br><br> l_cells->InsertNextCell(4); <br> l_cells->InsertCellPoint(0);<br> l_cells->InsertCellPoint(1);<br> l_cells->InsertCellPoint(2);<br> l_cells->InsertCellPoint(3);<br>
<br> m_polydata->SetPoints(l_pts);<br> m_polydata->SetPolys(l_cells);<br><br> CDataSpace* l_space = l_prop->GetBox().get();<br> m_polydata->GetPoints()->SetPoint(0,l_space->x_min,l_space->y_min,-1.0);<br>
m_polydata->GetPoints()->SetPoint(1,l_space->x_min,l_space->y_max,-1.0);<br> m_polydata->GetPoints()->SetPoint(2,l_space->x_max,l_space->y_max,-1.0);<br> m_polydata->GetPoints()->SetPoint(3,l_space->x_max,l_space->y_min,-1.0);<br>
m_polydata->Update();<br> m_mapper->Update();<br><br><br><br></div>