1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-05-21 10:55:33 +03:00

0030644: Coding - inline trivial methods of V3d_View class

This commit is contained in:
kgv 2019-04-17 14:58:35 +03:00 committed by bugmaster
parent 2b2be3fb82
commit 1ec17fb48a
2 changed files with 11 additions and 75 deletions

View File

@ -315,24 +315,6 @@ void V3d_View::SetAutoZFitMode (const Standard_Boolean theIsOn,
myAutoZFitIsOn = theIsOn; myAutoZFitIsOn = theIsOn;
} }
// ========================================================================
// function : AutoZFitMode
// purpose :
// ========================================================================
Standard_Boolean V3d_View::AutoZFitMode() const
{
return myAutoZFitIsOn;
}
// ========================================================================
// function : AutoZFitScaleFactor
// purpose :
// ========================================================================
Standard_Real V3d_View::AutoZFitScaleFactor() const
{
return myAutoZFitScaleFactor;
}
//============================================================================= //=============================================================================
//function : AutoZFit //function : AutoZFit
//purpose : //purpose :
@ -1504,18 +1486,6 @@ void V3d_View::DepthFitAll(const Standard_Real Aspect,
ImmediateUpdate(); ImmediateUpdate();
} }
//=============================================================================
//function : WindowFitAll
//purpose :
//=============================================================================
void V3d_View::WindowFitAll(const Standard_Integer Xmin,
const Standard_Integer Ymin,
const Standard_Integer Xmax,
const Standard_Integer Ymax)
{
WindowFit(Xmin,Ymin,Xmax,Ymax);
}
//======================================================================= //=======================================================================
//function : WindowFit //function : WindowFit
//purpose : //purpose :
@ -2098,15 +2068,6 @@ void V3d_View::Eye(Standard_Real& X, Standard_Real& Y, Standard_Real& Z) const
Z = aCameraEye.Z(); Z = aCameraEye.Z();
} }
//=============================================================================
//function : FocalReferencePoint
//purpose :
//=============================================================================
void V3d_View::FocalReferencePoint(Standard_Real& X, Standard_Real& Y,Standard_Real& Z) const
{
Eye (X,Y,Z);
}
//============================================================================= //=============================================================================
//function : ProjReferenceAxe //function : ProjReferenceAxe
//purpose : //purpose :
@ -2245,15 +2206,6 @@ V3d_TypeOfVisualization V3d_View::Visualization() const
return static_cast<V3d_TypeOfVisualization> (myView->VisualizationType()); return static_cast<V3d_TypeOfVisualization> (myView->VisualizationType());
} }
//=============================================================================
//function : Viewer
//purpose :
//=============================================================================
Handle(V3d_Viewer) V3d_View::Viewer() const
{
return MyViewer;
}
//============================================================================= //=============================================================================
//function : IfWindow //function : IfWindow
//purpose : //purpose :
@ -2263,15 +2215,6 @@ Standard_Boolean V3d_View::IfWindow() const
return myView->IsDefined(); return myView->IsDefined();
} }
//=============================================================================
//function : Window
//purpose :
//=============================================================================
Handle(Aspect_Window) V3d_View::Window() const
{
return MyWindow;
}
//============================================================================= //=============================================================================
//function : Type //function : Type
//purpose : //purpose :
@ -2317,15 +2260,6 @@ Standard_Real V3d_View::Focale() const
return aCamera->Distance() * 2.0 * Tan (aCamera->FOVy() * M_PI / 360.0); return aCamera->Distance() * 2.0 * Tan (aCamera->FOVy() * M_PI / 360.0);
} }
//=============================================================================
//function : View
//purpose :
//=============================================================================
Handle(Graphic3d_CView) V3d_View::View() const
{
return myView;
}
//============================================================================= //=============================================================================
//function : screenAxis //function : screenAxis
//purpose : //purpose :

View File

