[vtkusers] Adding the results of two vtkRotationalExtrusionFilters

Karl Merkley karl at elemtech.com
Mon Dec 12 12:28:54 EST 2005


We are creating two helices via vtkRotationalExtrusionFilter.  Now we 
would like to compose the two helices by doing a point-by-point 
addition of the helices.  What is the best way to this in VTK?

This is basically how we are creating the helices via 
vtkRotationalExtrusionFilter.

   extrude1 = vtkRotationalExtrusionFilter::New();
   extrude1->SetInput(mProfile1);  // where mProfile is a single point.
   extrude1->SetAngle(1440.0);
   if (mFrequency1 == 0)
      mFrequency1 = 1;
   double trans = 4.0/mFrequency1;
   extrude1->SetTranslation(trans);
   extrude1->SetResolution(90);

   extrude2 = vtkRotationalExtrusionFilter::New();
   extrude2->SetInput(mProfile1);  // where mProfile is a single point.
   extrude2->SetAngle(1440.0);
   if (mFrequency2 == 0)
      mFrequency2 = 1;
   trans = 4.0/mFrequency2;
   extrude2->SetTranslation(trans);
   extrude2->SetResolution(90);


   Thanks,
         Karl





More information about the vtkusers mailing list