]> OCCT Git - occt-copy.git/commitdiff
0024059: Eliminate compiler warning C4701 in MSVC++ with warning level 4
authoromy <omy@opencascade.com>
Thu, 22 Aug 2013 08:07:14 +0000 (12:07 +0400)
committerbugmaster <bugmaster@opencascade.com>
Thu, 22 Aug 2013 08:08:59 +0000 (12:08 +0400)
Removing pPotentially uninitialized local variable
Got rid of most of warnings C4701: Potentially uninitialized local variable
Removed redundant variable definitions.
Refactored a part of AppParCurves_ResolConstraint CTOR.
Replaced 0. to Precision::Confusion for tolerance vars;
Changed values for min and max parameter vars;
Got rid of redundant variables' initialization.

196 files changed:
src/AIS/AIS_Axis.cxx
src/Adaptor3d/Adaptor3d_CurveOnSurface.cxx
src/Adaptor3d/Adaptor3d_TopolTool.cxx
src/AdvApp2Var/AdvApp2Var_ApproxF2var.cxx
src/AdvApp2Var/AdvApp2Var_Iso.cxx
src/AdvApp2Var/AdvApp2Var_MathBase.cxx
src/AdvApp2Var/AdvApp2Var_SysBase.cxx
src/AdvApprox/AdvApprox_SimpleApprox.cxx
src/AppParCurves/AppParCurves_ResolConstraint.gxx
src/AppParCurves/AppParCurves_Variational_1.gxx
src/Approx/Approx_ComputeCLine.gxx
src/BOPAlgo/BOPAlgo_BOP.cxx
src/BOPAlgo/BOPAlgo_PaveFiller_6.cxx
src/BOPDS/BOPDS_DS.cxx
src/BOPTools/BOPTools_AlgoTools.cxx
src/BOPTools/BOPTools_AlgoTools3D.cxx
src/BOPTools/BOPTools_AlgoTools_1.cxx
src/BOPTools/BOPTools_AlgoTools_2.cxx
src/BRep/BRep_Builder.cxx
src/BRepAlgo/BRepAlgo.cxx
src/BRepBlend/BRepBlend_RstRstLineBuilder.cxx
src/BRepBlend/BRepBlend_SurfRstLineBuilder.cxx
src/BRepCheck/BRepCheck_Wire.cxx
src/BRepClass3d/BRepClass3d_SClassifier.cxx
src/BRepExtrema/BRepExtrema_DistanceSS.cxx
src/BRepFeat/BRepFeat.cxx
src/BRepFeat/BRepFeat_Form.cxx
src/BRepFeat/BRepFeat_MakePrism.cxx
src/BRepFill/BRepFill_CompatibleWires.cxx
src/BRepFill/BRepFill_EdgeOnSurfLaw.cxx
src/BRepFill/BRepFill_Evolved.cxx
src/BRepFill/BRepFill_Filling.cxx
src/BRepFill/BRepFill_Generator.cxx
src/BRepFill/BRepFill_MultiLine.cxx
src/BRepFill/BRepFill_OffsetWire.cxx
src/BRepFill/BRepFill_SectionPlacement.cxx
src/BRepLib/BRepLib_MakeFace.cxx
src/BRepMesh/BRepMesh_Classifier.cxx
src/BRepMesh/BRepMesh_IncrementalMesh.cxx
src/BRepOffset/BRepOffset_Inter3d.cxx
src/BRepOffsetAPI/BRepOffsetAPI_MiddlePath.cxx
src/BRepTest/BRepTest_CurveCommands.cxx
src/BRepTools/BRepTools_ShapeSet.cxx
src/BinTools/BinTools_ShapeSet.cxx
src/Blend/Blend_CSWalking_2.gxx
src/Blend/Blend_Walking_1.gxx
src/Blend/Blend_Walking_2.gxx
src/Blend/Blend_Walking_3.gxx
src/Blend/Blend_Walking_4.gxx
src/ChFi3d/ChFi3d_Builder_0.cxx
src/ChFi3d/ChFi3d_Builder_2.cxx
src/ChFi3d/ChFi3d_Builder_6.cxx
src/ChFi3d/ChFi3d_Builder_C1.cxx
src/ChFi3d/ChFi3d_Builder_C2.cxx
src/ChFi3d/ChFi3d_Builder_CnCrn.cxx
src/ChFi3d/ChFi3d_Builder_SpKP.cxx
src/ChFi3d/ChFi3d_FilBuilder_C2.cxx
src/ChFiDS/ChFiDS_FilSpine.cxx
src/Contap/Contap_ContourGen_2.gxx
src/Contap/Contap_ContourGen_3.gxx
src/Convert/Convert_ConicToBSplineCurve.cxx
src/DBRep/DBRep.cxx
src/DDF/DDF_IOStream.cxx
src/Draft/Draft_Modification_1.cxx
src/Draw/Draw.cxx
src/Draw/Draw_GraphicCommands.cxx
src/DrawTrSurf/DrawTrSurf.cxx
src/Dynamic/Dynamic.cxx
src/Extrema/Extrema_GenExtCS.cxx
src/GCPnts/GCPnts_TangentialDeflection.gxx
src/Geom/Geom_OffsetSurface.cxx
src/Geom2dAdaptor/Geom2dAdaptor_Curve.cxx
src/GeomAdaptor/GeomAdaptor_Curve.cxx
src/GeomFill/GeomFill_CorrectedFrenet.cxx
src/GeomFill/GeomFill_GuideTrihedronPlan.cxx
src/GeomFill/GeomFill_TgtOnCoons.cxx
src/GeomLib/GeomLib.cxx
src/GeometryTest/GeometryTest_APICommands.cxx
src/GeomliteTest/GeomliteTest_ApproxCommands.cxx
src/HLRAlgo/HLRAlgo_PolyAlgo.cxx
src/HLRAlgo/HLRAlgo_PolyInternalData.cxx
src/HLRAlgo/HLRAlgo_PolyShellData.cxx
src/HLRBRep/HLRBRep_PolyAlgo.cxx
src/HLRBRep/HLRBRep_ShapeToHLR.cxx
src/IGESAppli/IGESAppli_ToolLineWidening.cxx
src/IGESData/IGESData_ParamReader.cxx
src/IGESGeom/IGESGeom_ToolBSplineSurface.cxx
src/IGESGeom/IGESGeom_ToolConicArc.cxx
src/IGESGeom/IGESGeom_ToolPlane.cxx
src/IGESGraph/IGESGraph_ToolUniformRectGrid.cxx
src/IGESToBRep/IGESToBRep_TopoSurface.cxx
src/Image/Image_Diff.cxx
src/IntCurve/IntCurve_IntConicConic_1.cxx
src/IntCurveSurface/IntCurveSurface_Inter.gxx
src/IntCurveSurface/IntCurveSurface_Polyhedron.gxx
src/IntPatch/IntPatch_ALineToWLine.cxx
src/IntPatch/IntPatch_ImpImpIntersection_0.gxx
src/IntPatch/IntPatch_ImpPrmIntersection.cxx
src/IntPatch/IntPatch_RstInt.cxx
src/IntStart/IntStart_SearchOnBoundaries_1.gxx
src/IntTools/IntTools_BeanFaceIntersector.cxx
src/IntTools/IntTools_EdgeEdge_1.cxx
src/IntTools/IntTools_EdgeFace.cxx
src/IntWalk/IntWalk_IWalking_4.gxx
src/IntWalk/IntWalk_PWalking_4.gxx
src/Interface/Interface_FloatWriter.cxx
src/LDOM/LDOM_XmlReader.cxx
src/Law/Law_BSpFunc.cxx
src/LocOpe/LocOpe_BuildShape.cxx
src/LocOpe/LocOpe_CSIntersector.cxx
src/LocOpe/LocOpe_CurveShapeIntersector.cxx
src/LocOpe/LocOpe_Generator.cxx
src/LocOpe/LocOpe_SplitDrafts.cxx
src/LocOpe/LocOpe_SplitShape.cxx
src/MAT2d/MAT2d_Tool2d.cxx
src/MeshVS/MeshVS_MeshPrsBuilder.cxx
src/NIS/NIS_View.cxx
src/OpenGl/OpenGl_GraduatedTrihedron.cxx
src/OpenGl/OpenGl_View_2.cxx
src/Primitives/Primitives_Wedge.gxx
src/ProjLib/ProjLib_CompProjectedCurve.cxx
src/ProjLib/ProjLib_ComputeApprox.cxx
src/ProjLib/ProjLib_ComputeApproxOnPolarSurface.cxx
src/ProjLib/ProjLib_ProjectedCurve.cxx
src/QABugs/QABugs_11.cxx
src/QANewBRepNaming/QANewBRepNaming_BooleanOperationFeat.cxx
src/QANewBRepNaming/QANewBRepNaming_Loader.cxx
src/QANewModTopOpe/QANewModTopOpe.cxx
src/QANewModTopOpe/QANewModTopOpe_Glue_shell.cxx
src/RWStepBasic/RWStepBasic_RWSiUnit.cxx
src/RWStepBasic/RWStepBasic_RWSiUnitAndAreaUnit.cxx
src/RWStepBasic/RWStepBasic_RWSiUnitAndPlaneAngleUnit.cxx
src/RWStepBasic/RWStepBasic_RWSiUnitAndRatioUnit.cxx
src/RWStepBasic/RWStepBasic_RWSiUnitAndVolumeUnit.cxx
src/RWStepDimTol/RWStepDimTol_RWGeoTolAndGeoTolWthDatRefAndModGeoTolAndPosTol.cxx
src/RWStepDimTol/RWStepDimTol_RWModifiedGeometricTolerance.cxx
src/RWStepElement/RWStepElement_RWCurve3dElementDescriptor.cxx
src/RWStepElement/RWStepElement_RWElementDescriptor.cxx
src/RWStepElement/RWStepElement_RWSurface3dElementDescriptor.cxx
src/RWStepElement/RWStepElement_RWVolume3dElementDescriptor.cxx
src/RWStepFEA/RWStepFEA_RWFeaAxis2Placement3d.cxx
src/SWDRAW/SWDRAW_ShapeTool.cxx
src/Select3D/Select3D_SensitiveFace.cxx
src/ShapeAnalysis/ShapeAnalysis_CheckSmallFace.cxx
src/ShapeAnalysis/ShapeAnalysis_ShapeTolerance.cxx
src/ShapeAnalysis/ShapeAnalysis_Surface.cxx
src/ShapeAnalysis/ShapeAnalysis_WireOrder.cxx
src/ShapeConstruct/ShapeConstruct.cxx
src/ShapeCustom/ShapeCustom_Surface.cxx
src/ShapeFix/ShapeFix_ComposeShell.cxx
src/ShapeFix/ShapeFix_Wire.cxx
src/ShapeUpgrade/ShapeUpgrade_ClosedEdgeDivide.cxx
src/ShapeUpgrade/ShapeUpgrade_EdgeDivide.cxx
src/ShapeUpgrade/ShapeUpgrade_SplitSurfaceAngle.cxx
src/ShapeUpgrade/ShapeUpgrade_WireDivide.cxx
src/TNaming/TNaming_Localizer.cxx
src/TestTopOpe/TestTopOpe_HDSCommands.cxx
src/TopClass/TopClass_Classifier2d.gxx
src/TopClass/TopClass_FaceClassifier.gxx
src/TopOpeBRep/TopOpeBRep_EdgesFiller.cxx
src/TopOpeBRep/TopOpeBRep_EdgesIntersector_1.cxx
src/TopOpeBRep/TopOpeBRep_FFDumper.cxx
src/TopOpeBRep/TopOpeBRep_FFTransitionTool.cxx
src/TopOpeBRep/TopOpeBRep_FaceEdgeFiller.cxx
src/TopOpeBRep/TopOpeBRep_FacesFiller_1.cxx
src/TopOpeBRep/TopOpeBRep_VPointInter.cxx
src/TopOpeBRep/TopOpeBRep_kpart.cxx
src/TopOpeBRep/TopOpeBRep_mergePDS.cxx
src/TopOpeBRep/TopOpeBRep_vprclo.cxx
src/TopOpeBRep/TopOpeBRep_vprdeg.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_Builder.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_BuilderON.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_BuilderON2d.cxx
src/TopOpeBRepBuild/TopOpeBRepBuild_Fill.hxx
src/TopOpeBRepBuild/TopOpeBRepBuild_Merge.cxx
src/TopOpeBRepDS/TopOpeBRepDS_BuildTool.cxx
src/TopOpeBRepDS/TopOpeBRepDS_Check.cxx
src/TopOpeBRepDS/TopOpeBRepDS_Dumper.cxx
src/TopOpeBRepDS/TopOpeBRepDS_EXPORT.cxx
src/TopOpeBRepDS/TopOpeBRepDS_ProcessEdgeInterferences.cxx
src/TopOpeBRepDS/TopOpeBRepDS_Transition.cxx
src/TopOpeBRepDS/TopOpeBRepDS_redu.cxx
src/TopOpeBRepDS/TopOpeBRepDS_repvg.cxx
src/TopOpeBRepTool/TopOpeBRepTool_STATE.cxx
src/TopOpeBRepTool/TopOpeBRepTool_TOPOLOGY.cxx
src/V3d/V3d.cxx
src/ViewerTest/ViewerTest.cxx
src/ViewerTest/ViewerTest_ObjectCommands.cxx
src/ViewerTest/ViewerTest_ViewerCommands.cxx
src/Visual3d/Visual3d_View.cxx
src/VrmlData/VrmlData_Material.cxx
src/VrmlData/VrmlData_Node.cxx
src/VrmlData/VrmlData_Scene.cxx
src/WNT/EHDC.cxx
src/WNT/W95_Allocator.cxx
src/XSDRAWIGES/XSDRAWIGES.cxx

index 55c00c2fe7af074d7750ec49e81a023423d160b7..0eaf8f32da7e3f99f2f47cab495308e31a1f0811 100755 (executable)
@@ -270,7 +270,7 @@ void AIS_Axis::ComputeFields()
     gp_Dir oX = myAx2->Ax2().XDirection();
     gp_Dir oY = myAx2->Ax2().YDirection();
     gp_Dir oZ = myAx2->Ax2().Direction();
-    Quantity_Length xo,yo,zo,x,y,z;
+    Quantity_Length xo,yo,zo,x = 0.,y = 0.,z = 0.;
     Orig.Coord(xo,yo,zo);
     myPfirst.SetCoord(xo,yo,zo);
     