@ -179,10 +179,10 @@ public:
Standard_EXPORT void SetAutoZFitMode (const Standard_Boolean theIsOn, const Standard_Real theScaleFactor = 1.0); Standard_EXPORT void SetAutoZFitMode (const Standard_Boolean theIsOn, const Standard_Real theScaleFactor = 1.0);
//! returns TRUE if automatic z-fit mode is turned on. //! returns TRUE if automatic z-fit mode is turned on.
Standard_EXPORT Standard_Boolean AutoZFitMode() const; Standard_Boolean AutoZFitMode() const { return myAutoZFitIsOn; }
//! returns scale factor parameter of automatic z-fit mode. //! returns scale factor parameter of automatic z-fit mode.
Standard_EXPORT Standard_Real AutoZFitScaleFactor() const; Standard_Real AutoZFitScaleFactor() const { return myAutoZFitScaleFactor; }
//! If automatic z-range fitting is turned on, adjusts Z-min and Z-max //! If automatic z-range fitting is turned on, adjusts Z-min and Z-max
//! projection volume planes with call to ZFitAll. //! projection volume planes with call to ZFitAll.
@ -645,9 +645,8 @@ public:
//! Returns the position of the eye. //! Returns the position of the eye.
Standard_EXPORT void Eye (Standard_Real& X, Standard_Real& Y, Standard_Real& Z) const; Standard_EXPORT void Eye (Standard_Real& X, Standard_Real& Y, Standard_Real& Z) const;
//! Returns the position of point which emanating the //! Returns the position of point which emanating the projections.
//! projections. void FocalReferencePoint (Standard_Real& X, Standard_Real& Y, Standard_Real& Z) const { Eye (X,Y,Z); }
Standard_EXPORT void FocalReferencePoint (Standard_Real& X, Standard_Real& Y, Standard_Real& Z) const;
//! Returns the coordinate of the point (Xpix,Ypix) //! Returns the coordinate of the point (Xpix,Ypix)
//! in the view (XP,YP,ZP), and the projection vector of the //! in the view (XP,YP,ZP), and the projection vector of the
@ -702,13 +701,13 @@ public:
Standard_EXPORT Standard_Integer LightLimit() const; Standard_EXPORT Standard_Integer LightLimit() const;
//! Returns the viewer in which the view has been created. //! Returns the viewer in which the view has been created.
Standard_EXPORT Handle(V3d_Viewer) Viewer() const; Handle(V3d_Viewer) Viewer() const { return MyViewer; }
//! Returns True if MyView is associated with a window . //! Returns True if MyView is associated with a window .
Standard_EXPORT Standard_Boolean IfWindow() const; Standard_EXPORT Standard_Boolean IfWindow() const;
//! Returns the Aspect Window associated with the view. //! Returns the Aspect Window associated with the view.
Standard_EXPORT Handle(Aspect_Window) Window() const; const Handle(Aspect_Window)& Window() const { return MyWindow; }
//! Returns the Type of the View //! Returns the Type of the View
Standard_EXPORT V3d_TypeOfView Type() const; Standard_EXPORT V3d_TypeOfView Type() const;
@ -771,7 +770,7 @@ public:
Standard_EXPORT Standard_Real Focale() const; Standard_EXPORT Standard_Real Focale() const;
//! Returns the associated Graphic3d view. //! Returns the associated Graphic3d view.
Standard_EXPORT Handle(Graphic3d_CView) View() const; const Handle(Graphic3d_CView)& View() const { return myView; }
//! Switches computed HLR mode in the view. //! Switches computed HLR mode in the view.
Standard_EXPORT void SetComputedMode (const Standard_Boolean theMode); Standard_EXPORT void SetComputedMode (const Standard_Boolean theMode);
@ -780,7 +779,10 @@ public:
Standard_EXPORT Standard_Boolean ComputedMode() const; Standard_EXPORT Standard_Boolean ComputedMode() const;
//! idem than WindowFit //! idem than WindowFit
Standard_EXPORT void WindowFitAll (const Standard_Integer Xmin, const Standard_Integer Ymin, const Standard_Integer Xmax, const Standard_Integer Ymax); void WindowFitAll (const Standard_Integer Xmin, const Standard_Integer Ymin, const Standard_Integer Xmax, const Standard_Integer Ymax)
{
WindowFit (Xmin, Ymin, Xmax, Ymax);
}
//! Transform camera eye, center and scale to fit in the passed bounding box specified in WCS. //! Transform camera eye, center and scale to fit in the passed bounding box specified in WCS.
//! @param theCamera [in] the camera //! @param theCamera [in] the camera