mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-04-10 18:51:21 +03:00
0022523: DRAWEXE randomly crashed on smooth navigation in 3D-Viewer
Check vector modulus to avoid possible exceptions.
This commit is contained in:
parent
fadcea2c79
commit
476ed21f1b
@ -550,6 +550,11 @@ void NIS_View::Select (const NCollection_List<gp_XY> &thePolygon,
|
|||||||
|
|
||||||
// Compute transformation.
|
// Compute transformation.
|
||||||
const gp_XYZ anXdir (gp_XYZ(anX, anY, aZ) - anEye.XYZ());
|
const gp_XYZ anXdir (gp_XYZ(anX, anY, aZ) - anEye.XYZ());
|
||||||
|
if (anXdir.Modulus() <= gp::Resolution())
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
const gp_Ax3 anAx3 (anEye, aProj, anXdir);
|
const gp_Ax3 anAx3 (anEye, aProj, anXdir);
|
||||||
gp_Trsf aTrf;
|
gp_Trsf aTrf;
|
||||||
aTrf.SetTransformation (anAx3);
|
aTrf.SetTransformation (anAx3);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user