mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-05 18:16:23 +03:00
0027549: Visualization, OpenGl_View - drop confusing misnamed methods Width() and Height()
This commit is contained in:
parent
b0fbc5796a
commit
c574faecb9
@ -39,17 +39,17 @@ namespace
|
||||
// =======================================================================
|
||||
void OpenGl_Trihedron::resetTransformations (const Handle(OpenGl_Workspace)& theWorkspace) const
|
||||
{
|
||||
const Handle(OpenGl_Context)& aContext = theWorkspace->GetGlContext();
|
||||
const OpenGl_View* aView = theWorkspace->View();
|
||||
GLdouble anU = 1.0;
|
||||
GLdouble aV = 1.0;
|
||||
if (aView->Height() < aView->Width())
|
||||
const Handle(OpenGl_Context)& aContext = theWorkspace->GetGlContext();
|
||||
const Handle(Graphic3d_Camera)& aCamera = theWorkspace->View()->Camera();
|
||||
double anU = 1.0;
|
||||
double aV = 1.0;
|
||||
if (aCamera->ViewDimensions().X() < aCamera->ViewDimensions().Y())
|
||||
{
|
||||
aV = aView->Width() / aView->Height();
|
||||
aV = aCamera->ViewDimensions().Y() / aCamera->ViewDimensions().X();
|
||||
}
|
||||
else
|
||||
{
|
||||
anU = aView->Height() / aView->Width();
|
||||
anU = aCamera->ViewDimensions().X() / aCamera->ViewDimensions().Y();
|
||||
}
|
||||
|
||||
// Reading the transformation matrices and projection of sight
|
||||
|
@ -425,12 +425,6 @@ public:
|
||||
void SetTextureEnv (const Handle(OpenGl_Context)& theCtx,
|
||||
const Handle(Graphic3d_TextureEnv)& theTexture);
|
||||
|
||||
//! Returns height of view volume.
|
||||
Standard_Real Height () const { return myCamera->ViewDimensions().X(); }
|
||||
|
||||
//! Returns width of view volume.
|
||||
Standard_Real Width () const { return myCamera->ViewDimensions().Y(); }
|
||||
|
||||
void SetBackgroundTextureStyle (const Aspect_FillMethod FillStyle);
|
||||
|
||||
void SetBackgroundGradient (const Quantity_Color& AColor1, const Quantity_Color& AColor2, const Aspect_GradientFillMethod AType);
|
||||
|
Loading…
x
Reference in New Issue
Block a user