]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
Porting on Mandriva 64
authorapo <apo@opencascade.com>
Wed, 5 Apr 2006 14:47:41 +0000 (14:47 +0000)
committerapo <apo@opencascade.com>
Wed, 5 Apr 2006 14:47:41 +0000 (14:47 +0000)
29 files changed:
src/VISUGUI/VisuGUI_ClippingDlg.cxx
src/VISUGUI/VisuGUI_CutLinesDlg.cxx
src/VISUGUI/VisuGUI_GaussPointsDlg.cxx
src/VISUGUI/VisuGUI_Module.cxx
src/VISUGUI/VisuGUI_OffsetDlg.cxx
src/VISUGUI/VisuGUI_OffsetDlg.h
src/VISUGUI/VisuGUI_Plot3DDlg.cxx
src/VISUGUI/VisuGUI_ScalarBarDlg.cxx
src/VISUGUI/VisuGUI_ScalarMapOnDeformedShapeDlg.cxx
src/VISUGUI/VisuGUI_Selection.cxx
src/VISUGUI/VisuGUI_TimeAnimation.cxx
src/VISUGUI/VisuGUI_TimeAnimation.h
src/VISUGUI/VisuGUI_Tools.cxx
src/VISU_I/VISU_ColoredPrs3d_i.cc
src/VISU_I/VISU_ColoredPrs3d_i.hh
src/VISU_I/VISU_CorbaMedConvertor.cxx
src/VISU_I/VISU_CutLines_i.cc
src/VISU_I/VISU_GaussPoints_i.cc
src/VISU_I/VISU_GaussPoints_i.hh
src/VISU_I/VISU_IsoSurfaces_i.cc
src/VISU_I/VISU_Prs3d_i.cc
src/VISU_I/VISU_Prs3d_i.hh
src/VISU_I/VISU_Result_i.cc
src/VISU_I/VISU_Result_i.hh
src/VISU_I/VISU_ScalarMapOnDeformedShape_i.cc
src/VISU_I/VISU_ScalarMapOnDeformedShape_i.hh
src/VISU_I/VISU_ScalarMap_i.cc
src/VISU_I/VISU_TimeAnimation.h
src/VISU_I/VISU_View_i.cc

index c2d918bd346eea0184972ef197725b8a978edbb7..656fb80ff74d43c7db9f6c44bbb773ed3f68feee 100644 (file)
@@ -120,7 +120,7 @@ public:
 
 
   VISU::Orientation myOrientation;
-  float myDistance;
+  vtkFloatingPointType myDistance;
   double myAngle[2];
 
   vtkPlaneSource* myPlaneSource;
@@ -129,8 +129,14 @@ public:
   void SetOrientation(VISU::Orientation theOrientation) {myOrientation = theOrientation;}
   VISU::Orientation GetOrientation() {return myOrientation;}
 
-  void SetDistance(float theDistance) {myDistance = theDistance;}
-  float GetDistance() {return myDistance;}
+  void SetDistance(vtkFloatingPointType theDistance) 
+  {
+    myDistance = theDistance;
+  }
+  vtkFloatingPointType GetDistance() 
+  {
+    return myDistance;
+  }
 
   void ShallowCopy(OrientedPlane* theOrientedPlane){
     SetNormal(theOrientedPlane->GetNormal());
@@ -182,7 +188,7 @@ protected:
     myActor->SetMapper(myMapper);
 
     vtkProperty* aProp = vtkProperty::New();
-    float anRGB[3];
+    vtkFloatingPointType anRGB[3];
 
     SUIT_ResourceMgr* aResourceMgr = VISU::GetResourceMgr();
 
@@ -607,8 +613,8 @@ void VisuGUI_ClippingDlg::onSelectionChanged()
       std::for_each(myPlanes.begin(),myPlanes.end(),TSetVisiblity(false));
       myPlanes.clear();
 
-      float anOffset [3];
-      myPrs3d->GetOffset(anOffset);
+      CORBA::Float anOffset[3];
+      myPrs3d->GetOffset(anOffset[0],anOffset[1],anOffset[2]);
 
       vtkIdType anId = 0, anEnd = myPrs3d->GetNumberOfClippingPlanes();
       for (; anId < anEnd; anId++) {
@@ -618,7 +624,7 @@ void VisuGUI_ClippingDlg::onSelectionChanged()
             VISU::TVTKPlane aTVTKPlane(anOrientedPlane);
             anOrientedPlane->Delete();
             aTVTKPlane->ShallowCopy(aPlane);
-            aTVTKPlane->myActor->SetPosition(anOffset);
+            aTVTKPlane->myActor->SetPosition(anOffset[0],anOffset[1],anOffset[2]);
             myPlanes.push_back(aTVTKPlane);
           }
         }
@@ -690,9 +696,9 @@ void VisuGUI_ClippingDlg::ClickOnNew()
     VISU::TVTKPlane aTVTKPlane(aPlane);
     myPlanes.push_back(aTVTKPlane);
 
-    float anOffset [3];
-    myPrs3d->GetOffset(anOffset);
-    aTVTKPlane->myActor->SetPosition(anOffset);
+    CORBA::Float anOffset[3];
+    myPrs3d->GetOffset(anOffset[0],anOffset[1],anOffset[2]);
+    aTVTKPlane->myActor->SetPosition(anOffset[0],anOffset[1],anOffset[2]);
 
     if (PreviewCheckBox->isChecked())
       aTVTKPlane->myActor->VisibilityOn();
@@ -817,18 +823,18 @@ void VisuGUI_ClippingDlg::SetCurrentPlaneParam()
 
   OrientedPlane* aPlane = myPlanes[aCurPlaneIndex].GetPointer();
 
-  float aNormal[3];
+  vtkFloatingPointType aNormal[3];
   VISU::Orientation anOrientation;
-  float aDir[3][3] = {{0, 0, 0}, {0, 0, 0}};
+  vtkFloatingPointType aDir[3][3] = {{0, 0, 0}, {0, 0, 0}};
   {
     static double aCoeff = vtkMath::Pi()/180.0;
 
-    float aRot[2] = {getRotation1(), getRotation2()};
+    vtkFloatingPointType aRot[2] = {getRotation1(), getRotation2()};
     aPlane->myAngle[0] = aRot[0];
     aPlane->myAngle[1] = aRot[1];
 
-    float anU[2] = {cos(aCoeff*aRot[0]), cos(aCoeff*aRot[1])};
-    float aV[2] = {sqrt(1.0-anU[0]*anU[0]), sqrt(1.0-anU[1]*anU[1])};
+    vtkFloatingPointType anU[2] = {cos(aCoeff*aRot[0]), cos(aCoeff*aRot[1])};
+    vtkFloatingPointType aV[2] = {sqrt(1.0-anU[0]*anU[0]), sqrt(1.0-anU[1]*anU[1])};
     aV[0] = aRot[0] > 0? aV[0]: -aV[0];
     aV[1] = aRot[1] > 0? aV[1]: -aV[1];
 
@@ -876,37 +882,37 @@ void VisuGUI_ClippingDlg::SetCurrentPlaneParam()
   myPrs3d->SetPlaneParam(aNormal, 1. - getDistance(), aPlane);
 
   vtkDataSet* aDataSet = myPrs3d->GetInput();
-  float *aPnt = aDataSet->GetCenter();
+  vtkFloatingPointType *aPnt = aDataSet->GetCenter();
 
-  float* anOrigin = aPlane->GetOrigin();
-  float aDel = aDataSet->GetLength()/2.0;
+  vtkFloatingPointType* anOrigin = aPlane->GetOrigin();
+  vtkFloatingPointType aDel = aDataSet->GetLength()/2.0;
 
-  float aDelta[2][3] = {{aDir[0][0]*aDel, aDir[0][1]*aDel, aDir[0][2]*aDel},
-                       {aDir[1][0]*aDel, aDir[1][1]*aDel, aDir[1][2]*aDel}};
-  float aParam, aPnt0[3], aPnt1[3], aPnt2[3];
+  vtkFloatingPointType aDelta[2][3] = {{aDir[0][0]*aDel, aDir[0][1]*aDel, aDir[0][2]*aDel},
+                                      {aDir[1][0]*aDel, aDir[1][1]*aDel, aDir[1][2]*aDel}};
+  vtkFloatingPointType aParam, aPnt0[3], aPnt1[3], aPnt2[3];
 
-  float aPnt01[3] = {aPnt[0] - aDelta[0][0] - aDelta[1][0],
-                    aPnt[1] - aDelta[0][1] - aDelta[1][1],
-                    aPnt[2] - aDelta[0][2] - aDelta[1][2]};
-  float aPnt02[3] = {aPnt01[0] + aNormal[0],
-                     aPnt01[1] + aNormal[1],
-                     aPnt01[2] + aNormal[2]};
+  vtkFloatingPointType aPnt01[3] = {aPnt[0] - aDelta[0][0] - aDelta[1][0],
+                                   aPnt[1] - aDelta[0][1] - aDelta[1][1],
+                                   aPnt[2] - aDelta[0][2] - aDelta[1][2]};
+  vtkFloatingPointType aPnt02[3] = {aPnt01[0] + aNormal[0],
+                                   aPnt01[1] + aNormal[1],
+                                   aPnt01[2] + aNormal[2]};
   vtkPlane::IntersectWithLine(aPnt01,aPnt02,aNormal,anOrigin,aParam,aPnt0);
 
-  float aPnt11[3] = {aPnt[0] - aDelta[0][0] + aDelta[1][0],
-                    aPnt[1] - aDelta[0][1] + aDelta[1][1],
-                    aPnt[2] - aDelta[0][2] + aDelta[1][2]};
-  float aPnt12[3] = {aPnt11[0] + aNormal[0],
-                    aPnt11[1] + aNormal[1],
-                    aPnt11[2] + aNormal[2]};
+  vtkFloatingPointType aPnt11[3] = {aPnt[0] - aDelta[0][0] + aDelta[1][0],
+                                   aPnt[1] - aDelta[0][1] + aDelta[1][1],
+                                   aPnt[2] - aDelta[0][2] + aDelta[1][2]};
+  vtkFloatingPointType aPnt12[3] = {aPnt11[0] + aNormal[0],
+                                   aPnt11[1] + aNormal[1],
+                                   aPnt11[2] + aNormal[2]};
   vtkPlane::IntersectWithLine(aPnt11,aPnt12,aNormal,anOrigin,aParam,aPnt1);
 
-  float aPnt21[3] = {aPnt[0] + aDelta[0][0] - aDelta[1][0],
-                    aPnt[1] + aDelta[0][1] - aDelta[1][1],
-                    aPnt[2] + aDelta[0][2] - aDelta[1][2]};
-  float aPnt22[3] = {aPnt21[0] + aNormal[0],
-                    aPnt21[1] + aNormal[1],
-                    aPnt21[2] + aNormal[2]};
+  vtkFloatingPointType aPnt21[3] = {aPnt[0] + aDelta[0][0] - aDelta[1][0],
+                                   aPnt[1] + aDelta[0][1] - aDelta[1][1],
+                                   aPnt[2] + aDelta[0][2] - aDelta[1][2]};
+  vtkFloatingPointType aPnt22[3] = {aPnt21[0] + aNormal[0],
+                                   aPnt21[1] + aNormal[1],
+                                   aPnt21[2] + aNormal[2]};
   vtkPlane::IntersectWithLine(aPnt21,aPnt22,aNormal,anOrigin,aParam,aPnt2);
 
   vtkPlaneSource* aPlaneSource = aPlane->myPlaneSource;
@@ -953,14 +959,14 @@ void VisuGUI_ClippingDlg::SetCurrentPlaneIJKParam()
   int i, axId = ButtonGroupIJKAxis->id (ButtonGroupIJKAxis->selected());
   VISU::Result_i::TAxis axis = (VISU::Result_i::TAxis) axId;
   gp_Dir dir;
-  const vector<float> * values =
+  const vector<vtkFloatingPointType> * values =
     result->GetAxisInfo(myPrs3d->GetMeshName(), axis, dir);
   if (!values)
     return;
 
   // find distance;
   int index = SpinBoxIJKIndex->value();
-  float distance = 0;
+  vtkFloatingPointType distance = 0;
   if (index < values->size())
     distance = (*values)[ index ];
 
@@ -977,14 +983,14 @@ void VisuGUI_ClippingDlg::SetCurrentPlaneIJKParam()
     }
   }
   // find rotation angles
