From db66a969800b3186fb247ac994b93895ae5f2634 Mon Sep 17 00:00:00 2001 From: ouv Date: Fri, 19 Sep 2014 13:03:31 +0400 Subject: [PATCH] 0002304: Surface grid is destroyed --- src/Plot3d/Plot3d_ViewWindow.cxx | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/Plot3d/Plot3d_ViewWindow.cxx b/src/Plot3d/Plot3d_ViewWindow.cxx index 57561d443..8015fd046 100644 --- a/src/Plot3d/Plot3d_ViewWindow.cxx +++ b/src/Plot3d/Plot3d_ViewWindow.cxx @@ -856,6 +856,13 @@ void Plot3d_ViewWindow::NormalizeSurfaces( const bool theIsRepaint ) aScale[0] = fabs( aDX ) > DBL_EPSILON ? 1.0 / aDX : 1.0; aScale[1] = fabs( aDY ) > DBL_EPSILON ? 1.0 / aDY : 1.0; aScale[2] = fabs( aDZ ) > DBL_EPSILON ? 1.0 / aDZ : 1.0; + + // 0002304: Surface grid is destroyed + static double aMaxLimit = 1e8; // empiric value + aScale[0] = qMin( aScale[0], aMaxLimit ); + aScale[1] = qMin( aScale[1], aMaxLimit ); + aScale[2] = qMin( aScale[2], aMaxLimit ); + SetScale( aScale, false ); if( theIsRepaint ) -- 2.39.2