1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0023947: Eliminate trivial compiler warnings in MSVC++ with warning level 4

Fix first subset of warnings (about 100)
- while(1) and similar constructs replaced by for(;;)
- some uninitialized variables corrected
Got rid of Warning C4189: local variable is initialised but not referenced
Corrected mistakes after getting rid of C4189 compiler warning
Corrected some mistakes that led to compiling errors
Fixed test case because of improvement message - removed unnecessary TODO.
Small fix: tabs have been replaced with whitespaces.
Added TODO for Windows platform
removed last TODO
Corrected mistakes, returned some #ifdef DEB code, fixed test case .
Restoring a few places which have been modified too much
Small grammar fix
Deleted unnecessary puts in bugs/end
This commit is contained in:
omy
2013-07-12 12:37:38 +04:00
parent a8195d65ba
commit 302f96fb0d
189 changed files with 455 additions and 1010 deletions

View File

@@ -1516,7 +1516,6 @@ void V3d_View::SetZSize(const Standard_Real Size)
Standard_Real Front = MyViewContext.ZClippingFrontPlane() ;
Standard_Real Back = MyViewContext.ZClippingBackPlane() ;
Standard_Real focale= Focale();
MyViewMapping.SetFrontPlaneDistance(Zmax) ;
MyViewMapping.SetBackPlaneDistance(-Zmax) ;

View File

@@ -72,10 +72,7 @@ void V3d_View::Move(const Standard_Real Dx, const Standard_Real Dy, const Standa
Zeye = Zrp*Zpn + Dx*XZ + Dy*YZ + Dz*ZZ ;
Zrp = sqrt( Xeye*Xeye + Yeye*Yeye + Zeye*Zeye ) ;
V3d_BadValue_Raise_if( Zrp <= 0. ,"V3d_View::Move:: Eye,At are Confused");
#ifdef DEB
Standard_Real focale =
#endif
Focale();
Prp.SetCoord(Xrp,Yrp,Zrp) ;
MyViewMapping.SetProjectionReferencePoint(Prp) ;
Xpn = Xeye / Zrp ; Ypn = Yeye / Zrp ; Zpn = Zeye / Zrp ;
@@ -84,24 +81,8 @@ void V3d_View::Move(const Standard_Real Dx, const Standard_Real Dy, const Standa
MyView->SetViewOrientation(MyViewOrientation) ;
// Check ZClipping planes
#ifdef IMP020300
MyView->SetViewMapping(MyViewMapping) ;
SetZSize(0.);
#else
Standard_Real Zmax,Xat,Yat,Zat ;
MyViewReferencePoint.Coord(Xat,Yat,Zat) ;
Xeye += Xat ; Yeye += Yat ; Zeye += Zat ;
Zmax = sqrt( Xeye*Xeye + Yeye*Yeye + Zeye*Zeye ) ;
if( Zmax > MyViewMapping.FrontPlaneDistance() &&
MyProjModel == V3d_TPM_SCREEN ) {
SetZSize(2.*Zmax+Zmax*Zmargin) ;
} else {
if( MyType == V3d_PERSPECTIVE ) {
SetFocale(focale) ;
}
MyView->SetViewMapping(MyViewMapping) ;
}
#endif
ImmediateUpdate();
}
@@ -124,10 +105,6 @@ void V3d_View::Move(const Standard_Real Length, const Standard_Boolean Start) {
Zrp = sqrt( Xeye*Xeye + Yeye*Yeye + Zeye*Zeye ) ;
V3d_BadValue_Raise_if( Zrp <= 0. ,"V3d_View::Move:: Eye,At are Confused");
#ifdef DEB
Standard_Real focale =
#endif
Focale();
Prp.SetCoord(Xrp,Yrp,Zrp) ;
MyViewMapping.SetProjectionReferencePoint(Prp) ;
Xpn = Xeye / Zrp ; Ypn = Yeye / Zrp ; Zpn = Zeye / Zrp ;