-  float angle[2];
+  vtkFloatingPointType angle[2];
   int rotId[2] = {
     (axId == 0) ? 2 : axId - 1,
     (axId == 2) ? 0 : axId + 1
     };
   static double aCoeff = 180.0/vtkMath::Pi();
   for (i = 0; i < 2; ++i) {
-    float cosin = cos[ rotId[ i ]];
+    vtkFloatingPointType cosin = cos[ rotId[ i ]];
     if (maxCos < 0)
       cosin = -cosin;
     angle[ i ] = asin(cosin) * aCoeff;
@@ -1021,7 +1027,7 @@ void VisuGUI_ClippingDlg::setIJKByNonStructured()
   int planeIndex = ComboBoxPlanes->currentItem();
   OrientedPlane* plane = myPlanes[ planeIndex ].GetPointer();
   vtkPlaneSource* planeSource = plane->myPlaneSource;
-  float * planeNormal = planeSource->GetNormal();
+  vtkFloatingPointType * planeNormal = planeSource->GetNormal();
   gp_Dir normal(planeNormal[0], planeNormal[1], planeNormal[2]);
 
   // find a grid axis most co-directed with plane normal
@@ -1029,7 +1035,7 @@ void VisuGUI_ClippingDlg::setIJKByNonStructured()
   int i, maxAx = 0, gridAxId = 0;
   gp_Dir dir, gridDir;
   double maxDot = 0;
-  const vector<float> *curValues, *values = 0;
+  const vector<vtkFloatingPointType> *curValues, *values = 0;
   VISU::Result_i* result = myPrs3d->GetResult();
   for (i = 0; i < 3; ++i) {
     VISU::Result_i::TAxis axis = (VISU::Result_i::TAxis) i;
@@ -1104,8 +1110,8 @@ void VisuGUI_ClippingDlg::onIJKAxisChanged(int axisId)
   if (result) {
     VISU::Result_i::TAxis axis = (VISU::Result_i::TAxis) axisId;
     gp_Dir dir;
-    const vector<float> * indices = result->GetAxisInfo(myPrs3d->GetMeshName(),
-                                                        axis, dir);
+    const vector<vtkFloatingPointType> * indices = result->GetAxisInfo(myPrs3d->GetMeshName(),
+                                                                      axis, dir);
     if (indices)
       maxIndex = indices->size() - 1;
   }
index bdfe873e653b6d4a911131d1d902e242e90cb55e..b24e48c29163fa00ec755b63015b578f512ed161 100644 (file)
@@ -461,7 +461,7 @@ void VisuGUI_CutLinesDlg::setBaseDefault (bool theUpdate)
         //aView->Repaint();
       }
     }
