From: kgv Date: Tue, 30 Jun 2020 22:12:37 +0000 (+0300) Subject: 0031643: Visualization - Graphic3d_Camera::Copy() raises exception on copying ZNear... X-Git-Tag: V7_5_0_beta~163 X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=commitdiff_plain;h=7e251883e144ef08e4fe487202d5fa96f906c7da 0031643: Visualization - Graphic3d_Camera::Copy() raises exception on copying ZNear < 0.0 Graphic3d_Camera::CopyMappingData() now copies ProjectionType at first. --- diff --git a/src/Graphic3d/Graphic3d_Camera.cxx b/src/Graphic3d/Graphic3d_Camera.cxx index a2abd6a79e..12ef55d2a8 100644 --- a/src/Graphic3d/Graphic3d_Camera.cxx +++ b/src/Graphic3d/Graphic3d_Camera.cxx @@ -139,6 +139,7 @@ Graphic3d_Camera::Graphic3d_Camera (const Handle(Graphic3d_Camera)& theOther) // ======================================================================= void Graphic3d_Camera::CopyMappingData (const Handle(Graphic3d_Camera)& theOtherCamera) { + SetProjectionType (theOtherCamera->ProjectionType()); SetFOVy (theOtherCamera->FOVy()); SetFOV2d (theOtherCamera->FOV2d()); SetZRange (theOtherCamera->ZNear(), theOtherCamera->ZFar()); @@ -146,7 +147,6 @@ void Graphic3d_Camera::CopyMappingData (const Handle(Graphic3d_Camera)& theOther SetScale (theOtherCamera->Scale()); SetZFocus (theOtherCamera->ZFocusType(), theOtherCamera->ZFocus()); SetIOD (theOtherCamera->GetIODType(), theOtherCamera->IOD()); - SetProjectionType (theOtherCamera->ProjectionType()); SetTile (theOtherCamera->myTile); ResetCustomProjection();