index 8705445cbff72185b6e9c4932da296326d4ef522..84013ac23731a67873cfc6c7ec7b8977386ef932 100755 (executable)
@@ -332,17 +332,17 @@ static void Locate1Coord(const Standard_Integer Index,
 //=======================================================================
 
 static void Locate1Coord(const Standard_Integer Index,
-                        const gp_Pnt2d& UV, 
-                        const gp_Vec2d& DUV,
-                        const Handle(Geom_BSplineSurface)& BSplS,
-                        Standard_Boolean& DIsNull,
-                        gp_Pnt2d& LeftBot, 
-                        gp_Pnt2d& RightTop)
+        const gp_Pnt2d& UV, 
+        const gp_Vec2d& DUV,
+        const Handle(Geom_BSplineSurface)& BSplS,
+        Standard_Boolean& DIsNull,
+        gp_Pnt2d& LeftBot, 
+        gp_Pnt2d& RightTop)
 {
   Standard_Real Comp1=0,DComp1=0; 
   Standard_Real Tol = Precision::PConfusion()/10;
-  Standard_Integer i=1, Up=0, Up1, Up2, Down=0, Down1, Down2, Bnd1, Bnd2;
-  Standard_Real cur=0, f, l;
+  Standard_Integer i=1, Up=0, Up1, Up2, Down=0, Down1, Down2;
+  Standard_Real cur = 0.;
 
   DIsNull= Standard_False; 
 
@@ -351,96 +351,193 @@ static void Locate1Coord(const Standard_Integer Index,
   Up2 =  BSplS->LastVKnotIndex();
   Down2 = BSplS->FirstVKnotIndex();
 
-  
-  if(Index==1){ i = Down1; Comp1 =  UV.X(); DComp1= DUV.X(); Up=Up1; Down=Down1;
-               while ( ( Abs(BSplS->UKnot(i)-Comp1)>Tol )&&(i!=Up1 ) ) i++;
-               cur = BSplS->UKnot(i); 
-             }   else
-               if(Index==2) { i = Down2; Comp1 = UV.Y(); DComp1=DUV.Y(); Up=Up2; Down=Down2;
-                              while ( ( Abs(BSplS->VKnot(i)-Comp1)>Tol )&&(i!=Up2 ) ) i++;
-                              cur = BSplS->VKnot(i);
-                            }
+  if(Index==1)
+  { 
+    i = Down1; 
+    Comp1 =  UV.X(); 
+    DComp1= DUV.X(); 
+    Up=Up1; 
+    Down=Down1;
+
+    while ( ( Abs(BSplS->UKnot(i)-Comp1)>Tol )&&(i!=Up1 ) )
+    {
+      i++;
+    }
+
+    cur = BSplS->UKnot(i); 
+  }
+  else if(Index==2)
+  {
+    i = Down2;
+    Comp1 = UV.Y();
+    DComp1=DUV.Y();
+    Up=Up2;
+    Down=Down2;
+
+    while ( ( Abs(BSplS->VKnot(i)-Comp1)>Tol )&&(i!=Up2 ) )
+    {
+      i++;
+    }
+
+    cur = BSplS->VKnot(i);
+  }
   
   if( Abs(Comp1-cur)<=Tol ) 
-    { 
-      Bnd1 = Down; Bnd2 = Up;
-      if(Index==1) {
-        TColStd_Array1OfReal Arr1(1,BSplS->NbUKnots());
-        BSplS->UKnots(Arr1); //   Up1=Arr1.Upper(); Down1=Arr1.Lower();
-        FindBounds(Arr1,cur,DUV.X(),Bnd1,Bnd2,DIsNull); 
+  { 
+    Standard_Integer Bnd1 = Down, Bnd2 = Up;
+    if(Index==1)
+    {
+      TColStd_Array1OfReal Arr1(1,BSplS->NbUKnots());
+      BSplS->UKnots(Arr1); //   Up1=Arr1.Upper(); Down1=Arr1.Lower();
+      FindBounds(Arr1,cur,DUV.X(),Bnd1,Bnd2,DIsNull); 
+    }
+    else if(Index==2)
+    {
+      TColStd_Array1OfReal Arr2(1,BSplS->NbVKnots());
+      BSplS->VKnots(Arr2); //   Up2=Arr2.Upper(); Down2=Arr2.Lower();
+      FindBounds(Arr2,cur,DUV.Y(),Bnd1,Bnd2,DIsNull); 
+    }
+    
+    ReverseParam(Bnd1,Bnd2,Bnd1,Bnd2);
+
+    if(DIsNull==Standard_False)
+    {
+      if(Index==1)
+      {
+        LeftBot.SetX(BSplS->UKnot(Bnd1));
+        RightTop.SetX(BSplS->UKnot(Bnd2));
       }
-      else if(Index==2) {
-        TColStd_Array1OfReal Arr2(1,BSplS->NbVKnots());
-        BSplS->VKnots(Arr2); //   Up2=Arr2.Upper(); Down2=Arr2.Lower();
-        FindBounds(Arr2,cur,DUV.Y(),Bnd1,Bnd2,DIsNull); 
+      else if(Index==2)
+      { 
+        LeftBot.SetY(BSplS->VKnot(Bnd1));
+        RightTop.SetY(BSplS->VKnot(Bnd2));
       }
-      
-      ReverseParam(Bnd1,Bnd2,Bnd1,Bnd2);
-      
-      if(DIsNull==Standard_False){
-       if(Index==1) {LeftBot.SetX(BSplS->UKnot(Bnd1));
-                     RightTop.SetX(BSplS->UKnot(Bnd2));}
-       else
-         if(Index==2){ LeftBot.SetY(BSplS->VKnot(Bnd1));
-                       RightTop.SetY(BSplS->VKnot(Bnd2));
-                     }
-      }      
-    }
+    }      
+  }
   else//*********if Coord != Knot
+  {
+    if( (Index==1)&&(Comp1 < BSplS->UKnot(Down)) )
+    { 
+      LeftBot.SetX(BSplS->UKnot(Down)); 
+      RightTop.SetX( BSplS->UKnot(Down + 1) );
+      return;
+    }
+    else if( (Index==2)&&(Comp1 < BSplS->VKnot(Down)) )
+    { 
+      LeftBot.SetY(BSplS->VKnot(Down)); 
+      RightTop.SetY( BSplS->VKnot(Down + 1) );
+      return;
+    }
+    else if( (Index==1)&&(Comp1 > BSplS->UKnot(Up)) )
+    { 
+      RightTop.SetX(BSplS->UKnot(Up - 1)); 
+      LeftBot.SetX( BSplS->UKnot(Up) );
+      return;
+    }
+    else if( (Index==2)&&(Comp1 > BSplS->VKnot(Up)) )
+    { 
+      RightTop.SetY(BSplS->VKnot(Up - 1)); 
+      LeftBot.SetY( BSplS->VKnot(Up) );
+      return;
+    } 
+    else
     {
-      if( (Index==1)&&(Comp1 < BSplS->UKnot(Down)) )
-       { LeftBot.SetX(BSplS->UKnot(Down)); 
-         RightTop.SetX( BSplS->UKnot(Down + 1) );
-         return; }
+      Standard_Real f = 0., l = 1.;
+      if (Index==1)
+      {
+        f=BSplS->UKnot(Down);
+        l=BSplS->UKnot(Up);
+      }
+      else if (Index == 2)
+      {
+        f=BSplS->VKnot(Down);
+        l=BSplS->VKnot(Up);
+      }
+
+      i = Down;
+      if ((!(Comp1 < f))&&(!(Comp1 > l)))
+      {
+        if (Index==1)
+        {
+          while (!(((f=BSplS->UKnot(i)) < Comp1)&&((l=BSplS->UKnot(i+1)) > Comp1)) && (i<Up)) 
+          {
+            i++;
+          }
+        }
+        else if (Index==2)
+        {
+          while (!(((f=BSplS->VKnot(i)) < Comp1)&&((l=BSplS->VKnot(i+1)) > Comp1)) && (i<Up)) 
+          {
+            i++;
+          }
+        }
+      }
       else
-       if( (Index==2)&&(Comp1 < BSplS->VKnot(Down)) )
-         { LeftBot.SetY(BSplS->VKnot(Down)); 
-           RightTop.SetY( BSplS->VKnot(Down + 1) );
-           return; }
-       else
-         if( (Index==1)&&(Comp1 > BSplS->UKnot(Up)) )
-           { RightTop.SetX(BSplS->UKnot(Up - 1)); 
-             LeftBot.SetX( BSplS->UKnot(Up) );
-             return; }
-         else
-           if( (Index==2)&&(Comp1 > BSplS->VKnot(Up)) )
-             { RightTop.SetY(BSplS->VKnot(Up - 1)); 
-               LeftBot.SetY( BSplS->VKnot(Up) );
-               return; }
-           else
-             { i = Down;
-               if( (Index==1)&&(!(Comp1 < BSplS->UKnot(Down)))&&(!(Comp1 > BSplS->UKnot(Up))) )
-                 while (!( ((f=BSplS->UKnot(i)) < Comp1)&&((l=BSplS->UKnot(i+1)) > Comp1)) && (i<Up)) i++;
-               else
-                 if( (Index==2)&&(!(Comp1 < BSplS->VKnot(Down)))&&(!(Comp1 > BSplS->VKnot(Up))) )
-                   while (!(((f=BSplS->VKnot(i)) < Comp1)&&((l=BSplS->VKnot(i+1)) > Comp1)) && (i<Up)) i++;
-                 else
-                   ReverseParam(f,l,f,l);
-               
-               if(i!=Up){
-                 if(Abs(DComp1)>Tol)
-                   {if(Index==1) {  
-                     if(DComp1>0){ LeftBot.SetX(Comp1); RightTop.SetX(l);}else
-                       if(DComp1<0){LeftBot.SetX(f); RightTop.SetX(Comp1);}
-                   }else
-                     if(Index==2) {  
-                       if(DComp1>0){ LeftBot.SetY(Comp1); RightTop.SetY(l);}else
-                         if(DComp1<0){ LeftBot.SetY(f); RightTop.SetY(Comp1);}
-                     }
-                  }
-                 else
-                   {
-                     if(Abs(DComp1)<Tol)
-                       {if(Index==1){LeftBot.SetX(f); RightTop.SetX(l);}          else
-                          if(Index==2) { LeftBot.SetY(f); RightTop.SetY(l);}
-                      }
-                   }
-               }else
-                 if(i==Up){if(Index==1){LeftBot.SetX(Comp1); RightTop.SetX(BSplS->UKnot(i));} else
-                             if(Index==2) { LeftBot.SetY(Comp1); RightTop.SetY(BSplS->VKnot(i));}
-                         }
-             }
+        ReverseParam(f,l,f,l);
+
+      if(i!=Up)
+      {
+        if(Abs(DComp1)>Tol)
+        {
+          if(Index==1) 
+          {  
+            if(DComp1>0)
+            { 
+              LeftBot.SetX(Comp1); 
+              RightTop.SetX(l);
+            }
+            else if(DComp1<0)
+            {
+              LeftBot.SetX(f); 
+              RightTop.SetX(Comp1);
+            }
+          }
+          else if(Index==2)
+          {
+            if(DComp1>0)
+            { 
+              LeftBot.SetY(Comp1); 
+              RightTop.SetY(l);
+            }
+            else if(DComp1<0)
+            { 
+              LeftBot.SetY(f); 
+              RightTop.SetY(Comp1);
+            }
+          }
+        }
+        else
+        {
+          if(Abs(DComp1)<Tol)
+          {
+            if(Index==1)
+            {
+              LeftBot.SetX(f); 
+              RightTop.SetX(l);
+            }
+            else if(Index==2) 
+            { 
+              LeftBot.SetY(f); 
+              RightTop.SetY(l);
+            }
+          }
+        }
+      } 
+      else if(i==Up)
+      {
+        if(Index==1)
+        {
+          LeftBot.SetX(Comp1);
+          RightTop.SetX(BSplS->UKnot(i));
+        }
+        else if(Index==2)
+        { 
+          LeftBot.SetY(Comp1); 
+          RightTop.SetY(BSplS->VKnot(i));
+        }
+      }
     }
+  }
 }
 //=======================================================================
 //function :Locate2Coord
index cfaa83dae2bdaf7e2ff566716be151e1dbc6312a..f852a0c1622e57bded8af9ab92d793ee40efd5e6 100755 (executable)
@@ -936,7 +936,7 @@ void Adaptor3d_TopolTool::BSplSamplePnts(const Standard_Real theDefl,
   uinf = myS->FirstUParameter();  usup = myS->LastUParameter();
   vinf = myS->FirstVParameter();  vsup = myS->LastVParameter();
 
-  Standard_Integer i, j, k, nbi;
+  Standard_Integer i, k, j = 1;
   Standard_Real t1, t2, dt;
   Standard_Integer ui1 = aBS->FirstUKnotIndex();
   Standard_Integer ui2 = aBS->LastUKnotIndex();
@@ -1023,7 +1023,7 @@ void Adaptor3d_TopolTool::BSplSamplePnts(const Standard_Real theDefl,
     }
   }
   else {  
-    nbi = aBS->UDegree();
+    Standard_Integer nbi = aBS->UDegree();
     k = 0;
     t1 = uinf;
     for(i = ui1+1; i <= ui2; ++i) {
@@ -1058,7 +1058,7 @@ void Adaptor3d_TopolTool::BSplSamplePnts(const Standard_Real theDefl,
     }
   }
   else {  
-    nbi = aBS->VDegree();
+    Standard_Integer nbi = aBS->VDegree();
     k = 0;
     t1 = vinf;
     for(i = vi1+1; i <= vi2; ++i) {
index cf529d3a315b39ae1318c3b738d3a92f94315f0f..0e717ddffde8106356c167c3f8d9c5fc3801e783 100755 (executable)
@@ -288,7 +288,7 @@ int mma1cdi_(integer *ndimen,
   /* Local variables */
   integer nroo2, ncfhe, nd, ii, kk;
   integer ibb, kkm, kkp;
-  doublereal bid1, bid2, bid3;
+  doublereal bid1, bid2, bid3 = 0.;
 
 /* ********************************************************************** 
 */
@@ -971,7 +971,7 @@ int mma1fer_(integer *,//ndimen,
   integer crvjac_dim1, crvjac_offset, i__1, i__2;
 
   /* Local variables */
-  integer idim, ncfja, ncfnw, ndses, ii, kk, ibb, ier = 0;
+  integer idim, ncfja, ncfnw, ndses, ii, kk, ibb, ier;
   integer nbr0;
 
 
@@ -3323,7 +3323,7 @@ int AdvApp2Var_ApproxF2var::mma2cdi_( integer *ndimen,
     intptr_t iofwr;
     doublereal* wrkar = 0;
     integer iszwr;
-    integer ibb, ier;
+    integer ibb, ier = 0;
     integer isz1, isz2, isz3, isz4;
     intptr_t ipt1, ipt2, ipt3, ipt4;
 
index 91e367d354dd0c6dac6501b572e1fe19c57b677a..dbf6eeeaf7a75302f00a584a6fa02aed86121b2a 100755 (executable)
@@ -139,7 +139,7 @@ void AdvApp2Var_Iso::MakeApprox(const AdvApp2Var_Context& Conditions,
   Standard_Real TCONST = myConstPar;
 
 // data related to the type of the iso
-  Standard_Integer ISOFAV,NBROOT,NDGJAC,NCFLIM;
+  Standard_Integer ISOFAV = 0,NBROOT = 0,NDGJAC = 0,NCFLIM = 1;
   Standard_Real TABDEC[2];
   Handle (TColStd_HArray1OfReal) HUROOT  = Conditions.URoots();
   Handle (TColStd_HArray1OfReal) HVROOT  = Conditions.VRoots();
index 110ff0294235aec77e5e7d3b5acd3564f8cb48cb..fab4947bd88877fcf457d879dc86433cdbc8422f 100755 (executable)
@@ -2252,7 +2252,7 @@ int AdvApp2Var_MathBase::mmcglc1_(integer *ndimax,
   integer ndec;
   doublereal tdeb, tfin;
   integer iter;
-  doublereal oldso;
+  doublereal oldso = 0.;
   integer itmax;
   doublereal sottc;
   integer kk, ibb;
@@ -4757,8 +4757,8 @@ int AdvApp2Var_MathBase::mmfmtb1_(integer *maxsz1,
 
     /* Local variables */
     doublereal* work = 0;
-    integer ilong, isize, ii, jj, ier;
-    intptr_t iofst,iipt, jjpt;
+    integer ilong, isize, ii, jj, ier = 0;
+    intptr_t iofst = 0,iipt, jjpt;
 
 
 /************************************************************************
@@ -6355,8 +6355,9 @@ int mmloncv_(integer *ndimax,
   
   /* Local variables */
   doublereal tran;
-  integer ngaus;
-  doublereal c1, c2, d1, d2, wgaus[20], uroot[20], x1, x2, dd;
+  integer ngaus = 0;
+  doublereal c1, c2, d1, d2,
+    wgaus[20] = {0.}, uroot[20] = {0.}, x1, x2, dd;
   integer ii, jj, kk;
   doublereal som;
   doublereal der1, der2;
@@ -9638,7 +9639,7 @@ L9999:
     doublereal d__1;
 
     /* Local variables */
-    integer nchif, iunit, izero;
+    integer nchif, iunit = 1, izero;
     doublereal vnorm;
     integer ii;
     doublereal bid;
index 576214e434afe8e2a2a403765ea334da655c3442..696b3d26be7899fb5830e5e674ac8c0fcbc85635 100755 (executable)
@@ -747,7 +747,7 @@ int macrgfl_(intptr_t *iadfld,
   char cbid[1];
   integer ibid, ienr;
   doublereal* t = 0;
-  integer novfl;
+  integer novfl = 0;
   intptr_t ioff,iadrfl, iadt;
   
   
index fc0476c9ccef4057b953ef6f582b9c966ce15f69..b38f15f9d9ba8f5c433abf265106ea57f427ea0b 100755 (executable)
@@ -208,7 +208,7 @@ void AdvApprox_SimpleApprox::Perform(const TColStd_Array1OfInteger& LocalDimensi
   }
   
   // the computation of Qq(t)
-  Standard_Real Sum;
+  Standard_Real Sum = 0.;
   for (k=0; k<=DegreeQ; k+=2) {
     for (idim=1; idim<=myTotalDimension; idim++) {
       Sum=0.;
index 7c074d40e4ccdf753fbab81fbd73f2fb1bcf43cb..a2e4a5ffcd50b8191b08d9905f241c23201271cc 100755 (executable)
@@ -74,12 +74,11 @@ AppParCurves_ResolConstraint::
           ICurv(1, LastPoint-FirstPoint+1)
  {
   Standard_Integer i, j, k, NbCu= SCurv.NbCurves();
-//  Standard_Integer Npt, Nptl = LastPoint-FirstPoint+1;
   Standard_Integer Npt;
-  Standard_Integer Inc3, IncSec, IncCol, IP, CCol;
+  Standard_Integer Inc3, IncSec, IncCol, IP = 0, CCol;
   Standard_Integer myindex, Def = SCurv.NbPoles()-1;    
   Standard_Integer nb3d, nb2d, Npol= Def+1, Npol2 = 2*Npol;
-  Standard_Real T1, T2, T3, Tmax, Daij;
+  Standard_Real T1 = 0., T2 = 0., T3, Tmax, Daij;
   Standard_Boolean Ok;
   gp_Vec V;
   gp_Vec2d V2d;
@@ -273,191 +272,110 @@ AppParCurves_ResolConstraint::
   // Equations exprimant le meme rapport de tangence sur chaque courbe:
   // On prend les coordonnees les plus significatives.
 
-  Inc3 = Inc3 -1;
-  for (i =1; i <= IncTan; i++) {
+  --Inc3;
+  for (i = 1; i <= IncTan; ++i) {
     IncCol = 0;
     Npt = ITan(i);
-    for (k = 1; k <= NbCu-1; k++) {
-      Inc3 = Inc3 + 1;
-      if (Ibont(k, i) == 1) {
-       if (k <= nb3d) {
-         Ok = ToolLine::Tangency(SSP, Npt, tabV);
-         V = tabV(k);
-         T1 = V.X(); 
-         IP = 3*Npol;
-       }
-       else { 
-         Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-         V2d = tabV2d(k-nb3d);
-         T1 = V2d.X(); 
-         IP = 2*Npol;
-       }
-       if (Ibont(k+1, i) == 1) {  // Relations entre T1x et T2x:
-         if ((k+1) <= nb3d) { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.X();
-         }
-         else { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.X();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
-       else if (Ibont(k+1, i) == 2) {  // Relations entre T1x et T2y:
-         if ((k+1) <= nb3d) { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.Y();
-         }
-         else { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.Y();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
-       else if (Ibont(k+1,i) == 3) {    // Relations entre T1x et T2z:
-         Ok = ToolLine::Tangency(SSP, Npt, tabV);
-         V = tabV(k+1);
-         T2 = V.Z();
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + 2*Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
+    for (k = 1; k <= NbCu-1; ++k) {
+      ++Inc3;
+// Initialize first relation variable (T1)
+      Standard_Integer addIndex_1 = 0, aVal = Ibont(k, i);
+      switch (aVal)
+      {
+        case 1: //T1 ~ T1x
+        { 
+          if (k <= nb3d) {
+            Ok = ToolLine::Tangency(SSP, Npt, tabV);
+            V = tabV(k);
+            T1 = V.X(); 
+            IP = 3 * Npol;
+          }
+          else { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
+            V2d = tabV2d(k-nb3d);
+            T1 = V2d.X(); 
+            IP = 2 * Npol;
+          }
+          addIndex_1 = 0; 
+          break;
+        }
+        case 2: //T1 ~ T1y
+        {
+          if (k <= nb3d) {
+            Ok = ToolLine::Tangency(SSP, Npt, tabV);
+            V = tabV(k);
+            IP = 3 * Npol;
+          }
+          else { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
+            V2d = tabV2d(k-nb3d);
+            T1 = V2d.Y(); 
+            IP = 2 * Npol;
+          }
+          addIndex_1 = Npol; 
+          break;
+        }
+        case 3: //T1 ~ T1z
+        {
+          Ok = ToolLine::Tangency(SSP, Npt, tabV);
+          V = tabV(k);
+          T1 = V.Z();
+          IP = 3 * Npol;
+          addIndex_1 = 2 * Npol; 
+          break;
+        }
       }
-      else if (Ibont(k,i) == 2) {  
-       if (k <= nb3d) { 
-         Ok = ToolLine::Tangency(SSP, Npt, tabV);
-         V = tabV(k);
-         IP = 3*Npol;
-       }
-       else { 
-         Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-         V2d = tabV2d(k-nb3d);
-         T1 = V2d.Y();
-         IP = 2*Npol;
-       }
-       if (Ibont(k+1, i) == 1) {  // Relations entre T1y et T2x:
-         if ((k+1) <= nb3d) { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.X();
-         }
-         else {
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.X();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + Npol + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-         
-       }
-       else if (Ibont(k+1, i) == 2) {  // Relations entre T1y et T2y:
-         if ((k+1) <= nb3d) { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.Y();
-         }
-         else { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.Y();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + Npol + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-
-       }
-       else if (Ibont(k+1,i)== 3) {    // Relations entre T1y et T2z:
-         Ok = ToolLine::Tangency(SSP, Npt, tabV);
-         V = tabV(k+1);
-         T2 = V.Z();
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + Npol +IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + 2*Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
+      // Initialize second relation variable (T2)
+      Standard_Integer addIndex_2 = 0, aNextVal = Ibont(k + 1, i);
+      switch (aNextVal)
+      {
+        case 1: //T2 ~ T2x
+        {
+          if ((k+1) <= nb3d) { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV);
+            V = tabV(k+1);
+            T2 = V.X();
+          }
+          else { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
+            V2d = tabV2d(k+1-nb3d);
+            T2 = V2d.X();
+          }
+          addIndex_2 = 0; 
+          break;
+        }
+        case 2: //T2 ~ T2y
+        {
+          if ((k+1) <= nb3d) { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV);
+            V = tabV(k+1);
+            T2 = V.Y();
+          }
+          else { 
+            Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
+            V2d = tabV2d(k+1-nb3d);
+            T2 = V2d.Y();
+          }
+          addIndex_2 = Npol; 
+          break;
+        }
+        case 3: //T2 ~ T2z
+        {
+          Ok = ToolLine::Tangency(SSP, Npt, tabV);
+          V = tabV(k+1);
+          T2 = V.Z();
+          addIndex_2 = 2 * Npol;
+          break;
+        }
       }
-
-      else {
-       Ok = ToolLine::Tangency(SSP, Npt, tabV);
-       V = tabV(k);
-       T1 = V.Z();
-       IP = 3*Npol;
-       if (Ibont(k+1, i) == 1) {  // Relations entre T1z et T2x:
-         if ((k+1) <= nb3d) { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.X();
-         }
-         else { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.X();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + 2*Npol +IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
-
-       else if (Ibont(k+1, i) == 2) {  // Relations entre T1z et T2y:   
-         if ((k+1) <= nb3d) {
-           Ok = ToolLine::Tangency(SSP, Npt, tabV);
-           V = tabV(k+1);
-           T2 = V.Y();
-         }
-         else { 
-           Ok = ToolLine::Tangency(SSP, Npt, tabV2d);
-           V2d = tabV2d(k+1-nb3d);
-           T2 = V2d.Y();
-         }
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + 2*Npol +IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
-
-       else if (Ibont(k+1,i)==3) {      // Relations entre T1z et T2z:
-         Ok = ToolLine::Tangency(SSP, Npt, tabV);
-         V = tabV(k+1);
-         T2 = V.Z();
-         for (j = 1; j <=  Npol; j++) {
-           Daij = DerivativeBern(Npt, j);
-           Cont(Inc3, j + 2*Npol + IncCol) = Daij*T2;
-           Cont(Inc3, j + IP + 2*Npol + IncCol) = -Daij*T1;
-         }
-         IncCol = IncCol + IP;
-       }
+      
+      // Relations between T1 and T2:
+      for (j = 1; j <=  Npol; j++) {
+        Daij = DerivativeBern(Npt, j);
+        Cont(Inc3, j + IncCol + addIndex_1) = Daij*T2;
+        Cont(Inc3, j + IP + IncCol + addIndex_2) = -Daij*T1;
       }
+      IncCol += IP;
     }
   }
 
index 1cad36f8e3f884b7236bbee1f5666d6cd140c85c..e4ec1ce8e88359c1a6df685a05678d5d7282e924 100755 (executable)
@@ -51,17 +51,17 @@ void AppParCurves_Variational::TheMotor(
   Handle(TColStd_HArray1OfReal) CurrentTi, NewTi, OldTi;  
   Handle(TColStd_HArray2OfInteger) Dependence;
   Standard_Boolean lestim, lconst, ToOptim, iscut;
-  Standard_Boolean isnear, again = Standard_True; 
+  Standard_Boolean isnear = Standard_False, again = Standard_True; 
   Standard_Integer NbEst, ICDANA, NumPnt, Iter;
   Standard_Integer MaxNbEst =5; 
   Standard_Real VOCRI[3] = {BigValue, BigValue, BigValue}, EROLD = BigValue,
-                VALCRI[3], ERRMAX, ERRMOY, ERRQUA;
+                VALCRI[3], ERRMAX = BigValue, ERRMOY, ERRQUA;
   Standard_Real CBLONG, LNOLD;
   Standard_Integer NbrPnt = myLastPoint - myFirstPoint + 1;
   Standard_Integer NbrConstraint = myNbPassPoints + myNbTangPoints + myNbCurvPoints;
   Handle(FEmTool_Curve) CCurrent, COld, CNew;
-  Standard_Real EpsLength;// = 1.e-6 * CBLONG / NbrPnt;
-  Standard_Real EpsDeg; // = Min(WQuality * .1, CBLONG * .001);
+  Standard_Real EpsLength = SmallValue;
+  Standard_Real EpsDeg; 
 
   Standard_Real e1, e2, e3;
   Standard_Real J1min, J2min, J3min;
@@ -366,8 +366,3 @@ void AppParCurves_Variational::TheMotor(
 
   delete TheAssembly;
 }
-
-
-
-
-
index 00562f5c9b1b7215cbe872cf37db5dd8996cfeba..d88e1109da0747ce49428a29163e15a3714c4f6e 100755 (executable)
@@ -28,6 +28,7 @@
 #include <TColStd_Array1OfReal.hxx>
 #include <AppParCurves_Constraint.hxx>
 #include <Approx_Status.hxx>
+#include <Precision.hxx>
 
 //=======================================================================
 //function : Approx_ComputeCLine
@@ -89,12 +90,10 @@ Approx_ComputeCLine::Approx_ComputeCLine
 
 void Approx_ComputeCLine::Perform(const MultiLine& Line)
 {
-    
-
   Standard_Real UFirst, ULast;
   Standard_Boolean Finish = Standard_False, 
           begin = Standard_True, Ok = Standard_False;
-  Standard_Real thetol3d, thetol2d;
+  Standard_Real thetol3d = Precision::Confusion(), thetol2d = Precision::Confusion();
   UFirst = LineTool::FirstParameter(Line);
   ULast  = LineTool::LastParameter(Line);
   Standard_Real TolU = (ULast-UFirst)*1.e-05;
@@ -116,11 +115,9 @@ void Approx_ComputeCLine::Perform(const MultiLine& Line)
 
     // previous decision to be taken if we get worse with next cut (eap)
     AppParCurves_MultiCurve KeptMultiCurve;
-    Standard_Real KeptUfirst, KeptUlast, KeptT3d, KeptT2d;
+    Standard_Real KeptUfirst = 0., KeptUlast = 0., KeptT3d = RealLast(), KeptT2d = 0.;
     Standard_Integer NbWorseDecis = 0, NbAllowedBadDecis = 10;
-    
-    KeptT3d = RealLast(); KeptT2d = 0;
-    
+
     while (!Finish) {
       
       // Gestion du decoupage de la multiline pour approximer:
index 3def311de555ec7a58a0d696f2f76d57729744f2..56e84611e4173dd3bfe08b8dbd24b950f0a0cbb4 100644 (file)
@@ -467,7 +467,7 @@ static
   void BOPAlgo_BOP::BuildRC()
 {
   Standard_Boolean bFlag;
-  Standard_Integer i, aDmin, aNb[2], iX, iY;
+  Standard_Integer i, aDmin, aNb[2], iX = 0, iY = 0;
   TopAbs_ShapeEnum aTmin;
   TopoDS_Compound aC, aCS[2];
   BRep_Builder aBB;
index 977430fa9345645c317ffaf71bbb062ed6af568a..022771071d71d157e6f370a196d6b66903811723 100644 (file)
@@ -478,7 +478,7 @@ void BOPAlgo_PaveFiller::PerformFF()
   }
   //
   Standard_Boolean bHasPaveBlocks, bOld;
-  Standard_Integer iErr, nSx, nVSD, iX, iP, iC, j, nV, iV, iE, k;
+  Standard_Integer iErr, nSx, nVSD, iX, iP, iC, j, nV, iV = 0, iE, k;
   Standard_Integer jx;
   Standard_Real aT;
   Standard_Integer aNbLPBx;
index cc6f8792811e7c5dc0750d97dc39eb15c260e0ed..9e4a91f77ef643ada8d460f49aff4b49dd2b7967 100644 (file)
@@ -725,7 +725,7 @@ BOPDS_ListOfPaveBlock& BOPDS_DS::ChangePaveBlocks(const Standard_Integer theI)
 //=======================================================================
 void BOPDS_DS::InitPaveBlocks(const Standard_Integer theI)
 {
-  Standard_Integer nV, iRef, aNbV, nVSD, i;
+  Standard_Integer nV = 0, iRef, aNbV, nVSD, i;
   Standard_Real aT;
   TopoDS_Vertex aV;
   BOPCol_ListIteratorOfListOfInteger aIt;
index 59439bc639cc3eb02493f175438f140b28eae1f7..5611f37fe2389d80b8f2eb911508bfba468a176f 100644 (file)
@@ -1470,7 +1470,7 @@ Standard_Boolean FindFacePairs (const TopoDS_Edge& theE,
 {
   Standard_Boolean bFound;
   Standard_Integer i, aNbCEF;
-  TopAbs_Orientation aOr, aOrC;
+  TopAbs_Orientation aOr, aOrC = TopAbs_FORWARD;
   BOPCol_MapOfShape aMFP;
   TopoDS_Face aF1, aF2;
   TopoDS_Edge aEL, aE1;
index dac4e6f1e4380432cbdbe735fb3567e1017b3f90..1ca2a76954f4109b6d8c113701168449ba3d3064 100644 (file)
@@ -90,7 +90,7 @@ static
   void BOPTools_AlgoTools3D::DoSplitSEAMOnFace (const TopoDS_Edge& aSplit,
                                                 const TopoDS_Face& aF)
 {
-  Standard_Boolean bIsUPeriodic, bIsVPeriodic, bIsLeft;
+  Standard_Boolean bIsUPeriodic, bIsVPeriodic, bIsLeft = Standard_False;
   Standard_Real aTol, a, b, anUPeriod, anVPeriod, aT, anU, dU=1.e-7, anU1,
                 anV, dV=1.e-7, anV1;
   Standard_Real aScPr;
@@ -116,7 +116,7 @@ static
   //
   if (!bIsUPeriodic && !bIsVPeriodic) {
     Standard_Boolean bIsUClosed, bIsVClosed;
-    Standard_Real aUmin, aUmax, aVmin, aVmax;
+    Standard_Real aUmin = 0., aUmax = 0., aVmin = 0., aVmax = 0.;
     Handle(Geom_BSplineSurface) aBS;
     Handle(Geom_BezierSurface) aBZ;
     //
@@ -741,7 +741,7 @@ void Add(const TopoDS_Shape& aS,
   Standard_Boolean bIsDone, bHasFirstPoint, bHasSecondPoint;
   Standard_Integer iErr, aIx, aNbDomains, i;
   Standard_Real aUMin, aUMax, aVMin, aVMax;
-  Standard_Real aVx, aUx, aV1, aV2, aEpsT;
+  Standard_Real aVx = 0., aUx, aV1, aV2, aEpsT;
   gp_Dir2d aD2D (0., 1.);
   gp_Pnt2d aP2D;
   gp_Pnt aPx;
index 4d99c1508da3c0d5284017a5df63d340ef20d3b9..924f85ec4c4b55f4cb1c902889b1bb4b57d33d67 100644 (file)
@@ -716,7 +716,7 @@ void CheckEdge (const TopoDS_Edge& Ed, const Standard_Real aMaxTol)
   TopoDS_Iterator aItF, aItW, aItE;
   BRep_Builder aBB;
   //
-  aTolF = BRep_Tool::Tolerance(aF);
+  aTolE = aTolF = BRep_Tool::Tolerance(aF);
   aItF.Initialize(aF);
   for (; aItF.More(); aItF.Next()) {
     const TopoDS_Shape& aS = aItF.Value();
index e57f7624b6d734e7abacff626d383b914ca7e924..f75982b30c9a3706b9a7e0a3b12c50ad3e51abe3 100644 (file)
@@ -415,7 +415,7 @@ static
 //=======================================================================
   Standard_Integer BOPTools_AlgoTools::Dimension(const TopoDS_Shape& theS)
 {
-  Standard_Integer i, iRet, iRx0, iRx;
+  Standard_Integer i, iRet, iRx0 = 0, iRx = 0;
   TopAbs_ShapeEnum aTS;
   BOPCol_ListOfShape aLS;
   BOPCol_ListIteratorOfListOfShape aIt;
index 5ab0f4ffc984912d02f3662452d9da4773ee7530..2c501de189d22b41260469b30125d93487c84d1e 100755 (executable)
@@ -63,7 +63,7 @@ static void UpdateCurves(BRep_ListOfCurveRepresentation& lcr,
 {
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
   Handle(BRep_GCurve) GC;
-  Standard_Real f,l;
+  Standard_Real f = 0.,l = 0.;
 
   while (itcr.More()) {
     GC = Handle(BRep_GCurve)::DownCast(itcr.Value());
@@ -105,7 +105,7 @@ static void UpdateCurves(BRep_ListOfCurveRepresentation& lcr,
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
   Handle(BRep_CurveRepresentation) cr;
   Handle(BRep_GCurve) GC;
-  Standard_Real f,l;
+  Standard_Real f = 0.,l = 0.;
   Standard_Boolean rangeFound = Standard_False;
 
   // search the range of the 3d curve
@@ -171,7 +171,7 @@ static void UpdateCurves(BRep_ListOfCurveRepresentation& lcr,
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
   Handle(BRep_CurveRepresentation) cr;
   Handle(BRep_GCurve) GC;
-  Standard_Real f,l;
+  Standard_Real f = 0.,l = 0.;
   Standard_Boolean rangeFound = Standard_False;
 
   // search the range of the 3d curve
@@ -238,7 +238,7 @@ static void UpdateCurves(BRep_ListOfCurveRepresentation& lcr,
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
   Handle(BRep_CurveRepresentation) cr;
   Handle(BRep_GCurve) GC;
-  Standard_Real f,l;
+  Standard_Real f = 0.,l = 0.;
 
   while (itcr.More()) {
     GC = Handle(BRep_GCurve)::DownCast(itcr.Value());
@@ -285,7 +285,7 @@ static void UpdateCurves(BRep_ListOfCurveRepresentation& lcr,
   BRep_ListIteratorOfListOfCurveRepresentation itcr(lcr);
   Handle(BRep_CurveRepresentation) cr;
   Handle(BRep_GCurve) GC;
-  Standard_Real f,l;
+  Standard_Real f = 0.,l = 0.;
 
   while (itcr.More()) {
     GC = Handle(BRep_GCurve)::DownCast(itcr.Value());
index da2b79ab83cf2beb94c1f9be1a777479385ac51f..68bf4c0e1300f924361e14ae38ab2331d7f2e718 100755 (executable)
@@ -254,7 +254,7 @@ TopoDS_Edge  BRepAlgo::ConcatenateWireC0(const TopoDS_Wire& aWire)
   TColStd_SequenceOfReal FparSeq;
   TColStd_SequenceOfReal LparSeq;
   TColStd_SequenceOfReal TolSeq;
-  GeomAbs_CurveType CurType;
+  GeomAbs_CurveType CurType = GeomAbs_OtherCurve;
   TopoDS_Vertex FirstVertex, LastVertex;
   Standard_Boolean FinalReverse = Standard_False;
 
@@ -294,7 +294,7 @@ TopoDS_Edge  BRepAlgo::ConcatenateWireC0(const TopoDS_Wire& aWire)
       else
        {
          Standard_Boolean Done = Standard_False;
-         Standard_Real NewFpar, NewLpar;
+         Standard_Real NewFpar = 0., NewLpar = 0.;
          GeomAdaptor_Curve GAprevcurve(CurveSeq.Last());
          TopoDS_Vertex CurVertex = wexp.CurrentVertex();
          TopoDS_Vertex CurFirstVer = TopExp::FirstVertex(anEdge);
index 3215bb976e004f6018feaff2c4ffc9eab91c4243..a8d22c60b911c53ca266755a90a0b1bd97626298 100755 (executable)
@@ -553,8 +553,8 @@ void BRepBlend_RstRstLineBuilder::InternalPerform(Blend_RstRstFunction&   Func,
   }
   Blend_Status State = Blend_OnRst12;
   Standard_Real trst11 = 0., trst12 = 0., trst21 = 0., trst22 = 0.;
-  TopAbs_State situonc1, situonc2;
-  Blend_DecrochStatus decroch;
+  TopAbs_State situonc1 = TopAbs_UNKNOWN, situonc2 = TopAbs_UNKNOWN;
+  Blend_DecrochStatus decroch = Blend_NoDecroch;
   Standard_Boolean Arrive, recadp1, recadp2, recadrst1, recadrst2, echecrecad;
   Standard_Real wp1, wp2, wrst1, wrst2;
   math_Vector infbound(1, 2), supbound(1, 2);
index 61eae6197245d86a20fdf9e2acd31595ef556302..e72b0e10d13ba75deae97873c27dd1e88ef650ce 100755 (executable)
@@ -164,7 +164,7 @@ Standard_Integer BRepBlend_SurfRstLineBuilder::
   Standard_Boolean ok = Standard_False;
   Standard_Boolean byinter = (line->NbPoints() != 0), okinter = 0;
   Standard_Real distmin = RealLast();
-  Standard_Real uprev = 0.0, vprev = 0.0, prm = 0.0, dist = 0.0;
+  Standard_Real uprev = 0.,vprev = 0., prm =  0., dist = 0.;
 
   if(byinter) previousP.ParametersOnS(uprev,vprev);
   pt2d.SetCoord(sol(1),sol(2));
@@ -345,7 +345,7 @@ Standard_Boolean BRepBlend_SurfRstLineBuilder::PerformFirstSection
   Standard_Real trst = 0.;
   Standard_Boolean recadp,recadrst,recads;
   Standard_Real wp,wrst,ws;
-  Standard_Real U,V;
+  Standard_Real U = 0.,V = 0.;
   math_Vector infbound(1,3),supbound(1,3),tolerance(1,3);
   math_Vector solinvp(1,3),solinvrst(1,4),solinvs(1,3);
   Handle(Adaptor3d_HVertex) Vtxp,Vtxrst,Vtxs,Vtxc;
@@ -512,12 +512,12 @@ void BRepBlend_SurfRstLineBuilder::InternalPerform(Blend_SurfRstFunction&  Func,
     return;
   }
   Blend_Status State = Blend_OnRst12;
-  TopAbs_State situonc,situons;
-  Standard_Boolean decroch;
+  TopAbs_State situonc = TopAbs_UNKNOWN, situons = TopAbs_UNKNOWN;
+  Standard_Boolean decroch = Standard_False;
   Standard_Boolean Arrive,recadp,recadrst,recads,echecrecad;
   Standard_Real wp,wrst,ws;
-  Standard_Real U,V;
-  Standard_Real  trst = 0.;
+  Standard_Real U = 0.,V = 0.;
+  Standard_Real trst = 0.;
   math_Vector infbound(1,3),supbound(1,3);
   math_Vector parinit(1,3),tolerance(1,3);
   math_Vector solinvp(1,3),solinvrst(1,4),solinvs(1,3);
index 25610f02f43c27cf1dbf2629255a3df7311253f0..0fb2df20a89adfbacc6b70b1c50e247f3503411b 100755 (executable)
@@ -1172,7 +1172,7 @@ BRepCheck_Status BRepCheck_Wire::SelfIntersect(const TopoDS_Face& F,
                f2-IP_ParamOnSecond > ::Precision::PConfusion() || 
                IP_ParamOnSecond-l2 > ::Precision::PConfusion() ) 
              continue;
-           Standard_Real tolvtt;
+           Standard_Real tolvtt = 0.;
            //  Modified by Sergey KHROMOV - Mon Apr 15 12:34:22 2002 Begin
            if (!ConS.IsNull()) { 
              P3d = ConS->Value(IP_ParamOnFirst); 
index d4758ee6c7b37ba52a1df3c9e3b403a5b553f602..45ab28b49f9f552afdba7f99d8cb7d65c5ca109f 100755 (executable)
@@ -95,7 +95,7 @@ void BRepClass3d_SClassifier::PerformInfinitePoint(BRepClass3d_SolidExplorer& aS
   // 1
   Standard_Boolean bFound, bFlag;
   Standard_Integer nump;
-  Standard_Real aParam, aU1, aV1, aU2, aV2;
+  Standard_Real aParam, aU1 = 0., aV1 = 0., aU2 = 0., aV2 = 0.;
   gp_Pnt A,B;
   gp_Dir aDN1, aDN2;
   TopoDS_Face aF1, aF2;
@@ -274,7 +274,7 @@ void BRepClass3d_SClassifier::Perform(BRepClass3d_SolidExplorer& SolidExplorer,
     //  That's why the main loop while is added.
     Standard_Boolean isFaultyLine = Standard_True;
     Standard_Integer anIndFace    = 0;
-    Standard_Real    parmin;
+    Standard_Real    parmin = 0.;
 
     while (isFaultyLine) {
       if (anIndFace == 0) {
index dea6e55ec9bc7b1d54aed301d578ab8eb76b6807..e39c17c03bc39af752de9fd41e61efa5be4cbef0 100755 (executable)
@@ -120,7 +120,7 @@ static void TRIM_INFINIT_EDGE(const TopoDS_Edge& S1, const TopoDS_Edge& S2, Topo
       Precision::IsInfinite(aLast2))
     return;
   
-  Standard_Real Umin, Umax;
+  Standard_Real Umin = 0., Umax = 0.;
   Standard_Boolean bUmin, bUmax;
   bUmin = bUmax = Standard_False;
 
@@ -259,7 +259,7 @@ static void TRIM_INFINIT_FACE(const TopoDS_Shape& S1, const TopoDS_Shape& S2,
   const Standard_Boolean bRestrict = BRep_Tool::NaturalRestriction(aF);
 
   Standard_Real U1, V1, U2, V2;
-  Standard_Real Umin, Umax, Vmin, Vmax;
+  Standard_Real Umin = RealLast(), Umax = RealFirst(), Vmin = RealLast(), Vmax = RealFirst();
   Standard_Boolean bUmin, bUmax, bVmin, bVmax;
   bUmin = bUmax = bVmin = bVmax = Standard_False;
   Standard_Boolean bIsTrim = Standard_False;
index 7d6940a88b0ff4a5e693282c29d9732a7126e135..539a279b55ebbc84dbf5396a6d9f60acb0dbdbf0 100755 (executable)
@@ -579,11 +579,9 @@ TopoDS_Solid BRepFeat::Tool(const TopoDS_Shape& SRef,
 
 
   Sh.Orientation(TopAbs_FORWARD);
-#ifdef DEB
-  TopAbs_Orientation orient;
-#else
+
   TopAbs_Orientation orient = TopAbs_FORWARD;
-#endif
+
   for (exp.Init(Sh,TopAbs_FACE); exp.More(); exp.Next()) {
     if (exp.Current().IsSame(Fac)) {
       orient = exp.Current().Orientation();
index c4d242262b15e646463431e992c622411df16fdc..6ce9b8fcff75fab65a8e8355d727ffe5bf524a59 100755 (executable)
@@ -711,8 +711,10 @@ static void Descendants(const TopoDS_Shape&,
     TopTools_ListOfShape lshape;
     theBuilder.PartsOfTool(lshape);
     //
-    Standard_Real pbmin, pbmax, prmin, prmax;
-    Standard_Boolean flag1;
+    Standard_Real pbmin = RealLast(), pbmax = RealFirst();
+    Standard_Real prmin = RealLast()  - 2*Precision::Confusion();
+    Standard_Real prmax = RealFirst() + 2*Precision::Confusion();
+    Standard_Boolean flag1 = Standard_False;
     Handle(Geom_Curve) C;
 
 //--- Selection of pieces of tool to be preserved
index 493ad8d7a20d6d8dfe281456bbe85d09ca04ba1d..18c05108401ecf35f739a6b2e00276a3727ce5ce 100755 (executable)
@@ -1114,11 +1114,10 @@ static Standard_Real HeightMax(const TopoDS_Shape& theSbase,
       exp1.Init(exp.Current(), TopAbs_VERTEX);
       if(!exp1.More()) 
       {
-             FacRevolInfini = Standard_True;
-             break;
+        FacRevolInfini = Standard_True;
+        break;
       }
     }
-
     if(!FacRevolInfini)
       BRepBndLib::Add(theSUntil,Box);
   }
index 00686ec8eb31797516c7216d8b345248f4ee8159..349db51c094f8ff8d09483d8897561193f9c7aa2 100755 (executable)
@@ -1476,8 +1476,8 @@ void BRepFill_CompatibleWires::ComputeOrigin(const  Standard_Boolean /*polar*/ )
        }
       
       Standard_Real MinSumDist = Precision::Infinite();
-      Standard_Integer jmin, j, k, n;
-      Standard_Boolean forward;
+      Standard_Integer jmin = 1, j, k, n;
+      Standard_Boolean forward = Standard_False;
       if (i == myWork.Length() && myDegen2)
        {
          // last point section
index 4ef720834d50dabed4e3dc8cb55544136e20679d..766983f5d9090b643f1269e6f4c06971697ea0db 100755 (executable)
@@ -60,7 +60,7 @@ BRepFill_EdgeOnSurfLaw::BRepFill_EdgeOnSurfLaw(const TopoDS_Wire& Path,
   Handle(Geom2dAdaptor_HCurve) AC2d;
   Handle(Adaptor3d_HCurveOnSurface) AC;
   Handle(BRepAdaptor_HSurface) AS;
-  Standard_Real First, Last;
+  Standard_Real First = 0., Last = 0.;
   Handle(GeomFill_Darboux) TLaw = new (GeomFill_Darboux)() ;
   Handle(GeomFill_CurveAndTrihedron) Law = 
     new (GeomFill_CurveAndTrihedron) (TLaw);
index c77341dcc2f8bf0f0b547431ad12e26396152c71..bc6edb19a9aae378afddb4e6d58c853761e86af3 100755 (executable)
@@ -2826,7 +2826,7 @@ void ComputeIntervals (const TopTools_SequenceOfShape& VOnF,
                             TopTools_SequenceOfShape& LastV )
 {
   Standard_Integer IOnF    = 1,IOnL = 1;
-  Standard_Real    U1,U2;
+  Standard_Real    U1 = 0.,U2;
   TopoDS_Shape     V1,V2;
   
   if (!VS.IsNull()) {
index 038aab0e985ad1de3cea6f7c086fc1a60770203f..6645231e069dde7908fd567c6118835c07d678c8 100755 (executable)
@@ -497,7 +497,7 @@ void BRepFill_Filling::FindExtremitiesOfHoles(const TopTools_ListOfShape& WireLi
   while (! WireSeq.IsEmpty())
     {
       TopoDS_Vertex MinVtx;
-      Standard_Integer i, MinInd;
+      Standard_Integer i, MinInd = 1;
       Standard_Boolean IsLast = Standard_False;
       Standard_Real MinAngle = M_PI;
       
index e660d664ff3af3dd562009206cf321113a9beb8f..73e3a71726b348ad59bb7ee306c064502f611977 100755 (executable)
@@ -81,7 +81,7 @@ Standard_Integer DetectKPart(const TopoDS_Edge& Edge1,
   Standard_Integer IType = 0;
 
   // characteristics of the first edge
-  Standard_Real first1, last1, first2, last2, ff, ll;
+  Standard_Real first1 = 0., last1 = 0., first2, last2, ff, ll;
   TopLoc_Location loc;
   TopoDS_Vertex V1, V2;
   Handle(Geom_Curve) curv1, curv;
@@ -542,7 +542,7 @@ void BRepFill_Generator::Perform()
 
   BRepTools_WireExplorer ex1,ex2;
 
-  Standard_Boolean wPoint1, wPoint2, uClosed, DegenFirst, DegenLast;
+  Standard_Boolean wPoint1, wPoint2, uClosed = Standard_False, DegenFirst = Standard_False, DegenLast = Standard_False;
   
   for ( Standard_Integer i = 1; i <= Nb-1; i++) {
 
index c02477ba7e2789adbcd40e332b40e638f4653acf..ec008d9ad3fae7cd3d89970bc956e66f84fe8343 100755 (executable)
@@ -127,7 +127,7 @@ myKPart(0)
   TopLoc_Location L;
 
   TopExp_Explorer Exp;
-  Standard_Real Umin,Vmin,Umax,Vmax,U,V;
+  Standard_Real Umin = 0.,Vmin = 0.,Umax = 0.,Vmax = 0.,U,V;
   gp_Pnt2d P1,P2;
   gp_Vec DZ;
   gp_Pnt P;
index 27d2a0c0b98854df129de481067c6f82b64f65ad..2b515f3bc852e5634eff11965627914dcdeaba28 100755 (executable)
@@ -1412,8 +1412,8 @@ void BRepFill_OffsetWire::FixHoles()
       Pf = BRep_Tool::Pnt(Vf);
       Pl = BRep_Tool::Pnt(Vl);
       Standard_Real DistF = RealLast(), DistL = RealLast();
-      Standard_Integer IndexF, IndexL;
-      Standard_Boolean IsFirstF, IsFirstL;
+      Standard_Integer IndexF = 1, IndexL = 1;
+      Standard_Boolean IsFirstF = Standard_False, IsFirstL = Standard_False;
       for (Standard_Integer i = 2; i <= UnclosedWires.Length(); i++)
        {
          TopoDS_Wire aWire = TopoDS::Wire( UnclosedWires(i) );
index 96e4de5b164d47fd3da03d4bc4108d648b76f037..7055ec77699bef35365a3fc96e09bc4d6573a1b8 100755 (executable)
@@ -107,7 +107,7 @@ BRepFill_SectionPlacement(const Handle(BRepFill_LocationLaw)& Law,
   Standard_Integer ii; 
   Standard_Integer Ind1 = 0, Ind2 = 0;
   Standard_Boolean Bof, isVertex = Standard_False;
-  Standard_Real First, Last;
+  Standard_Real First = 0., Last = 0.;
   TopExp_Explorer Ex;
   TopoDS_Edge E;
   TopoDS_Vertex V;
index 2e9f8cbcb062cf150fc0b5a69dee54f765b77ce6..5c7d9cd5a813e53707512c54e620b3c883cf8522 100755 (executable)
@@ -588,7 +588,10 @@ void  BRepLib_MakeFace::Init(const Handle(Geom_Surface)& SS,
   Handle(Geom_Curve) Cumin,Cumax,Cvmin,Cvmax;
   Standard_Boolean Dumin,Dumax,Dvmin,Dvmax;
   Dumin = Dumax = Dvmin = Dvmax = Standard_False;
-  Standard_Real uminTol, umaxTol, vminTol, vmaxTol;
+  Standard_Real uminTol = Precision::Confusion(), 
+                umaxTol = Precision::Confusion(), 
+                vminTol = Precision::Confusion(), 
+                vmaxTol = Precision::Confusion();
 
   if (!umininf) {
     Cumin = S->UIso(UMin);
index 03ce5db8909ed9f7f2a86f41452053ed21ae4915..c553afea2874feaba2670c4029a6cf46b1d50b5e 100755 (executable)
@@ -539,7 +539,7 @@ BRepMesh_Classifier::BRepMesh_Classifier(const TopoDS_Face& theFace,
   Standard_Integer k = 1;
   for (Standard_Integer i = 1; i <= aNbWires; i++)
   {
-    Standard_Real x1, y1, x2, y2, aXstart, aYstart;
+    Standard_Real x1 = 0., y1 = 0., x2, y2, aXstart = 0., aYstart = 0.;
     const Standard_Integer aLen = aWireLength(i) + 1;
     for (Standard_Integer j = 1; j <= aLen; j++)
     {
index 50c349d92c6a20dd29b618a9bed1847738261048..9e4853c4cc025ada1091330fac745ad200e04047 100755 (executable)
@@ -343,7 +343,7 @@ void BRepMesh_IncrementalMesh::Update(const TopoDS_Edge& E)
   Handle(Poly_Triangulation) T, TNull;
   Handle(Poly_PolygonOnTriangulation) Poly, NullPoly;
   Standard_Boolean found = Standard_False;
-  Standard_Real defedge;
+  Standard_Real defedge = Precision::Confusion();
   Standard_Real cdef = 1.;
   BRep_Builder B;
   Standard_Boolean defined = Standard_False;
index ea1bc30fbaab8d1b482b7735e53aab71e3bbaa22..a5e5658cdfdf690739d6489200371ab3b0e7eb3c 100755 (executable)
@@ -45,6 +45,7 @@
 #include <TopTools_IndexedMapOfShape.hxx>
 #include <Extrema_ExtPC.hxx>
 #include <TopTools_MapOfShape.hxx>
+#include <Precision.hxx>
 
 
 
@@ -141,8 +142,8 @@ static void SelectEdge (const TopoDS_Face& /*F*/,
     Standard_Integer i;
     Standard_Real    aTol       = BRep_Tool::Tolerance(EI);
     Standard_Boolean isMinFound = Standard_False;
-    Standard_Real    aSqrDist1;
-    Standard_Real    aSqrDist2;
+    Standard_Real    aSqrDist1  = Precision::Infinite();
+    Standard_Real    aSqrDist2  = Precision::Infinite();
 
     anExt.Initialize(Ad2, Fst, Lst, aTol);
 
index cf3c5f5efe5493dff1c740bd208a069bc19de7c8..940d1cab572477e97e26edea875c2a8cdc96393c 100644 (file)
@@ -814,7 +814,7 @@ void BRepOffsetAPI_MiddlePath::Build()
     {
       gp_Ax1 theAxis;
       gp_Dir theDir1, theDir2;
-      Standard_Real theAngle;
+      Standard_Real theAngle = 0.;
       gp_Vec theTangent;
       Standard_Boolean SimilarArcs = Standard_True;
       for (j = 1; j <= myPaths.Length(); j++)
@@ -890,7 +890,12 @@ void BRepOffsetAPI_MiddlePath::Build()
           theAx2 = gp_Ax2(theCenterOfCirc, theAxis.Direction(), Vec1);
           theCircle = GC_MakeCircle(theAx2, Vec1.Magnitude());
         }
-        MidEdges(i) = BRepLib_MakeEdge(theCircle, 0., theAngle);
+        BRepLib_MakeEdge aME (theCircle, 0., theAngle);
+        aME.Build();
+
+        MidEdges(i) = aME.IsDone() ? 
+          aME.Shape() : 
+          TopoDS_Edge();
       }
     }
   }
index 9ec91692db476f9fa1b005c5c01b9e99cd7f51db..9a771eb3e8fae46d64e47472d80b992147fdc6fd 100755 (executable)
@@ -389,7 +389,7 @@ static Standard_Integer mk2dcurve(Draw_Interpretor& di,
   TopoDS_Edge E = TopoDS::Edge(S);
 
   TopLoc_Location L;
-  Standard_Real f,l;
+  Standard_Real f = 0., l = 0.;
   Handle(Geom2d_Curve) C;
   Handle(Geom_Surface) Surf;
   
index eef394c6017951a05a7989b660dc4bc390818be8..8531773ee4ea2c322f6748cb7b291645f7df38a8 100755 (executable)
@@ -21,7 +21,7 @@
 // Modifed:     Portage NT 7-5-97 DPF (strcasecmp)
 
 #include <Standard_Stream.hxx>
-
+#include <Precision.hxx>
 #include <BRepTools_ShapeSet.ixx>
 
 #include <BRepTools.hxx>
@@ -823,7 +823,7 @@ void  BRepTools_ShapeSet::ReadGeometry(const TopAbs_ShapeEnum T,
 {
   // Read the geometry
 
-  Standard_Integer val,c,pc,pc2,s,s2,l,l2,t, pt, pt2;
+  Standard_Integer val,c,pc,pc2 = 0,s,s2,l,l2,t, pt, pt2 = 0;
   Standard_Real tol,X,Y,Z,first,last,p1,p2;
   Standard_Real PfX,PfY,PlX,PlY;
   gp_Pnt2d aPf, aPl;
index 4c41df54accf1c28f2905f41baf872df3d59faea..4eddfb20d28f6e4d95abd500745c3165d993bd2f 100755 (executable)
@@ -759,8 +759,8 @@ void  BinTools_ShapeSet::ReadGeometry(const TopAbs_ShapeEnum T,
 {
   // Read the geometry
 
-  Standard_Integer val, c,pc,pc2,s,s2,l,l2,t, pt, pt2;
-  Standard_Real tol,X,Y,Z,first,last,p1,p2;
+  Standard_Integer val, c,pc,pc2 = 0,s,s2,l,l2,t, pt, pt2 = 0;
+  Standard_Real tol,X,Y,Z,first,last,p1 = 0.,p2;
   Standard_Real PfX,PfY,PlX,PlY;
   gp_Pnt2d aPf, aPl;
   Standard_Boolean closed, bval;
index 9dd6703ed5447422d4afd0ff86a0a5284c2033df..374ec5b5f7771b1c330f74288a0410547a686faf 100755 (executable)
@@ -41,11 +41,8 @@ Blend_Status Blend_CSWalking::TestArret(Blend_CSFunction& Function,
   gp_Pnt2d pt2d;
   Standard_Real pOnC;
   Blend_Status State1,State2;
-#ifndef DEB
   IntSurf_TypeTrans tras = IntSurf_Undecided;
-#else
-  IntSurf_TypeTrans tras;
-#endif
+
   if (Function.IsSolution(Sol,tolesp)) {
 
     pt1  = Function.PointOnS();
index e9afc1499960012f58289ed549cc9483b5b7b6a3..1dffbb597f255cfee1e6104d63ae6df9148dd241 100755 (executable)
@@ -260,8 +260,8 @@ Standard_Boolean Blend_Walking::PerformFirstSection
   math_Vector tolerance(1,4),infbound(1,4),supbound(1,4);
   math_Vector solrst1(1,4),solrst2(1,4);
   TheExtremity Ext1,Ext2;
-  Standard_Integer Index1,Index2,nbarc;
-  Standard_Boolean Isvtx1,Isvtx2;
+  Standard_Integer Index1 = 0, Index2 = 0, nbarc;
+  Standard_Boolean Isvtx1 = Standard_False, Isvtx2 = Standard_False;
   TheVertex Vtx1,Vtx2;
   gp_Pnt2d p2d;
 
index c1a07e3b87785568cb55099452b7975bbe13de2b..2768847581950cca97ee300d35bdd8371752623f 100755 (executable)
@@ -189,11 +189,7 @@ Blend_Status Blend_Walking::CheckDeflection
   const Standard_Real CosRef2D = 0.88; // correspond a 25 d
 
   Standard_Real Norme, Cosi, Cosi2;
-#ifndef DEB
   Standard_Real prevNorme = 0.;
-#else
-  Standard_Real prevNorme;
-#endif
   Standard_Real FlecheCourante;
   Standard_Real Du,Dv,Duv;
   Standard_Real tolu,tolv;
index bc662e4c84d05299d7e25957a19d7d81a5af1b24..92e50002a1448a0ea08a37544cd7a8357cb726b0 100755 (executable)
@@ -29,7 +29,7 @@ Standard_Integer Blend_Walking::ArcToRecadre(const Standard_Boolean OnFirst,
   Standard_Boolean ok = Standard_False;
   Standard_Boolean byinter = (line->NbPoints() != 0), okinter = 0;
   Standard_Real distmin = RealLast();
-  Standard_Real uprev = 0.0, vprev = 0.0, prm = 0.0, dist = 0.0;
+  Standard_Real uprev = 0.,vprev = 0., prm = 0., dist = 0.;
   Handle(TheTopolTool) Iter;
 
   if (OnFirst) {
@@ -86,11 +86,8 @@ Standard_Boolean Blend_Walking::Recadre(Blend_FuncInv& FuncInv,
   Standard_Boolean jalons_Trouve = Standard_False;
   Standard_Boolean recadre = Standard_True, ok;
   Standard_Boolean byinter = (line->NbPoints() != 0);
-#ifndef DEB
   Standard_Integer LeJalon = 0;
-#else
-  Standard_Integer LeJalon;
-#endif
+
   Standard_Integer nbarc;
   Standard_Real dist,prm,pmin, vtol;
   gp_Pnt2d pt2d, lastpt2d;
index 2fb2e541ffec4c27f127d732626405d0f8036b6b..a644b96c76f833e82a169c9a110690b8d178f3cd 100755 (executable)
@@ -91,9 +91,9 @@ void Blend_Walking::InternalPerform(Blend_Function& Func,
   Blend_Status State = Blend_OnRst12;
   TopAbs_State situ1 =TopAbs_IN,situ2=TopAbs_IN;
   Standard_Real w1,w2;
-  Standard_Integer Index1,Index2,nbarc;
+  Standard_Integer Index1 = 0, Index2 = 0, nbarc;
   Standard_Boolean Arrive,recad1,recad2, control;
-  Standard_Boolean Isvtx1,Isvtx2,echecrecad;
+  Standard_Boolean Isvtx1 = Standard_False, Isvtx2 = Standard_False, echecrecad;
   gp_Pnt2d p2d;
   math_Vector tolerance(1,4),infbound(1,4),supbound(1,4),parinit(1,4);
   math_Vector solrst1(1,4),solrst2(1,4);
@@ -559,12 +559,3 @@ void Blend_Walking::InternalPerform(Blend_Function& Func,
   }
 
 }
-
-
-
-
-
-
-
-
-
index 0ce56466e508ecb331ff85e1bb6202deeb48c7dc..211cbc843c5bcc8311bbcc39295eaa4d6ab37711 100755 (executable)
@@ -2122,7 +2122,7 @@ void  ChFi3d_FilDS(const Standard_Integer       SolidIndex,
   Standard_Integer Iarc1 = 0,Iarc2 = 0;
   TopAbs_Orientation trafil1 = TopAbs_FORWARD, trafil2 = TopAbs_FORWARD;
   Standard_Integer IcFil1,IcFil2,Isurf,Ishape1,Ishape2;
-  Standard_Real Pardeb,Parfin;
+  Standard_Real Pardeb = 0.,Parfin = 0.;
   TopAbs_Orientation ET1;
   Handle(TopOpeBRepDS_CurvePointInterference) Interfp1,Interfp2;
   Handle(TopOpeBRepDS_SurfaceCurveInterference) Interfc1,Interfc2;
@@ -3052,7 +3052,7 @@ Standard_Boolean ChFi3d_ComputeCurves(Handle(Adaptor3d_HSurface)&   S1,
   //in the direction of the start/end line.
   gp_Vec Vint, Vref(pdeb,pfin);
   gp_Pnt Pbid;
-  Standard_Real Udeb,Ufin;
+  Standard_Real Udeb = 0.,Ufin = 0.;
   Standard_Real tolr1,tolr2;
   tolr1 = tolr2 = tolreached = tol3d;
   if((S1->GetType() == GeomAbs_Cylinder && S2->GetType() == GeomAbs_Plane)||
@@ -3893,7 +3893,7 @@ Standard_EXPORT
   
   Standard_Boolean periodic, Bof, checkdeb, cepadur,bIsSmooth;
   Standard_Integer IEdge,IF,IL,nbed, iToApproxByC2;
-  Standard_Real WF, WL, Wrefdeb, Wreffin,nwf,nwl,period,pared,tolpared;
+  Standard_Real WF, WL, Wrefdeb, Wreffin,nwf,nwl,period,pared = 0.,tolpared;
   Standard_Real First, Last, epsV, urefdeb, tolrac;
   GeomAbs_Shape aContinuity;
   gp_Pnt PDeb, PFin, Bout;
index 408310190628510cef187aa73c62ae5e271289c5..ae743a746e939a687e2e455b9155632ee3f563d1 100755 (executable)
@@ -1890,11 +1890,11 @@ void ChFi3d_Builder::PerformSetOfSurfOnElSpine
   Handle(BRepAdaptor_HCurve2d) HC1,HC2;
   Handle(BRepAdaptor_HCurve2d) HCref1 = new BRepAdaptor_HCurve2d();
   Handle(BRepAdaptor_HCurve2d) HCref2 = new BRepAdaptor_HCurve2d();
-  Standard_Boolean decroch1 = 0, decroch2 = 0;
-  Standard_Boolean RecP1 = 0, RecS1 = 0, RecRst1 = 0, obstacleon1 = 0;
-  Standard_Boolean RecP2 = 0, RecS2 = 0, RecRst2 = 0, obstacleon2 = 0;
+  Standard_Boolean decroch1 = Standard_False, decroch2 = Standard_False;
+  Standard_Boolean RecP1 = Standard_False, RecS1 = Standard_False, RecRst1 = Standard_False, obstacleon1 = Standard_False;
+  Standard_Boolean RecP2 = Standard_False, RecS2 = Standard_False, RecRst2 = Standard_False, obstacleon2 = Standard_False;
   gp_Pnt2d pp1,pp2,pp3,pp4;
-  Standard_Real w1,w2;
+  Standard_Real w1 = 0.,w2 = 0.;
   math_Vector Soldep(1,4);
   math_Vector SoldepCS(1,3);
   math_Vector SoldepCC(1,2);
index 20bec9e27c365a2433655e2ed7ef233247857767..1e79f9adbcdb7e43c6f9ab9505e1809efdcc94db 100755 (executable)
@@ -955,7 +955,7 @@ Standard_Boolean ChFi3d_Builder::ComputeData
   Standard_Real MS = MaxStep;
   Standard_Integer again = 0;
   Standard_Integer nbptmin = 3; //jlr
-  Standard_Integer Nbpnt = 0;
+  Standard_Integer Nbpnt = 1;
   // the initial solution is reframed if necessary.
   math_Vector ParSol(1,3);
   Standard_Real NewFirst = PFirst;
@@ -2073,7 +2073,7 @@ Standard_Boolean ChFi3d_Builder::SimulData
   
   Standard_Real MS = MaxStep;
   Standard_Real TolGuide=tolguide, TolEsp = tolesp;
-  Standard_Integer Nbpnt;
+  Standard_Integer Nbpnt = 0;
   Standard_Real SpFirst = HGuide->FirstParameter();
   Standard_Real SpLast =  HGuide->LastParameter();
   Standard_Boolean reverse = (!Forward || Inside);
index 18e7db28d186cacc4ebdc72d9fc4b62e30d510ff..83cd64dbc206c8bb54ded884d9878159b2d9f3a0 100755 (executable)
@@ -819,7 +819,7 @@ void ChFi3d_Builder::PerformOneCorner(const Standard_Integer Index,
 
   TopoDS_Edge edgecouture;
   Standard_Boolean couture,intcouture=Standard_False;;
-  Standard_Real tolreached;
+  Standard_Real tolreached = tolesp;
   Standard_Real  par1 =0.,par2 =0.;
   Standard_Integer indpt = 0,Icurv1 = 0,Icurv2 = 0;
   Handle(Geom_TrimmedCurve) curv1,curv2;
@@ -3795,7 +3795,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
   TopoDS_Edge Arcpiv,Arcprol,Arcspine,Arcprolbis;
   if(isfirst) Arcspine = spine->Edges(1);
   else Arcspine = spine->Edges(spine->NbEdges());
-  TopAbs_Orientation OArcprolbis;
+  TopAbs_Orientation OArcprolbis = TopAbs_FORWARD;
   TopAbs_Orientation OArcprolv = TopAbs_FORWARD, OArcprolop = TopAbs_FORWARD;
   Standard_Integer ICurve;
   Handle(BRepAdaptor_HSurface) HBs  = new BRepAdaptor_HSurface();
@@ -3983,7 +3983,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
 
   TopoDS_Edge edgecouture;
   Standard_Boolean couture,intcouture=Standard_False;;
-  Standard_Real tolreached;
+  Standard_Real tolreached = tolesp;
   Standard_Real par1 = 0.,par2 = 0.;
   Standard_Integer indpt =0,Icurv1 =0,Icurv2 =0;
   Handle(Geom_TrimmedCurve) curv1,curv2;
@@ -4203,7 +4203,7 @@ void ChFi3d_Builder::IntersectMoreCorner(const Standard_Integer Index)
     // Above all the points cut the points with the edge of the spine.
     Standard_Integer IArcspine = DStr.AddShape(Arcspine);
     Standard_Integer IVtx = DStr.AddShape(Vtx);
-    TopAbs_Orientation OVtx2;
+    TopAbs_Orientation OVtx2 = TopAbs_FORWARD;
     TopAbs_Orientation OVtx = TopAbs_FORWARD;
     for(ex.Init(Arcspine.Oriented(TopAbs_FORWARD),TopAbs_VERTEX);
        ex.More(); ex.Next()){
index 9bdbd459dffd37f95d9566fec701a5afb5185799..f3e48687f67d630e4b5bd17d2f4c4d4e3402f546 100755 (executable)
@@ -327,7 +327,7 @@ Standard_Integer ChFi3d_Builder::PerformTwoCornerbyInter(const Standard_Integer
       Reduce(UIntPC1,UIntPC2,HS1,HS2);
     }
     
-    Standard_Real tolreached;
+    Standard_Real tolreached = tolesp;
     if (IFaCo1 == 1 && 
        !ChFi3d_ComputeCurves(HS1,HS2,Pardeb,Parfin,Gc,
                              PGc1,PGc2,tolesp,tol2d,tolreached)) {
index b650f0093ef061c7d54c01ea8d097fa3475683dd..46469058c63fadd4cad2b072913ab54137f685d7 100755 (executable)
@@ -1042,13 +1042,13 @@ void  ChFi3d_Builder::PerformMoreThreeCorner(const Standard_Integer Jndex,
   ChFiDS_ListIteratorOfListOfStripe It;
   Handle(ChFiDS_Stripe) cd2,cdbid,cnext;
   TopoDS_Face face;
-  Standard_Integer jfp,ii;
+  Standard_Integer jfp = 0,ii;
   Standard_Integer ic,icplus,icmoins,icplus2,
                    sense,index,indice,isurf1,isurf2;
-  Standard_Integer cbplus=0, n3d=0,IVtx,nb;
+  Standard_Integer cbplus=0, n3d=0,IVtx = 0,nb;
   Standard_Boolean sameside,trouve,isfirst;
   Standard_Real pardeb ,parfin,xdir,ydir;
-  Standard_Real tolapp=1.e-4,maxapp,maxapp1,avedev;
+  Standard_Real tolapp=1.e-4,maxapp = 0.,maxapp1 = 0.,avedev;
   Handle (TopOpeBRepDS_CurvePointInterference) Interfp1, Interfp2;
   Handle (TopOpeBRepDS_SurfaceCurveInterference) Interfc;
   Handle(Geom_Curve) Curv3d;
@@ -1452,9 +1452,9 @@ void  ChFi3d_Builder::PerformMoreThreeCorner(const Standard_Integer Jndex,
       oksea.SetValue(ic, Standard_False);
     }
     else {
-      Standard_Integer jf1;
-      Standard_Integer i1,i2;
-      Standard_Real pa1,pa2;
+      Standard_Integer jf1 = 0;
+      Standard_Integer i1 = 0,i2 = 0;
+      Standard_Real pa1 = 0.,pa2;
       Standard_Boolean ok;
       Handle(ChFiDS_Stripe) strip;
       Standard_Real angedg;
@@ -1824,7 +1824,7 @@ void  ChFi3d_Builder::PerformMoreThreeCorner(const Standard_Integer Jndex,
 // Then this courbe3d is projected on all faces (nbface) that
 // separate icmoins and indfin
   Standard_Integer nbface = 0;
-  Standard_Real  error;
+  Standard_Real  error = 0.;
   TColGeom2d_Array1OfCurve proj2d1(0,size);
   TColGeom2d_Array1OfCurve proj2d2(0,size);
   TColGeom_Array1OfCurve cproj1(0,size);
index ecc5ebf560ff5464317162c57f13b34f71ec028a..1a02f47ac934994afdcfe7a9a67f99e6b1dcc2fe 100755 (executable)
@@ -448,7 +448,7 @@ static Standard_Real ResetProl(const TopOpeBRepDS_DataStructure& DStr,
   const Handle(Geom_Surface)& surf = DStr.Surface(CD->Surf()).Surface();
   Standard_Real par = 0., x, y;
   if(!isfirst) par = edglen;
-  Standard_Real sppar;
+  Standard_Real sppar = 0.;
   for (Standard_Integer i = 1; i <= 2; i++) { 
     CD->ChangeInterference(i).SetParameter(par,isfirst);
     Handle(Geom2d_Curve) pc = CD->Interference(i).PCurveOnSurf();
index d9b72d27f4aea6685ab3eecb8be9733e26d2e25b..e22c8400e75a5776c5a61bb51ed6bbf59474ebde 100755 (executable)
@@ -477,7 +477,7 @@ void ChFi3d_FilBuilder::PerformTwoCorner(const Standard_Integer Index)
        TopAbs_Orientation oriSFF1 = st1->Orientation(IFaArc1);
        bid = 1;
        bid = ChFi3d::NextSide(ori,OFF1,oriS,oriSFF1,bid);
-       TopAbs_Orientation op1,op2;
+       TopAbs_Orientation op1 = TopAbs_FORWARD,op2 = TopAbs_FORWARD;
        if(yapiv) bid = ChFi3d::ConcaveSide(BRS1,BRS2,pivot,op1,op2);
        op1 = TopAbs::Reverse(op1);
        op2 = TopAbs::Reverse(op2);
index 71dad8256e7c85d19d5e6b2bfcf9b39e6e52fe28..6329cfe80bb1938502380706c6d6dd8d0d0a88f0 100755 (executable)
@@ -314,7 +314,7 @@ Standard_Real  ChFiDS_FilSpine::Radius(const Standard_Integer IE)const
   Standard_Real Uf = FirstParameter(IE);
   Standard_Real Ul = LastParameter(IE);
 
-  Standard_Real StartRad, par, rad;
+  Standard_Real StartRad = 0., par, rad;
   Standard_Integer i;
   for (i = 1; i < parandrad.Length(); i++)
     {
index 52fbbd3e9f396a82ee94b303ec79e6cdc6bc3aba..5dc9d8aac679bfba913e379be1ccdf902a7560f6 100755 (executable)
@@ -861,7 +861,7 @@ void ComputeInternalPointsOnRstr
   gp_Pnt2d p2d;
   gp_Vec2d d2d;
   Standard_Boolean found,ok = Standard_False,toutvu,solution;
-  Standard_Real paramp,paraminf,paramsup,toler;
+  Standard_Real paramp = 0.,paraminf,paramsup,toler;
 
   if (Line.TypeContour() != Contap_Restriction) {
     return;
index 7ac1d5749d07c807fab23e6efd129b7fbbf96a89..fb5b95b5f1fc1c1496c65d6a84071ff201e1fde6 100755 (executable)
@@ -156,7 +156,7 @@ IntSurf_TypeTrans ComputeTransitionOngpLine
   gp_Pnt P;
   gp_Vec T;
   ElCLib::D1(0.0,L,P,T);
-  Standard_Real u,v;
+  Standard_Real u = 0.,v = 0.;
   switch (typS) {
   case GeomAbs_Cylinder: {
     ElSLib::Parameters(TheSurfaceTool::Cylinder(Surf),P,u,v);
@@ -186,7 +186,7 @@ IntSurf_TypeTrans ComputeTransitionOngpCircle
   gp_Pnt P;
   gp_Vec T;
   ElCLib::D1(0.0,C,P,T);
-  Standard_Real u,v;
+  Standard_Real u = 0.,v = 0.;
   switch (typS) {
   case GeomAbs_Cylinder: {
     ElSLib::Parameters(TheSurfaceTool::Cylinder(Surf),P,u,v);
index 056ac802ff8fa055b7a68f75978a0216d072901f..30ff17a235ba65186870808bba46a53107b81475 100755 (executable)
@@ -344,17 +344,17 @@ void Convert_ConicToBSplineCurve::BuildCosAndSin(
   q_param,
   param ;
 
-  Standard_Integer num_poles,
+  Standard_Integer num_poles = 0,
   ii,
   jj,
-  num_knots=0,
-  num_spans=0,
+  num_knots = 1,
+  num_spans = 1,
   num_flat_knots,
   num_temp_knots,
-  temp_degree=0,
+  temp_degree = 0,
   tgt_theta_flag,
   num_temp_poles,
-  order ;
+  order  = 0;
 
   Convert_CosAndSinEvalFunction *EvaluatorPtr=NULL ;
 
index 38d598c30829804509589b3ac670948f6cebd112..f207074b03acad58c8df914f18259d3e0e515b65 100755 (executable)
@@ -720,11 +720,7 @@ static Standard_Integer orientation(Draw_Interpretor& ,
 {
   if (n <= 1) return 1;
   Standard_Integer cas = 0;
-#ifdef DEB
-  TopAbs_Orientation ori;
-#else
   TopAbs_Orientation ori=TopAbs_FORWARD;
-#endif
   Standard_Integer last = n;
   if (!strcasecmp(a[0],"orientation")) {
     if (n <= 2) return 1;
index 83fbbf929217b6f30be7463b1b1f189602aba9f3..bb1b70da58fbcbc4be9fff984e63aa4740ac9485 100755 (executable)
@@ -303,7 +303,7 @@ void DDF_IOStream::ReadChar(TCollection_AsciiString& buffer, const Standard_Inte
 
 void DDF_IOStream::ReadString(TCollection_AsciiString& buffer)
 {
-  char c;
+  char c = '\0';
   Standard_Boolean IsEnd = Standard_False;
 
   buffer.Clear();
@@ -329,7 +329,7 @@ void DDF_IOStream::ReadString(TCollection_AsciiString& buffer)
 
 void DDF_IOStream::ReadWord(TCollection_AsciiString& buffer)
 {
-  char c;
+  char c = '\0';
   Standard_Boolean IsEnd = Standard_False;
 
   buffer.Clear();
index a2ca0bff83516f9ad9f1a570c67e0b99fe1041d4..a7800c54179300f26a43a7a648cba66905709495 100755 (executable)
@@ -1008,8 +1008,8 @@ void Draft_Modification::Perform ()
                          theSurf = S2;             
                        }
                        if(detrompeur != 0 && detrompeur != 4) {
-                         Standard_Real ul, vl, uf, vf;
-                         Standard_Real ufprim, ulprim, vfprim, vlprim;
+                         Standard_Real ul = 0., vl = 0., uf = 0., vf = 0.;
+                         Standard_Real ufprim = 0., ulprim = 0., vfprim = 0., vlprim = 0.;
                          
                          if(theSurf->DynamicType() == STANDARD_TYPE(Geom_Plane)) {     
                            gp_Pln pl = Handle(Geom_Plane)::DownCast(S2)->Pln();
index d654dd22e61e211e6fabfeb3017048de9daa2735..7780a1357c9b50ef0ed834788702c3f2bd54a618 100755 (executable)
@@ -276,7 +276,7 @@ void Draw_Appli(Standard_Integer argc, char** argv,const FDraw_InitAppli Draw_In
   // init X window and create display
   // *****************************************************************
 #ifdef WNT
-  HWND hWnd;
+  HWND hWnd = NULL;
 #endif
 
   if (!Draw_Batch)
index 13d485b99b3ad390a4fa0acd8f7ce7e13c107d2f..b7dcd059f787f731f0bb8c7677f84ffae3299d0e 100755 (executable)
@@ -138,7 +138,7 @@ static Standard_Integer zoom(Draw_Interpretor& , Standard_Integer n, const char*
 
 static Standard_Integer wzoom(Draw_Interpretor& di, Standard_Integer argc, const char** argv)
 {
-  Standard_Integer id,X,Y,W,H,X1,Y1,X2,Y2,b;
+  Standard_Integer id,X,Y,W,H,X1,Y1,X2 = 0,Y2 = 0,b;
   Standard_Real dX1,dY1,dX2,dY2,zx,zy;
   if(argc != 1 && argc != 6)
   {
index 1950df77f51af733c37701fb5cdce8f3e31aeb24..37b3ca136bfbfc4281c82565e169ff854b8caa18 100755 (executable)
@@ -1777,7 +1777,7 @@ static Handle(Draw_Drawable3D) pntrestore (istream& is)
 {
   Standard_Integer is3d;
   is >> is3d;
-  Standard_Real x,y,z;
+  Standard_Real x,y,z = 0.;
   if (is3d)
     is >> x >> y >> z;
   else
index f7434e2d9bfca26be9674396582f7d085835bc1b..0b802147248152b3aff59f6c7f29a3913e09ff29 100755 (executable)
 
 Dynamic_ModeEnum Dynamic::Mode(const Standard_CString amode)
 {
-#ifdef DEB
-Dynamic_ModeEnum aMode;
-#else
 Dynamic_ModeEnum aMode=Dynamic_IN;
-#endif
   if     (!strcasecmp(amode,"in"      )) aMode = Dynamic_IN;
   else if(!strcasecmp(amode,"out"     )) aMode = Dynamic_OUT;
   else if(!strcasecmp(amode,"inout"   )) aMode = Dynamic_INOUT;
index 3b2639ce528e551f0c4f68b4386bbfb9a2eea00d..b0855037bc5f4df45694959320326b6b36932e47 100755 (executable)
@@ -243,7 +243,7 @@ void Extrema_GenExtCS::Perform(const Adaptor3d_Curve& C,
     Standard_Real aCUSq = 0, aSUSq = 0, aSVSq = 0;
     while (aRestIterCount--)
     {
-      Standard_Real aMinCU, aMinSU, aMinSV, aMaxCU, aMaxSU, aMaxSV;
+      Standard_Real aMinCU = 0., aMinSU = 0., aMinSV = 0., aMaxCU = 0., aMaxSU = 0., aMaxSV = 0.;
       Standard_Real aMinSqDist = DBL_MAX, aMaxSqDist = -DBL_MAX;
       for (Standard_Integer aSUNom = 1; aSUNom < aSUDen; aSUNom += 2)
       {
index d12bd588c706d6d9832ed37de0b893d89554913a..7063058ad2766872df3a90eb6811f9c7d3daa67d 100755 (executable)
@@ -365,7 +365,7 @@ void GCPnts_TangentialDeflection::PerformCurve (const TheCurve& C)
     }
     else D0 (C, U2, CurrentPoint);           //Point suivant
 
-    Standard_Real Coef, ACoef, FCoef;
+    Standard_Real Coef, ACoef = 0., FCoef = 0.;
     Standard_Boolean Correction, TooLarge, TooSmall;
     TooLarge   = Standard_False;
     TooSmall   = Standard_False;
index 097e14386ed819997c9f05d024d265eaa8766e4a..0f80fd467c97fdfa85a79875d55a5898ca4608ce 100755 (executable)
@@ -1502,7 +1502,7 @@ Handle(Geom_Surface) Geom_OffsetSurface::Surface() const
   Result.Nullify();
   Handle(Standard_Type) TheType = basisSurf->DynamicType();
   Standard_Boolean IsTrimmed;
-  Standard_Real U1, V1, U2, V2;
+  Standard_Real U1 = 0., V1 = 0., U2 = 0., V2 = 0.;
 
   // Preambule pour les surface trimmes
   if (TheType == STANDARD_TYPE(Geom_RectangularTrimmedSurface)) {
index 43946ad949a28f86069e3e3f16b8391896e5a5e9..42219c3501e86a5d89943c0e532236d32c0a73a4 100755 (executable)
@@ -529,7 +529,7 @@ gp_Pnt2d Geom2dAdaptor_Curve::Value(const Standard_Real U) const
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -556,7 +556,7 @@ void Geom2dAdaptor_Curve::D0(const Standard_Real U, gp_Pnt2d& P) const
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst,  PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -584,7 +584,7 @@ void Geom2dAdaptor_Curve::D1(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst,  PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -612,7 +612,7 @@ void Geom2dAdaptor_Curve::D2(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst,  PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -641,7 +641,7 @@ void Geom2dAdaptor_Curve::D3(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve) &&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst,  PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -669,7 +669,7 @@ gp_Vec2d Geom2dAdaptor_Curve::DN(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve) &&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
index b4f4a7662d5d62f2b3d727224db6ccddba77c456..ba1796967d5a658116ed6e62263e19563cd58ebb 100755 (executable)
@@ -522,7 +522,7 @@ gp_Pnt GeomAdaptor_Curve::Value(const Standard_Real U) const
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -547,7 +547,7 @@ void GeomAdaptor_Curve::D0(const Standard_Real U, gp_Pnt& P) const
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -574,7 +574,7 @@ void GeomAdaptor_Curve::D1(const Standard_Real U, gp_Pnt& P, gp_Vec& V) const
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -602,7 +602,7 @@ void GeomAdaptor_Curve::D2(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve)&&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -631,7 +631,7 @@ void GeomAdaptor_Curve::D3(const Standard_Real U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve) &&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -659,7 +659,7 @@ gp_Vec GeomAdaptor_Curve::DN(const Standard_Real    U,
 {
   if ( (myTypeCurve == GeomAbs_BSplineCurve) &&
       (U==myFirst || U==myLast) ) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (U==myFirst) {
       myBspl->LocateU(myFirst, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
index 406116faa51c5db2378277534c58515ded89c6ba..3fceb0dfc4e2be3256c5e0ba82d779f4e35a3c0e 100755 (executable)
@@ -486,7 +486,7 @@ Handle(GeomFill_TrihedronLaw) GeomFill_CorrectedFrenet::Copy() const
   aT = gp_Vec(0, 0, 0);
   aN = gp_Vec(0, 0, 0);   
 
-  Standard_Real angleAT, currParam, currStep = Step;
+  Standard_Real angleAT = 0., currParam, currStep = Step;
 
   Handle( Geom_Plane ) aPlane;
   Standard_Boolean isPlanar = Standard_False;
index 5540963fce2b08c88ad8696fe02e86a8acf96bd4..888b5c6edba45d045a1dfef9150a63d950c5f070 100755 (executable)
@@ -111,7 +111,7 @@ GeomFill_GuideTrihedronPlan::GeomFill_GuideTrihedronPlan (const Handle(Adaptor3d
 //  Box.Update(-0.1, -0.1, 0.1, 0.1); // Taille minimal
   gp_Vec Tangent,Normal,BiNormal;
   Standard_Integer ii;
-  Standard_Real t, DeltaG, w;
+  Standard_Real t, DeltaG, w = 0.;
   Standard_Real f = myCurve->FirstParameter();
   Standard_Real l = myCurve->LastParameter();
   
index 654139b15051d453866657af2af0b5b46aab37e5..711d134fe428170ac7716426daf9d97adf502de0 100755 (executable)
@@ -42,7 +42,7 @@ GeomFill_TgtOnCoons::GeomFill_TgtOnCoons
 
 gp_Vec GeomFill_TgtOnCoons::Value(const Standard_Real W) const 
 {
-  Standard_Real U,V,bid;
+  Standard_Real U = 0.,V = 0.,bid = 0.;
   switch (ibound){
   case 0 :
     myK->Bound(1)->Bounds(V,bid);
@@ -88,7 +88,7 @@ gp_Vec GeomFill_TgtOnCoons::Value(const Standard_Real W) const
 
 gp_Vec GeomFill_TgtOnCoons::D1(const Standard_Real W) const 
 {
-  Standard_Real U,V,bid;
+  Standard_Real U = 0.,V = 0.,bid = 0.;
   switch (ibound){
   case 0 :
     myK->Bound(1)->Bounds(V,bid);
@@ -150,7 +150,7 @@ gp_Vec GeomFill_TgtOnCoons::D1(const Standard_Real W) const
 
 void GeomFill_TgtOnCoons::D1(const Standard_Real W, gp_Vec& T, gp_Vec& DT) const 
 {
-  Standard_Real U,V,bid;
+  Standard_Real U = 0.,V = 0.,bid = 0.;
   switch (ibound){
   case 0 :
     myK->Bound(1)->Bounds(V,bid);
index b7cc55a0569e50c1a28f487478b92a0d14fd0e38..31e54cf40baa3655dad016c3a280f39373611a10 100755 (executable)
@@ -1482,10 +1482,10 @@ void GeomLib::ExtendSurfByLength(Handle(Geom_BoundedSurface)& Surface,
 
 
         
-  Standard_Integer Cdeg, Cdim, NbP, Ksize, Psize ;
+  Standard_Integer Cdeg = 0, Cdim = 0, NbP = 0, Ksize = 0, Psize = 1;
   Standard_Integer ii, jj, ipole, Kount;  
   Standard_Real Tbord, lambmin=Length;
-  Standard_Real * Padr;
+  Standard_Real * Padr = NULL;
   Standard_Boolean Ok;
   Handle(TColStd_HArray1OfReal)  FKnots, Point, lambda, Tgte, Poles;
 
@@ -1668,7 +1668,7 @@ void GeomLib::ExtendSurfByLength(Handle(Geom_BoundedSurface)& Surface,
   }
   
 //  tableaux necessaires pour l'extension
-  Standard_Integer Ksize2 = Ksize+Cdeg, NbPoles, NbKnots;
+  Standard_Integer Ksize2 = Ksize+Cdeg, NbPoles, NbKnots = 0;
   TColStd_Array1OfReal  FK(1, Ksize2) ; 
   Standard_Real * FKRadr = &FK(1);
 
index 6cb85a2fa918e0586c498e592ab6a0fc65d08606..f78e23d2f30cf643a65cf03a0921dac178ffe760 100755 (executable)
@@ -336,7 +336,7 @@ static Standard_Integer extrema(Draw_Interpretor& di, Standard_Integer n, const
   Standard_Boolean S1 = Standard_False;
   Standard_Boolean S2 = Standard_False;
 
-  Standard_Real U1f,U1l,U2f,U2l,V1f,V1l,V2f,V2l;
+  Standard_Real U1f,U1l,U2f,U2l,V1f = 0.,V1l = 0.,V2f = 0.,V2l = 0.;
 
   GC1 = DrawTrSurf::GetCurve(a[1]);
   if ( GC1.IsNull()) {
index 71a80049ba0adfef1e76025702fcf295600502fa..ba8bb1f0327299b640b0322ec7cb90d9b05e5cec 100755 (executable)
@@ -337,11 +337,9 @@ static Standard_Integer smoothing (Draw_Interpretor& di,Standard_Integer n, cons
 //
 {
   Standard_Real Tolerance=0;
-#ifdef DEB
-  AppParCurves_Constraint  Constraint;
-#else
+
   AppParCurves_Constraint  Constraint=AppParCurves_NoConstraint;
-#endif
+
   Handle(AppParCurves_HArray1OfConstraintCouple)TABofCC;
   TABofCC.Nullify();
   Handle(AppDef_HArray1OfMultiPointConstraint) Points;
@@ -506,11 +504,7 @@ static Standard_Integer smoothingbybezier (Draw_Interpretor& di,
 //============================================================================
 {
   Standard_Real Tolerance=0;
-#ifdef DEB
-  AppParCurves_Constraint  Constraint;
-#else
-  AppParCurves_Constraint  Constraint=AppParCurves_NoConstraint;
-#endif
+  AppParCurves_Constraint Constraint = AppParCurves_NoConstraint;
   Handle(AppParCurves_HArray1OfConstraintCouple)TABofCC;
   Handle(AppDef_HArray1OfMultiPointConstraint) Points;
 
index 70e51915be4b749edfe12823f07f0b2298ac0187..3abcab3395766d3d8cc97fe287e58f360ecc017a 100755 (executable)
@@ -220,7 +220,7 @@ void HLRAlgo_PolyAlgo::Update ()
     TColStd_Array1OfTransient& Polyg = (*psd2)->PolyData();
     Standard_Integer nbFace = Polyg.Upper();
     Standard_Integer nbFaHi = 0;
-    Handle(HLRAlgo_PolyData)* pd;
+    Handle(HLRAlgo_PolyData)* pd = NULL;
     if(nbFace > 0) pd = (Handle(HLRAlgo_PolyData)*)&(Polyg.ChangeValue(1));
     
     for (j = 1; j <= nbFace; j++) {
index 953555c5c38499fe9995adaa245b80b174dc79f7..d0a56f32ca6c5d25683579259263d38fbfe40a55 100755 (executable)
@@ -161,8 +161,8 @@ void HLRAlgo_PolyInternalData::UpdateLinks
  Standard_Address& PINod)
 {
   Standard_Integer i,n1,n2;
-  Standard_Integer find,iiii,icsv;
-  Standard_Address A1,A2,A3,Nod1Indices,Nod2Indices,Seg2Indices,Tri2Indices;
+  Standard_Integer find,iiii,icsv = 0;
+  Standard_Address A1,A2,A3,Nod1Indices,Nod2Indices,Seg2Indices = NULL,Tri2Indices;
   Standard_Boolean newSeg = Standard_False;
   HLRAlgo_TriangleData* TD =
     &(((HLRAlgo_Array1OfTData*)TData)->ChangeValue(1));
@@ -455,7 +455,7 @@ HLRAlgo_PolyInternalData::UpdateLinks (const Standard_Integer ip1,
                                       Standard_Address& )
 {
   Standard_Integer find,iiii,iisv,icsv,iip2 =0,cnx1 =0,cnx2 =0;
-  Standard_Address Seg1Indices,Seg2Indices;
+  Standard_Address Seg1Indices,Seg2Indices = NULL;
   Seg1Indices = 0;
   find = 0;
   iisv = 0;
index 381f497df4f56a82a04e2046cc51b4aa7966063b..0985143f594f805a6fa6f6975aec8c1df6a60158 100755 (executable)
@@ -97,7 +97,7 @@ UpdateGlobalMinMax(const Standard_Address TotMinMax)
     }
   }
   Standard_Integer nbFace      = myPolyg.Upper();
-  Handle(HLRAlgo_PolyData)* pd;
+  Handle(HLRAlgo_PolyData)* pd = NULL;
   if(nbFace > 0) pd =  (Handle(HLRAlgo_PolyData)*)&(myPolyg.ChangeValue(1));
   
   for (Standard_Integer i = 1; i <= nbFace; i++) {
index 4d02250e39b8e1cbd184bf992a9606d8a30b7e96..f658f22ecdb14f497b2144dbb68cc79e3e936e56 100755 (executable)
@@ -693,7 +693,7 @@ void HLRBRep_PolyAlgo::StoreShell (const TopoDS_Shape& Shape,
 {
   TopLoc_Location L;
   TopExp_Explorer exface,exedge;
-  Standard_Integer f,i,j;
+  Standard_Integer f = 0,i,j;
   Standard_Integer nbFaceShell = 0;
   Standard_Boolean reversed;
   Standard_Boolean closed    = Standard_False;
@@ -1228,7 +1228,7 @@ InitBiPointsWithConnexity (const Standard_Integer e,
   Standard_Integer iPol,nbPol,i1,i1p1,i1p2,i2,i2p1,i2p2;
   Standard_Real X1  ,Y1  ,Z1  ,X2  ,Y2  ,Z2  ;
   Standard_Real XTI1,YTI1,ZTI1,XTI2,YTI2,ZTI2;
-  Standard_Real U1,U2;
+  Standard_Real U1,U2 = 0.;
   Handle(Poly_PolygonOnTriangulation) HPol[2];
   TopLoc_Location L;
   myBCurv.Initialize(E);
@@ -2494,7 +2494,7 @@ HLRBRep_PolyAlgo::InsertOnOutLine (TColStd_Array1OfTransient& PID)
   TopLoc_Location L;
   Standard_Boolean insP3,mP3P1,IntOutL;
   Standard_Integer f,ip1,ip2,ip3;//, i;
-  Standard_Real U3,V3,coef3,X3,Y3,Z3;
+  Standard_Real U3,V3,coef3,X3 = 0.,Y3 = 0.,Z3 = 0.;
 
   const gp_Trsf& T  = myProj.Transformation();
   
index 53ab5c8987d9bdb7f83433f5651a79ba2939eb79..e60d809081d010c17bc68aeb6bf9226cadf11782 100755 (executable)
@@ -103,7 +103,7 @@ HLRBRep_ShapeToHLR::Load(const Handle(HLRTopoBRep_OutLiner)& S,
 
   // Create the data structure
   Handle(HLRBRep_Data) DS = new HLRBRep_Data (nbVert, nbEdge, nbFace);
-  HLRBRep_EdgeData* ed; 
+  HLRBRep_EdgeData* ed = NULL
   if(nbEdge != 0) ed = &(DS->EDataArray().ChangeValue(1));
 //  ed++;
 
index 50f644b86fe77f0d2a8f4be1d5a5114b218d17e7..0eeece18dd33a3814b8af024031ae7bf3da367df 100755 (executable)
@@ -37,7 +37,7 @@ void  IGESAppli_ToolLineWidening::ReadOwnParams
   Standard_Integer tempCorneringCode;
   Standard_Integer tempExtensionFlag;
   Standard_Integer tempJustificationFlag;
-  Standard_Real tempExtensionValue;
+  Standard_Real tempExtensionValue = 0.;
   //Standard_Boolean st; //szv#4:S4163:12Mar99 not needed
 
   //szv#4:S4163:12Mar99 `st=` not needed
index 32a6b54ab646e5810cbe47dfb1f9884234057b7d..fe060ff5e9ca913f761cfdeb55e5f1ac7a088136 100755 (executable)
@@ -559,7 +559,7 @@ Standard_Boolean IGESData_ParamReader::ReadXY
   (const IGESData_ParamCursor& PC,Message_Msg& /*amsg*/, gp_XY& val)
 {
   if (!PrepareRead(PC,Standard_False,2)) return Standard_False;
-  Standard_Real X,Y;
+  Standard_Real X,Y = 0.;
   Standard_Boolean stat =
     (ReadingReal (theindex  ,X)  &&
      ReadingReal (theindex+1,Y)  );
@@ -577,7 +577,7 @@ Standard_Boolean IGESData_ParamReader::ReadXY
   (const IGESData_ParamCursor& PC, const Standard_CString mess, gp_XY& val)
 {
   if (!PrepareRead(PC,mess,Standard_False,2)) return Standard_False;
-  Standard_Real X,Y;
+  Standard_Real X,Y = 0.;
   Standard_Boolean stat =
     (ReadingReal (theindex  ,mess,X)  &&
      ReadingReal (theindex+1,mess,Y)  );
@@ -597,7 +597,7 @@ Standard_Boolean IGESData_ParamReader::ReadXYZ
   (const IGESData_ParamCursor& PC,Message_Msg& /*amsg*/, gp_XYZ& val)
 {
   if (!PrepareRead(PC,Standard_False,3)) return Standard_False;
-  Standard_Real X,Y,Z;
+  Standard_Real X,Y = 0.,Z = 0.;
   Standard_Boolean stat =
     (ReadingReal (theindex  ,X)  &&
      ReadingReal (theindex+1,Y)  &&
@@ -616,7 +616,7 @@ Standard_Boolean IGESData_ParamReader::ReadXYZ
   (const IGESData_ParamCursor& PC, const Standard_CString mess, gp_XYZ& val)
 {
   if (!PrepareRead(PC,mess,Standard_False,3)) return Standard_False;
-  Standard_Real X,Y,Z;
+  Standard_Real X,Y = 0.,Z = 0.;
   Standard_Boolean stat =
     (ReadingReal (theindex  ,mess,X)  &&
      ReadingReal (theindex+1,mess,Y)  &&
index ffcb43bf2381abb99235d999ebead4b74a714a08..355db37f168911aadff1eec5d23cedb7ed077216 100755 (executable)
@@ -65,7 +65,7 @@ void IGESGeom_ToolBSplineSurface::ReadOwnParams
   Standard_Integer I, J;
   Standard_Integer anIndexU, anIndexV, aDegU, aDegV;
   Standard_Boolean aCloseU, aCloseV, aPolynom, aPeriodU, aPeriodV;
-  Standard_Real aUmin, aUmax, aVmin, aVmax;
+  Standard_Real aUmin, aUmax, aVmin = 0., aVmax = 0.;
   Standard_Real tempVal;
   gp_XYZ tempXYZ;
   Handle(TColStd_HArray1OfReal) allKnotsU;
index 312a3123be036490ec0fa68b223b44a3b08459c9..60756e004e4354e04bb46392c7d5aad4e492e3b1 100755 (executable)
@@ -60,7 +60,7 @@ void IGESGeom_ToolConicArc::ReadOwnParams(const Handle(IGESGeom_ConicArc)& ent,
   //======================================
 
   //Standard_Boolean st; //szv#4:S4163:12Mar99 not needed
-  Standard_Real A, B, C, D, E, F, ZT;
+  Standard_Real A, B = 0., C = 0., D = 0., E = 0., F = 0., ZT;
   gp_XY tempStart, tempEnd;
 
  /* PR.ReadReal(PR.Current(), Msg81, A); //szv#4:S4163:12Mar99 `st=` not needed
index 92bbb43862b652250ff70af9b065d8a052b1e343..2707967aa4f10f4ff8048e1720cfb14bd8878be8 100755 (executable)
@@ -55,7 +55,7 @@ void IGESGeom_ToolPlane::ReadOwnParams(const Handle(IGESGeom_Plane)& ent,
 {
   // MGE 30/07/98
 
-  Standard_Real A, B, C, D, aSize = 0.;
+  Standard_Real A, B = 0., C = 0., D = 0., aSize = 0.;
   Handle(IGESData_IGESEntity) aCurve;
   gp_XYZ attach (0.,0.,0.);
   IGESData_Status aStatus;
index 099e6515ca0f61292aa2caeb73da4f051d871b36..76478490ffb54975227888c4661a185b3007014c 100755 (executable)
@@ -41,8 +41,8 @@ void IGESGraph_ToolUniformRectGrid::ReadOwnParams
   Standard_Integer weighted;
   gp_XY            gridPoint;
   gp_XY            gridSpacing;
-  Standard_Integer nbPointsX;
-  Standard_Integer nbPointsY;
+  Standard_Integer nbPointsX = 0;
+  Standard_Integer nbPointsY = 0;
 
   // Reading nbPropertyValues(Integer)
   PR.ReadInteger(PR.Current(), "No. of property values", nbPropertyValues);
index e65114c9b552dacb6e9cf722758293f0b8b2c833..fe1b793418a414d126d6b9c19720facec0a344c7 100755 (executable)
@@ -201,7 +201,7 @@ static Standard_Boolean extractCurve3d (const TopoDS_Shape& theEdges,
 {
   TopExp_Explorer anExp(theEdges, TopAbs_EDGE);
   Standard_Integer howMuch = 0;
-  Standard_Real f, l;
+  Standard_Real f = 0., l = 0.;
   for (; anExp.More(); anExp.Next()) {
     TopoDS_Edge anEdge = TopoDS::Edge(anExp.Current());
     if (anEdge.IsNull())
index f9249ee87693531439510054fdef4bdff72fa9e6..bcedb7bd4f301189a896706f57105838aea48e3c 100644 (file)
@@ -412,7 +412,7 @@ Standard_Integer Image_Diff::ignoreBorderEffect()
 
   // Find a different area (a set of close to each other pixels which colors differ in both images).
   // It filters alone pixels with different color.
-  Standard_Size aRow1, aCol1, aRow2, aCol2;
+  Standard_Size aRow1 = 0, aCol1 = 0, aRow2, aCol2;
   Standard_Integer aLen1 = (myDiffPixels.Length() > 0) ? (myDiffPixels.Length() - 1) : 0;
   for (Standard_Integer aPixelId1 = 0; aPixelId1 < aLen1; ++aPixelId1)
   {
index 6432d0439db26b544e7789fccace71b9d88ef217..2455dac3584b55ac574b7239ff097b32cdb6223b 100755 (executable)
@@ -1548,7 +1548,7 @@ void IntCurve_IntConicConic::Perform(const gp_Lin2d& L1
       //--
       Standard_Integer ResHasFirstPoint=0;    
       Standard_Integer ResHasLastPoint=0;
-      Standard_Real ParamStart,ParamStart2,ParamEnd,ParamEnd2;
+      Standard_Real ParamStart = 0.,ParamStart2,ParamEnd = 0.,ParamEnd2;
       Standard_Real Org2SurL1=ElCLib::Parameter(L1,L2.Location());
       //== 3 : L1 et L2 bornent
       //== 2 :       L2 borne
index ba48975a1a10357bf73025d58be6861a9fcfa111..9f729fa665358d544057da8e02c3e0f5ede19b3e 100755 (executable)
@@ -1483,7 +1483,7 @@ void SectionPointToParameters(const Intf_SectionPoint&              Sp,
   gp_Pnt P(Sp.Pnt());
   
   Standard_Integer Pt1,Pt2,Pt3;
-  Standard_Real u1,v1,param;
+  Standard_Real u1 = 0.,v1 = 0.,param;
   //----------------------------------------------------------------------
   //--          Calcul des parametres approches sur la surface          --
   //----------------------------------------------------------------------
index 59168580b6d91bd891bc8ac74f572f1ea4fe1e7e..802fa38d23f162ff4c2b48c6135405f069004abc 100755 (executable)
@@ -445,11 +445,7 @@ Standard_Integer IntCurveSurface_Polyhedron::TriConnex
   Standard_Integer colP = Pivotm1 - ligP * nbdeltaVp1;
 
 // Point sur Edge position in the MaTriangle and edge typ :
-#ifndef DEB  
   Standard_Integer ligE =0, colE =0, typE =0;
-#else
-  Standard_Integer ligE, colE, typE;
-#endif
   if (Pedge!=0) {
     ligE= (Pedge-1)/nbdeltaVp1;
     colE= (Pedge-1) - (ligE * nbdeltaVp1);
@@ -465,15 +461,11 @@ Standard_Integer IntCurveSurface_Polyhedron::TriConnex
   }
 
 // Triangle position General case :
-#ifndef DEB
+
   Standard_Integer linT =0, colT =0;
   Standard_Integer linO =0, colO =0;
   Standard_Integer t =0, tt =0;
-#else
-  Standard_Integer linT, colT;
-  Standard_Integer linO, colO;
-  Standard_Integer t,tt;
-#endif
+
   if (Triang!=0) {
     t = (Triang-1)/(nbdeltaVm2);
     tt= (Triang-1)-t*nbdeltaVm2;
index 6d2f87951aa16447c3e0d783ecae3918086a923e..39004b69ca2a81ac70a7d4897cee086bd0f7bde6 100755 (executable)
@@ -305,7 +305,7 @@ static
   LinOn2S = new IntSurf_LineOn2S;
 
   //// Modified by jgv, 17.09.09 for OCC21255 ////
-  Standard_Real refpar = RealLast(), ref_u1, ref_u2;
+  Standard_Real refpar = RealLast(), ref_u1 = 0., ref_u2 = 0.;
   if (nbvtx)
     {
       const IntPatch_Point& FirstVertex = aline->Vertex(1);
@@ -1092,8 +1092,8 @@ void RefineParameters(const Handle(IntPatch_ALine)& aALine,
   }
   //
   Standard_Boolean bIsDone, bIsEmpty, bParallel, bFound;
-  Standard_Integer aNbPoints;
-  Standard_Real aHalfPi, aEpsilon, aLimV, dT, aT1, aT2, aEpsT;
+  Standard_Integer aNbPoints = 0;
+  Standard_Real aHalfPi, aEpsilon, aLimV, dT, aT1, aT2 = 0., aEpsT;
   Standard_Real aU1, aV1, aU2, aV2;
   gp_Pnt aP1, aP2, aPx;
   gp_Pnt2d  aP2D1, aP2D2, aPLim(0., 0.);
index ac532439485db9e6c5760201797e8f5958794d7b..9b099ba06c0e420f19cd600f2bf385c23372409b 100755 (executable)
@@ -109,11 +109,9 @@ Standard_Boolean IntersectionWithAnArc(gp_Pnt& PSurf,
   dtheta = (u1alin-u0alin)*0.01;
   Standard_Real du=0.000000001;
   Standard_Real distmin = RealLast();
-#ifndef DEB
+
   Standard_Real thetamin = 0.;
-#else
-  Standard_Real thetamin;
-#endif
+
   Standard_Real theparameteronarc = _theparameteronarc;
   for(Standard_Real _theta=u0alin+dtheta; _theta<=u1alin-dtheta; _theta+=dtheta) { 
     gp_Pnt P=alin->Value(_theta);
@@ -123,11 +121,9 @@ Standard_Boolean IntersectionWithAnArc(gp_Pnt& PSurf,
       distmin=d;
     }
   }
-#ifndef DEB
+
   Standard_Real bestpara =0., besttheta =0., bestdist =0., distinit =0. ;
-#else
-    Standard_Real bestpara,besttheta,bestdist,distinit;
-#endif
+
   //-- Distance initiale
   {
     gp_Pnt pp0 = alin->Value(thetamin);
@@ -1232,7 +1228,7 @@ Standard_Boolean  SingleLine (const gp_Pnt& Psurf,
 
   IntPatch_IType typarc = lin->ArcType();
 
-  Standard_Real parproj;
+  Standard_Real parproj = 0.;
   gp_Vec tgint;
   gp_Pnt ptproj;
   Standard_Boolean retvalue;
@@ -1343,11 +1339,9 @@ void ProcessSegments (const IntPatch_SequenceOfSegmentOfTheSOnBounds& listedg,
   IntPatch_TheSegmentOfTheSOnBounds thesegsol;
   IntPatch_ThePathPointOfTheSOnBounds PStartf,PStartl;
   Standard_Boolean dofirst,dolast,procf,procl;
-#ifndef DEB
+
   Standard_Real paramf =0.,paraml =0.,U1 =0.,V1 =0.,U2 =0.,V2 =0.;
-#else
-  Standard_Real paramf,paraml,U1,V1,U2,V2;
-#endif
+
   IntPatch_IType typ;
   IntSurf_TypeTrans trans1,trans2;
   IntSurf_Transition TRest,TArc;
@@ -1684,11 +1678,9 @@ void ProcessRLine (IntPatch_SequenceOfLine& slin,
   
   Standard_Integer i,j,k;
   Standard_Integer Nblin,Nbvtx, Nbpt;
-#ifndef DEB
+
   Standard_Boolean OnFirst = Standard_False,project = Standard_False,keeppoint = Standard_False;
-#else
-  Standard_Boolean OnFirst,project,keeppoint;
-#endif
+
   Handle(Adaptor2d_HCurve2d) arcref;
   Standard_Real paramproj,paramf,paraml;
 
index c2a063bf7e60e8a1129c12758e854263f9f90a5a..bd39936770aba313f0030b575452a7385d2053d5 100755 (executable)
@@ -405,7 +405,7 @@ void IntPatch_ImpPrmIntersection::Perform (const Handle(Adaptor3d_HSurface)& Sur
                                           const Standard_Real Pas)
 {
   Standard_Boolean reversed, procf, procl, dofirst, dolast;
-  Standard_Integer indfirst, indlast, ind2, i,j,k, NbSegm;
+  Standard_Integer indfirst = 0, indlast = 0, ind2, i,j,k, NbSegm;
   Standard_Integer NbPointIns, NbPointRst, Nblines, Nbpts, NbPointDep;
   Standard_Real U1,V1,U2,V2,paramf,paraml,currentparam;
   
index 18d1e4c3dbeeb3b6a50c4a51c0b578dffe78ab0f..ae33cf20b5b5022e7c1a547d2ebf1312d508345c 100755 (executable)
@@ -460,7 +460,7 @@ void IntPatch_RstInt::PutVertexOnLine (Handle(IntPatch_Line)& L,
   IntPatch_SearchPnt Commun;
 
   Standard_Real U,V,W;
-  Standard_Real U1,V1,U2,V2;
+  Standard_Real U1,V1,U2 = 0.,V2 = 0.;
   Standard_Real paramarc=0.,paramline=0.;
   Standard_Integer i,j,k;
   TColgp_SequenceOfPnt locpt;
index aa5b9e3216ce5d4a373efd6bcd1780b71806c459..c99c74640b599c1a2912b6d8f7c462f18638749f 100755 (executable)
@@ -147,7 +147,7 @@ void BoundedArc (const TheArc& A,
   Standard_Integer i,Nbi,Nbp;
 
   gp_Pnt ptdeb,ptfin;
-  Standard_Real pardeb,parfin;
+  Standard_Real pardeb = 0,parfin = 0;
   Standard_Integer ideb,ifin,range,ranged,rangef;
   
 
@@ -593,7 +593,7 @@ void InfiniteArc (const TheArc& A,
   Standard_Integer i,Nbi,Nbp;
 
   gp_Pnt ptdeb,ptfin;
-  Standard_Real pardeb,parfin;
+  Standard_Real pardeb = 0.,parfin = 0.;
   Standard_Integer ideb,ifin,range,ranged,rangef;
   
 
index 975e5e077f67de8a0f0cb11f40877b0cfb632c2c..1e92ff5e6f94316d1ec40cb6f048cfc1152feaeb 100755 (executable)
@@ -908,7 +908,7 @@ Standard_Integer IntTools_BeanFaceIntersector::FastComputeExactIntersection()
       }
       //
       if(aAng2<=aTolang2) {// IsParallel = Standard_True;
-        Standard_Boolean bFlag;
+        Standard_Boolean bFlag = Standard_False;
         Standard_Integer i;
         Standard_Real aD;
         gp_Pnt aPL[2];
index d184d4f498ed54002e31eb8edb884ca00f4bfe24..77aa02dcb55f513a0551320eb62ac9954d62fd0b 100644 (file)
@@ -518,7 +518,7 @@ Standard_Boolean
   IntTools_ComparatorCurve::IsSameXYZ(const gp_XYZ& aXYZ1, 
                                      const gp_XYZ& aXYZ2)
 {
-  Standard_Boolean bRet;
+  Standard_Boolean bRet = Standard_False;
   Standard_Integer i;
   Standard_Real aX1[3], aX2[3];
   
index 649fec29dd9ba19a1d3fb8511061dbf8ca2c7722..1402429b3accb41a88835ff6c382deede0969f8c 100755 (executable)
@@ -427,7 +427,7 @@ void IntTools_EdgeFace::CheckData()
   myC.D0(t, P);
   GeomAPI_ProjectPointOnSurf aProjector;
   //
-  Standard_Real ULD, VLD;
+  Standard_Real ULD = 0., VLD = 0.;
 
   GeomAPI_ProjectPointOnSurf& aLocProj = myContext->ProjPS(myFace);
   aLocProj.Perform(P);
index a87fd9a8e560b2eb7f98b7541d4cf233c9c1634d..849ce9080ffc091f2c489a9d697af33d110b58b1 100755 (executable)
@@ -47,7 +47,7 @@ void IntWalk_IWalking::ComputeCloseLine(const TColStd_SequenceOfReal& Umult,
 // ******************************************************************** 
 {
 
-  Standard_Integer I,N;
+  Standard_Integer I,N = 0;
   Standard_Real aBornInf[2], aBornSup[2], aUVap[2];
   math_Vector BornInf(aBornInf,1,2), BornSup(aBornSup,1,2);
   math_Vector Uvap(aUVap,1,2);// parameters of current approach
index 26c35e15ac4707a43a1131f1de368076dc80a02d..69dacc3579f0e3e6dae7f1d00e547b07bec3823b 100755 (executable)
@@ -47,11 +47,7 @@ Standard_Boolean IntWalk_PWalking::
 {
   Standard_Real Uvd[4],Uvf[4],Epsuv[4],Duv[4],Uvp[4],dv,dv2,ParC[4];
   Standard_Real DPc,DPb;
-#ifndef DEB
   Standard_Integer i = 0, k = 0;
-#else 
-  Standard_Integer i,k;
-#endif
   Epsuv[0] = ResoU1;
   Epsuv[1] = ResoV1;
   Epsuv[2] = ResoU2;
index afba0c0bcfead1455d3aaf4adbcf68fbddbe4e83..6d57b9b2d6961d4868c117403f4736c692d8e77c 100755 (executable)
@@ -104,7 +104,7 @@ Standard_Integer Interface_FloatWriter::Convert (const Standard_Real val,
 //    Valeur flottante, expurgee de "0000" qui trainent et de "E+00"
   const Standard_Integer anMasSize = 5; // change 6 to 5: index 5 is not used below
   char lxp[anMasSize], *pText; 
-  int i0, j0 = 0;
+  int i0 = 0, j0 = 0;
 
   for (Standard_Integer i = 0; i < anMasSize; ++i)
     lxp[i] = '\0';
index 5a274aa2aa2b57c3b83e710905241cf48c55d672..9f0c024556c06a03d7f854fcfc7068d65a90c93f 100755 (executable)
@@ -112,7 +112,7 @@ LDOM_XmlReader::RecordType LDOM_XmlReader::ReadRecord
   theData.Clear();
   myError.Clear();
   ParserState aState = STATE_WAITING;
-  const char * aStartData = NULL, * aNameEnd, * aPtr;
+  const char * aStartData = NULL, * aNameEnd = NULL, * aPtr;
   LDOMBasicString anAttrName, anAttrValue;
   char anAttDelimiter = '\0';
 
index f97f10f3be785b81e5a2b68788c6dddd01c5d652..aac0935bd7a8530214a3d7388ee340d375144fc3 100755 (executable)
@@ -202,7 +202,7 @@ void Law_BSpFunc::Intervals(TColStd_Array1OfReal& T,
 Standard_Real Law_BSpFunc::Value(const Standard_Real X)
 {
   if ((X==first) || (X==last)) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (X==first) {
       curv->LocateU(first, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -231,7 +231,7 @@ void Law_BSpFunc::D1(const Standard_Real X,
                     Standard_Real& D)
 {
   if ((X==first) || (X==last)) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (X==first) {
       curv->LocateU(first, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
@@ -260,7 +260,7 @@ void Law_BSpFunc::D2(const Standard_Real X,
                     Standard_Real& D2)
 {
   if ((X==first) || (X==last)) {
-    Standard_Integer Ideb, Ifin;
+    Standard_Integer Ideb = 0, Ifin = 0;
     if (X==first) {
       curv->LocateU(first, PosTol, Ideb, Ifin);
       if (Ideb<1) Ideb=1;
index 5c043a493d2d646abaa9e942329142a3e6e19532..c51b356574353356ffeae21e602024f510051e0a 100755 (executable)
@@ -354,11 +354,9 @@ static void Propagate(const TopoDS_Shape& F,
   for (exp.Init(F,TopAbs_EDGE); exp.More(); exp.Next()) {
 //  for (TopExp_Explorer exp(F,TopAbs_EDGE); exp.More(); exp.Next()) {
     const TopoDS_Shape& edg = exp.Current();
-#ifdef DEB
-    TopAbs_Orientation ored1 = edg.Orientation(),ored2;
-#else
+
     TopAbs_Orientation ored1 = edg.Orientation(),ored2 = TopAbs_FORWARD;
-#endif
+
     if (ored1 == TopAbs_INTERNAL || ored1 == TopAbs_EXTERNAL) {
       continue;
     }
index 4c2c8b0120bf61593a6409694b9616968c1e7b34..42fc64521d5cad1f94720d1e367bbe108328006a 100755 (executable)
@@ -543,11 +543,9 @@ static void AddPoints(IntCurvesFace_Intersector& theInt,
     param = theInt.WParameter(j);
     paramu = theInt.UParameter(j);
     paramv = theInt.VParameter(j);
-#ifdef DEB
-    TopAbs_Orientation theor;
-#else
+
     TopAbs_Orientation theor=TopAbs_FORWARD;
-#endif
+
     switch (theInt.Transition(j)) {
     case IntCurveSurface_In:
 /* JAG 13.09.96
index a844cbebe29f00a5c5b120de024822e003ee3bcd..ad97f715a2aa2f7556e29f4522fd0b1615176147 100755 (executable)
@@ -345,11 +345,8 @@ static void Perform(BRepIntCurveSurface_Inter & theInt,
 {
   Standard_Real param,paramu,paramv;
   Standard_Integer i, nbpoints=0;
-#ifdef DEB
-  TopAbs_Orientation theor, orface;
-#else
+
   TopAbs_Orientation theor=TopAbs_FORWARD, orface;
-#endif
 
   while (theInt.More()) {
     const gp_Pnt& thept = theInt.Pnt();
index e99c9f218ea55cb05c8fc11037f768e8b4336ed9..7c04a534ea1c8e1dd45b18a97402dd4bc8621b1b 100755 (executable)
@@ -388,7 +388,7 @@ void LocOpe_Generator::Perform(const Handle(LocOpe_GeneratedShape)& G)
   TopoDS_Edge newedg;
   TopoDS_Vertex newvtx;
   TopLoc_Location loc;
-  Standard_Real tol,prm,f,l, Uminc,Umaxc;;
+  Standard_Real tol,prm,f,l, Uminc = 0.,Umaxc = 0.;
   gp_Pnt2d pf,pl;
 
   Handle(Geom_Surface) S;
index a3758818d9decdc295be0b85d1359e88f84e4477..aa77905838bf016419758a243d5c41e9b80cdb0c 100755 (executable)
@@ -156,11 +156,8 @@ void LocOpe_SplitDrafts::Perform(const TopoDS_Face& F,
     Standard_ConstructionError::Raise();
   }
 
-#ifdef DEB
-  TopAbs_Orientation OriF;
-#else
   TopAbs_Orientation OriF = TopAbs_FORWARD;
-#endif
+
   Standard_Boolean FinS = Standard_False;
   TopExp_Explorer exp,exp2;
   for (exp.Init(myShape,TopAbs_FACE); exp.More(); exp.Next()) {
@@ -1493,11 +1490,9 @@ static void MakeFace(TopoDS_Face& F,
     Standard_Boolean wdone = (ledg.IsEmpty() || VFirst.IsSame(VLast));
     while (!wdone) {
       TopoDS_Vertex VF,VL;
-#ifdef DEB
-      TopAbs_Orientation oredg;
-#else
+
       TopAbs_Orientation oredg = TopAbs_FORWARD;
-#endif
+
       for (itl.Initialize(ledg); itl.More(); itl.Next()) {
        const TopoDS_Edge& edg2 = TopoDS::Edge(itl.Value());
        TopoDS_Shape aLocalShape  = edg2.Oriented(TopAbs_FORWARD);
index 87cfbbbf2dc7425e310c859f600ab09ee7dab137..611fd58ef65f051acef4012070c4942eb24c7f2d 100755 (executable)
@@ -951,11 +951,9 @@ void LocOpe_SplitShape::AddOpenWire(const TopoDS_Wire& W,
     newF2.Orientation(TopAbs_FORWARD);
     
     // modifs JAG 97.05.28
-#ifdef DEB
-    TopAbs_Orientation orfila;
-#else
+
     TopAbs_Orientation orfila=TopAbs_FORWARD;
-#endif
+
     for (exp.Init(FaceRef.Oriented(TopAbs_FORWARD),TopAbs_WIRE); 
          exp.More(); exp.Next()) {
       const TopoDS_Wire& wir = TopoDS::Wire(exp.Current());
@@ -1493,7 +1491,7 @@ static TopoDS_Shape ChooseDirection(const TopoDS_Shape& RefDir,
   TopExp_Explorer Explo(RefDir, TopAbs_EDGE);
   TopoDS_Edge RefEdge;
   TopoDS_Vertex V1, V2;
-  TopAbs_Orientation anOr;
+  TopAbs_Orientation anOr = TopAbs_FORWARD;
   for (; Explo.More(); Explo.Next())
   {
     RefEdge = TopoDS::Edge(Explo.Current());
index fb9e735b0722fbf17b4d383ccad7f51807149944..927eb21b3672771fc520aff602118c37c53eafdf 100755 (executable)
@@ -666,7 +666,7 @@ Standard_Real MAT2d_Tool2d::IntersectBisector (
   Standard_Real    Tolerance     = MAT2d_TOLCONF;
   Standard_Real    Param1,Param2;
   Standard_Real    Parama,Paramb;
-  Standard_Real    Distance,DistanceMini;
+  Standard_Real    Distance = 0.,DistanceMini;
   Standard_Boolean SolutionValide;
   gp_Pnt2d         PointSolution;
 
index dce4b8932f697beb59bb72d5421e9ce0e8511745..008848587527423ddb8dc83a64bfb891a78b1dc2 100755 (executable)
@@ -585,7 +585,7 @@ void MeshVS_MeshPrsBuilder::AddFaceWirePrs (const TColStd_Array1OfReal& theCoord
                                             const Standard_Boolean IsShrinked,
                                             const Standard_Real ShrinkCoef) const
 {
-  Standard_Real xG, yG, zG, X, Y, Z, startX=0., startY=0., startZ=0.;
+  Standard_Real xG = 0., yG = 0., zG = 0., X, Y, Z, startX=0., startY=0., startZ=0.;
   theLines->AddBound ( NbNodes+1 );
   if ( IsShrinked )
     CalculateCenter( theCoords, NbNodes, xG, yG, zG );
@@ -628,7 +628,7 @@ void MeshVS_MeshPrsBuilder::AddFaceSolidPrs (const Standard_Integer ID,
   if ( aDS.IsNull() )
     return;
 
-  Standard_Real xG, yG, zG, X, Y, Z, nx, ny, nz;
+  Standard_Real xG = 0., yG = 0., zG = 0., X, Y, Z, nx = 0., ny = 0., nz = 0.;
   thePolygons->AddBound ( NbNodes );
   if ( IsShrinked )
     CalculateCenter( theCoords, NbNodes, xG, yG, zG );
index 37119241cbe4681c126abef8199d326e54a925a1..37a24aa65885b6b395d3e51e1a68f9c78e2e840a 100755 (executable)
@@ -129,7 +129,7 @@ Standard_Boolean NIS_View::FitAll3d (const Quantity_Coefficient theCoef)
   // Check that the box is not empty
   if (aBox.IsVoid() == Standard_False && MyView->IsDefined() == Standard_True) {
     // Convert the 3D box to 2D representation in view coordinates
-    Standard_Real Umin,Umax,Vmin,Vmax,U,V,W;
+    Standard_Real Umin = 0.,Umax = 0.,Vmin = 0.,Vmax = 0.,U,V,W;
     gp_XYZ aCoord;
 
     const gp_XYZ aCorner[2] = { aBox.CornerMin(), aBox.CornerMax() };
index de72c8c74e3e64364883f710b9c1a4339bef1140..41b8a94a664d7d59bf079bfd1a1e15df94621167 100644 (file)
@@ -330,9 +330,9 @@ void OpenGl_GraduatedTrihedron::Render (const Handle(OpenGl_Workspace)& theWorks
   float LX1[6], LX2[6], LX3[6]; /* Lines along X direction */
   float LY1[6], LY2[6], LY3[6]; /* Lines along Y direction */
   float LZ1[6], LZ2[6], LZ3[6]; /* Lines along Z direction */
-  unsigned char LX1draw, LX2draw, LX3draw; /* Allows drawing of X-line (000 - 100 is forbidden) */
-  unsigned char LY1draw, LY2draw, LY3draw; /* Allows drawing of Y-line (000 - 010 is forbidden) */
-  unsigned char LZ1draw, LZ2draw, LZ3draw; /* Allows drawing of Z-line (000 - 001 is forbidden) */
+  unsigned char LX1draw = 0, LX2draw = 0, LX3draw = 0; /* Allows drawing of X-line (000 - 100 is forbidden) */
+  unsigned char LY1draw = 0, LY2draw = 0, LY3draw = 0; /* Allows drawing of Y-line (000 - 010 is forbidden) */
+  unsigned char LZ1draw = 0, LZ2draw = 0, LZ3draw = 0; /* Allows drawing of Z-line (000 - 001 is forbidden) */
 
   /* The first axis will be used for drawing the text and the values. */
   switch (farestCorner)
index 2e2b5f66e55673e5b0f68e7f96c5a1ad9102e15a..a9faf4627f6a18c90c7ce80c425b014f379c1cf4 100644 (file)
@@ -68,7 +68,7 @@ static void bind_light(const OpenGl_Light *lptr, int *gl_lid)
   if (*gl_lid > GL_LIGHT7) return;
 
   // the light is a headlight ?
-  GLint cur_matrix;
+  GLint cur_matrix = 0;
   if (lptr->HeadLight)
   {
     glGetIntegerv(GL_MATRIX_MODE, &cur_matrix);
index bdaa52e7493a1b88560e2e0c7a0ac7a242587927..bb67ed27cc409488e37262f4cb3670ac34c5c402 100755 (executable)
@@ -362,11 +362,7 @@ gp_Pln Primitives_Wedge::Plane(const Primitives_Direction d1)
     break;
     
   };
-#ifndef DEB
-  Standard_Real X =0., Y =0., Z =0.;
-#else
-  Standard_Real X, Y, Z;
-#endif
+  Standard_Real X = 0., Y = 0., Z = 0.;
   
   switch (i) {
     
@@ -444,12 +440,10 @@ const TheFace& Primitives_Wedge::Face
     if ( i%2 == 0 ) myBuilder.ReverseFace(myFaces[i]);
 
     // pcurves
-#ifndef DEB
+
     Primitives_Direction dd1 = Primitives_ZMin, dd2 = Primitives_YMax, 
     dd3 = Primitives_ZMax,dd4 = Primitives_YMin;
-#else
-    Primitives_Direction dd1,dd2,dd3,dd4;
-#endif
+
     switch (i/2) {
       
     case 0 :
@@ -540,11 +534,8 @@ Standard_Boolean Primitives_Wedge::HasWire (const Primitives_Direction d1) const
   Standard_Integer i = Primitives_Wedge_NumDir1(d1);
 
   if (myInfinite[i]) return Standard_False;
-#ifndef DEB
   Primitives_Direction dd1 = Primitives_XMin,dd2 = Primitives_YMax,dd3 = Primitives_XMax ,dd4 = Primitives_ZMin;
-#else
-  Primitives_Direction dd1,dd2,dd3,dd4;
-#endif
+
   switch (i/2) {
     
   case 0 :
@@ -590,11 +581,8 @@ const TheWire& Primitives_Wedge::Wire
 {
   Standard_Integer i = Primitives_Wedge_NumDir1(d1);
 
-#ifndef DEB
   Primitives_Direction dd1 = Primitives_XMin,dd2 = Primitives_YMax,dd3 = Primitives_XMax ,dd4 = Primitives_ZMin;
-#else
-  Primitives_Direction dd1,dd2,dd3,dd4;
-#endif
+
   if (!WiresBuilt[i]) {
 
     switch (i/2) {
@@ -675,11 +663,9 @@ gp_Lin Primitives_Wedge::Line
   if (!HasEdge(d1,d2)) Standard_DomainError::Raise();
 
   Standard_Integer i = Primitives_Wedge_NumDir2(d1,d2);
-#ifndef DEB
+
   Standard_Real X =0., Y =0., Z =0.;
-#else
-  Standard_Real X, Y, Z;
-#endif
+
   gp_Dir D;
   gp_Vec VX = myAxes.XDirection();
   gp_Vec VY = myAxes.YDirection();
@@ -827,11 +813,9 @@ const TheEdge& Primitives_Wedge::Edge
   Standard_Integer i = Primitives_Wedge_NumDir2(d1,d2);
 
   if (!EdgesBuilt[i]) {
-#ifndef DEB
+
     Primitives_Direction dd1 = Primitives_XMin ,dd2 = Primitives_XMax;
-#else
-    Primitives_Direction dd1,dd2;
-#endif
+
     switch (i/4) {
     
     case 0 :
@@ -923,11 +907,9 @@ gp_Pnt  Primitives_Wedge::Point
   if (!HasVertex(d1,d2,d3)) Standard_DomainError::Raise();
 
   Standard_Integer i = Primitives_Wedge_NumDir3(d1,d2,d3);
-#ifndef DEB
+
   Standard_Real X =0., Y =0., Z =0.;
-#else
-  Standard_Real X, Y, Z;
-#endif
+
   switch (i) {
     
   case 0 :
index 5d32f2514ae1943e6ed7a0adf023c0a0c592323b..132068f5e5a87352258b4eed52d01122d5f15c84 100755 (executable)
@@ -612,7 +612,7 @@ static Standard_Boolean InitialPoint(const gp_Pnt& Point,
       prevDeb=t;
       if (t == LastU) FromLastU=Standard_True;
       Standard_Boolean initpoint=Standard_False;
-      Standard_Real U, V;
+      Standard_Real U = 0., V = 0.;
       gp_Pnt CPoint;
       Standard_Real ParT,ParU,ParV; 
 
index 2c4a5046945860add5c7d8cc509380737a36b9ee..e50adb312ea52c819af02641f38f6c0968a90f9f 100755 (executable)
@@ -91,7 +91,7 @@ static gp_Pnt2d Function_Value(const Standard_Real U,
                               const Standard_Boolean UCouture,
                               const Standard_Boolean VCouture ) 
 {
-  Standard_Real S, T;
+  Standard_Real S = 0., T = 0.;
 
   gp_Pnt P3d = myCurve->Value(U);
   GeomAbs_SurfaceType SType = mySurface->GetType();
@@ -1072,7 +1072,7 @@ ProjLib_ComputeApprox::ProjLib_ComputeApprox
     //Return curve home
     Standard_Real UFirst = F.FirstParameter();
     gp_Pnt P3d = C->Value( UFirst );
-    Standard_Real u, v;
+    Standard_Real u = 0., v = 0.;
     switch (SType)
       {
       case GeomAbs_Plane:
index 8fde532a9b3406402d07dec6d40ec2257f094f41..e9df2b509fa9980065dddd404699b32bf3df9a3b 100755 (executable)
@@ -119,7 +119,7 @@ static gp_Pnt2d Function_Value(const Standard_Real U,
   if((Type != GeomAbs_BSplineSurface) && 
      (Type != GeomAbs_BezierSurface)  &&
      (Type != GeomAbs_OffsetSurface)    ) {
-    Standard_Real S, T;
+    Standard_Real S = 0., T = 0.;
     switch (Type) {
 //    case GeomAbs_Plane:
 //      {
index 97d9c0fa47f71c4b6100055b0e664d5e6201d361..2f5911a9a0b8f215f881efd548a6b1edc329ebd8 100755 (executable)
@@ -468,7 +468,7 @@ void ProjLib_ProjectedCurve::Load(const Handle(Adaptor3d_HCurve)& C)
       {
        Standard_Boolean IsTrimmed[2] = {Standard_False, Standard_False};
         Standard_Real Vsingular[2]; //for surfaces of revolution
-       Standard_Real f, l, dt;
+       Standard_Real f = 0., l = 0., dt = 0.;
        const Standard_Real eps = 0.01;
        
        if(mySurface->GetType() == GeomAbs_SurfaceOfRevolution) {
@@ -512,7 +512,7 @@ void ProjLib_ProjectedCurve::Load(const Handle(Adaptor3d_HCurve)& C)
        // doit etre une et une seule courbe !!!
        // De plus, cette courbe ne doit pas etre Single point
        Standard_Integer NbCurves = Projector.NbCurves();
-       Standard_Real Udeb,Ufin;
+       Standard_Real Udeb = 0.,Ufin = 0.;
        if (NbCurves > 0) {
          Projector.Bounds(1,Udeb,Ufin);
        }
index 231ec0b9a44e3316463a401e1b6f64666bab50a9..d0aebf4a5d618a5876651c359ab9ccf564577aa5 100755 (executable)
@@ -254,7 +254,7 @@ static int BUC60610(Draw_Interpretor& di, Standard_Integer argc, const char ** a
     printf("Usage: %s  iges_input [name]\n",argv[0]);
     return(1);
   }
-  Standard_Character *Ch;
+  Standard_Character *Ch = NULL;
 
   if(argc > 2) {
     Ch = new Standard_Character[strlen(argv[2])+3];
index ebf10571afc1853f9a602de713ebed8ee0919717..55a0f3ca9376b55e1f64623e02faa09e1877d5dc 100755 (executable)
@@ -620,7 +620,7 @@ static void Sort3Faces(const TopTools_ListOfShape& theListIn, TopTools_ListOfSha
   }
 
   Standard_Boolean found = Standard_False;
-  Standard_Integer j, i1, i2, i3
+  Standard_Integer j, i1 = 0, i2 = 0, i3 = 0
   TopoDS_Edge anEdge;
   for(i=1;i<=3;i++) {
     TopExp_Explorer anExp1(ArS.Value(i), TopAbs_EDGE);
@@ -840,7 +840,7 @@ static void SortEdges2(const TColgp_Array1OfPnt& theArP, const gp_Ax1& theAx,
 static void SortEdges3(const TopTools_Array1OfShape& theArS, const TColgp_Array1OfPnt& theArP, 
                       const gp_Ax1& theAx, TColStd_Array1OfInteger& theArI)
 {
-  Standard_Integer i, j, i1,i2, i3;
+  Standard_Integer i, j, i1 = 0,i2 = 0, i3 = 0;
   TopoDS_Shape aV;
   Standard_Boolean adjacent = Standard_False;
   for(i=1;i<=3;i++) {    
@@ -910,13 +910,13 @@ static void SortEdges4(const TopTools_Array1OfShape& theArS, const TColgp_Array1
 // 2. find nearest pair, reorganize ArI
 // 3. sort inside pairs
 // =======================================
-  Standard_Integer i, j, i1,i2, i3, i4;
+  Standard_Integer i, j, i1 = 0,i2 = 0, i3 = 0, i4 = 0;
 // 1.
   TopoDS_Shape aV1;
   for(i=1;i<=4;i++) { 
     const TopoDS_Shape& aV11 = TopExp::FirstVertex(TopoDS::Edge(theArS.Value(i)));
     const TopoDS_Shape& aV12 = TopExp::LastVertex(TopoDS::Edge(theArS.Value(i)));
-    Standard_Boolean aDjacent;
+    Standard_Boolean aDjacent = Standard_False;
     for(j=1;j<=4;j++) {
       if(i==j) continue;
       const TopoDS_Shape& aV21 = TopExp::FirstVertex(TopoDS::Edge(theArS.Value(j)));
@@ -1166,7 +1166,7 @@ static void FindAdjacent3(const TopTools_ListOfShape& theList,
     ArD.SetValue(i, anAx.Direction());
   }
   Standard_Boolean aDjacent = Standard_False;
-  Standard_Integer j, i2, i3; //i2, i3 - indexes of two adjacent faces having the same surface
+  Standard_Integer j, i2 = 0, i3 = 0; //i2, i3 - indexes of two adjacent faces having the same surface
   Standard_Integer i1 = 0; //single face
   for(i=1;i<=3;i++) {    
     for(j=1;j<=3;j++) {
index 14f9ea20d3808caf1d1396e8754a81c981dc96c0..4b4724db8e77b4bea37b803749b4199e7a73fa65 100755 (executable)
@@ -120,7 +120,7 @@ void QANewBRepNaming_Loader::LoadModifiedShapes (BRepBuilderAPI_MakeShape&    MS
   TopTools_MapOfShape View;
   TopExp_Explorer ShapeExplorer (ShapeIn, KindOfShape);
   TopTools_ListOfShape Shapes;
-  BRepAlgoAPI_BooleanOperation* pMS;
+  BRepAlgoAPI_BooleanOperation* pMS = NULL;
   if (theBool) 
     pMS = (reinterpret_cast<BRepAlgoAPI_BooleanOperation *>(&MS));
   for (; ShapeExplorer.More(); ShapeExplorer.Next ()) {
index 9d9bcd4ff11add18318f0b71a4de7bfa674cf02f..9614612f2b2b2b3565ec186a4bdf77f93ea4b97d 100755 (executable)
@@ -254,7 +254,7 @@ static Standard_Boolean CorrectOrientation(const TopoDS_Shell& TheS)
 
   Standard_Integer i, nbEdgs = aMapEdgeFace.Extent();
   TopExp_Explorer anExp;
-  TopAbs_Orientation anOrnt;
+  TopAbs_Orientation anOrnt = TopAbs_FORWARD;
 
   for(i = 1; i <= nbEdgs; i++) {
 
index 54bcb616102ae20cb7790cdb6efb07b7d7bd1369..b9074d5ab07bd8e5765c2e810f5e893fb35dd9b7 100755 (executable)
@@ -763,7 +763,7 @@ QANewModTopOpe_Glue::PerformShell()
   TopoDS_Shape aNewS[2];
   Standard_Integer nbModified = 0;
   Standard_Integer nbDeleted = 0;
-  Standard_Integer iShape;
+  Standard_Integer iShape = 0;
 
   for (i = 0; i < 2; i++) {
     const TopoDS_Shape& aOldS = (i==0 ? myS1 : myS2);
@@ -1208,7 +1208,7 @@ IsVertexOnFaceBound (const TopoDS_Vertex& theVer,
                     Standard_Real& thePar,
                     Standard_Real& theDist)
 {
-  Standard_Real aDist, aPar, aTol2;
+  Standard_Real aDist, aPar, aTol2 = 0.;
   theDist = RealLast();
   gp_Pnt aPnt(BRep_Tool::Pnt(theVer));
   Standard_Boolean isContactByVer = Standard_False;
index ef25ee582bd219f4468a091d4afaab70943d0d30..3c167a4e52524419d06f8342bd146ef2fb4a3841 100755 (executable)
@@ -97,7 +97,7 @@ void RWStepBasic_RWSiUnit::ReadStep(const Handle(StepData_StepReaderData)& data,
   }
   
   // --- own field : name ---
-  StepBasic_SiUnitName aName;
+  StepBasic_SiUnitName aName = StepBasic_sunMetre;
   if (data->ParamType(num,3) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num,3);
     if(!DecodeName(aName,text))
index 76c61b5b375442bfaee0ced20965b75c8f7b21e2..de3fad68ac6ba9ca02a17cacd0aa9ac9bfb82e5a 100755 (executable)
@@ -48,7 +48,7 @@ void RWStepBasic_RWSiUnitAndAreaUnit::ReadStep(const Handle(StepData_StepReaderD
   if (!data->CheckNbParams(num,2,ach,"si_unit")) return;
   
   RWStepBasic_RWSiUnit reader;
-  StepBasic_SiPrefix aPrefix;
+  StepBasic_SiPrefix aPrefix = StepBasic_spExa;
   Standard_Boolean hasAprefix = Standard_False;
   if (data->IsParamDefined(num,1)) {
     if (data->ParamType(num,1) == Interface_ParamEnum) {
index 4e603ce90c698c0e1c149c3e02190745f03aa05a..23439568c3033e9193392ee276dee72d66fecbd9 100755 (executable)
@@ -53,7 +53,7 @@ void RWStepBasic_RWSiUnitAndPlaneAngleUnit::ReadStep(const Handle(StepData_StepR
 
   // --- field : prefix ---
   RWStepBasic_RWSiUnit reader;
-  StepBasic_SiPrefix aPrefix = StepBasic_spExa; // by default
+  StepBasic_SiPrefix aPrefix = StepBasic_spExa;
   Standard_Boolean hasAprefix = Standard_False;
   if (data->IsParamDefined(num,1)) {
     if (data->ParamType(num,1) == Interface_ParamEnum) {
index 6c359aec1388a8adc7e7b64415a2869976ce378a..1a71c66acf2cb2785fd2da8a055bb0f7830781ff 100755 (executable)
@@ -52,7 +52,7 @@ void RWStepBasic_RWSiUnitAndRatioUnit::ReadStep       (const Handle(StepData_StepReade
 
   // --- field : prefix ---
   RWStepBasic_RWSiUnit reader;
-  StepBasic_SiPrefix aPrefix;
+  StepBasic_SiPrefix aPrefix = StepBasic_spExa;
   Standard_Boolean hasAprefix = Standard_False;
   if (data->IsParamDefined(num,1)) {
     if (data->ParamType(num,1) == Interface_ParamEnum) {
index 4c00ee099d82cbc10fc6fba09cc93a3651c98b68..c8e9e87748498e14d940cde1dbf184d24736eb20 100755 (executable)
@@ -43,7 +43,7 @@ void RWStepBasic_RWSiUnitAndVolumeUnit::ReadStep(const Handle(StepData_StepReade
   if (!data->CheckNbParams(num,2,ach,"si_unit")) return;
   
   RWStepBasic_RWSiUnit reader;
-  StepBasic_SiPrefix aPrefix;
+  StepBasic_SiPrefix aPrefix = StepBasic_spExa;
   Standard_Boolean hasAprefix = Standard_False;
   if (data->IsParamDefined(num,1)) {
     if (data->ParamType(num,1) == Interface_ParamEnum) {
index fc42dc81620a74e093cdc19816828f4f1b008dbe..1557e9691928729236deb8c73f0f6398a5bd3200 100755 (executable)
@@ -78,7 +78,7 @@ void RWStepDimTol_RWGeoTolAndGeoTolWthDatRefAndModGeoTolAndPosTol::ReadStep
 
   data->NamedForComplex("MODIFIED_GEOMETRIC_TOLERANCE",num0,num,ach);
   // Own fields of ModifiedGeometricTolerance
-  StepDimTol_LimitCondition aModifier;
+  StepDimTol_LimitCondition aModifier = StepDimTol_MaximumMaterialCondition;
   if (data->ParamType (num, 1) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 1);
     if      (strcmp(text, ".MAXIMUM_MATERIAL_CONDITION.")==0) aModifier = StepDimTol_MaximumMaterialCondition;
index c889617beb47cf9442e71393092fed3d9b40b319..ee2c89ce281cb0505c51680fb60105478400da07 100755 (executable)
@@ -59,7 +59,7 @@ void RWStepDimTol_RWModifiedGeometricTolerance::ReadStep (const Handle(StepData_
 
   // Own fields of ModifiedGeometricTolerance
 
-  StepDimTol_LimitCondition aModifier;
+  StepDimTol_LimitCondition aModifier = StepDimTol_MaximumMaterialCondition;
   if (data->ParamType (num, 5) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 5);
     if      (strcmp(text, ".MAXIMUM_MATERIAL_CONDITION.")==0) aModifier = StepDimTol_MaximumMaterialCondition;
index e06b4d437153436455d1d9a328689295da6e9b37..db5ff23c3f7934933c2be2a3509d391a5b4ca932 100755 (executable)
@@ -48,7 +48,7 @@ void RWStepElement_RWCurve3dElementDescriptor::ReadStep (const Handle(StepData_S
 
   // Inherited fields of ElementDescriptor
 
-  StepElement_ElementOrder aElementDescriptor_TopologyOrder;
+  StepElement_ElementOrder aElementDescriptor_TopologyOrder = StepElement_Linear;
   if (data->ParamType (num, 1) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 1);
     if      (strcmp(text, ".LINEAR.")==0) aElementDescriptor_TopologyOrder = StepElement_Linear;
index 0e0a98015849c234d418cfcddaa994471d39a411..5775ca174b20ebe4ebda402cbe10c7a41d122f3f 100755 (executable)
@@ -45,7 +45,7 @@ void RWStepElement_RWElementDescriptor::ReadStep (const Handle(StepData_StepRead
 
   // Own fields of ElementDescriptor
 
-  StepElement_ElementOrder aTopologyOrder;
+  StepElement_ElementOrder aTopologyOrder = StepElement_Linear;
   if (data->ParamType (num, 1) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 1);
     if      (strcmp(text, ".LINEAR.") == 0) aTopologyOrder = StepElement_Linear;
index 71d6c6ab2f54b0eaf572daa303ef3c4a3344148a..86870b50a4d5815e740ad332650bfd3149205d73 100755 (executable)
@@ -48,7 +48,7 @@ void RWStepElement_RWSurface3dElementDescriptor::ReadStep (const Handle(StepData
 
   // Inherited fields of ElementDescriptor
 
-  StepElement_ElementOrder aElementDescriptor_TopologyOrder;
+  StepElement_ElementOrder aElementDescriptor_TopologyOrder = StepElement_Linear;
   if (data->ParamType (num, 1) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 1);
     if      (!strcmp(text, ".LINEAR.")) aElementDescriptor_TopologyOrder = StepElement_Linear;
@@ -86,7 +86,7 @@ void RWStepElement_RWSurface3dElementDescriptor::ReadStep (const Handle(StepData
     }
   }
 
-  StepElement_Element2dShape aShape;
+  StepElement_Element2dShape aShape = StepElement_Quadrilateral;
   if (data->ParamType (num, 4) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 4);
     if      (!strcmp(text, ".QUADRILATERAL.")) aShape = StepElement_Quadrilateral;
index 5784da5cbbded213dee2a8e86f168d22c3cb70c1..7d79fcc77786b9cfd6de5da3990917b515ec9fdf 100755 (executable)
@@ -47,7 +47,7 @@ void RWStepElement_RWVolume3dElementDescriptor::ReadStep (const Handle(StepData_
 
   // Inherited fields of ElementDescriptor
 
-  StepElement_ElementOrder aElementDescriptor_TopologyOrder;
+  StepElement_ElementOrder aElementDescriptor_TopologyOrder = StepElement_Linear;
   if (data->ParamType (num, 1) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 1);
     if      (!strcmp(text, ".LINEAR.")) aElementDescriptor_TopologyOrder = StepElement_Linear;
@@ -77,7 +77,7 @@ void RWStepElement_RWVolume3dElementDescriptor::ReadStep (const Handle(StepData_
     }
   }
 
-  StepElement_Volume3dElementShape aShape;
+  StepElement_Volume3dElementShape aShape = StepElement_Hexahedron;
   if (data->ParamType (num, 4) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 4);
     if      (!strcmp(text, ".HEXAHEDRON.")) aShape = StepElement_Hexahedron;
index 9a1c6a923de855c62dcbb6bfe3988a1d9ff7a5d4..aa814d87560c6e669bab98f0773c63dd944bb396 100755 (executable)
@@ -75,7 +75,7 @@ void RWStepFEA_RWFeaAxis2Placement3d::ReadStep (const Handle(StepData_StepReader
 
   // Own fields of FeaAxis2Placement3d
 
-  StepFEA_CoordinateSystemType aSystemType;
+  StepFEA_CoordinateSystemType aSystemType = StepFEA_Cartesian;
   if (data->ParamType (num, 5) == Interface_ParamEnum) {
     Standard_CString text = data->ParamCValue(num, 5);
     if      (strcmp(text, ".CARTESIAN.") == 0) aSystemType = StepFEA_Cartesian;
index fee64818f13f65e33a9156ffc87ba723e7f8365b..c38d48233d57858ab2a4d880981c08ff26c1ac86 100755 (executable)
@@ -200,7 +200,7 @@ static Standard_Integer XSHAPE_edgeregul
   (Draw_Interpretor& di, Standard_Integer argc, const char** argv)
 {
   //cky/rln 03.02.99 To eliminate dependence of SWDRAW on TKXSBase (to use only ShapeHealing)
-  Standard_Real tolang; // = Interface_Static::RVal("XSTEP.encoderegularity.angle");
+  Standard_Real tolang = Precision::Angular(); // = Interface_Static::RVal("XSTEP.encoderegularity.angle");
 //  if (argc < 3) di<<"Current value for regularity angle : "<<tolang<<"\n";
   if (argc < 3) {
     di<<"Donner nom de shape.\n + option : angle en radian, sinon la valeur courante est prise"<<"\n";
index 227a0798b5cdf4a2db5db8a0d96269804628307a..a671b52dba3e2aebc444fd39c8f81e6d58a58b20 100755 (executable)
@@ -88,7 +88,7 @@ Matches(const Standard_Real X,
         Standard_Real& DMin)
 {
   Standard_Real DMin2 = 0.;
-  Standard_Real Xmin,Ymin,Xmax,Ymax;
+  Standard_Real Xmin = 0.,Ymin = 0.,Xmax = 0.,Ymax = 0.;
   if(!Bnd_Box2d(mybox2d).IsVoid())
   {
     Bnd_Box2d(mybox2d).Get(Xmin,Ymin,Xmax,Ymax);
index 6db19eab794b6e53d74f00548314284e4b65a499..779d9bb2ad4f3a64cd9dae9b315a54d1029a8ee1 100755 (executable)
@@ -232,7 +232,7 @@ static Standard_Boolean MinMaxSmall
     else     { nbu = bs->NbUPoles(), nbv = bs->NbVPoles(); }
     // Standard_Real dx = 0, dy = 0, dz = 0;
     // Standard_Real    x,y,z;
-    Standard_Real minx,miny,minz,maxx,maxy,maxz;
+    Standard_Real minx = 0.,miny = 0.,minz = 0.,maxx = 0.,maxy = 0.,maxz = 0.;
     Standard_Boolean issmall = Standard_True;
 
     for (iu = 1; iu <= nbu; iu ++) {
@@ -426,7 +426,7 @@ static Standard_Boolean MinMaxSmall
 
 //    Edge on same vertex : small one ?
     if (VA.IsSame(VB)) {
-      Standard_Real cf,cl;
+      Standard_Real cf = 0.,cl = 0.;
       Handle(Geom_Curve) C3D;
       if (!BRep_Tool::Degenerated(E)) C3D = BRep_Tool::Curve (E,cf,cl);
       if (C3D.IsNull()) continue;  // DGNR
@@ -584,7 +584,7 @@ static Standard_Integer IsoStat
   Standard_Integer i, np = 0;
   Standard_Integer i0 = (uorv == 1 ? poles.LowerCol() : poles.LowerRow());
   Standard_Integer i1 = (uorv == 1 ? poles.UpperCol() : poles.UpperRow());
-  Standard_Real xmin,ymin,zmin, xmax,ymax,zmax;
+  Standard_Real xmin = 0.,ymin = 0.,zmin = 0., xmax = 0.,ymax = 0.,zmax = 0.;
   for (i = i0; i <= i1; i ++) {
     if (uorv == 1) MinMaxPnt (poles(rank,i),np,xmin,ymin,zmin, xmax,ymax,zmax);
     else      MinMaxPnt (poles(i,rank), np, xmin,ymin,zmin, xmax,ymax,zmax);
index f2ed43b8663687e387272c4fce75f04bf124988d..55b8d8298846849f6a1bb065e4d0a17eba54e606 100755 (executable)
@@ -202,7 +202,7 @@ Standard_Real ShapeAnalysis_ShapeTolerance::Tolerance(const TopoDS_Shape& shape,
  void ShapeAnalysis_ShapeTolerance::AddTolerance(const TopoDS_Shape& shape,const TopAbs_ShapeEnum type) 
 {
   Standard_Integer nbt   = 0;
-  Standard_Real tol, cmin,cmoy,cmax;
+  Standard_Real tol, cmin = 0.,cmoy = 0.,cmax = 0.;
 
   TopExp_Explorer myExp;
 
index 6230b3964ccd875a58675e232227e5a99b7130bf..6308a12e34ecdce2c6cfa6571f07eeeaf974668f 100755 (executable)
@@ -911,7 +911,7 @@ gp_Pnt2d ShapeAnalysis_Surface::NextValueOfUV(const gp_Pnt2d &p2dPrev,
 gp_Pnt2d ShapeAnalysis_Surface::ValueOfUV(const gp_Pnt& P3D,const Standard_Real preci)
 {
   GeomAdaptor_Surface& SurfAdapt = Adaptor3d()->ChangeSurface();
-  Standard_Real S, T;
+  Standard_Real S = 0., T = 0.;
   myGap = -1.;    // devra etre calcule
   Standard_Boolean computed = Standard_True;  // a priori
   
index 5f107268c9df2f08d3ce17c7e141c90a03fca114..56cb4c3dd711af45e10c450b8545072dcb988430 100755 (executable)
@@ -239,7 +239,7 @@ void ShapeAnalysis_WireOrder::Perform(const Standard_Boolean /*closed*/)
   while(!done) {
     Standard_Integer resultType = 3;
     Standard_Real distmin = RealLast();
-    Standard_Integer ledge;
+    Standard_Integer ledge = 0;
     Standard_Boolean found = Standard_False;
     Standard_Real closeDist = wireFirst.SquareDistance(wireLast);
     
index 0bd098c478e052fa8291ae4afc601fdd2df78560..4b05cca99df2051497b068ba77bbd1944ae03e8f 100755 (executable)
@@ -293,7 +293,7 @@ Standard_Boolean ShapeConstruct::JoinPCurves(const Handle(TopTools_HSequenceOfSh
     Standard_Boolean IsEdgeSeam = Standard_False;
     Handle(Geom2d_Curve) aCrvRes1, aCrvRes2;
     TopAbs_Orientation resOrient;
-    Standard_Real newf,newl;
+    Standard_Real newf = 0.,newl = 0.;
     // iterates on edges
     Standard_Integer i = 1;
     for(; i <= edges->Length(); i++) {
index 87e536d9e4c25e530c484883f786d2983dfe3a6d..da340267992f42ddd7e08629e300aa0b69bfaf09 100755 (executable)
@@ -327,7 +327,7 @@ Handle(Geom_Surface) ShapeCustom_Surface::ConvertToAnalytical (const Standard_Re
   GeomAdaptor_Surface& SurfAdapt = NHS->ChangeSurface();
 
   const Standard_Integer NP = 21;
-  Standard_Real S, T;  // U,V deja fait
+  Standard_Real S = 0., T = 0.;  // U,V deja fait
   gp_Pnt P3d, P3d2;
   Standard_Boolean onSurface = Standard_True;
 
index a0a41c9e6008248519b60bc9462ecca8327d5b08..435cf3524cd6058a9ed2bec041858382ff6b4e9a 100755 (executable)
@@ -2001,7 +2001,7 @@ void ShapeFix_ComposeShell::CollectWires (ShapeFix_SequenceOfWireSegment &wires,
   TopoDS_Vertex firstV, endV;
   TopoDS_Edge firstEdge, lastEdge;
   Standard_Real tol = 0;
-  Standard_Integer iumin, iumax, ivmin, ivmax;
+  Standard_Integer iumin = 0, iumax = 0, ivmin = 0, ivmax = 0;
   Standard_Real dsu=0., dsv=0.;
   Standard_Boolean canBeClosed = Standard_False;
   for(;;) {
index 4d07225a73bfb0c8a93a5c11a9ef99a7610bec35..7903053f4752528a62f3b1578834859858128ddd 100755 (executable)
@@ -1343,7 +1343,7 @@ Standard_Boolean ShapeFix_Wire::FixShifted()
     TopoDS_Vertex V = sae.FirstVertex ( E2 );
     gp_Pnt p = BRep_Tool::Pnt ( V );
   
-    Standard_Real a1, b1, a2, b2;
+    Standard_Real a1 = 0., b1 = 0., a2 = 0., b2 = 0.;
     Handle(Geom2d_Curve) c2d1, c2d2;
 
     //:abv 29.08.01: torCuts.sat: distinguish degeneration by U and by V;
@@ -1385,7 +1385,7 @@ Standard_Boolean ShapeFix_Wire::FixShifted()
 //     if ( stop < n2 ) { stop = n2; degstop = Standard_True; }
       }
       else {
-       Standard_Real ax1, bx1, ax2, bx2;
+       Standard_Real ax1 = 0., bx1 = 0., ax2 = 0., bx2 = 0.;
        Handle(Geom2d_Curve) cx1, cx2;
        if ( ( c2d1.IsNull() && ! sae.PCurve ( E1, Face(), c2d1, a1, b1, Standard_True ) ) ||
             ( c2d2.IsNull() && ! sae.PCurve ( E2, Face(), c2d2, a2, b2, Standard_True ) ) ||
@@ -2108,7 +2108,7 @@ Standard_Boolean ShapeFix_Wire::FixSelfIntersectingEdge (const Standard_Integer
 
   // cycle is to verify fix in case of RemoveLoop
   Standard_Real tolfact = 0.1; // factor for shifting by parameter in RemoveLoop
-  Standard_Real f2d, l2d;
+  Standard_Real f2d = 0., l2d = 0.;
   Handle(Geom2d_Curve) c2d;
   Standard_Real newtol=0.; // = Precision();
 
@@ -2744,9 +2744,9 @@ Standard_Boolean ShapeFix_Wire::FixLacking (const Standard_Integer num,
 
   //=============
   //:s2 abv 21 Apr 99: Speculation: try bending pcurves
-  Standard_Real bendtol1, bendtol2;
+  Standard_Real bendtol1 = 0., bendtol2 = 0.;
   Handle(Geom2d_Curve) bendc1, bendc2;
-  Standard_Real bendf1, bendl1, bendf2, bendl2;
+  Standard_Real bendf1 = 0., bendl1 = 0., bendf2 = 0., bendl2 = 0.;
   if ( myGeomMode && ! BRep_Tool::IsClosed(E1,face) && ! BRep_Tool::IsClosed(E2,face) ) {
     gp_Pnt2d p2d = 0.5 * ( p2d1.XY() + p2d2.XY() );
     Standard_Boolean ok1 = TryBendingPCurve (E1, face, p2d, E1.Orientation() == TopAbs_FORWARD, 
index ca2b3b154ec0d55c01939b99e4311700fcab9636..17313bbbc5843a78397b2ba2463356887541ca3a 100755 (executable)
@@ -61,7 +61,7 @@ Standard_Boolean ShapeUpgrade_ClosedEdgeDivide::Compute(const TopoDS_Edge& anEdg
     Standard_Real f, l;
     Handle(Geom_Curve) curve3d = BRep_Tool::Curve (anEdge, f, l);
     myHasCurve3d = !curve3d.IsNull();
-    Standard_Real f2d, l2d;
+    Standard_Real f2d = 0., l2d = 0.;
     Handle(Geom2d_Curve) pcurve1;
     if ( ! myFace.IsNull() ) { // process free edges
       sae.PCurve (anEdge, myFace, pcurve1, f2d, l2d, Standard_False);
index a7c04809123072980635653679f6c96bbb1580dc..d5ed1ba4934d0705dbf7354de52ce727f6668b64 100755 (executable)
@@ -71,7 +71,7 @@ Standard_Boolean ShapeUpgrade_EdgeDivide::Compute(const TopoDS_Edge& anEdge)
   
   // on pcurve(s): all knots
   // assume that if seam-edge, its pcurve1 and pcurve2 has the same split knots !!!
-  Standard_Real f2d, l2d;
+  Standard_Real f2d = 0., l2d = 0.;
   Handle(Geom2d_Curve) pcurve1;
   if ( ! myFace.IsNull() ) { // process free edges
     ShapeAnalysis_Edge sae;
index 5ec3563616346ba6b163227fe7598e52738d2fdd..4699cef3a121598690f1c120caffcbb63276dd4f 100755 (executable)
@@ -70,7 +70,7 @@ double ShapeUpgrade_SplitSurfaceAngle::MaxAngle () const
 void ShapeUpgrade_SplitSurfaceAngle::Compute(const Standard_Boolean /*Segment*/)
 {
   Handle(Geom_Surface) S;
-  Standard_Real U1,U2;
+  Standard_Real U1 = 0.,U2 = 0.;
   Standard_Boolean isRect = Standard_False;
   if(mySurface->IsKind(STANDARD_TYPE(Geom_RectangularTrimmedSurface))){
     Handle(Geom_RectangularTrimmedSurface) rts = 
index bf55c99dd2fa04d5891042e97729ea9127c1f513..21ccfe323f156bea907a3f51b76e9b1b817de702 100755 (executable)
@@ -408,7 +408,7 @@ void ShapeUpgrade_WireDivide::Perform ()
 
       //collect NM vertices
      
-      Standard_Real af,al;
+      Standard_Real af = 0.,al = 0.;
       Handle(Geom_Curve) c3d;
       Adaptor3d_CurveOnSurface AdCS;
       if(myEdgeDivide->HasCurve3d()) 
index fbdd70ec7cebe9a32c81a14d59eafbbe7b126df4..8060becdfafbedb4e189c08b884f59604e34f2d6 100755 (executable)
@@ -252,11 +252,9 @@ const TopTools_IndexedDataMapOfShapeListOfShape& TNaming_Localizer::Ancestors
   TopTools_IndexedDataMapOfShapeListOfShape emptyAnc;
   myShapeWithAncestors.Prepend(In);
   myAncestors         .Prepend(emptyAnc);
-#ifdef DEB
-  TopAbs_ShapeEnum TA;
-#else
+
   TopAbs_ShapeEnum TA=TopAbs_COMPOUND;
-#endif
+
   if (TS == TopAbs_VERTEX)      TA = TopAbs_EDGE;
   else if (TS == TopAbs_EDGE)   TA = TopAbs_FACE;
   else if (TS == TopAbs_FACE)   TA = TopAbs_SOLID;
@@ -557,11 +555,8 @@ void TNaming_Localizer::FindNeighbourg (const TopoDS_Shape&      Sol,
                                        TopTools_MapOfShape&     Neighbourg)
 {  
   TopAbs_ShapeEnum       TA = S.ShapeType();
-#ifdef DEB
-  TopAbs_ShapeEnum       TS;
-#else
   TopAbs_ShapeEnum       TS=TopAbs_COMPOUND;
-#endif
+
   if (TA == TopAbs_FACE) TS = TopAbs_EDGE;
   if (TA == TopAbs_EDGE) TS = TopAbs_VERTEX;
   if (TA == TopAbs_VERTEX) TS = TopAbs_VERTEX; // szy 30.03.10
index 89e43f3b10c74325d62da2bcfa81925ed2681f79..0f0c3313d28898c8a3dd6f3a21611cd9bf851dd0 100755 (executable)
@@ -842,11 +842,8 @@ void AddShapeKI
   // to sort, it is considered that : 
   // POINT == VERTEX,CURVE == EDGE,SURFACE == FACE
   
-#ifdef DEB
-  TopAbs_ShapeEnum SKtri;
-#else
   TopAbs_ShapeEnum SKtri=TopAbs_COMPOUND;
-#endif
+
   if (isshape) SKtri = TopOpeBRepDS::KindToShape(K);
   else if (isgeome) {
     if      (K == TopOpeBRepDS_POINT) SKtri = TopAbs_VERTEX; 
index a60589dfef821c10c0a5c61c3843a261245cbb0a..4f99de7ce1c362ced4ead65afef16b1affc603b6 100755 (executable)
@@ -82,11 +82,9 @@ void TopClass_Classifier2d::Compare(const TheEdge& E,
 
   // find the closest point
   Standard_Integer iPoint, iSegment, nbPoints, nbSegments;
-#ifndef DEB
+
   const IntRes2d_IntersectionPoint *PClosest = NULL;
-#else 
-  const IntRes2d_IntersectionPoint *PClosest;
-#endif
+
   Standard_Real dMin = RealLast();
   nbPoints = myIntersector.NbPoints();
   for (iPoint = 1; iPoint <= nbPoints;  iPoint++)  {
@@ -165,11 +163,9 @@ void TopClass_Classifier2d::Compare(const TheEdge& E,
 //  Modified by skv - Wed Jul 12 15:20:58 2006 OCC12627 End
   
   // transition on the segment
-#ifndef DEB
+
   TopAbs_Orientation SegTrans = TopAbs_FORWARD;
-#else
-  TopAbs_Orientation SegTrans;
-#endif
+
   const IntRes2d_Transition& T1 = PClosest->TransitionOfFirst();
   switch (T1.TransitionType()) {
   case IntRes2d_In :
@@ -234,14 +230,3 @@ void TopClass_Classifier2d::Compare(const TheEdge& E,
     myState = myTrans.StateBefore();
   }
 }
-
-
-
-
-
-
-
-
-
-
-
index d6b285605f381a24cd4c900a61e037830353129b..ad6285d4b5f0a9bb33bdaaf8f498f41fee9e7645 100755 (executable)
@@ -68,7 +68,7 @@ void TopClass_FaceClassifier::Perform(TheFaceExplorer& Fexp,
   TopAbs_Orientation         anEdgeOri;
   Standard_Integer           aClosestInd;
   IntRes2d_IntersectionPoint aPInter;
-  TopAbs_State               aState;
+  TopAbs_State               aState = TopAbs_UNKNOWN;
   Standard_Boolean           IsWReject;
   Standard_Boolean           IsEReject;
 
index 449569c570f96177df9d0d23add3645887b1a5e9..65605664705388985f59a109d8fcf3c1b85281e0 100755 (executable)
@@ -198,11 +198,9 @@ void TopOpeBRep_EdgesFiller::Insert(const TopoDS_Shape& E1,const TopoDS_Shape& E
            Handle(TopOpeBRepDS_CurvePointInterference) epi = Handle(TopOpeBRepDS_CurvePointInterference)::DownCast(I);
            const TopOpeBRepDS_Transition& tevi = epi->Transition();
            Standard_Integer sevi = epi->Support();
-#ifdef DEB
-           Standard_Integer gevi;
-#else
+
            Standard_Integer gevi=0;
-#endif
+
            if      (isvertex1) gevi = myPDS->AddShape(V1,1);
            else if (isvertex2) gevi = myPDS->AddShape(V2,2);
            Standard_Boolean bevi = Standard_False;
index 7019cc17c4c804a1a5e1827b67000c2c92d60f86..957947c047f9d05ceca901bb60d48497dd7c7a7e 100755 (executable)
@@ -159,12 +159,8 @@ TopOpeBRepDS_Transition TopOpeBRep_EdgesIntersector::Transition1(const Standard_
   Standard_Boolean pointofsegment = IsPointOfSegment1();
   Standard_Boolean pur1d = (pointofsegment && mySameDomain);
 
-#ifdef DEB
-  TopAbs_State staB,staA; TopAbs_ShapeEnum shaB,shaA; Standard_Boolean pextremity; 
-#else
   TopAbs_State staB=TopAbs_UNKNOWN,staA=TopAbs_UNKNOWN;
   TopAbs_ShapeEnum shaB=TopAbs_COMPOUND,shaA=TopAbs_COMPOUND; Standard_Boolean pextremity; 
-#endif
   
   TopAbs_State staINON = TopAbs_IN;
   Standard_Integer dim = myDimension;
index 8a78386667aeb396d67e46b759738ee753a78911..be06fd46b289cc6d011a805a57435283c1632484 100755 (executable)
@@ -296,7 +296,7 @@ void TopOpeBRep_FFDumper::DumpDSP(const TopOpeBRep_VPointInter& VP,const TopOpeB
   cout<<" "<<G;
   
   const Handle(TopOpeBRepDS_HDataStructure)& HDS = myPFF->HDataStructure();
-  Standard_Real tol;
+  Standard_Real tol = Precision::Confusion();
   if      (GK == TopOpeBRepDS_VERTEX) tol = BRep_Tool::Tolerance(TopoDS::Vertex(HDS->Shape(G)));
   else if (GK == TopOpeBRepDS_POINT)  tol = HDS->Point(G).Tolerance();
   cout<<" tol = "<<tol;
index 0063202dfbaf80739ad730748cb4904b7d37c45f..6de5d42a536498305c444ee63ecbf13563953005 100755 (executable)
@@ -218,11 +218,8 @@ TopOpeBRepDS_Transition TopOpeBRep_FFTransitionTool::ProcessFaceTransition
   }
   else {
     Standard_Boolean Odefined = Standard_True;
-#ifdef DEB
-    TopAbs_Orientation O;
-#else
+
     TopAbs_Orientation O = TopAbs_FORWARD;
-#endif
 
     IntSurf_TypeTrans trans;
     trans = (Index == 1) ? L.TransitionOnS1() : L.TransitionOnS2();
@@ -385,7 +382,7 @@ TopOpeBRepDS_Transition TopOpeBRep_FFTransitionTool::ProcessEdgeONTransition
  TopAbs_Orientation oriE = E.Orientation();
  
  const Handle(Geom_Surface)& S = BRep_Tool::Surface(F);
- Standard_Real U,V;
+ Standard_Real U = 0.,V = 0.;
  if      (ShapeIndex == 1) VP.ParametersOnS1(U,V);
  else if (ShapeIndex == 2) VP.ParametersOnS2(U,V);
  
index 381a433fa1626c0592711c23b5c346366fa2d39b..f4df2ed5ea2c90926985e09f79794936403c87b7 100755 (executable)
@@ -309,11 +309,7 @@ Standard_Integer TopOpeBRep_FaceEdgeFiller::MakeGeometry
     (TopOpeBRep_FaceEdgeIntersector& FEINT,
      TopOpeBRepDS_DataStructure& BDS) const
 {
-#ifdef DEB
-  Standard_Integer G;
-#else
   Standard_Integer G=0;
-#endif
 
   TopoDS_Vertex V1;
   Standard_Boolean isvertexF = FEINT.IsVertex(1,V1);
index cc3ff5ad8cf41727e2c6dd279e0da57e880074fc..4cef11b69ff521a71c574b8df6d7d6feee2a9bbf 100755 (executable)
@@ -343,7 +343,7 @@ static Standard_Boolean FUN_findTOOF(const TopOpeBRepDS_PDataStructure pDS,
     if (!ok1) return Standard_False;
     Standard_Real f,l; FUN_tool_bounds(OOE,f,l);
     
-    TopAbs_State stb,sta;
+    TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN;
     TopOpeBRepTool_makeTransition MKT; 
     OOdone = MKT.Initialize(OOE,f,l,oopar,F,uv,factor);
     if (OOdone) OOdone = MKT.SetRest(E,paronE);
index 6371df6f3d6f947e36e5b12b94190482a0acf674..22981b763380012e8b1b2ec38ed520bb0ef99e9b 100755 (executable)
@@ -244,11 +244,8 @@ void TopOpeBRep_VPointInter::UpdateKeep()
 
   Standard_Integer SI = ShapeIndex();
 
-#ifdef DEB
-  Standard_Boolean condition; 
-#else
   Standard_Boolean condition=Standard_False; 
-#endif
+
   if      (SI == 1) condition = M_SINON(pos2);
   else if (SI == 2) condition = M_SINON(pos1);
   else if (SI == 0) condition = M_SINON(pos1) && M_SINON(pos2);
index 2e7dcc59e003e8c8c47b47d31f3a4707334104cc..d999323c3b39f687431b0e4d3585686676b2a963 100755 (executable)
@@ -114,7 +114,7 @@ static Standard_Boolean FUNBREP_SameUV(const TopOpeBRep_VPointInter& VP1,
                          const Standard_Integer sind,const Standard_Real toluv)
 //-----------------------------------------------------------------------
 {
-  Standard_Real u1,v1,u2,v2;
+  Standard_Real u1 = 0.,v1 = 0.,u2 = 0.,v2 = 0.;
   if (sind == 1) {
     VP1.ParametersOnS1(u1,v1); VP2.ParametersOnS1(u2,v2);
   }
index d362fa5536973dc190bf7d0d08bde5a76eb6fa54..32ac5879fe4ce9edb5274e376594f69d73ccc2a4 100755 (executable)
@@ -88,11 +88,8 @@ void BREP_mergePDS(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
       //**!
       const TopOpeBRepDS_Point& PDS = BDS.Point(GI);
 
-#ifdef DEB      
-      Standard_Integer ivp1; TopoDS_Shape v1; Standard_Boolean newv1 = Standard_False; TopOpeBRepDS_Kind k1; Standard_Integer iv1 = 0;
-#else
       Standard_Integer ivp1; TopoDS_Shape v1; Standard_Boolean newv1 = Standard_False; TopOpeBRepDS_Kind k1=TopOpeBRepDS_UNKNOWN; Standard_Integer iv1 = 0;
-#endif
+
       ivp1 = BREP_findPDSamongIDMOVP(PDS,Mvp1);
       if (ivp1) {
        v1 = Mvp1.FindKey(ivp1);
@@ -101,11 +98,9 @@ void BREP_mergePDS(const Handle(TopOpeBRepDS_HDataStructure)& HDS)
        k1 = TopOpeBRepDS_VERTEX;
       }
       
-#ifdef DEB      
-      Standard_Integer ivp2; TopoDS_Shape v2; Standard_Boolean newv2 = Standard_False; TopOpeBRepDS_Kind k2; Standard_Integer iv2 = 0;
-#else
+
       Standard_Integer ivp2; TopoDS_Shape v2; Standard_Boolean newv2 = Standard_False; TopOpeBRepDS_Kind k2=TopOpeBRepDS_UNKNOWN; Standard_Integer iv2 = 0;
-#endif
+
       ivp2 = BREP_findPDSamongIDMOVP(PDS,Mvp2);
       if (ivp2) {
        v2 = Mvp2.FindKey(ivp2);
index a97f9d2f5864612efc9385fca630d72674e5a57c..77e709366d74e02d63e34d4365b97e4e95eea97d 100755 (executable)
@@ -96,11 +96,9 @@ TopOpeBRepDS_Transition TopOpeBRep_FacesFiller::GetEdgeTrans(const TopOpeBRep_VP
   Standard_Real paredge = VP.EdgeParameter(ShapeIndex);
 
   TopoDS_Edge OOedge;
-#ifdef DEB
-  Standard_Real OOparedge;
-#else
-  Standard_Real OOparedge=0;
-#endif
+
+  Standard_Real OOparedge = 0.;
+
   Standard_Boolean hasONedge = (VP.State(OOShapeIndex) == TopAbs_ON);
   Standard_Boolean hasOOedge = (on2edges) ? Standard_True : hasONedge;
   if ( hasOOedge ) {
index f22c633f028b2204a3ba19fe5c0a264fce62dcc6..f90f3d392d182afd8e57c202b6e83b05b3e33edb 100755 (executable)
@@ -1029,7 +1029,7 @@ static Standard_Integer FUN_putInterfonDegenEd
   }
 
   Standard_Boolean setrest = Standard_False;
-  Standard_Integer mkt = 0; Standard_Real par1,par2;
+  Standard_Integer mkt = 0; Standard_Real par1 = 0.,par2 = 0.;
   if (on3) {
     TopoDS_Edge ei = (rki == 1) ? TopoDS::Edge(VP.ArcOnS1()) : TopoDS::Edge(VP.ArcOnS2());
     Standard_Real pari = (rki == 1) ? VP.ParameterOnArc1() : VP.ParameterOnArc2();
index f689e7224df291e3536bbcd891063f9097a093ec..ccea83475c11a7faefe3f3614860a69d9493c663 100755 (executable)
@@ -493,11 +493,7 @@ Standard_Boolean TopOpeBRepBuild_Builder::Reverse(const TopAbs_State ToBuild1,co
 //=======================================================================
 TopAbs_Orientation TopOpeBRepBuild_Builder::Orient(const TopAbs_Orientation Ori,const Standard_Boolean Reverse)
 {
-#ifdef DEB
-  TopAbs_Orientation result;
-#else
   TopAbs_Orientation result=TopAbs_FORWARD;
-#endif
   switch (Reverse) {
     case Standard_True  : result = TopAbs::Complement(Ori); break;
     case Standard_False : result = Ori; break;
index 2f95c8cf537d94bd28d5822589ec725ed096505c..ee7b00cab9bb9e980b1432482e7ecd4a1e3fca47 100755 (executable)
@@ -482,7 +482,7 @@ void TopOpeBRepBuild_BuilderON::GFillONPartsWES2(const Handle(TopOpeBRepDS_Inter
   // FRA11018 (FOR=f5,EG=e18,EsdEG=e7)           
   Standard_Boolean espONesd = Standard_False; Standard_Integer Iesd=0;// xpu150698
   if (eghassd) espONesd = FUN_ds_ONesd(BDS,GI,EspON,Iesd);// xpu150698 
-  Standard_Boolean eONsoEsd;
+  Standard_Boolean eONsoEsd = Standard_False;
   if (eghassd && (Iesd != 0)) {     
     const TopoDS_Edge& Esd = TopoDS::Edge(BDS.Shape(Iesd));
     Standard_Boolean ok = FUN_tool_curvesSO(eON,Esd,eONsoEsd);
@@ -1351,7 +1351,7 @@ void TopOpeBRepBuild_BuilderON::GFillONPartsWES2(const Handle(TopOpeBRepDS_Inter
     if (ComOfCut) {b3d=Standard_True; b2d=Standard_True;} //xpu200598
      
     gp_Vec ngFS,ngFOR;
-    Standard_Real parEG;
+    Standard_Real parEG = 0.;
     // bcl1;bcl2; tsp(f9),tspON(e7)
     Standard_Boolean sdm = FUN_ds_sdm(BDS,BDS.Shape(iFOR),BDS.Shape(iFS));
     Standard_Boolean isfafa = sdm; // such interferences are computed IN fafa case
index e6b1a5891601c34e1cd72ce17761e7663559fcca..bd8de1499082025928691bb307470627ae89388f 100755 (executable)
@@ -195,7 +195,7 @@ void TopOpeBRepBuild_BuilderON::GFillONParts2dWES2(const Handle(TopOpeBRepDS_Int
 #ifdef DEB
     if (tFOR) cout<<"* yap6 = 1"<<endl;
 #endif
-    TopAbs_Orientation neworiE;
+    TopAbs_Orientation neworiE = TopAbs_FORWARD;
     // FF est samedomain avec FCX
     // on evalue la transition de FOR par rapport a la matiere 2d de la face FCX
     // au lieu de la transition par rapport a la matiere 3d de la face FS
@@ -211,7 +211,7 @@ void TopOpeBRepBuild_BuilderON::GFillONParts2dWES2(const Handle(TopOpeBRepDS_Int
     if (!rk1) return;
 
     TopAbs_Orientation oegFOR;
-    Standard_Boolean shareG;
+    Standard_Boolean shareG = Standard_False;
     Standard_Boolean ok = Standard_False;
     if      (EGBoundFCX) 
       ok = FUN_ds_shareG(myPB->DataStructure(),iFOR,iFCX,GI,TopoDS::Edge(EspON),shareG);
index 594f18f6805377c698d55395b9799078891604d7..d1fcb63142afbada6ddc7d120332738dac556632 100755 (executable)
@@ -34,13 +34,9 @@ void TopOpeBRepBuild_Builder::FillShape(const TopoDS_Shape& S1,
                                        const Standard_Boolean In_RevOri)
 {
   Standard_Boolean RevOri = In_RevOri;
-
   TopAbs_ShapeEnum t = S1.ShapeType();
-#ifdef DEB
-  TopAbs_ShapeEnum t1,t11;
-#else
   TopAbs_ShapeEnum t1=TopAbs_COMPOUND,t11=TopAbs_COMPOUND;
-#endif
+
   if      (t == TopAbs_FACE )  { 
     t1 = TopAbs_WIRE;
     t11 = TopAbs_EDGE;
index bed95e8cbde4a0fe0476d1f40684f71448d2205c..7d76bf52ea10d0908945f627e17d22f783fda1e2 100755 (executable)
@@ -209,11 +209,9 @@ void TopOpeBRepBuild_Builder::MergeShapes(const TopoDS_Shape& S1,const TopAbs_St
   // NYI : SplitCompound appele par SplitShape
   
   TopOpeBRepTool_ShapeExplorer ex1;
-#ifdef DEB
-  TopAbs_ShapeEnum t1,tex1;
-#else
+
   TopAbs_ShapeEnum t1=TopAbs_COMPOUND,tex1=TopAbs_COMPOUND;
-#endif
+
   if ( ! S1null ) {
     t1 = tex1 = TopType(S1);
     if ( t1 == TopAbs_COMPOUND ) {
@@ -236,11 +234,9 @@ void TopOpeBRepBuild_Builder::MergeShapes(const TopoDS_Shape& S1,const TopAbs_St
   }
   
   TopOpeBRepTool_ShapeExplorer ex2;
-#ifdef DEB
-  TopAbs_ShapeEnum t2,tex2;
-#else
+
   TopAbs_ShapeEnum t2=TopAbs_COMPOUND,tex2=TopAbs_COMPOUND;
-#endif
+
   if ( ! S2null ) {
     t2 = tex2 = TopType(S2);
     if ( t2 == TopAbs_COMPOUND ) {
index b5613eeed098a45ecd073702a2b1f4163206e274..9cb3e64f90dea34bc989e8b25b417ce7fe06d64e 100755 (executable)
@@ -884,7 +884,7 @@ void TopOpeBRepDS_BuildTool::ComputePCurves
   Handle(Geom2d_Curve) PC2new;
   
   if(C3D.IsNull()) {
-    Standard_Real tolreached2d1, tolreached2d2, r1, r2, tol=0;
+    Standard_Real tolreached2d1 = Precision::Confusion(), tolreached2d2 = Precision::Confusion(), r1, r2, tol=Precision::Confusion();
     if (comppc1) PC1new = myCurveTool.MakePCurveOnFace(F1,C3D,tolreached2d1);
     if (comppc2) PC2new = myCurveTool.MakePCurveOnFace(F2,C3D,tolreached2d2);
     
@@ -1152,11 +1152,9 @@ void  TopOpeBRepDS_BuildTool::Parameter(const TopoDS_Shape& E,
   Handle(Geom_Curve) C = BRep_Tool::Curve(e,loc,f,l);
   if ( !C.IsNull() && C->IsPeriodic()) {
     Standard_Real per = C->Period();
-#ifdef DEB
-    TopAbs_Orientation oV;
-#else
+
     TopAbs_Orientation oV=TopAbs_FORWARD;
-#endif
+
     TopExp_Explorer exV(e,TopAbs_VERTEX);
     for (; exV.More(); exV.Next()) {
       const TopoDS_Vertex& vofe = TopoDS::Vertex(exV.Current());
index b9174897022ace742a462acc8b3b88d567a867db..0600d503ad05f01cf7959ce6e9765143fcf5fc6f 100755 (executable)
@@ -223,11 +223,9 @@ Standard_Boolean TopOpeBRepDS_Check::CheckDS(const Standard_Integer I,
     return Standard_False;
   }
   const TopoDS_Shape& S =myHDS->Shape(I);
-#ifdef DEB
-  TopAbs_ShapeEnum se;
-#else
+
   TopAbs_ShapeEnum se=TopAbs_COMPOUND;
-#endif
+
   switch (K) {
   case TopOpeBRepDS_SOLID  : se = TopAbs_SOLID; break;
   case TopOpeBRepDS_SHELL  : se = TopAbs_SHELL; break;
index af0afce40479872fc98312ba223f40880faad30d..02e6a33dde6173abab37d87e98ed22302694ffc2 100755 (executable)
@@ -196,7 +196,7 @@ Standard_OStream& TopOpeBRepDS_Dumper::Print(const Handle(Geom_BSplineCurve)&
                                              )
 {
 #ifdef DEB
-  Standard_Integer i,l,lb,n;
+  Standard_Integer i,l,lb = 0,n;
   
   Standard_Integer degree   = B->Degree();
   Standard_Integer nbpoles  = B->NbPoles();
index 684f16effc3b47b78dbad6aa8f122ceb42fe3009..7747fd654bbe41481a34aeabd6945b98ce029cc3 100755 (executable)
@@ -938,7 +938,7 @@ Standard_EXPORT void FUN_ds_completeforSE2(const Handle(TopOpeBRepDS_HDataStruct
                        BDS.ShapeInterferences(SE),par1,par2,isonper);
 
        TopOpeBRepTool_makeTransition MKT; 
-       TopAbs_State stb,sta
+       TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
        ok = MKT.Initialize(SE,par1,par2,par, FCX,OOuv, factor);
        if (ok) ok = MKT.SetRest(ES,OOpar);
        if (ok) ok = MKT.MkTonE(stb,sta);
@@ -1015,7 +1015,7 @@ static Standard_Boolean FUN_ds_completeforSE3(const TopOpeBRepDS_DataStructure&
   Standard_Real factor = 1.e-4;
 
 
-  TopOpeBRepTool_makeTransition MKT; TopAbs_State stb,sta
+  TopOpeBRepTool_makeTransition MKT; TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
   ok = MKT.Initialize(SE,par1,par2,parE, F,uv, factor);
   if (ok) ok = MKT.SetRest(Eline,parline);
   if (ok) ok = MKT.MkTonE(stb,sta);
@@ -1836,7 +1836,7 @@ Standard_EXPORT void FUN_ds_completeforE7(const Handle(TopOpeBRepDS_HDataStructu
          gp_Pnt2d uvFS; Standard_Boolean ok = FUN_tool_parF(E,par,FS,uvFS);
          if (!ok) {FUN_Raise(); continue;}
          
-         TopOpeBRepTool_makeTransition MKT; TopAbs_State stb,sta
+         TopOpeBRepTool_makeTransition MKT; TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
          ok = MKT.Initialize(E,par1,par2,par, FS,uvFS, factor);
          if (ok) ok = MKT.MkTonE(stb,sta);
          if (!ok) {FUN_Raise(); continue;}  
@@ -1850,7 +1850,7 @@ Standard_EXPORT void FUN_ds_completeforE7(const Handle(TopOpeBRepDS_HDataStructu
          gp_Pnt2d uvFS; ok = FUN_tool_paronEF(ES,parES,FS,uvFS);
          if (!ok) {FUN_Raise(); continue;}
 
-         TopOpeBRepTool_makeTransition MKT; TopAbs_State stb,sta
+         TopOpeBRepTool_makeTransition MKT; TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
          ok = MKT.Initialize(E,par1,par2,par, FS,uvFS, factor);
          if (ok) ok = MKT.SetRest(ES,parES);
          if (ok) ok = MKT.MkTonE(stb,sta);
@@ -2187,7 +2187,7 @@ static Standard_Boolean FUN_redusamshaonE(const TopOpeBRepDS_DataStructure& BDS,
   gp_Pnt2d uv; ok = FUN_tool_paronEF(ES,parES,FTRA,uv);
   if (!ok) return Standard_False;
 
-  Standard_Real factor = 1.e-2; TopAbs_State stb,sta
+  Standard_Real factor = 1.e-2; TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
   TopOpeBRepTool_makeTransition MKT; 
   ok = MKT.Initialize(E,f,l,parE, FTRA,uv, factor);
   if (ok) ok = MKT.SetRest(ES,parES);
index e07a6ee17527a5b453495472e345e568eda98a3b..5e151a7ae71d5273f3231bde1675069bb2aa4c15 100755 (executable)
@@ -328,7 +328,7 @@ Standard_EXPORT void FUN_unkeepEsymetrictransitions
        Standard_Boolean idshape = ::FUN_transitionSHAPEEQUAL(T1,T2);
        Standard_Boolean idstate = ::FUN_transitionSTATEEQUAL(T1,T2);
        Standard_Boolean newV = Standard_True;
-       Standard_Boolean oppostate;
+       Standard_Boolean oppostate = Standard_False;
        
        if (newV) {
          // sym is not precise enough (croix3_3-> OUT/IN; ON/OUT)
index 5673566fb3c48d1139e43108cdb56a8cef9959f2..1ee110b170c332a45f086bd4d65cf7f0a7721d3e 100755 (executable)
@@ -283,11 +283,7 @@ TopAbs_Orientation TopOpeBRepDS_Transition::Orientation(const TopAbs_State S,con
 //=======================================================================
 TopAbs_Orientation TopOpeBRepDS_Transition::OrientationON(const TopAbs_State S,const TopAbs_ShapeEnum ) const // T) const
 {
-#ifdef DEB
-  TopAbs_Orientation result;
-#else
   TopAbs_Orientation result=TopAbs_FORWARD;
-#endif
 
   if      (myStateBefore == TopAbs_ON && myStateAfter == TopAbs_ON) {
 #if 0
index f4b1695b46b994398ceabc299e2afee1e8c6af9b..d4452dc85d0737d7c0802b7b87431121d55eada9 100755 (executable)
@@ -79,7 +79,7 @@ Standard_EXPORT Standard_Boolean FUN_ds_redu2d1d(const TopOpeBRepDS_DataStructur
       if (!ok) return Standard_False;
       
       TopOpeBRepTool_makeTransition MKT;
-      TopAbs_State stb1,sta1
+      TopAbs_State stb1 = TopAbs_UNKNOWN,sta1 = TopAbs_UNKNOWN
       ok = MKT.Initialize(SE,pbef,paft,parSE, F,uv, factor);
       if (ok) ok = MKT.SetRest(E,parE);
       if (ok) ok = MKT.MkTonE(stb1,sta1); 
index 65b16d1f72e7acf33af851951163059044834e94..adc70c9ec91395e7d616c7192e3fdbea09414161 100755 (executable)
@@ -139,7 +139,7 @@ Standard_EXPORT void FDS_repvg2
          gp_Pnt2d uv; ok = FUN_tool_paronEF(E,pE,F1,uv); if (!ok) {it2.Next();continue;}
          Standard_Real factor = 0.789;
          TopOpeBRepTool_makeTransition MKT; 
-         TopAbs_State stb,sta
+         TopAbs_State stb = TopAbs_UNKNOWN,sta = TopAbs_UNKNOWN
          ok = MKT.Initialize(E,pbef,paft,pE, F1,uv, factor);
          if (ok) ok = MKT.SetRest(E1,pE1);
          if (ok) ok = MKT.MkTonE(stb,sta);
index 65fc721d17e7034702645f41089d7862df8e6d51..e81439c23cf802ef2f7e5f1f893689084d72ba35 100755 (executable)
@@ -72,7 +72,7 @@ void TopOpeBRepTool_STATE::Set(const Standard_Boolean b,
 
 Standard_Boolean TopOpeBRepTool_STATE::Get(const TopAbs_State S)
 {
-  Standard_Boolean b;
+  Standard_Boolean b = Standard_False;
   switch(S) {
   case TopAbs_IN : b = myin; break;
   case TopAbs_OUT : b = myout; break;
index 2f0bc35ddf78e7fc1ac10f4ed195c44cc70071a0..33f19019a6a8908883e7d02d97530a966b2ad186 100755 (executable)
@@ -1177,11 +1177,9 @@ Standard_EXPORT void FUN_ds_Parameter(const TopoDS_Shape& E,const TopoDS_Shape&
   Handle(Geom_Curve) C = BRep_Tool::Curve(e,loc,f,l);
   if ( !C.IsNull() && C->IsPeriodic()) {
     Standard_Real per = C->Period();
-#ifdef DEB
-    TopAbs_Orientation oV;
-#else
+
     TopAbs_Orientation oV=TopAbs_FORWARD;
-#endif
+
     TopExp_Explorer exV(e,TopAbs_VERTEX);
     for (; exV.More(); exV.Next()) {
       const TopoDS_Vertex& vofe = TopoDS::Vertex(exV.Current());
index d3bef1ac0eb82f5808d9c1291f6a69152923eeef..a43f8d18b20523402c9205db245f3f5aebf32f8d 100755 (executable)
@@ -140,8 +140,8 @@ Graphic3d_Vector Vec ;
 
 void V3d::ArrowOfRadius(const Handle(Graphic3d_Group)& garrow,const Standard_Real X0,const Standard_Real Y0,const Standard_Real Z0,const Standard_Real Dx,const Standard_Real Dy,const Standard_Real Dz,const Standard_Real Alpha,const Standard_Real Lng)
 {
-  Standard_Real Xc,Yc,Zc,Xi,Yi,Zi,Xj,Yj,Zj;
-  Standard_Real Xn,Yn,Zn,X,Y,Z,X1,Y1,Z1,Norme;
+  Standard_Real Xc, Yc, Zc, Xi, Yi, Zi, Xj, Yj, Zj;
+  Standard_Real Xn, Yn, Zn, X, Y, Z, X1 = 0., Y1 = 0., Z1 = 0., Norme;
   const Standard_Integer NbPoints = 10;
 
 //      Centre du cercle base de la fleche :
@@ -262,7 +262,7 @@ void V3d::DrawSphere(const Handle(V3d_Viewer)& aViewer,const Quantity_Length ray
 
   const Standard_Real Dbeta = 2. * M_PI / NFACES;
   const Standard_Real Dalpha = 2. * M_PI / NFACES;
-  Standard_ShortReal X,Y,Z,X0,Y0,Z0;
+  Standard_ShortReal X,Y,Z,X0 = 0.,Y0 = 0.,Z0 = 0.;
   Standard_Real R, Alpha, Beta = 0.;
   Standard_Integer i,j ;
   for( j=0; j<NFACES/2 ; j++, Beta += Dbeta ) {
index 90638695b0bc83871200183531db8c147ffba371..ae1675a820377e6e158ad6574a71aeac900ac5ee 100755 (executable)
@@ -590,8 +590,8 @@ static int visos (Draw_Interpretor& di, Standard_Integer argc, const char** argv
 
   Standard_Integer aLastInd = argc - 1;
   Standard_Boolean isChanged = Standard_False;
-  Standard_Integer aNbUIsos;
-  Standard_Integer aNbVIsos;
+  Standard_Integer aNbUIsos = 0;
+  Standard_Integer aNbVIsos = 0;
 
   if (aLastInd >= 3) {
     Standard_Boolean isIsoOnPlane = Standard_False;
index 1c808eac256148fb9e76329230e6b4814274b8ad..444a365c7a97c3ebb88b77aba69d9f159761cc0c 100755 (executable)
@@ -312,11 +312,8 @@ static int VSize (Draw_Interpretor& di, Standard_Integer argc, const char** argv
   Standard_Boolean             ThereIsCurrent;
   Standard_Real                value;
   Standard_Boolean             hascol;
-#ifdef DEB
-  Quantity_NameOfColor         col;
-#else
+
   Quantity_NameOfColor         col = Quantity_NOC_BLACK ;
-#endif
 
   // Verification des arguments
   if ( argc>3 ) {di<<argv[0]<<" Syntaxe error"<<"\n"; return 1;}
@@ -3522,7 +3519,7 @@ static Standard_Integer VConnect(Draw_Interpretor& /*di*/,
   TCollection_AsciiString aName (argv[anArgIter++]);
   Handle(AIS_InteractiveObject) anOriginObject;
   TCollection_AsciiString aColorString (argv[argc-1]);
-  Standard_CString aColorName;
+  Standard_CString aColorName = "";
   Standard_Boolean hasColor = Standard_False;
   if (aColorString.Search ("color=") != -1)
   {
@@ -3702,7 +3699,7 @@ static Standard_Integer VConnectShape(Draw_Interpretor& /*di*/,
   TCollection_AsciiString aName (argv[anArgIter++]);
   Handle(AIS_InteractiveObject) anOriginShape;
   TCollection_AsciiString aColorString(argv[argc-1]);
-  Standard_CString aColorName;
+  Standard_CString aColorName = "";
   Standard_Boolean hasColor = Standard_False;
   if (aColorString.Search ("color=") != -1)
   {
index 250ced8955abb0115cd9ff5192f388ee754127cf..eacdc3d484864380fc0b473b0c3c6b9f43fb136c 100755 (executable)
@@ -2502,26 +2502,20 @@ static int VSetBgMode(Draw_Interpretor& di, Standard_Integer argc, const char**
     di << "use 'vinit' command before " << argv[0] << "\n";
     return 1;
   }
-
-  Aspect_FillMethod aFillType;
-  if (argc == 2)
+  Aspect_FillMethod aFillType = Aspect_FM_NONE;
+  const char* szType = argv[1];
+  if      (strcmp(szType, "NONE"    ) == 0) aFillType = Aspect_FM_NONE;
+  else if (strcmp(szType, "CENTERED") == 0) aFillType = Aspect_FM_CENTERED;
+  else if (strcmp(szType, "TILED"   ) == 0) aFillType = Aspect_FM_TILED;
+  else if (strcmp(szType, "STRETCH" ) == 0) aFillType = Aspect_FM_STRETCH;
+  else
   {
-    const char* szType = argv[1];
-    if      (strcmp(szType, "NONE"    ) == 0) aFillType = Aspect_FM_NONE;
-    else if (strcmp(szType, "CENTERED") == 0) aFillType = Aspect_FM_CENTERED;
-    else if (strcmp(szType, "TILED"   ) == 0) aFillType = Aspect_FM_TILED;
-    else if (strcmp(szType, "STRETCH" ) == 0) aFillType = Aspect_FM_STRETCH;
-    else
-    {
-      di << "Wrong fill type : " << szType << "\n";
-      di << "Must be one of CENTERED, TILED, STRETCH, NONE" << "\n";
-      return 1;
-    }
+    di << "Wrong fill type : " << szType << "\n";
+    di << "Must be one of CENTERED, TILED, STRETCH, NONE" << "\n";
+    return 1;
   }
-
   Handle(V3d_View) V3dView = ViewerTest::CurrentView();
   V3dView->SetBgImageStyle(aFillType, Standard_True);
-
   return 0;
 }
 
@@ -4267,7 +4261,7 @@ static Standard_Integer VZClipping (Draw_Interpretor& di,
     return 1;
   }
   Handle(V3d_View) aView = ViewerTest::CurrentView();
-  V3d_TypeOfZclipping aZClippingMode;
+  V3d_TypeOfZclipping aZClippingMode = V3d_OFF;
   if(argc==1)
   {
     TCollection_AsciiString aZClippingModeString;
index 3a75172b1b2fd64532f3ec20bf4c1fbbf74de9d0..75703253831ebcb896c93716f7346ea212764c01 100755 (executable)
@@ -753,10 +753,10 @@ CALL_DEF_LIGHT *lights=NULL;
 
 Standard_Real X, Y, Z;
 
-Standard_Real LightConcentration;
-Standard_Real LightAttenuation1;
-Standard_Real LightAttenuation2;
-Standard_Real LightAngle;
+Standard_Real LightConcentration = 0.;
+Standard_Real LightAttenuation1 = 0.;
+Standard_Real LightAttenuation2 = 0.;
+Standard_Real LightAngle = 0.;
 Quantity_Color LightColor;
 Graphic3d_Vertex LightPosition;
 Graphic3d_Vector LightDirection;
index 56819362728602c062fca754cdf4d76b38f32686..5b109384fb75c4ed4ae53d9d33e72f2c702d9b27 100755 (executable)
@@ -190,7 +190,7 @@ VrmlData_ErrorStatus VrmlData_Material::Read (VrmlData_InBuffer& theBuffer)
 
 VrmlData_ErrorStatus VrmlData_Material::Write (const char * thePrefix) const
 {
-  VrmlData_ErrorStatus aStatus;
+  VrmlData_ErrorStatus aStatus = VrmlData_StatusOK;
   const VrmlData_Scene& aScene = Scene();
   static char header[] = "Material {";
   if (aScene.IsDummyWrite() == Standard_False &&
index 1cc491cbb1f28f5ad2d08cc9d50d34a02919fdbf..e4997eac063997143c1f9cbb6c94f0082a825813 100755 (executable)
@@ -446,7 +446,7 @@ Standard_Boolean VrmlData_ShapeNode::IsDefault () const
 
 VrmlData_ErrorStatus VrmlData_UnknownNode::Read (VrmlData_InBuffer& theBuffer)
 {
-  VrmlData_ErrorStatus aStatus;
+  VrmlData_ErrorStatus aStatus = VrmlData_StatusOK;
   Standard_Integer aLevelCounter (0);
   // This loop searches for any opening brace.
   // Such brace increments the level counter. A closing brace decrements
index 25e4400de809f6232e8bce29ec399badaea9c2cc..6105142c44078e875643b9f2fd6d53dbfd456e41 100755 (executable)
@@ -701,7 +701,7 @@ VrmlData_ErrorStatus VrmlData_Scene::ReadXYZ
                                  Standard_Boolean       isOnlyPos) const
 {
   Standard_Real aVal[3] = {0., 0., 0.};
-  VrmlData_ErrorStatus aStatus;
+  VrmlData_ErrorStatus aStatus = VrmlData_StatusOK;
   for (Standard_Integer i = 0; i < 3; i++) {
     if (!VrmlData_Node::OK(aStatus, VrmlData_Scene::ReadLine(theBuffer)))
       break;
@@ -740,7 +740,7 @@ VrmlData_ErrorStatus VrmlData_Scene::ReadXY
                                  Standard_Boolean       isOnlyPos) const
 {
   Standard_Real aVal[2] = {0., 0.};
-  VrmlData_ErrorStatus aStatus;
+  VrmlData_ErrorStatus aStatus = VrmlData_StatusOK;
   for (Standard_Integer i = 0; i < 2; i++) {
     if (!VrmlData_Node::OK(aStatus, VrmlData_Scene::ReadLine(theBuffer)))
       break;
index 28bca44436200548aec495ddaa4d7051db39c46c..db6a88c8969a691c698f908581bc1cefafb019dc 100755 (executable)
@@ -1127,7 +1127,7 @@ void EHDC :: _ETextOut ( int x, int y, void* str, double angle, BOOL fOutline, B
  int     i;
  DWORD   dwLen;
  HPEN    hpo;
- HBRUSH  hbo;
+ HBRUSH  hbo = NULL;
  HFONT   hfo;
  XFORM   lXfm, rXfm, xfm;
  PXFORM  pXfm;
@@ -1566,7 +1566,7 @@ static void WINAPI _XFORMApplyf ( PFPOINT pp, int n, PXFORM xf ) {
 
 static void WINAPI _RenderPath ( HDC hdc, LPPOINT lpPts, PBYTE lpType, int nPts ) {
 
- LPPOINT pp;
+ LPPOINT pp = NULL;
 
  for ( int i = 0; i < nPts; ++i ) {
 
index 16d2e54cfaf1a4cf62e99dfef404bc6206af1ad8..e577eeb7e18c492bdd6dd6a02da980f24079ea53 100755 (executable)
@@ -791,7 +791,7 @@ void W32_ImageNote :: Play ( BOOL ) {
     int     Ymin    = MIN4( Y1, Y2, Y3, Y4 );
     PINT    line1, line2, line3, line4;
     PPOINT  lines;
-    HBITMAP hbo2, hBmp;
+    HBITMAP hbo2 = NULL, hBmp = NULL;
 
     if ( fScale ) {
 
index fba8546a231fa163e7df4b3f699188af011d9ab7..2963f33ac95427b8844097373101d74af205cf1c 100755 (executable)
@@ -431,7 +431,7 @@ static Standard_Integer brepiges (Draw_Interpretor& di, Standard_Integer n, cons
 
 //  Mode d emploi (K4B ->) : brepiges shape [+shape][ +shape] nomfic
 //   c a d tant qu il y a des + on ajoute ce qui suit
-  const char* nomfic;
+  const char* nomfic = NULL;
   Standard_Integer npris = 0;
 
   Handle(Draw_ProgressIndicator) progress = new Draw_ProgressIndicator ( di, 1 );