[vtkusers] overwriting point coordinate ingnored

Martin Baumann mailsgetlost at web.de
Thu May 25 08:26:19 EDT 2006


Hi,

I want to change change geometry of a 2D grid to 3D, by replacing 
(x,y,0) by (x,y,some scalar value).

The code was:

  _zero_grid = vtkUnstructuredGrid::New();
  _zero_grid->DeepCopy(_reader->GetOutput());

I replaced this by:

  _zero_grid = vtkUnstructuredGrid::New();
  _zero_grid->DeepCopy(_reader->GetOutput());
  for (int i=0; i<_number_of_points; ++i)
  {
   _zero_grid->GetPoint(i)[2] = 77.7;           // THIS LINE SEEMS TO BE 
IGNORED!!!
    std::cout << i << ": " << _zero_grid->GetPoint(i)[2] << std::endl;
  }

But the output is still (x,y,0), should be (x,y,77.7).
How can this be?

Regards, M.B.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20060525/fff3a051/attachment.htm>


More information about the vtkusers mailing list