]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
Fix on Bug GVIEW10251
authorapo <apo@opencascade.com>
Thu, 13 Oct 2005 16:08:16 +0000 (16:08 +0000)
committerapo <apo@opencascade.com>
Thu, 13 Oct 2005 16:08:16 +0000 (16:08 +0000)
  Sweep doesn't work

src/PIPELINE/VISU_DeformedShapePL.cxx
src/PIPELINE/VISU_IsoSurfacesPL.cxx
src/PIPELINE/VISU_ScalarMapPL.cxx
src/VISUGUI/VisuGUI.cxx

index 913feb183f3169a9428edd9cea55d1b67ef165bc..12847fa973e28c4411a097c109b3063e8a80e3b0 100644 (file)
@@ -74,13 +74,12 @@ float VISU_DeformedShapePL::GetScaleFactor(vtkDataSet* theDataSet){
 
 
 void VISU_DeformedShapePL::SetScale(float theScale) {
-  if(myScaleFactor == theScale) return;
+  myWarpVector->SetScaleFactor(theScale);
   myScaleFactor = theScale;
-  myWarpVector->SetScaleFactor(myScaleFactor);
   Modified();
 }
 float VISU_DeformedShapePL::GetScale() {
-  return myWarpVector->GetScaleFactor();
+  return myScaleFactor;
 }
 
 void VISU_DeformedShapePL::Init(){
index c3ffd9b4e29b2f3c3cb5c00aad1e64ffdcda5fc6..8e14bca9949723895838d7cf74c9a5f2d357fafe 100644 (file)
@@ -97,14 +97,13 @@ void VISU_IsoSurfacesPL::Init(){
 }
 
 VISU_ScalarMapPL::THook* VISU_IsoSurfacesPL::DoHook(){
+  VISU::CellDataToPoint(myContourFilter,myCellDataToPointData,GetInput2(),myFieldTransform);
   return myContourFilter->GetOutput();
 }
 
 
-void VISU_IsoSurfacesPL::Update(){
-  VISU::CellDataToPoint(myContourFilter,myCellDataToPointData,GetInput2(),myFieldTransform);
-  SetMapScale();
-
+void VISU_IsoSurfacesPL::Update()
+{
   VISU_ScalarMapPL::Update();
 }
 
index 8721290a75f06bffba912c20c5d56a9119dddc09..42daa1bc099206e9907686221daf4bd630d63eff 100644 (file)
@@ -77,6 +77,7 @@ VISU_ScalarMapPL
     SetScalarMode(aPipeLine->GetScalarMode());
     SetNbColors(aPipeLine->GetNbColors());
     SetScaling(aPipeLine->GetScaling());
+    SetMapScale(aPipeLine->GetMapScale());
   }
   Superclass::ShallowCopy(thePipeLine);
 }
@@ -223,13 +224,12 @@ VISU_ScalarMapPL
 void
 VISU_ScalarMapPL
 ::Update() 
-{
+{ 
   float *aRange = myFieldTransform->GetScalarRange();
   float aScalarRange[2] = {aRange[0], aRange[1]};
   if(myBarTable->GetScale() == VTK_SCALE_LOG10)
     VISU_LookupTable::ComputeLogRange(aRange,aScalarRange);
   myMapperTable->SetRange(aScalarRange);
-  myMapperTable->SetMapScale(1.0);
 
   myMapperTable->Build();
   myBarTable->Build();
index d89cbb86f89e17143f968ec9ed88517286c13ab3..b3b56888462a15220c59759f240077fa486c7e4d 100644 (file)
@@ -1569,6 +1569,8 @@ OnSweep()
         usleep(aTemp);
       }
     }
+    aPrsObject->SetMapScale(1.0);
+    aPrsObject->UpdateActor(aActor);
   } catch (std::exception& exc) {
     INFOS("Follow exception was occured :\n" << exc.what());
   } catch (...) {