From 6ddc1f984af6a4fb35942bee3eab2193755860bb Mon Sep 17 00:00:00 2001 From: apo Date: Wed, 7 Dec 2005 09:49:54 +0000 Subject: [PATCH] To use the same scalar range that was calculated during initlization of the pipe-line --- src/PIPELINE/VISU_GaussPointsPL.cxx | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/PIPELINE/VISU_GaussPointsPL.cxx b/src/PIPELINE/VISU_GaussPointsPL.cxx index db7fdde9..1316b2f6 100644 --- a/src/PIPELINE/VISU_GaussPointsPL.cxx +++ b/src/PIPELINE/VISU_GaussPointsPL.cxx @@ -194,11 +194,10 @@ VISU_GaussPointsPL { Superclass::Init(); - float aScalarRange[2]; - GetSourceRange(aScalarRange); vtkDataSet* aDataSet = GetParentMesh(); float aScaleFactor = VISU_DeformedShapePL::GetScaleFactor( aDataSet ); + float* aScalarRange = GetScalarRange(); static double EPS = 1.0 / VTK_LARGE_FLOAT; if(fabs(aScalarRange[1]) > EPS) SetScale( aScaleFactor / aScalarRange[1] ); @@ -229,9 +228,10 @@ VISU_GaussPointsPL ::Update() { //cout << "VISU_GaussPointsPL::Update()" << endl; - - GetSourceRange(mySourceScalarRange); - myDeltaScalarRange = mySourceScalarRange[1] - mySourceScalarRange[0]; + float* aScalarRange = GetScalarRange(); + mySourceScalarRange[0] = aScalarRange[0]; + mySourceScalarRange[1] = aScalarRange[1]; + myDeltaScalarRange = aScalarRange[1] - aScalarRange[0]; SetAverageCellSize( VISU_DeformedShapePL::GetScaleFactor( GetParentMesh() ) ); @@ -241,7 +241,7 @@ VISU_GaussPointsPL myScalarArray = aCellData->GetScalars(); myPSMapper->SetLookupTable( myMapperTable ); - myPSMapper->SetScalarRange( mySourceScalarRange ); + myPSMapper->SetScalarRange( aScalarRange ); this->UpdateGlyph(); @@ -255,8 +255,7 @@ VISU_GaussPointsPL { //cout << "VISU_GaussPointsPL::UpdateGlyph()" << endl; - float aScalarRange[2]; - GetSourceRange( aScalarRange ); + float* aScalarRange = GetScalarRange(); if( myPSMapper->GetPointSpriteMode() == 0 ) // Results { -- 2.39.2