]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
To fix a regression with appling 'Geometry Sphere' primitive type
authorapo <apo@opencascade.com>
Fri, 29 Dec 2006 14:56:26 +0000 (14:56 +0000)
committerapo <apo@opencascade.com>
Fri, 29 Dec 2006 14:56:26 +0000 (14:56 +0000)
src/PIPELINE/VISU_GaussPointsPL.cxx
src/PIPELINE/VISU_GaussPointsPL.hxx

index 0b6985e55208a5492287f242e4f8c05eee5c37e9..f30f05533077f03af720ca14cea5c084d12aa9f6 100644 (file)
@@ -63,8 +63,6 @@ VISU_GaussPointsPL
   myGeomFilter = vtkGeometryFilter::New();
 
   myWarpVector = vtkWarpVector::New();
-  myCellDataToPointData = vtkCellDataToPointData::New();
-  myCellDataToPointData->SetPassCellData(true);
 
   myGlyph = vtkGlyph3D::New();
   myGlyph->SetScaleModeToScaleByScalar();
@@ -74,8 +72,6 @@ VISU_GaussPointsPL
   myExtractor->SetInput( myExtractGeometry->GetOutput() );
   myFieldTransform->SetInput( myExtractor->GetOutput() );
 
-  myCellDataToPointData->SetInput( myFieldTransform->GetUnstructuredGridOutput() );
-
   mySphereSource = vtkSphereSource::New();
   mySphereSource->SetThetaResolution( 8 );
   mySphereSource->SetPhiResolution( 8 );
@@ -83,6 +79,18 @@ VISU_GaussPointsPL
 
   for(int i = 0; i < 3; i++)
     myPassFilter.push_back(VTKViewer_PassThroughFilter::New());
+
+  // Deformed Shape
+  myPassFilter[0]->SetInput(myFieldTransform->GetUnstructuredGridOutput());
+
+  myPassFilter[1]->SetInput(myPassFilter[0]->GetOutput());
+
+  myGeomFilter->SetInput( myPassFilter[1]->GetOutput() );
+
+  // Geometrical Sphere
+  myPassFilter[2]->SetInput(myGeomFilter->GetOutput());
+
+  myPSMapper->SetInput( myPassFilter[2]->GetPolyDataOutput() );
 }
 
 
@@ -103,8 +111,6 @@ VISU_GaussPointsPL
 
   myWarpVector->Delete();
 
-  myCellDataToPointData->Delete();
-
   myGlyph->Delete();
 
   mySphereSource->Delete();
@@ -234,18 +240,6 @@ VISU_GaussPointsPL
     SetScale( aScaleFactor / aScalarRange[1] );
   else
     SetScale(0.0);
-
-  // Deformed Shape
-  myPassFilter[0]->SetInput(myFieldTransform->GetUnstructuredGridOutput());
-
-  myPassFilter[1]->SetInput(myPassFilter[0]->GetOutput());
-
-  myGeomFilter->SetInput( myPassFilter[1]->GetOutput() );
-
-  // Geometrical Sphere
-  myPassFilter[2]->SetInput(myGeomFilter->GetOutput());
-
-  myPSMapper->SetInput( myPassFilter[2]->GetPolyDataOutput() );
 }
 
 //----------------------------------------------------------------------------
@@ -289,11 +283,6 @@ VISU_GaussPointsPL
   vtkDataSet* aDataSet = myGeomFilter->GetOutput();
   unsigned long int aSize = aDataSet->GetActualMemorySize() * 1024;
   
-  if(myCellDataToPointData->GetInput()){
-    aDataSet = myCellDataToPointData->GetOutput();
-    aSize += aDataSet->GetActualMemorySize() * 1024;
-  }
-
   if(GetIsDeformed()){
     aDataSet = myWarpVector->GetOutput();
     aSize += aDataSet->GetActualMemorySize() * 1024;
@@ -413,8 +402,7 @@ VISU_GaussPointsPL
 
   if( theIsDeformed )
   {
-    myCellDataToPointData->SetInput( myPassFilter[0]->GetUnstructuredGridOutput() );
-    myWarpVector->SetInput( myCellDataToPointData->GetUnstructuredGridOutput() );
+    myWarpVector->SetInput( myPassFilter[0]->GetUnstructuredGridOutput() );
     myPassFilter[1]->SetInput(myWarpVector->GetOutput());
   }
   else
index a30f38664ba8c8a02d06b203406d513c4cfae588..158342d2761a6e0d3e12a1954f298d55ed42edb1 100644 (file)
@@ -43,7 +43,6 @@ class vtkDataArray;
 class vtkImageData;
 class vtkPointSet;
 
-class vtkCellDataToPointData;
 class vtkWarpVector;
 class SALOME_Transform;
 
@@ -297,7 +296,6 @@ protected:
   bool myIsDeformed;
   vtkFloatingPointType myScaleFactor;
   vtkWarpVector *myWarpVector;
-  vtkCellDataToPointData* myCellDataToPointData;
   std::vector<VTKViewer_PassThroughFilter*> myPassFilter;
   
   vtkGlyph3D* myGlyph;