From: apo Date: Wed, 7 Dec 2005 09:49:54 +0000 (+0000) Subject: To use the same scalar range that was calculated during initlization of the pipe... X-Git-Tag: TG-D5-38-2003_D2005-20-12~54 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=6ddc1f984af6a4fb35942bee3eab2193755860bb;p=modules%2Fvisu.git To use the same scalar range that was calculated during initlization of the pipe-line --- 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 {