From 421435679281e33c842b8db7231ef92d2372cd49 Mon Sep 17 00:00:00 2001 From: mkr Date: Mon, 28 Apr 2008 08:44:52 +0000 Subject: [PATCH] Fix for bug IPAL19512: Qt4 porting: Error message is shown after selection of Gauss point outside of secgmentation cursor => fix of SIGFPE exception during selection. --- src/VTKViewer/VTKViewer_Trihedron.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/VTKViewer/VTKViewer_Trihedron.cxx b/src/VTKViewer/VTKViewer_Trihedron.cxx index f50d67b30..d9f5d3321 100755 --- a/src/VTKViewer/VTKViewer_Trihedron.cxx +++ b/src/VTKViewer/VTKViewer_Trihedron.cxx @@ -81,7 +81,7 @@ void VTKViewer_UnScaledActor::Render(vtkRenderer *theRenderer) vtkFloatingPointType aPrecision = 1.0E-3; vtkFloatingPointType anOldScale = GetScale()[0]; vtkFloatingPointType aScale = mySize*aWorldDiag/aWinDiag/aLength*sqrt(vtkFloatingPointType(aSize[0])/vtkFloatingPointType(aSize[1])); - if(fabs(aScale - anOldScale)/aScale > aPrecision){ + if(aScale != 0.0 && fabs(aScale - anOldScale)/aScale > aPrecision){ SetScale(aScale); } } -- 2.39.2