From: ouv Date: Tue, 11 Oct 2016 13:01:28 +0000 (+0300) Subject: 0004068: Plot3d surfaces are destroyed X-Git-Tag: CTH_2_2_b~4 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=38fb864ee9fdf44a20df356020986677d35dc6b8;p=modules%2Fgui.git 0004068: Plot3d surfaces are destroyed --- diff --git a/src/Plot3d/Plot3d_ViewWindow.cxx b/src/Plot3d/Plot3d_ViewWindow.cxx index 412dd8977..c87bb3599 100644 --- a/src/Plot3d/Plot3d_ViewWindow.cxx +++ b/src/Plot3d/Plot3d_ViewWindow.cxx @@ -959,8 +959,12 @@ void Plot3d_ViewWindow::NormalizeSurfaces( const bool theIsRepaint ) // 1) decrease all the values using a scale factor for WarpScalar filter (Plot3d_Actor::Build()) // 2) reset the Z scale of the view to 1.0 (Plot3d_ViewWindow::NormalizeSurfaces()) // (see 0003928: External 20834 (Bug) Plot3d, irregular scaling). + + // But if the Z scale is less than 1.0 (e.g. if several surfaces with different Z range are displayed), + // we keep the computed scale without changes (see "0004068: Plot3d surfaces are destroyed"). + if( anIsValueScaleFactorEnabled ) - aScale[2] = 1.0; + aScale[2] = qMin( aScale[2], 1.0 ); SetScale( aScale, false );