Salome HOME
Update Help for VISU module.
[modules/visu.git] / src / PIPELINE / VISU_FieldTransform.cxx
index 34da24790ca6315139fce8fea279587a63820ad5..5fd707425a202e69304563b7daa29b1e2a7ab698 100644 (file)
@@ -5,7 +5,7 @@
 //  File   : VISU_FieldTransform.cxx
 //  Module : VISU
 
-#include "VISU_FieldTransform.hxx"   
+#include "VISU_FieldTransform.hxx"
 #include "VTKViewer_Transform.h"
 
 #include <vtkObjectFactory.h>
 
 using namespace std;
 
-#ifdef DEBUG
-static int MYDEBUG = 0;
-#else
-static int MYDEBUG = 0;
-#endif
-
 vtkStandardNewMacro(VISU_FieldTransform);
 
-double VISU_FieldTransform::Ident(double theArg){ 
+double VISU_FieldTransform::Ident(double theArg){
   return theArg;
 }
-double VISU_FieldTransform::Log10(double theArg){ 
+double VISU_FieldTransform::Log10(double theArg){
   if(theArg <= 0.0) return -VTK_LARGE_FLOAT;
   return log10(theArg);
 }
@@ -56,7 +50,7 @@ unsigned long VISU_FieldTransform::GetMTime(){
   return vtkSource::GetMTime();
 }
 
-void VISU_FieldTransform::SetScalarTransform(TTransformFun theFunction) { 
+void VISU_FieldTransform::SetScalarTransform(TTransformFun theFunction) {
   myFunction = theFunction;
   if(myFunction == NULL) myFunction = &Ident;
   Modified();
@@ -72,7 +66,7 @@ void VISU_FieldTransform::SetSpaceTransform(VTKViewer_Transform* theTransform){
 }
 
 
-void VISU_FieldTransform::SetScalarRange(float theScalarRange[2]) { 
+void VISU_FieldTransform::SetScalarRange(float theScalarRange[2]) {
   myScalarRange[0] = theScalarRange[0];
   myScalarRange[1] = theScalarRange[1];
   Modified();
@@ -88,13 +82,13 @@ void VISU_FieldTransform::SetScalarMax(float theValue){
 
 
 template<typename TypeData> void
-ExecVectors(VISU_FieldTransform::TTransformFun theFunction, 
+ExecVectors(VISU_FieldTransform::TTransformFun theFunction,
            VTKViewer_Transform* theTransform,
-           float theScalarRange[2], int theNbComponent, 
+           float theScalarRange[2], int theNbComponent,
            TypeData* theInputData, TypeData* theOutputData)
 {
   vtkDataArray *inVectors = theInputData->GetVectors();
-  if ( !inVectors || theNbComponent < 1 ) return; 
+  if ( !inVectors || theNbComponent < 1 ) return;
   vtkFloatArray *newVectors = vtkFloatArray::New();
   newVectors->SetNumberOfComponents(3);
   newVectors->SetNumberOfTuples(theNbComponent);
@@ -135,8 +129,8 @@ ExecScalars(VISU_FieldTransform::TTransformFun theFunction, float theScalarRange
            int theNbComponent, TypeData* theInputData, TypeData* theOutputData)
 {
   vtkDataArray *inScalars = theInputData->GetScalars();
-  if ( !inScalars || theNbComponent < 1 ) 
-    return; 
+  if ( !inScalars || theNbComponent < 1 )
+    return;
   vtkFloatArray *newScalars = vtkFloatArray::New();
   newScalars->SetNumberOfComponents(1);
   newScalars->SetNumberOfTuples(theNbComponent);