-    float aPos = myCutLines->GetBasePlanePosition();
+    vtkFloatingPointType aPos = myCutLines->GetBasePlanePosition();
     myBasePlanePos->setText( QString::number(aPos) );
     myBasePlanePos->setEnabled(false);
   } else {
@@ -536,15 +536,15 @@ void VisuGUI_CutLinesDlg::DrawTable()
 
 void VisuGUI_CutLinesDlg::updateGlyphs(bool update){
   if (myPreviewActorGlyphs == 0 ) return;
-  const float *aDirLn = myCutLines->GetCutLinesPL()->GetDirLn();
-  const float *aBasePnt = myCutLines->GetCutLinesPL()->GetBasePnt();
-  float aSecondPnt[3];
-  float aBoundCenter[3];
+  const vtkFloatingPointType *aDirLn = myCutLines->GetCutLinesPL()->GetDirLn();
+  const vtkFloatingPointType *aBasePnt = myCutLines->GetCutLinesPL()->GetBasePnt();
+  vtkFloatingPointType aSecondPnt[3];
+  vtkFloatingPointType aBoundCenter[3];
 
   vtkAppendPolyData* aPolyData = myCutLines->GetCutLinesPL()->GetAppendPolyData();
   vtkDataSetMapper* aPlaneMapper = vtkDataSetMapper::New();
   aPlaneMapper->SetInput(aPolyData->GetOutput());
-  float bounds[6];
+  vtkFloatingPointType bounds[6];
   aPlaneMapper->GetBounds(bounds);
 
   for(int i=0; i<3; i++) aBoundCenter[i] = (bounds[i*2] + bounds[i*2+1])/2.0;
@@ -555,7 +555,7 @@ void VisuGUI_CutLinesDlg::updateGlyphs(bool update){
       aSecondPnt[i] = -aBasePnt[i] - aDirLn[i];
   }
   
-  float max_bound = 0;
+  vtkFloatingPointType max_bound = 0;
   max_bound < bounds[1]-bounds[0] ? max_bound = bounds[1] - bounds[0] : max_bound = max_bound;
   max_bound < bounds[3]-bounds[2] ? max_bound = bounds[3] - bounds[2] : max_bound = max_bound;
   max_bound < bounds[5]-bounds[4] ? max_bound = bounds[5] - bounds[4] : max_bound = max_bound;
index dfbe850fed9d75ed41cdc49bbde2f2985c2c5234..c88b47e35541a66e01ee03e25e1d772bdda9c974 100644 (file)
@@ -340,7 +340,7 @@ void VisuGUI_GaussScalarBarPane::initFromPrsObject(VISU::GaussPoints_i* thePrs)
   // "Title"
   myTextDlg->setTitleText(QString(thePrs->GetTitle()));
 
-  float R, G, B;
+  vtkFloatingPointType R, G, B;
   thePrs->GetTitleColor(&R, &G, &B);
 
   myTextDlg->myTitleFont->SetData(QColor((int)(R*255.), (int)(G*255.), (int)(B*255.)),
index f1dd565298572e73685e3bdd8eba6352e97a307c..a528cdde9e5a901286a8818c2a3a086d48ba193c 100644 (file)
@@ -1017,7 +1017,7 @@ namespace
                const char* theSuffix,
                std::ostringstream& theStr)
   {
-    float aColor[3];
+    vtkFloatingPointType aColor[3];
     vtkRenderer* aRenderer = theViewWindow->getRenderer();
     aRenderer->GetBackground(aColor);
     Storable::DataToStream(theStr,(std::string("myColor") + theSuffix + ".R").c_str(),aColor[0]);
@@ -1043,7 +1043,7 @@ namespace
     Storable::DataToStream(theStr,(std::string("myViewUp") + theSuffix + "[1]").c_str(),aViewUp[1]);
     Storable::DataToStream(theStr,(std::string("myViewUp") + theSuffix + "[2]").c_str(),aViewUp[2]);
       
-    float aParallelScale = aCamera->GetParallelScale();
+    vtkFloatingPointType aParallelScale = aCamera->GetParallelScale();
     Storable::DataToStream(theStr,(std::string("myParallelScale") + theSuffix).c_str(),aParallelScale);
       
     double aScaleFactor[3];
@@ -1059,7 +1059,7 @@ namespace
                const char* theSuffix,
                const Storable::TRestoringMap& theMap)
   {
-    float aColor[3];
+    vtkFloatingPointType aColor[3];
     aColor[0] = Storable::FindValue(theMap,std::string("myColor") + theSuffix + ".R").toDouble();
     aColor[1] = Storable::FindValue(theMap,std::string("myColor") + theSuffix + ".G").toDouble();
     aColor[2] = Storable::FindValue(theMap,std::string("myColor") + theSuffix + ".B").toDouble();
@@ -1085,7 +1085,7 @@ namespace
     aViewUp[2] = Storable::FindValue(theMap,std::string("myViewUp") + theSuffix + "[2]").toDouble();
     aCamera->SetViewUp(aViewUp);
 
-    float aParallelScale = Storable::FindValue(theMap,std::string("myParallelScale") + theSuffix).toDouble();
+    vtkFloatingPointType aParallelScale = Storable::FindValue(theMap,std::string("myParallelScale") + theSuffix).toDouble();
     aCamera->SetParallelScale(aParallelScale);
       
     double aScaleFactor[3];
@@ -1107,31 +1107,31 @@ namespace
       std::string aSegmentationMode;
       if(aWidgetCtrl->IsPlanesActive()){
        VISU_PlanesWidget *aPlanesWidget = aWidgetCtrl->GetPlanesWidget();
-       float anOrigin[3];
+       vtkFloatingPointType anOrigin[3];
        aPlanesWidget->GetOrigin(anOrigin);
        Storable::DataToStream(theStr,"myCursorOrigin[0]",anOrigin[0]);
        Storable::DataToStream(theStr,"myCursorOrigin[1]",anOrigin[1]);
        Storable::DataToStream(theStr,"myCursorOrigin[2]",anOrigin[2]);
        
-       float aNormal[3];
+       vtkFloatingPointType aNormal[3];
        aPlanesWidget->GetNormal(aNormal);
        Storable::DataToStream(theStr,"myCursorNormal[0]",aNormal[0]);
        Storable::DataToStream(theStr,"myCursorNormal[1]",aNormal[1]);
        Storable::DataToStream(theStr,"myCursorNormal[2]",aNormal[2]);
        
-       float aDepth = aPlanesWidget->Distance();
+       vtkFloatingPointType aDepth = aPlanesWidget->Distance();
        Storable::DataToStream(theStr,"myCursorDepth",aDepth);
        
        aSegmentationMode = "Planes";
       }else if(aWidgetCtrl->IsSphereActive()){
        VISU_SphereWidget *aSphereWidget = aWidgetCtrl->GetSphereWidget();
-       float aCenter[3];
+       vtkFloatingPointType aCenter[3];
        aSphereWidget->GetCenter(aCenter);
        Storable::DataToStream(theStr,"mySphereCursorCenter[0]",aCenter[0]);
        Storable::DataToStream(theStr,"mySphereCursorCenter[1]",aCenter[1]);
        Storable::DataToStream(theStr,"mySphereCursorCenter[2]",aCenter[2]);
        
-       float aRadius = aSphereWidget->GetRadius();
+       vtkFloatingPointType aRadius = aSphereWidget->GetRadius();
        Storable::DataToStream(theStr,"mySphereCursorRaduis",aRadius);
        
        aSegmentationMode = "Sphere";
@@ -1499,31 +1499,31 @@ OnRestoreConfiguration()
        
        if(aSegmentationMode == "Planes"){
          VISU_PlanesWidget *aPlanesWidget = aWidgetCtrl->GetPlanesWidget();
-         float anOrigin[3];
+         vtkFloatingPointType anOrigin[3];
          anOrigin[0] = Storable::FindValue(aMap,"myCursorOrigin[0]").toDouble();
          anOrigin[1] = Storable::FindValue(aMap,"myCursorOrigin[1]").toDouble();
          anOrigin[2] = Storable::FindValue(aMap,"myCursorOrigin[2]").toDouble();
          aPlanesWidget->SetOrigin(anOrigin);
          
-         float aNormal[3];
+         vtkFloatingPointType aNormal[3];
          aNormal[0] = Storable::FindValue(aMap,"myCursorNormal[0]").toDouble();
          aNormal[1] = Storable::FindValue(aMap,"myCursorNormal[1]").toDouble();
          aNormal[2] = Storable::FindValue(aMap,"myCursorNormal[2]").toDouble();
          aPlanesWidget->SetNormal(aNormal);
          
-         float aDepth = Storable::FindValue(aMap,"myCursorDepth").toDouble();
+         vtkFloatingPointType aDepth = Storable::FindValue(aMap,"myCursorDepth").toDouble();
          aPlanesWidget->SetDistance(aDepth);
          
          aMainWindow->SetPlanesSegementation(true);
        }else if(aSegmentationMode == "Sphere"){
          VISU_SphereWidget *aSphereWidget = aWidgetCtrl->GetSphereWidget();
-         float aCenter[3];
+         vtkFloatingPointType aCenter[3];
          aCenter[0] = Storable::FindValue(aMap,"mySphereCursorCenter[0]").toDouble();
          aCenter[1] = Storable::FindValue(aMap,"mySphereCursorCenter[1]").toDouble();
          aCenter[2] = Storable::FindValue(aMap,"mySphereCursorCenter[2]").toDouble();
          aSphereWidget->SetCenter(aCenter);
          
-         float aRadius = Storable::FindValue(aMap,"mySphereCursorRaduis").toDouble();
+         vtkFloatingPointType aRadius = Storable::FindValue(aMap,"mySphereCursorRaduis").toDouble();
          aSphereWidget->SetRadius(aRadius);
          
          aMainWindow->SetSphereSegementation(true);
@@ -1679,7 +1679,7 @@ void VisuGUI_Module::storeVisualParameters(int savePoint)
                  ip->setParameter( entry, param, QString::number( vActor->GetRepresentation() ).latin1() );
                  param = vtkParam + "Opacity";  
                  ip->setParameter( entry, param, QString::number( vActor->GetOpacity() ).latin1() );
-                 float r, g, b;
+                 vtkFloatingPointType r, g, b;
                  vActor->GetColor(r, g, b);
                  QString colorStr  = QString::number( r ); colorStr += gDigitsSep;
                          colorStr += QString::number( g ); colorStr += gDigitsSep; 
@@ -1703,7 +1703,7 @@ void VisuGUI_Module::storeVisualParameters(int savePoint)
                    param = vtkParam + "ClippingPlane_";
                    for ( int p = 0, nPlanes = vPrs->GetNumberOfClippingPlanes(); p < nPlanes; p++ ) {
                      vtkPlane* plane = vPrs->GetClippingPlane( p );
-                     float normal[3], origin[3];
+                     vtkFloatingPointType normal[3], origin[3];
                      plane->GetNormal( normal );
                      plane->GetOrigin( origin );
                      std::string planeValue  = QString::number( normal[0] ).latin1(); planeValue += gDigitsSep;
@@ -1933,7 +1933,7 @@ void VisuGUI_Module::restoreVisualParameters(int savePoint)
          else if ( paramName.find( "ClippingPlane" ) != std::string::npos ) {
            QStringList vals = QStringList::split( gDigitsSep, val );
            if ( vals.count() == 6 && vActor->GetPrs3d() ) {
-             float normal[3], origin[3];
+             vtkFloatingPointType normal[3], origin[3];
              for (int x = 0; x < 3; x++ ) {
                normal[x] = vals[x].toFloat();
                origin[x] = vals[x+3].toFloat();
index ed732b9cf80ee56322e925fdc1838ff5899204d0..7a28b3dccc03d7d513d2388aeb25a7a69155ecfc 100644 (file)
@@ -67,25 +67,25 @@ myModule(theModule)
   TopLayout->setSpacing(6);
   TopLayout->setMargin(11);
 
-  QHBox* aOffsetsPane = new QHBox (this);
-  aOffsetsPane->setSpacing(6);
+  QHBox* anOffsetsPane = new QHBox (this);
+  anOffsetsPane->setSpacing(6);
 
-  new QLabel ("dX:", aOffsetsPane);
-  myDxEdt = new QtxDblSpinBox (aOffsetsPane, "myDxEdt");
+  new QLabel ("dX:", anOffsetsPane);
+  myDxEdt = new QtxDblSpinBox (anOffsetsPane, "myDxEdt");
   myDxEdt->setRange(-MAXVAL, MAXVAL);
 
-  new QLabel("dY:", aOffsetsPane);
-  myDyEdt = new QtxDblSpinBox (aOffsetsPane, "myDyEdt");
+  new QLabel("dY:", anOffsetsPane);
+  myDyEdt = new QtxDblSpinBox (anOffsetsPane, "myDyEdt");
   myDyEdt->setRange(-MAXVAL, MAXVAL);
 
-  new QLabel("dZ:", aOffsetsPane);
-  myDzEdt = new QtxDblSpinBox (aOffsetsPane, "myDzEdt");
+  new QLabel("dZ:", anOffsetsPane);
+  myDzEdt = new QtxDblSpinBox (anOffsetsPane, "myDzEdt");
   myDzEdt->setRange(-MAXVAL, MAXVAL);
 
-  QPushButton* aResetBtn = new QPushButton(tr("BTN_RESET"), aOffsetsPane);
+  QPushButton* aResetBtn = new QPushButton(tr("BTN_RESET"), anOffsetsPane);
   connect(aResetBtn, SIGNAL(clicked()), this, SLOT(onReset()));
 
-  TopLayout->addWidget(aOffsetsPane);
+  TopLayout->addWidget(anOffsetsPane);
 
   if (!VISU::GetCStudy(VISU::GetAppStudy(theModule))->GetProperties()->IsLocked()) {
     mySaveChk = new QCheckBox ("Save to presentation", this);
@@ -136,26 +136,26 @@ myModule(theModule)
 void VisuGUI_OffsetDlg::addPresentation (VISU::Prs3d_i* thePrs)
 {
   myPrsList.append(thePrs);
-  OffsetStruct aOffs;
-  thePrs->GetOffset(aOffs.myOffset);
-  myOldOffsets.append(aOffs);
+  CORBA::Float anOffset[3];
+  thePrs->GetOffset(anOffset[0],anOffset[1],anOffset[2]);
+  OffsetStruct anOffs(anOffset[0],anOffset[1],anOffset[2]);
+  myOldOffsets.append(anOffs);
   if (myPrsList.count() == 1) {
-    setOffset(aOffs.myOffset);
+    setOffset(anOffs.myOffset);
   } else if (myPrsList.count() == 2) {
-    float aOffset[3];
-    aOffset[0] = aOffset[1] = aOffset[2] = 0;
-    setOffset(aOffset);
+    OffsetStruct anOffs;
+    setOffset(anOffs.myOffset);
   }
 }
 
-void VisuGUI_OffsetDlg::setOffset (const float* theOffset)
+void VisuGUI_OffsetDlg::setOffset (const vtkFloatingPointType* theOffset)
 {
   myDxEdt->setValue(theOffset[0]);
   myDyEdt->setValue(theOffset[1]);
   myDzEdt->setValue(theOffset[2]);
 }
 
-void VisuGUI_OffsetDlg::getOffset (float* theOffset) const
+void VisuGUI_OffsetDlg::getOffset (vtkFloatingPointType* theOffset) const
 {
   theOffset[0] = myDxEdt->value();
   theOffset[1] = myDyEdt->value();
@@ -177,11 +177,11 @@ bool VisuGUI_OffsetDlg::isToSave() const
     return false;
 }
 
-void VisuGUI_OffsetDlg::updateOffset (VISU::Prs3d_i* thePrs, float* theOffset)
+void VisuGUI_OffsetDlg::updateOffset (VISU::Prs3d_i* thePrs, vtkFloatingPointType* theOffset)
 {
   if (myPrsList.count() == 0) return;
 
-  if (isToSave()) thePrs->SetOffset(theOffset);
+  if (isToSave()) thePrs->SetOffset(theOffset[0],theOffset[1],theOffset[2]);
 
   ViewManagerList aViewManagerList;
   SalomeApp_Application* anApp = myModule->getApp();
@@ -213,10 +213,10 @@ void VisuGUI_OffsetDlg::updateOffset (VISU::Prs3d_i* thePrs, float* theOffset)
 
 void VisuGUI_OffsetDlg::accept()
 {
-  float aOffset[3];
-  getOffset(aOffset);
+  vtkFloatingPointType anOffset[3];
+  getOffset(anOffset);
   for (int i = 0; i < myPrsList.count(); i++) {
-    updateOffset(myPrsList.at(i), aOffset);
+    updateOffset(myPrsList.at(i), anOffset);
   }
   QDialog::accept();
 }
@@ -231,10 +231,10 @@ void VisuGUI_OffsetDlg::reject()
 
 void VisuGUI_OffsetDlg::onApply()
 {
-  float aOffset[3];
-  getOffset(aOffset);
+  vtkFloatingPointType anOffset[3];
+  getOffset(anOffset);
   for (int i = 0; i < myPrsList.count(); i++) {
-    updateOffset(myPrsList.at(i), aOffset);
+    updateOffset(myPrsList.at(i), anOffset);
   }
 }
 
index 98a0bdb09f2bc58b05af3c9a527fb7455cda135a..81a86bbbbf1518e956d5715a8086c5cf93cf84ad 100644 (file)
@@ -21,6 +21,7 @@
 #ifndef DIALOGBOX_OFFSET_H
 #define DIALOGBOX_OFFSET_H
 
+#include "VTKViewer.h"
 #include "VISU_Prs3d_i.hh"
 
 // QT Includes
@@ -31,8 +32,23 @@ class QCheckBox;
 class QtxDblSpinBox;
 class VisuGUI;
 
-struct OffsetStruct {
-  float myOffset[3];
+struct OffsetStruct
+{
+  vtkFloatingPointType myOffset[3];
+
+  OffsetStruct()
+  {
+    myOffset[0] = myOffset[1] = myOffset[2] = 0;
+  }
+
+  OffsetStruct(vtkFloatingPointType theX,
+              vtkFloatingPointType theY,
+              vtkFloatingPointType theZ)
+  {
+    myOffset[0] = theX;
+    myOffset[1] = theY;
+    myOffset[2] = theZ;
+  }
 };
 
 class VisuGUI_OffsetDlg: public QDialog
@@ -45,8 +61,8 @@ class VisuGUI_OffsetDlg: public QDialog
   void addPresentation (VISU::Prs3d_i* thePrs);
   int getPrsCount() const { return myPrsList.count(); }
 
-  void setOffset (const float* theOffset);
-  void getOffset (float* theOffset) const;
+  void setOffset (const vtkFloatingPointType* theOffset);
+  void getOffset (vtkFloatingPointType* theOffset) const;
   bool isToSave() const;
 
  public slots:
@@ -59,7 +75,7 @@ class VisuGUI_OffsetDlg: public QDialog
   void onHelp();
 
  private:
-  void updateOffset (VISU::Prs3d_i* thePrs, float* theOffset);
+  void updateOffset (VISU::Prs3d_i* thePrs, vtkFloatingPointType* theOffset);
 
   VisuGUI * myModule;
 
index ed955d7f298fb00d7e2f336d9612afa56e9ee543..b80b5417084f02bb2b8069eca9e268d936802dd9 100644 (file)
@@ -78,20 +78,20 @@ static void renderViewFrame (SVTK_ViewWindow* vw)
 //=======================================================================
 class TPlane : public SALOME_Actor
 {
-  float                mySize;
+  vtkFloatingPointType mySize;
   vtkDataSetMapper*    myMapper;
   vtkPlaneSource*      myPlaneSource;
 
  public:
   // constructor
-  TPlane(float planeSize): mySize(planeSize)
+  TPlane(vtkFloatingPointType planeSize): mySize(planeSize)
   {
     Init();
   }
   // set plane parameters
-  void Set(float origin[3], float normal[3])
+  void Set(vtkFloatingPointType origin[3], vtkFloatingPointType normal[3])
   {
-    float point2[3], point1[3];
+    vtkFloatingPointType point2[3], point1[3];
     vtkMath::Perpendiculars(normal, point1, point2, 0.);
     for (int i = 0; i < 3; ++i) {
       point1[ i ] = point1[ i ] * mySize + origin[ i ];
@@ -285,7 +285,7 @@ void VisuGUI_Plot3DPane::restorePrsParams()
 void VisuGUI_Plot3DPane::onPositionSpn()
 {
   if (myPrs && !RelativeChkB->isChecked()) {
-    float minPos, maxPos;
+    vtkFloatingPointType minPos, maxPos;
     storePrsParams();
     myPrs->GetPlot3DPL()->GetMinMaxPosition(minPos, maxPos);
     restorePrsParams();
@@ -323,7 +323,7 @@ void VisuGUI_Plot3DPane::orientationChanged(int Id)
 //=======================================================================
 void VisuGUI_Plot3DPane::onRelativePos(bool isRelativePos)
 {
-  float minPos = 0., maxPos = 1., pos = PositionSpn->value();
+  vtkFloatingPointType minPos = 0., maxPos = 1., pos = PositionSpn->value();
   if (myPrs) {
     storePrsParams();
     myPrs->GetPlot3DPL()->GetMinMaxPosition(minPos, maxPos);
@@ -376,7 +376,7 @@ void VisuGUI_Plot3DPane::updatePreview()
     }
     // set plane parameters corresponding to control values
     storePrsParams();
-    float normal[3], origin[3];
+    vtkFloatingPointType normal[3], origin[3];
     myPrs->GetPlot3DPL()->GetBasePlane(origin, normal, true);
     planePreview->Set(origin, normal);
     restorePrsParams();
index bf91604a397451e9e674f5eabd400dcad6e32eba..fbbfa6505024e11ec4be15ba2195556b239a2bab 100644 (file)
@@ -561,7 +561,7 @@ void VisuGUI_ScalarBarPane::initFromPrsObject(VISU::ScalarMap_i* thePrs) {
   default:
     setLogarithmic(false);
   }
-  float aRange[2];
+  vtkFloatingPointType aRange[2];
   thePrs->GetScalarMapPL()->GetSourceRange(aRange);
   Rmin = aRange[0]; Rmax = aRange[1];
   setRange( thePrs->GetMin(), thePrs->GetMax(),
@@ -603,7 +603,7 @@ void VisuGUI_ScalarBarPane::initFromPrsObject(VISU::ScalarMap_i* thePrs) {
   // "Title"
   myTextDlg->setTitleText(QString(thePrs->GetTitle()));
 
-  float R, G, B;
+  vtkFloatingPointType R, G, B;
   thePrs->GetTitleColor(&R, &G, &B);
 
   myTextDlg->myTitleFont->SetData(QColor((int)(R*255.), (int)(G*255.), (int)(B*255.)),
@@ -710,9 +710,9 @@ void VisuGUI_ScalarBarPane::createScalarBar()
                                  isTitleBold,isTitleItalic,isTitleShadow);
   vtkTextProperty* aTitleProp = aScalarBarActor->GetTitleTextProperty();
   aTitleProp->SetFontFamily(aTitleFontFamily);
-  aTitleProp->SetColor(float(aTitleColor.red())/255.,
-                      float(aTitleColor.green())/255.,
-                      float(aTitleColor.blue())/255.);
+  aTitleProp->SetColor(vtkFloatingPointType(aTitleColor.red())/255.,
+                      vtkFloatingPointType(aTitleColor.green())/255.,
+                      vtkFloatingPointType(aTitleColor.blue())/255.);
   (isTitleBold)? aTitleProp->BoldOn() : aTitleProp->BoldOff();
   (isTitleItalic)? aTitleProp->ItalicOn() : aTitleProp->ItalicOff();
   (isTitleShadow)? aTitleProp->ShadowOn() : aTitleProp->ShadowOff();
@@ -727,9 +727,9 @@ void VisuGUI_ScalarBarPane::createScalarBar()
                                  isLabelBold, isLabelItalic, isLabelShadow);
   vtkTextProperty* aLabelProp = aScalarBarActor->GetLabelTextProperty();
   aLabelProp->SetFontFamily(aLabelFontFamily);
-  aLabelProp->SetColor(float(aLabelColor.red())/255.,
-                      float(aLabelColor.green())/255.,
-                      float(aLabelColor.blue())/255.);
+  aLabelProp->SetColor(vtkFloatingPointType(aLabelColor.red())/255.,
+                      vtkFloatingPointType(aLabelColor.green())/255.,
+                      vtkFloatingPointType(aLabelColor.blue())/255.);
   (isLabelBold)? aLabelProp->BoldOn() : aLabelProp->BoldOff();
   (isLabelItalic)? aLabelProp->ItalicOn() : aLabelProp->ItalicOff();
   (isLabelShadow)? aLabelProp->ShadowOn() : aLabelProp->ShadowOff();
@@ -907,7 +907,7 @@ void VisuGUI_ScalarBarPane::changeScalarMode( int theMode )
 {
   if ( myScalarMap ) {
     if ( RBFrange->isChecked() ) {
-      float aRange[2];
+      vtkFloatingPointType aRange[2];
       myScalarMap->SetScalarMode(theMode);
       myScalarMap->GetScalarMapPL()->GetSourceRange(aRange);
       MinEdit->setText( QString::number( aRange[0] ) );
index d23580337d703a0034db43ee723608eeb7bd79c9..cc87ab69df7a1a68b8319de6bbaab94f88dcc3d5 100644 (file)
@@ -444,7 +444,7 @@ void VisuGUI_ScalarMapOnDeformedShapeDlg::onTimeStampChanged(int){
 
 void VisuGUI_ScalarMapOnDeformedShapeDlg::UpdateScalarField(){
   myPrs->SetScale(getFactor());
-  float aRange[2];
+  vtkFloatingPointType aRange[2];
   myPrs->GetScalarMapOnDeformedShapePL()->Build();
   myPrs->GetScalarMapOnDeformedShapePL()->Update();
   myPrs->GetScalarMapOnDeformedShapePL()->GetSourceRange(aRange);
index 7e5e658e8474796dd0722af8480ef8d07025b65f..46549cc52a6e8f37bd71a5dae876261c0de6918f 100644 (file)
@@ -322,7 +322,7 @@ void VisuGUI_SelectionDlg::closeEvent (QCloseEvent* theEvent)
 
 template<class TData> QString getValue(TData* theData, int theId){
   if (vtkDataArray *aScalar = theData->GetScalars()){
-    float aVal = aScalar->GetTuple1(theId);
+    vtkFloatingPointType aVal = aScalar->GetTuple1(theId);
     return QString::number(aVal);
   } else {
     return QString("No data");
@@ -331,7 +331,7 @@ template<class TData> QString getValue(TData* theData, int theId){
 
 template<class TData> QString getVector(TData* theData, int theId){
   if (vtkDataArray *aVector = theData->GetVectors()) {
-    float *aVal = aVector->GetTuple3(theId);
+    vtkFloatingPointType *aVal = aVector->GetTuple3(theId);
     return QString("%1; %2; %3").arg(aVal[0]).arg(aVal[1]).arg(aVal[2]);
   } else {
     return QString("No data");
@@ -417,7 +417,7 @@ void VisuGUI_SelectionDlg::onSelectionEvent() {
     VISU_Actor* anVISUActor =
       VISU::FindActor(aViewWindow, aSObject->GetID().c_str());
     if (anVISUActor) {
-      float aCoord[6];
+      vtkFloatingPointType aCoord[6];
       anVISUActor->GetBounds(aCoord);
       myXPosLbl->setText(QString::number( aCoord[0] ));
       myYPosLbl->setText(QString::number( aCoord[2] ));
@@ -428,7 +428,7 @@ void VisuGUI_SelectionDlg::onSelectionEvent() {
       myDZLbl->setText(QString::number( ABS(aCoord[5]-aCoord[4]) ));
 
       TColStd_IndexedMapOfInteger aMapIndex;
-      typedef map<int,float*> PointsMap;
+      typedef map<int,vtkFloatingPointType*> PointsMap;
       PointsMap aPointsMap;
 
       aSelector->GetIndex(anIO, aMapIndex);
@@ -442,7 +442,7 @@ void VisuGUI_SelectionDlg::onSelectionEvent() {
         switch (aType) {
         case 0:
           {
-            float* aCoord = anVISUActor->GetNodeCoord(anID);
+            vtkFloatingPointType* aCoord = anVISUActor->GetNodeCoord(anID);
            int aVTKID = anVISUActor->GetNodeVTKID(anID);
             myXValLbl->setText( QString::number( aCoord[0] ) );
             myYValLbl->setText( QString::number( aCoord[1] ) );
@@ -466,7 +466,7 @@ void VisuGUI_SelectionDlg::onSelectionEvent() {
                 myCellScalarValLbl->setText(getValue(aCellData, aVTKID));
                 myCellVectorValLbl->setText(getVector(aCellData, aVTKID));
 
-                float* aCoord;
+                vtkFloatingPointType* aCoord;
                 vtkIdList *aPointList = aCell->GetPointIds();
 
                 for (int i = 0; i < aNbOfPoints; i++) {
@@ -487,7 +487,7 @@ void VisuGUI_SelectionDlg::onSelectionEvent() {
         myListPoints->verticalHeader()->setLabel(i, QString::number( i ));
         int id = It->first;
         myListPoints->setText(i, 0, QString::number( id ));
-        float* aCoord = It->second;
+        vtkFloatingPointType* aCoord = It->second;
         myListPoints->setText(i, 1, QString::number( aCoord[0] ));
         myListPoints->setText(i, 2, QString::number( aCoord[1] ));
         myListPoints->setText(i, 3, QString::number( aCoord[2] ));
index c5e32dc870deb565edfa8f5c253a70f5453af2ef..3ac37f5f28ce0747f55923a6de2c429a0a23e6bb 100644 (file)
@@ -290,9 +290,9 @@ void ArrangeDlg::acceptAnimation()
     FieldData& aData = myAnimator->getFieldData(myFieldLst->currentItem());
     if (aData.myPrs.empty())
       myAnimator->generatePresentations(myFieldLst->currentItem());
-    float aBounds[6];
+    vtkFloatingPointType aBounds[6];
     aData.myPrs[0]->GetBounds(aBounds);
-    float aDist = 0;
+    vtkFloatingPointType aDist = 0;
     int aAxis = getAxis();
     switch (aAxis) {
     case XAxis:
@@ -305,10 +305,10 @@ void ArrangeDlg::acceptAnimation()
       aDist = fabs(aBounds[5] - aBounds[4]);
     }
 
-    float dx = fabs(aBounds[1] - aBounds[0]);
-    float dy = fabs(aBounds[3] - aBounds[2]);
-    float dz = fabs(aBounds[5] - aBounds[4]);
-    float max = (dx > dy) ? dx : dy;
+    vtkFloatingPointType dx = fabs(aBounds[1] - aBounds[0]);
+    vtkFloatingPointType dy = fabs(aBounds[3] - aBounds[2]);
+    vtkFloatingPointType dz = fabs(aBounds[5] - aBounds[4]);
+    vtkFloatingPointType max = (dx > dy) ? dx : dy;
     max = (dz > max) ? dz : max;
     max /= 100.0;
 
@@ -351,13 +351,13 @@ void ArrangeDlg::acceptViewWindow()
         anActor->SetPosition(aOffs.myOffset);
       if (mySaveChk)
        if (mySaveChk->isChecked())
-         aPrs->SetOffset(aOffs.myOffset);
+         aPrs->SetOffset(aOffs.myOffset[0],aOffs.myOffset[1],aOffs.myOffset[2]);
     }
   } else {
-    float aDist = 0;
-    float aShift = 0;
-    float aPrevDist = 0;
-    float aPrevShift = 0;
+    vtkFloatingPointType aDist = 0;
+    vtkFloatingPointType aShift = 0;
+    vtkFloatingPointType aPrevDist = 0;
+    vtkFloatingPointType aPrevShift = 0;
     int i;
     QMap<VISU::Prs3d_i*, int>::Iterator it;
     for (it = myPrsMap.begin(), i = 0; it != myPrsMap.end(); ++it, i++) {
@@ -365,12 +365,12 @@ void ArrangeDlg::acceptViewWindow()
       if (VISU_Actor* aActor = VISU::GetActor(aPrs, myViewWindow)) {
        int aAxis = getAxis();
 
-       float aZeroOffset[3];
+       vtkFloatingPointType aZeroOffset[3];
         aZeroOffset[0] = aZeroOffset[1] = aZeroOffset[2] = 0;
        aActor->SetPosition(aZeroOffset);
         aActor->GetMapper()->Update();
 
-       float aBounds[6];
+       vtkFloatingPointType aBounds[6];
        aActor->GetBounds(aBounds);
        switch (aAxis) {
        case XAxis:
@@ -382,18 +382,18 @@ void ArrangeDlg::acceptViewWindow()
        case ZAxis:
          aDist = fabs(aBounds[5] - aBounds[4]);
        }
-       float aOffset[3];
+       vtkFloatingPointType aOffset[3];
         aOffset[0] = aOffset[1] = aOffset[2] = 0;
         aOffset[aAxis] =
           (aBounds[2*aAxis+1] < aBounds[2*aAxis]) ? -aBounds[2*aAxis+1] : -aBounds[2*aAxis];
 
         if (i > 0) {
-          float aCCDist = (aDist + aPrevDist) / 2.0;
+          vtkFloatingPointType aCCDist = (aDist + aPrevDist) / 2.0;
 
-          float dx = fabs(aBounds[1] - aBounds[0]);
-          float dy = fabs(aBounds[3] - aBounds[2]);
-          float dz = fabs(aBounds[5] - aBounds[4]);
-          float max = (dx > dy) ? dx : dy;
+          vtkFloatingPointType dx = fabs(aBounds[1] - aBounds[0]);
+          vtkFloatingPointType dy = fabs(aBounds[3] - aBounds[2]);
+          vtkFloatingPointType dz = fabs(aBounds[5] - aBounds[4]);
+          vtkFloatingPointType max = (dx > dy) ? dx : dy;
           max = (dz > max) ? dz : max;
           max /= 100.0;
 
@@ -428,7 +428,7 @@ void ArrangeDlg::acceptViewWindow()
        aActor->SetPosition(aOffset);
        if (mySaveChk)
          if (mySaveChk->isChecked())
-           aPrs->SetOffset(aOffset);
+           aPrs->SetOffset(aOffset[0],aOffset[1],aOffset[2]);
 
        aPrevDist = aDist;
        aPrevShift = aShift;
index af7df3f2a4deb9692a7a48533888a03ba7e0fcdc..2f15249a1849d20f3843a48805fe948b141746d0 100644 (file)
@@ -11,8 +11,8 @@
 #ifndef VISUGUI_TIMEANIMATION_H
 #define VISUGUI_TIMEANIMATION_H
 
+#include "VTKViewer.h"
 #include "QtxDblSpinBox.h"
-
 #include "SALOMEDSClient_Study.hxx"
 
 #include <qdialog.h>
@@ -64,7 +64,7 @@ class ArrangeDlg: public QDialog
 
  private:
   struct Offset {
-    float myOffset[3];
+    vtkFloatingPointType myOffset[3];
   };
 
 
index 79b6607f01bf3a9ab43b6997bf10e8ea57aa2970..4427982a013385f47b82897bd6391dd274fe2d2a 100644 (file)
@@ -617,7 +617,7 @@ namespace VISU
 
     QApplication::setOverrideCursor( Qt::waitCursor );
     try {
-      if (aActor = thePrs->CreateActor())
+      if ((aActor = thePrs->CreateActor()))
         theViewWindow->AddActor(aActor);
     } catch(std::exception& exc) {
       SUIT_MessageBox::warn1
@@ -706,15 +706,17 @@ namespace VISU
     QApplication::restoreOverrideCursor();
   }
 
-  static bool ComputeVisiblePropBounds(SVTK_ViewWindow* theViewWindow,
-                                      float             allBounds[6], 
-                                      const char*       theActorClassName = "VISU_Actor")
+  static 
+  bool
+  ComputeVisiblePropBounds(SVTK_ViewWindow* theViewWindow,
+                          vtkFloatingPointType allBounds[6], 
+                          const char* theActorClassName = "VISU_Actor")
   {
     vtkRenderer *aRen = theViewWindow->getRenderer();
     vtkActorCollection *anActColl = aRen->GetActors(); 
     vtkProp *prop;
-    float   *bounds;
-    int     somethingVisible = false;
+    vtkFloatingPointType *bounds;
+    int somethingVisible = false;
 
     allBounds[0] = allBounds[2] = allBounds[4] = VTK_LARGE_FLOAT;
     allBounds[1] = allBounds[3] = allBounds[5] = -VTK_LARGE_FLOAT;
@@ -744,14 +746,14 @@ namespace VISU
 
   void SetFitAll(SVTK_ViewWindow* theViewWindow)
   {
-    static float PRECISION = 0.000001;
-    static float DEVIATION = 600;
-    float XYZ_Bnd[6];
+    static vtkFloatingPointType PRECISION = 0.000001;
+    static vtkFloatingPointType DEVIATION = 600;
+    vtkFloatingPointType XYZ_Bnd[6];
     if (!ComputeVisiblePropBounds(theViewWindow, XYZ_Bnd)) return;
 
-    float absX = XYZ_Bnd[1] - XYZ_Bnd[0];
-    float absY = XYZ_Bnd[3] - XYZ_Bnd[2];
-    float absZ = XYZ_Bnd[5] - XYZ_Bnd[4];
+    vtkFloatingPointType absX = XYZ_Bnd[1] - XYZ_Bnd[0];
+    vtkFloatingPointType absY = XYZ_Bnd[3] - XYZ_Bnd[2];
+    vtkFloatingPointType absZ = XYZ_Bnd[5] - XYZ_Bnd[4];
 
     enum CameraOrient {e3D, eFront, eLeft, eTop};
     CameraOrient aCameraOrient = e3D;
@@ -762,9 +764,9 @@ namespace VISU
         if (absZ <= PRECISION) aCameraOrient = eTop;
         else {
           // all the three dimensions exceeds precision
-          float dev_abs_XY = absX / absY;
-          float dev_abs_YZ = absY / absZ;
-          float dev_abs_XZ = absX / absZ;
+          vtkFloatingPointType dev_abs_XY = absX / absY;
+          vtkFloatingPointType dev_abs_YZ = absY / absZ;
+          vtkFloatingPointType dev_abs_XZ = absX / absZ;
           if (dev_abs_XY >= DEVIATION || 1./dev_abs_YZ >= DEVIATION)
             aCameraOrient = eLeft;
           else {
@@ -953,14 +955,10 @@ namespace VISU
          if(aPlot){
            QList<Plot2d_Curve> clist;
            aPlot->getCurves( clist );
-           SPlot2d_Curve* plotCurve = 0;
-           SPlot2d_Curve* tmpCurve;
            for (int i = 0; i < clist.count(); i++) {
-             tmpCurve = dynamic_cast<SPlot2d_Curve*>(clist.at(i));
-             if (tmpCurve && 
-                 tmpCurve->hasIO() &&
-                 (tmpCurve->getIO()->getEntry() == anEntry))
-               aPlot->eraseCurve(clist.at(i));
+             if(SPlot2d_Curve* plotCurve = dynamic_cast<SPlot2d_Curve*>(clist.at(i)))
+               if(plotCurve->hasIO() && (plotCurve->getIO()->getEntry() == anEntry))
+                 aPlot->eraseCurve(clist.at(i));
            }
          }
        }
index 5501a17ada3f85bd6b671ae9d0b84eaf7a8bc60f..22977d6773016382b28b861b5ac9aa1715134abc 100644 (file)
@@ -128,7 +128,7 @@ VISU::ColoredPrs3d_i
     SetItalicTitle(anOrigin->IsItalicTitle());
     SetShadowTitle(anOrigin->IsShadowTitle());
     SetTitFontType(anOrigin->GetTitFontType());
-    float r,g,b;
+    vtkFloatingPointType r,g,b;
     anOrigin->GetTitleColor(&r,&g,&b);
     SetTitleColor(r,g,b);
     
@@ -341,7 +341,9 @@ VISU::ColoredPrs3d_i
 
 void
 VISU::ColoredPrs3d_i
-::GetTitleColor(float* theR, float* theG, float* theB)
+::GetTitleColor(vtkFloatingPointType* theR, 
+               vtkFloatingPointType* theG, 
+               vtkFloatingPointType* theB)
 {
   *theR = myTitleColor[0]; 
   *theG = myTitleColor[1]; 
@@ -350,7 +352,9 @@ VISU::ColoredPrs3d_i
 
 void
 VISU::ColoredPrs3d_i
-::SetTitleColor(float theR, float theG, float theB)
+::SetTitleColor(vtkFloatingPointType theR, 
+               vtkFloatingPointType theG, 
+               vtkFloatingPointType theB)
 {
   myTitleColor[0] = theR; 
   myTitleColor[1] = theG; 
@@ -415,7 +419,9 @@ VISU::ColoredPrs3d_i
 
 void
 VISU::ColoredPrs3d_i
-::GetLabelColor(float* theR, float* theG, float* theB)
+::GetLabelColor(vtkFloatingPointType* theR, 
+               vtkFloatingPointType* theG, 
+               vtkFloatingPointType* theB)
 {
   *theR = myLabelColor[0]; 
   *theG = myLabelColor[1]; 
@@ -424,7 +430,9 @@ VISU::ColoredPrs3d_i
 
 void
 VISU::ColoredPrs3d_i
-::SetLabelColor(float theR, float theG, float theB)
+::SetLabelColor(vtkFloatingPointType theR, 
+               vtkFloatingPointType theG, 
+               vtkFloatingPointType theB)
 {
   myLabelColor[0] = theR; 
   myLabelColor[1] = theG; 
@@ -470,11 +478,11 @@ VISU::ColoredPrs3d_i
   // Scalar Bar origin
   QString propertyName = QString( "scalar_bar_%1_" ).arg( anOrientation == 0 ? "vertical" : "horizontal" );
 
-  float aXorigin = (myOrientation == VISU::ScalarMap::VERTICAL) ? 0.01 : 0.2;
+  vtkFloatingPointType aXorigin = (myOrientation == VISU::ScalarMap::VERTICAL) ? 0.01 : 0.2;
   aXorigin = aResourceMgr->doubleValue("VISU", propertyName + "x", aXorigin);
   myPosition[0] = aXorigin;
 
-  float aYorigin = (myOrientation == VISU::ScalarMap::VERTICAL) ? 0.1 : 0.012;
+  vtkFloatingPointType aYorigin = (myOrientation == VISU::ScalarMap::VERTICAL) ? 0.1 : 0.012;
   aYorigin = aResourceMgr->doubleValue("VISU", propertyName + "y", aYorigin);
   myPosition[1] = aYorigin;
 
index 9e277a47e4f46a209bac769872a16b7b8127c7bc..6e2a5fd9814ccb99b4b4e21198c725418348d112 100644 (file)
@@ -135,7 +135,7 @@ namespace VISU
     VISU::ScalarMap::Orientation myOrientation;
     std::string myTitle;
     int myNumberOfLabels;
-    float myPosition[2], myWidth, myHeight;
+    vtkFloatingPointType myPosition[2], myWidth, myHeight;
 
   public:
     //----------------------------------------------------------------------------
@@ -218,11 +218,15 @@ namespace VISU
 
     virtual 
     void
-    GetTitleColor(float* theR, float* theG, float* theB);
+    GetTitleColor(vtkFloatingPointType* theR, 
+                 vtkFloatingPointType* theG, 
+                 vtkFloatingPointType* theB);
     
     virtual
     void
-    SetTitleColor(float theR, float theG, float theB);    
+    SetTitleColor(vtkFloatingPointType theR, 
+                 vtkFloatingPointType theG, 
+                 vtkFloatingPointType theB);    
 
     virtual
     bool
@@ -258,11 +262,15 @@ namespace VISU
 
     virtual 
     void
-    GetLabelColor(float* theR, float* theG, float* theB);
+    GetLabelColor(vtkFloatingPointType* theR, 
+                 vtkFloatingPointType* theG, 
+                 vtkFloatingPointType* theB);
 
     virtual
     void
-    SetLabelColor(float theR, float theG, float theB);
+    SetLabelColor(vtkFloatingPointType theR, 
+                 vtkFloatingPointType theG, 
+                 vtkFloatingPointType theB);
 
     //----------------------------------------------------------------------------
   protected:
@@ -276,13 +284,13 @@ namespace VISU
     bool myIsItalicTitle;
     bool myIsShadowTitle;
     int  myTitFontType;
-    float myTitleColor[3];
+    vtkFloatingPointType myTitleColor[3];
 
     bool myIsBoldLabel;
     bool myIsItalicLabel;
     bool myIsShadowLabel;
     int  myLblFontType;
-    float myLabelColor[3];
+    vtkFloatingPointType myLabelColor[3];
 
     VISU_ScalarMapPL* myScalarMapPL;
     bool myIsFixedRange;
index b1dc814ba896de75545557e01071e18aaacccbbc..e69db1a8827bd8e2d5f20e440f98a04835c2792c 100644 (file)
@@ -1206,7 +1206,6 @@ VISU_MEDConvertor
   if(theFamily->myIsDone) 
     return 0;
 
-  const VISU::TGeom2SubMesh& aGeom2SubMesh = theMeshOnEntity->myGeom2SubMesh;
   SALOME_MED::FAMILY_var aMedFamily = theFamily->myFamily;
   CORBA::Boolean anIsOnAllElements = aMedFamily->isOnAllElements();
   if(!anIsOnAllElements){
index 879b0531b617b305203ecde56bf9350340b47257..065956566954f254a41e8649615801b69cc470d9 100644 (file)
@@ -37,7 +37,7 @@
 using namespace VISU;
 using namespace std;
 
-static float EPS_machine = 1.0E-7;
+static vtkFloatingPointType EPS_machine = 1.0E-7;
 
 #ifdef _DEBUG_
 static int MYDEBUG = 0;
@@ -325,8 +325,8 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
     anAttr = aStudyBuilder->FindOrCreateAttribute(theSObject, "AttributeTableOfReal");
     SALOMEDS::AttributeTableOfReal_var aTableOfReal = SALOMEDS::AttributeTableOfReal::_narrow(anAttr);
     
-    typedef set<float> TXCont;
-    typedef map<float,float> TXYMap;
+    typedef set<vtkFloatingPointType> TXCont;
+    typedef map<vtkFloatingPointType,vtkFloatingPointType> TXYMap;
     typedef map<int,TXYMap> TXYMapCont;
     typedef map<long,long> TLineIdCont;
     
@@ -340,9 +340,9 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
     TXCont aXCont;
     TXYMapCont aXYMapCont; 
     TLineIdCont aLineIdCont;  // Define internal numeration of lines
-    const float *aDirLn = myCutLinesPL->GetDirLn();
-    const float *aBasePnt = myCutLinesPL->GetBasePnt();
-    const float *aBoundPrjLn = myCutLinesPL->GetBoundPrjLn();
+    const vtkFloatingPointType *aDirLn = myCutLinesPL->GetDirLn();
+    const vtkFloatingPointType *aBasePnt = myCutLinesPL->GetBasePnt();
+    const vtkFloatingPointType *aBoundPrjLn = myCutLinesPL->GetBoundPrjLn();
     for(int iLine = 0, jLine = 0; iLine < iLineEnd; iLine++){
       vtkDataSet *aDataSet = myCutLinesPL->GetAppendPolyData()->GetInput(iLine);
       aDataSet->Update();
@@ -364,7 +364,7 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
       if(MYDEBUG) MESSAGE("CutPlanes_i::BuildTableOfReal iLine = "<<iLine<<"; aNbPoints = "<<aNbPoints);
       aLineIdCont[iLine] = jLine++;
       TXYMap& aXYMap = aXYMapCont[iLine];
-      float aPnt[3], aVect[3], aDist;
+      vtkFloatingPointType aPnt[3], aVect[3], aDist;
       for(int i = 0; i < aNbPoints; i++){
        aDataSet->GetPoint(i,aPnt);
        Sub(aPnt,aBasePnt,aVect);
@@ -394,19 +394,19 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
        TXYMap aNewXYMap;
        TXYMap& aXYMap = aXYMapCont[iLine];
        TXYMap::const_iterator aXYMapIter = aXYMap.begin();
-       std::list<float> XKeys;
+       std::list<vtkFloatingPointType> XKeys;
        for (;aXYMapIter != aXYMap.end() ; aXYMapIter++) XKeys.push_back(aXYMapIter->first);
        XKeys.sort();
        if (XKeys.size() > 1) {
-         float a_first_indx = XKeys.front();
-         float a_last_indx = XKeys.back();
+         vtkFloatingPointType a_first_indx = XKeys.front();
+         vtkFloatingPointType a_last_indx = XKeys.back();
          if (a_first_indx > a_last_indx){
            XKeys.reverse();
-           float tmp = a_first_indx;
+           vtkFloatingPointType tmp = a_first_indx;
            a_first_indx = a_last_indx;
            a_last_indx = tmp;
          }
-         std::list<float>::const_iterator aIter = XKeys.begin();
+         std::list<vtkFloatingPointType>::const_iterator aIter = XKeys.begin();
          for (int k=0;k<XKeys.size() and aIter != XKeys.end();k++,aIter++){
            // Warning: value '1.0' come from workaround:
            // see also aDist = vtkMath::Dot(aVect,aDirLn) / aBoundPrjLn[2];
@@ -431,9 +431,9 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
        aNewXYMap[aXYMapIter[0]->first] = aXYMapIter[0]->second;
        aXCont.insert(aXYMapIter[0]->first);
        for(; aXYMapIter[1] != aXYMap.end(); aXYMapIter[0]++, aXYMapIter[1]++){
-         float aY[3] = {aXYMapIter[0]->second, aXYMapIter[1]->second, 0.0};
+         vtkFloatingPointType aY[3] = {aXYMapIter[0]->second, aXYMapIter[1]->second, 0.0};
          aY[2] = (aY[0] + aY[1])/2.0;
-         float aX[3] = {aXYMapIter[0]->first, aXYMapIter[1]->first, 0.0};
+         vtkFloatingPointType aX[3] = {aXYMapIter[0]->first, aXYMapIter[1]->first, 0.0};
          aX[2] = (aX[0] + aX[1])/2.0;
          aNewXYMap[aX[2]] = aY[2];
          aXCont.insert(aX[2]);
@@ -454,7 +454,7 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
     aTableOfReal->SetNbColumns(iEnd);
     TXCont::const_iterator aXContIter = aXCont.begin();
     for(long i = 0; aXContIter != aXCont.end(); aXContIter++, i++){
-      float aDist = *aXContIter; 
+      vtkFloatingPointType aDist = *aXContIter; 
       aTableOfReal->PutValue(aDist,1,i+1);
       aString.sprintf("%d",i);
       aTableOfReal->SetColumnTitle(i+1,aString.latin1());
@@ -467,7 +467,7 @@ void VISU::CutLines_i::BuildTableOfReal(SALOMEDS::SObject_ptr theSObject){
        TXYMap::const_iterator aXYMapIter = aXYMap.find(aDist);
        // Can we find some value that belong to the line and have the same X coordinate?
        if(aXYMapIter == aXYMap.end()) continue;
-       float aVal = aXYMapIter->second;
+       vtkFloatingPointType aVal = aXYMapIter->second;
        aTableOfReal->PutValue(aVal,iLineId+2,i+1);
       }
     }
index 93da92ac33f85fb5c43216f9cd0df2be2f7c2676..cb73301bef5313f5af5611088807c7e20d9fad5d 100644 (file)
@@ -154,16 +154,16 @@ VISU::GaussPoints_i
   int aBicolor = aResourceMgr->integerValue( "VISU", "scalar_bar_bicolor", GetBiColor() );
   SetBiColor( aBicolor == 0 );
 
-  float aSpacing = aResourceMgr->doubleValue( "VISU", "scalar_bar_spacing", GetSpacing() );
+  vtkFloatingPointType aSpacing = aResourceMgr->doubleValue( "VISU", "scalar_bar_spacing", GetSpacing() );
   SetSpacing( aSpacing );
 
-  float aScaleFactor = aResourceMgr->doubleValue( "VISU", "deformed_shape_scale_factor", GetScaleFactor() );
+  vtkFloatingPointType aScaleFactor = aResourceMgr->doubleValue( "VISU", "deformed_shape_scale_factor", GetScaleFactor() );
   SetScaleFactor( aScaleFactor );
 
   int aPrimitiveType = aResourceMgr->integerValue( "VISU", "point_sprite_primitive_type", GetPrimitiveType() );
   SetPrimitiveType( aPrimitiveType );
 
-  float aClamp = aResourceMgr->doubleValue( "VISU", "point_sprite_clamp", GetClamp() );
+  vtkFloatingPointType aClamp = aResourceMgr->doubleValue( "VISU", "point_sprite_clamp", GetClamp() );
   SetClamp( aClamp );
 
   int aMinSize = aResourceMgr->integerValue( "VISU", "point_sprite_min_size", ( int )( GetMinSize() * 100.0 ) );
@@ -178,7 +178,7 @@ VISU::GaussPoints_i
   int aMagnification = aResourceMgr->integerValue( "VISU", "point_sprite_magnification", ( int )( GetMagnification() * 100.0 ) );
   SetMagnification( aMagnification / 100.0 );
 
-  float anIncrement = aResourceMgr->doubleValue( "VISU", "point_sprite_increment", GetMagnificationIncrement() );
+  vtkFloatingPointType anIncrement = aResourceMgr->doubleValue( "VISU", "point_sprite_increment", GetMagnificationIncrement() );
   SetMagnificationIncrement( anIncrement );
 
   bool isColored = aResourceMgr->booleanValue( "VISU", "point_sprite_results", GetIsColored() );
@@ -187,7 +187,7 @@ VISU::GaussPoints_i
   QColor aColor = aResourceMgr->colorValue( "VISU", "point_sprite_color", GetColor() );
   SetColor( aColor );
 
-  float anAlphaThreshold = aResourceMgr->doubleValue( "VISU", "point_sprite_alpha_threshold", GetAlphaThreshold() );
+  vtkFloatingPointType anAlphaThreshold = aResourceMgr->doubleValue( "VISU", "point_sprite_alpha_threshold", GetAlphaThreshold() );
   SetAlphaThreshold( anAlphaThreshold );
 
   int aResolution = aResourceMgr->integerValue( "VISU", "geom_sphere_resolution", GetResolution() );
@@ -322,12 +322,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetScaleFactor( float theScaleFactor )
+::SetScaleFactor( vtkFloatingPointType theScaleFactor )
 {
   myGaussPointsPL->SetScale( theScaleFactor );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetScaleFactor()
 {
@@ -376,12 +376,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetAlphaThreshold( float theAlphaThreshold )
+::SetAlphaThreshold( vtkFloatingPointType theAlphaThreshold )
 {
   myGaussPointsPL->SetAlphaThreshold( theAlphaThreshold );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetAlphaThreshold()
 {
@@ -416,7 +416,7 @@ VISU::GaussPoints_i
   return myGaussPointsPL->GetPrimitiveType();
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetMaximumSupportedSize()
 {
@@ -425,12 +425,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetClamp(float theClamp)
+::SetClamp(vtkFloatingPointType theClamp)
 {
   myGaussPointsPL->SetClamp( theClamp );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetClamp()
 {
@@ -439,12 +439,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetGeomSize( float theGeomSize )
+::SetGeomSize( vtkFloatingPointType theGeomSize )
 {
   myGaussPointsPL->SetSize( theGeomSize );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetGeomSize()
 {
@@ -453,12 +453,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetMinSize( float theMinSize )
+::SetMinSize( vtkFloatingPointType theMinSize )
 {
   myGaussPointsPL->SetMinSize( theMinSize );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetMinSize()
 {
@@ -467,12 +467,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetMaxSize( float theMaxSize )
+::SetMaxSize( vtkFloatingPointType theMaxSize )
 {
   myGaussPointsPL->SetMaxSize( theMaxSize );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetMaxSize()
 {
@@ -481,12 +481,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetMagnification( float theMagnification )
+::SetMagnification( vtkFloatingPointType theMagnification )
 {
   myGaussPointsPL->SetMagnification( theMagnification );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetMagnification()
 {
@@ -495,12 +495,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetMagnificationIncrement( float theIncrement )
+::SetMagnificationIncrement( vtkFloatingPointType theIncrement )
 {
   myGaussPointsPL->SetMagnificationIncrement( theIncrement );
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetMagnificationIncrement()
 {
@@ -639,14 +639,14 @@ VISU::GaussPoints_i
 
   vtkTextProperty* aTitleProp = theScalarBar->GetTitleTextProperty();
   aTitleProp->SetFontFamily(myTitFontType);
-  aTitleProp->SetColor(myTitleColor);
+  aTitleProp->SetColor(myTitleColor[0],myTitleColor[1],myTitleColor[2]);
   (myIsBoldTitle)? aTitleProp->BoldOn() : aTitleProp->BoldOff();
   (myIsItalicTitle)? aTitleProp->ItalicOn() : aTitleProp->ItalicOff();
   (myIsShadowTitle)? aTitleProp->ShadowOn() : aTitleProp->ShadowOff();
   
   vtkTextProperty* aLabelProp = theScalarBar->GetLabelTextProperty();
   aLabelProp->SetFontFamily(myLblFontType);
-  aLabelProp->SetColor(myLabelColor);
+  aLabelProp->SetColor(myLabelColor[0],myLabelColor[1],myLabelColor[2]);
   (myIsBoldLabel)? aLabelProp->BoldOn() : aLabelProp->BoldOff();
   (myIsItalicLabel)? aLabelProp->ItalicOn() : aLabelProp->ItalicOff();
   (myIsShadowLabel)? aLabelProp->ShadowOn() : aLabelProp->ShadowOff();
@@ -666,7 +666,7 @@ VISU::GaussPoints_i
       anActor->SetBarVisibility(true);
       myPipeLine->GetMapper()->SetScalarVisibility(1);
 
-      float aRange[2];
+      vtkFloatingPointType aRange[2];
       myScalarMapPL->GetSourceRange(aRange);
       aScalarBarCtrl->SetRangeLocal(aRange);
       
@@ -687,7 +687,7 @@ VISU::GaussPoints_i
       }
       
       if(aScalarBarMode == VISU_ScalarBarCtrl::eGlobal){
-       float aRangeGlobal[2];
+       vtkFloatingPointType aRangeGlobal[2];
        //
        aRangeGlobal[0] = aTMinMax.first;
        aRangeGlobal[1] = aTMinMax.second;
@@ -813,12 +813,12 @@ VISU::GaussPoints_i
 
 void
 VISU::GaussPoints_i
-::SetSpacing(const float theSpacing)
+::SetSpacing(const vtkFloatingPointType theSpacing)
 {
   mySpacing = theSpacing;
 }
 
-float
+vtkFloatingPointType
 VISU::GaussPoints_i
 ::GetSpacing() const 
 {
index 5a0fe102627c77a2bdf57cb2dfa1edcd3a8ffb0d..71c49c72aedd743008b68e8a8073c5e0b37d5cdb 100644 (file)
@@ -87,11 +87,11 @@ namespace VISU
     void
     SetIsDeformed( bool theIsDeformed );
 
-    float
+    vtkFloatingPointType
     GetScaleFactor();
 
     void
-    SetScaleFactor( float theScaleFactor );
+    SetScaleFactor( vtkFloatingPointType theScaleFactor );
 
     //! Get color for Geometry mode of the presentation.
     QColor
@@ -133,10 +133,10 @@ namespace VISU
 
     //! Redirect the request to VISU_GaussPointsPL::SetAlphaThreshold.
     void
-    SetAlphaThreshold(float theAlphaThreshold);
+    SetAlphaThreshold(vtkFloatingPointType theAlphaThreshold);
 
     //! Redirect the request to VISU_GaussPointsPL::GetAlphaThreshold.
-    float
+    vtkFloatingPointType
     GetAlphaThreshold();
 
     //! Redirect the request to VISU_GaussPointsPL::SetResolution.
@@ -154,55 +154,55 @@ namespace VISU
     GetPrimitiveType();
 
     //! Redirect the request to VISU_GaussPointsPL::GetMaximumSupportedSize.
-    float 
+    vtkFloatingPointType 
     GetMaximumSupportedSize();
 
     //! Redirect the request to VISU_GaussPointsPL::SetClamp.
     void
-    SetClamp(float theClamp);
+    SetClamp(vtkFloatingPointType theClamp);
 
     //! Redirect the request to VISU_GaussPointsPL::GetClamp.
-    float
+    vtkFloatingPointType
     GetClamp();
 
     //! Redirect the request to VISU_GaussPointsPL::SetSize.
     void
-    SetGeomSize(float theGeomSize);
+    SetGeomSize(vtkFloatingPointType theGeomSize);
 
     //! Redirect the request to VISU_GaussPointsPL::GetSize.
-    float 
+    vtkFloatingPointType 
     GetGeomSize();
 
     //! Redirect the request to VISU_GaussPointsPL::SetMinSize.
     void
-    SetMinSize(float theMinSize);
+    SetMinSize(vtkFloatingPointType theMinSize);
 
     //! Redirect the request to VISU_GaussPointsPL::GetMinSize.
-    float 
+    vtkFloatingPointType 
     GetMinSize();
 
     //! Redirect the request to VISU_GaussPointsPL::SetMaxSize.
     void
-    SetMaxSize(float theMaxSize);
+    SetMaxSize(vtkFloatingPointType theMaxSize);
 
     //! Redirect the request to VISU_GaussPointsPL::GetMaxSize.
-    float 
+    vtkFloatingPointType 
     GetMaxSize();
 
     //! Redirect the request to VISU_GaussPointsPL::SetMagnification.
     void
-    SetMagnification(float theMagnification);
+    SetMagnification(vtkFloatingPointType theMagnification);
 
     //! Redirect the request to VISU_GaussPointsPL::GetMagnification.
-    float
+    vtkFloatingPointType
     GetMagnification();
 
     //! Redirect the request to VISU_GaussPointsPL::SetMagnificationIncrement.
     void
-    SetMagnificationIncrement(float theIncrement);
+    SetMagnificationIncrement(vtkFloatingPointType theIncrement);
 
     //! Redirect the request to VISU_GaussPointsPL::GetMagnificationIncrement.
-    float
+    vtkFloatingPointType
     GetMagnificationIncrement();
 
     //! Set flag indicating which scalar bar is active.
@@ -231,10 +231,10 @@ namespace VISU
 
     //! Set value of the distance between global and local scalar bars.
     void
-    SetSpacing(const float theSpacing);
+    SetSpacing(const vtkFloatingPointType theSpacing);
 
     //! Get value of the distance between global and local scalar bars.
-    float
+    vtkFloatingPointType
     GetSpacing() const;
 
     //! Let know is the global range is already calculated
@@ -280,7 +280,7 @@ namespace VISU
     bool myIsDispGlobalScalarBar;
     bool myIsActiveLocalScalarBar;
     QColor myColor;
-    float mySpacing;
+    vtkFloatingPointType mySpacing;
     int myFaceLimit;
 
     QString myMainTexture;
index 4198c8a6497849222fb098c9207f99461cea2058..eac046c3284345a74253a7bd3369366ee9555ae1 100644 (file)
@@ -115,8 +115,9 @@ CORBA::Long VISU::IsoSurfaces_i::GetNbSurfaces(){
 }
 
 
-void VISU::IsoSurfaces_i::SetSubRange(CORBA::Double theMin, CORBA::Double theMax){ 
-  float aRange[2] = {theMin, theMax};
+void VISU::IsoSurfaces_i::SetSubRange(CORBA::Double theMin, CORBA::Double theMax)
+{ 
+  vtkFloatingPointType aRange[2] = {theMin, theMax};
   myIsoSurfacesPL->SetRange(aRange);
 }
 CORBA::Double VISU::IsoSurfaces_i::GetSubMin(){
index 1bdd88b8620cfb67340c3e95225f5072df705be1..c00463849e1a23d0e2d5f1a82fd9577a0cd145b4 100644 (file)
@@ -252,7 +252,7 @@ VISU::Prs3d_i
 
     theActor->SetPrs3d(this);
     theActor->SetShrinkFactor();
-    theActor->SetPosition(myOffset);
+    theActor->SetPosition(myOffset[0],myOffset[1],myOffset[2]);
     theActor->SetPipeLine(GetPipeLine());
 
     theActor->SetFactory(this);
@@ -295,7 +295,7 @@ VISU::Prs3d_i
 {
   if(MYDEBUG) MESSAGE("Prs3d_i::UpdateActor - this = "<<this<<"; theActor = "<<theActor);
   theActor->ShallowCopyPL(myPipeLine);
-  theActor->SetPosition(myOffset);
+  theActor->SetPosition(myOffset[0],myOffset[1],myOffset[2]);
   theActor->Modified();
 }
 
@@ -342,7 +342,9 @@ GetClippingPlane(vtkIdType theID) const
 
 void
 VISU::Prs3d_i
-::SetPlaneParam (float theDir[3], float theDist, vtkPlane* thePlane) 
+::SetPlaneParam (vtkFloatingPointType theDir[3], 
+                vtkFloatingPointType theDist, 
+                vtkPlane* thePlane) 
 {
   myPipeLine->SetPlaneParam(theDir, theDist, thePlane);
 }
@@ -351,14 +353,14 @@ VISU::Prs3d_i
 //----------------------------------------------------------------------------
 void
 VISU::Prs3d_i
-::GetBounds(float aBounds[6])
+::GetBounds(vtkFloatingPointType aBounds[6])
 {
   myPipeLine->GetMapper()->GetBounds(aBounds);
 }
 
 void 
 VISU::Prs3d_i
-::SetOffset(const float* theOffsets)
+::SetOffset(const CORBA::Float* theOffsets)
 {
   myOffset[0] = theOffsets[0];
   myOffset[1] = theOffsets[1];
@@ -367,7 +369,9 @@ VISU::Prs3d_i
 
 void
 VISU::Prs3d_i
-::SetOffset(float theDx, float theDy, float theDz)
+::SetOffset(CORBA::Float theDx, 
+           CORBA::Float theDy, 
+           CORBA::Float theDz)
 {
   myOffset[0] = theDx;
   myOffset[1] = theDy;
@@ -376,7 +380,7 @@ VISU::Prs3d_i
 
 void
 VISU::Prs3d_i
-::GetOffset(float* theOffsets)
+::GetOffset(CORBA::Float* theOffsets)
 {
   theOffsets[0] = myOffset[0];
   theOffsets[1] = myOffset[1];
@@ -385,7 +389,9 @@ VISU::Prs3d_i
 
 void 
 VISU::Prs3d_i
-::GetOffset(float& theDx, float& theDy, float& theDz)
+::GetOffset(CORBA::Float& theDx, 
+           CORBA::Float& theDy, 
+           CORBA::Float& theDz)
 {
   theDx = myOffset[0];
   theDy = myOffset[1];
index c83955f5bd1c983865b51111269a06ff7371c9ed..c7206654815966f7e7ce3ed1016effce6e9c5931 100644 (file)
@@ -184,25 +184,31 @@ namespace VISU
     GetClippingPlane(vtkIdType theID) const;
 
     void
-    SetPlaneParam(float theDir[3], float theDist, vtkPlane* thePlane);
+    SetPlaneParam(vtkFloatingPointType theDir[3], 
+                 vtkFloatingPointType theDist, 
+                 vtkPlane* thePlane);
 
     //----------------------------------------------------------------------------
     void
-    GetBounds(float aBounds[6]);
+    GetBounds(vtkFloatingPointType aBounds[6]);
 
     void
-    SetOffset(const float* theOffsets);
+    SetOffset(const CORBA::Float* theOffsets);
 
     virtual
     void
-    SetOffset(float theDx, float theDy, float theDz);
+    SetOffset(CORBA::Float theDx, 
+             CORBA::Float theDy, 
+             CORBA::Float theDz);
 
     void
-    GetOffset(float* theOffsets);
+    GetOffset(CORBA::Float* theOffsets);
 
     virtual
     void
-    GetOffset(float& theDx, float& theDy, float& theDz);
+    GetOffset(CORBA::Float& theDx, 
+             CORBA::Float& theDy, 
+             CORBA::Float& theDz);
 
     //----------------------------------------------------------------------------
   protected:
@@ -220,7 +226,7 @@ namespace VISU
     CheckDataSet();
 
     bool myAddToStudy;
-    float myOffset[3];
+    CORBA::Float myOffset[3];
     Result_i *myResult;
     VISU_PipeLine *myPipeLine;
     SALOMEDS::SObject_var mySObject;
index e75c21f1804e494c7cdec585b7ad5a4e8ddb125a..60cb15c822fc3282fdf29da47f872319f8970592 100644 (file)
@@ -1571,11 +1571,13 @@ VISU::Result_i
 //function : GetAxisInfo
 //purpose  :
 //=======================================================================
-const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
-                                             TAxis         theAxis,
-                                             gp_Dir&       thePlaneNormal)
+const Result_i::TAxisInfo* 
+Result_i
+::GetAxisInfo(const string& theMeshName,
+             TAxis         theAxis,
+             gp_Dir&       thePlaneNormal)
 {
-  const vector< float >* components = NULL;
+  const TAxisInfo* components = NULL;
 
   if ( theAxis < AXIS_X || theAxis > AXIS_Z ) {
     MESSAGE(" Bad axis index " << theAxis );
@@ -1621,7 +1623,7 @@ const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
       if ( nbPnt != 8 )
         continue;
       vtkPoints * points = cell->GetPoints();
-      float* coords[ 4 ];
+      vtkFloatingPointType* coords[ 4 ];
       coords[0] = points->GetPoint( 0 );
       coords[1] = points->GetPoint( 1 );
       coords[2] = points->GetPoint( 3 );
@@ -1629,10 +1631,10 @@ const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
       gp_Pnt p0( coords[0][0], coords[0][1], coords[0][2] );
       for ( iAx = 0; iAx < nbAxes; ++iAx )
       {
-        float* coo = coords[ iAx + 1 ];
+        vtkFloatingPointType* coo = coords[ iAx + 1 ];
         gp_Pnt p( coo[0], coo[1], coo[2] );
         // min size
-        float size = p0.SquareDistance( p );
+        vtkFloatingPointType size = p0.SquareDistance( p );
         if ( size > FLT_MIN && size < minSize[ iAx ] )
           minSize[ iAx ] = size;
         // axis direction
@@ -1662,34 +1664,34 @@ const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
 
     // get and sort intermediate component values - projections of nodes
     // on axis direction; define bnd box
-    set< float > comps[ 3 ];
+    set< vtkFloatingPointType > comps[ 3 ];
     Bnd_Box box;
     vtkPoints * points = aMesh->GetPoints();
     vtkIdType iP, nbP = aMesh->GetNumberOfPoints();
     for ( iP = 0; iP < nbP; ++iP )
     {
-      float* coo = points->GetPoint( iP );
+      vtkFloatingPointType* coo = points->GetPoint( iP );
       gp_Pnt p( coo[0], coo[1], coo[2] );
       box.Add( p );
       for ( iAx = 0; iAx < nbAxes; ++iAx ) {
         const gp_Dir& dir = gInfo->myAxis[ iAx ];
-        float dot = dir.XYZ() * p.XYZ();
+        vtkFloatingPointType dot = dir.XYZ() * p.XYZ();
         comps[ iAx ].insert( dot );
       }
     }
 
     // find a range of projections of bnd box corners on each axis
-    float range[3], firstValue[3];
+    vtkFloatingPointType range[3], firstValue[3];
     double x[2],y[2],z[2];
     box.Get(x[0],y[0],z[0],x[1],y[1],z[1]);
     for ( iAx = 0; iAx < nbAxes; ++iAx ) {
-      set< float > bndComps;
+      set< vtkFloatingPointType > bndComps;
       const gp_Dir& dir = gInfo->myAxis[ iAx ];
       for ( int iX = 0; iX < 2; ++iX ) {
         for ( int iY = 0; iY < 2; ++iY ) {
           for ( int iZ = 0; iZ < 2; ++iZ ) {
             gp_Pnt p( x[ iX ], y[ iY ], z[ iZ ] );
-            float dot = dir.XYZ() * p.XYZ();
+            vtkFloatingPointType dot = dir.XYZ() * p.XYZ();
             bndComps.insert( dot );
           }
         }
@@ -1701,14 +1703,14 @@ const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
     // compute component values
     for ( iAx = 0; iAx < nbAxes; ++iAx )
     {
-      list< float > values;
+      list< vtkFloatingPointType > values;
       int nbVals = 0;
-      set< float >& comp = comps[ iAx ];
-      set< float >::iterator val = comp.begin();
-      float bnd = -1., rng = range[ iAx ], first = firstValue[ iAx ];
-      float tol = 0.1 * sqrt( minSize[ iAx ]) / rng;
+      set< vtkFloatingPointType >& comp = comps[ iAx ];
+      set< vtkFloatingPointType >::iterator val = comp.begin();
+      vtkFloatingPointType bnd = -1., rng = range[ iAx ], first = firstValue[ iAx ];
+      vtkFloatingPointType tol = 0.1 * sqrt( minSize[ iAx ]) / rng;
       for ( ; val != comp.end(); ++val ) {
-        float value = ( *val - first ) / rng;
+        vtkFloatingPointType value = ( *val - first ) / rng;
         if ( value > bnd ) {
           values.push_back( value );
           bnd = value + tol;
@@ -1716,9 +1718,9 @@ const vector< float >* Result_i::GetAxisInfo(const string& theMeshName,
         }
       }
       // store values in gInfo
-      vector< float >& myComp = gInfo->myComponets[ iAx ];
+      vector< vtkFloatingPointType >& myComp = gInfo->myComponets[ iAx ];
       myComp.resize( nbVals );
-      list< float >::iterator v = values.begin();
+      list< vtkFloatingPointType >::iterator v = values.begin();
       for ( int i = 0; v != values.end(); ++v )
         myComp[ i++ ] = *v;
     }
index 27ec5e085c7b347531dd12f9205f55d70fc9592d..35fac0fcc6d6b677ac44ba92875e6b5b026c1391 100644 (file)
@@ -31,6 +31,8 @@
 #include "VISU_BoostSignals.h"
 #include "SALOME_GenericObj_i.hh"
 
+#include "VTKViewer.h"
+
 #include <gp_Dir.hxx>
 #include <vector>
 
@@ -175,17 +177,18 @@ namespace VISU
     // Info on structured mesh contained in TInput
   public:
     typedef enum { AXIS_X = 0, AXIS_Y, AXIS_Z } TAxis;
-    const std::vector< float >* GetAxisInfo(const std::string& theMeshName,
-                                            TAxis              theAxis,
-                                            gp_Dir&            thePlaneNormal);
+    typedef std::vector< vtkFloatingPointType > TAxisInfo;
+    const TAxisInfo* GetAxisInfo(const std::string& theMeshName,
+                                TAxis              theAxis,
+                                gp_Dir&            thePlaneNormal);
     // Return i,j or k values and cutting plane normal for theAxis.
     // In the case of any problems, return NULL pointer
   private:
     struct TGridInfo {
-      std::vector< float > myComponets[ 3 ];
-      gp_Dir               myAxis     [ 3 ];
+      TAxisInfo myComponets[ 3 ];
+      gp_Dir    myAxis     [ 3 ];
     };
-    map< string, TGridInfo > myMeshName2GridInfoMap;
+    std::map< std::string, TGridInfo > myMeshName2GridInfoMap;
   };
 
   Result_var FindResult(SALOMEDS::SObject_ptr theSObject);
index c9ee0e66a3ef620730f2b000c646bca08f5e333d..2639b5b7078a723abdadd94501c42008d6000639 100644 (file)
@@ -193,20 +193,20 @@ CORBA::Double VISU::ScalarMapOnDeformedShape_i::GetScale(){
 }
 
 void VISU::ScalarMapOnDeformedShape_i::SetSourceRange(CORBA::Double theMinRange,CORBA::Double theMaxRange){
-  float aRange[2];
-  aRange[0] = float(theMinRange);
-  aRange[1] = float(theMaxRange);
+  vtkFloatingPointType aRange[2];
+  aRange[0] = vtkFloatingPointType(theMinRange);
+  aRange[1] = vtkFloatingPointType(theMaxRange);
   myScalarMapOnDeformedShapePL->SetScalarRange(aRange);
 }
 
 CORBA::Double VISU::ScalarMapOnDeformedShape_i::GetSourceRangeMin(){
-  float aRange[2];
+  vtkFloatingPointType aRange[2];
   myScalarMapOnDeformedShapePL->GetSourceRange(aRange);
   return aRange[0];
 }
 
 CORBA::Double VISU::ScalarMapOnDeformedShape_i::GetSourceRangeMax(){
-  float aRange[2];
+  vtkFloatingPointType aRange[2];
   myScalarMapOnDeformedShapePL->GetSourceRange(aRange);
   return aRange[1];
 }
@@ -251,8 +251,8 @@ void VISU::ScalarMapOnDeformedShape_i::UpdateActor(VISU_Actor* theActor) {
 
 void VISU::ScalarMapOnDeformedShape_i::SetScalarField(const char* theMeshName,
                                                      const char* theFieldName,
-                                                     const int   theIteration,
-                                                     const VISU::TEntity  theEntity)
+                                                     int   theIteration,
+                                                     VISU::TEntity  theEntity)
 {
   if(MYDEBUG) cout << "VISU::ScalarMapOnDeformedShape_i::SetScalarField:"<<__LINE__<<endl;
   if(MYDEBUG) cout << "\ttheFieldName="<<theFieldName<<endl;
@@ -273,8 +273,8 @@ void VISU::ScalarMapOnDeformedShape_i::SetScalarField(const char* theMeshName,
 
 void VISU::ScalarMapOnDeformedShape_i::SetScalarField(const char* theMeshName,
                                                      const char* theFieldName,
-                                                     const long  theIteration,
-                                                     const VISU::Entity  theEntity)
+                                                     CORBA::Long  theIteration,
+                                                     VISU::Entity  theEntity)
 {
   this->SetScalarField(theMeshName,theFieldName,(int)theIteration,VISU::TEntity(theEntity));
 }
index cdd1444a3589335c5f2d97d197f4842c3e22ffc3..ff5f4aa1d5f9ef3f7978684eae991b9aa315d2b1 100644 (file)
@@ -121,13 +121,13 @@ namespace VISU{
 
     virtual void SetScalarField(const char* theMeshName,
                                const char* theFieldName,
-                               const int   theIteration,
-                               const VISU::TEntity  theEntity);
+                               int   theIteration,
+                               VISU::TEntity  theEntity);
     
     virtual void SetScalarField(const char* theMeshName,
                                const char* theFieldName,
-                               const long  theIteration,
-                               const VISU::Entity  theEntity);
+                               CORBA::Long  theIteration,
+                               VISU::Entity  theEntity);
 
     virtual void SetScalarFieldName(const char* theName);
     virtual std::string GetScalarFieldName();
index 19bdd8dab31163858924ebdc0938cf4ea1906f39..ec5e160ba5f3ca9bb6cc33b88c5643c90110a612 100644 (file)
@@ -240,7 +240,7 @@ VISU::ScalarMap_i
 {
   if(theMin > theMax) 
     return;
-  float aScalarRange[2] = {theMin, theMax};
+  vtkFloatingPointType aScalarRange[2] = {theMin, theMax};
   myScalarMapPL->SetScalarRange(aScalarRange);
   myIsFixedRange = true;
 }
@@ -339,14 +339,14 @@ VISU::ScalarMap_i
 
     vtkTextProperty* aTitleProp = aScalarBar->GetTitleTextProperty();
     aTitleProp->SetFontFamily(myTitFontType);
-    aTitleProp->SetColor(myTitleColor);
+    aTitleProp->SetColor(myTitleColor[0],myTitleColor[1],myTitleColor[2]);
     (myIsBoldTitle)? aTitleProp->BoldOn() : aTitleProp->BoldOff();
     (myIsItalicTitle)? aTitleProp->ItalicOn() : aTitleProp->ItalicOff();
     (myIsShadowTitle)? aTitleProp->ShadowOn() : aTitleProp->ShadowOff();
 
     vtkTextProperty* aLabelProp = aScalarBar->GetLabelTextProperty();
     aLabelProp->SetFontFamily(myLblFontType);
-    aLabelProp->SetColor(myLabelColor);
+    aLabelProp->SetColor(myLabelColor[0],myLabelColor[1],myLabelColor[2]);
     (myIsBoldLabel)? aLabelProp->BoldOn() : aLabelProp->BoldOff();
     (myIsItalicLabel)? aLabelProp->ItalicOn() : aLabelProp->ItalicOff();
     (myIsShadowLabel)? aLabelProp->ShadowOn() : aLabelProp->ShadowOff();
index bb1925a80348bf7b1432a6fc46fe849038347d3f..a090a1db9abd0abaf3913fabfbe7d089f74d91d6 100644 (file)
@@ -20,7 +20,8 @@
 class SVTK_ViewWindow;
 class VISU_Actor;
 
-namespace VISU{
+namespace VISU
+{
   class Result_i;
   class ColoredPrs3d_i;
 }
@@ -34,7 +35,7 @@ struct FieldData
   std::vector<VISU::ColoredPrs3d_i*> myPrs;     // Presentations
   std::vector<VISU_Actor*> myActors;         // Actors
   std::vector<double> myTiming;              // time values
-  float myOffset[3];
+  CORBA::Float myOffset[3];
 };
 
 
index 57a37098107b80b087638d1b0536d23cd2899dfe..06a3893d3b73242adb2b53de58333ab2c144944e 100644 (file)
@@ -1520,7 +1520,7 @@ namespace VISU {
       }else{
        if(SUIT_ViewManager* aViewManager = myApplication->activeViewManager()){
          if(SUIT_ViewWindow* aView = aViewManager->getActiveView()){
-           if(SVTK_ViewWindow* aViewWindow = dynamic_cast<SVTK_ViewWindow*>(aView)){
+           if(dynamic_cast<SVTK_ViewWindow*>(aView)){
              myView3D->myViewManager = aViewManager;
              myResult = aViewManager->getActiveView();
            }
@@ -1759,7 +1759,7 @@ namespace VISU {
   {
     Storable::DataToStream(theStr,"myType",VISU::TVIEW3D);
 
-    float backint[3];
+    vtkFloatingPointType backint[3];
     GetRenderer(theViewWindow)->GetBackground(backint);
     Storable::DataToStream(theStr,"myColor.R",backint[0]);
     Storable::DataToStream(theStr,"myColor.G",backint[1]);
@@ -1847,7 +1847,7 @@ namespace VISU {
   SALOMEDS::Color View3D_i::GetBackground (SUIT_ViewWindow* theViewWindow)
   {
     SALOMEDS::Color aColor;
-    float backint[3];
+    vtkFloatingPointType backint[3];
     GetRenderer(theViewWindow)->GetBackground(backint);
     aColor.R = backint[0];  aColor.G = backint[1];  aColor.B = backint[2];
     return aColor;