From 39b16fbba87f9294142495f9330fe4c815a4bb4d Mon Sep 17 00:00:00 2001 From: apo Date: Thu, 13 Oct 2005 16:08:16 +0000 Subject: [PATCH] Fix on Bug GVIEW10251 Sweep doesn't work --- src/PIPELINE/VISU_DeformedShapePL.cxx | 5 ++--- src/PIPELINE/VISU_IsoSurfacesPL.cxx | 7 +++---- src/PIPELINE/VISU_ScalarMapPL.cxx | 4 ++-- src/VISUGUI/VisuGUI.cxx | 2 ++ 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/PIPELINE/VISU_DeformedShapePL.cxx b/src/PIPELINE/VISU_DeformedShapePL.cxx index 913feb18..12847fa9 100644 --- a/src/PIPELINE/VISU_DeformedShapePL.cxx +++ b/src/PIPELINE/VISU_DeformedShapePL.cxx @@ -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(){ diff --git a/src/PIPELINE/VISU_IsoSurfacesPL.cxx b/src/PIPELINE/VISU_IsoSurfacesPL.cxx index c3ffd9b4..8e14bca9 100644 --- a/src/PIPELINE/VISU_IsoSurfacesPL.cxx +++ b/src/PIPELINE/VISU_IsoSurfacesPL.cxx @@ -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(); } diff --git a/src/PIPELINE/VISU_ScalarMapPL.cxx b/src/PIPELINE/VISU_ScalarMapPL.cxx index 8721290a..42daa1bc 100644 --- a/src/PIPELINE/VISU_ScalarMapPL.cxx +++ b/src/PIPELINE/VISU_ScalarMapPL.cxx @@ -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(); diff --git a/src/VISUGUI/VisuGUI.cxx b/src/VISUGUI/VisuGUI.cxx index d89cbb86..b3b56888 100644 --- a/src/VISUGUI/VisuGUI.cxx +++ b/src/VISUGUI/VisuGUI.cxx @@ -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 (...) { -- 2.39.2