1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0029712: Extrema algorithm raises exception

1. Extrema algorithm calls Curve-surface intersector. This intersector returns flag about infinite solution (in spite of extrema's returning not-parallel status correctly - axes of considered cylinder and circle are not parallel). In this case, attempt of obtaining number of intersection points leads to exception.

So, the fix adds check of infinite solution after the intersection algorithm.

2. The methods IsDone(), IsParallel(), NbExt(), SquareDistance() and Points() (of Extrema_* classes) have been corrected to make them consistent to the documentation.

3. Revision of some Extrema_* classes has been made in order to avoid places with uninitialized variables.

4. Currently Extrema does not store any points in case when the arguments are parallel. It stores the distance only.

5. Some cases on Extrema-algo have been moved from "fclasses"-group to "modalg"-group.
This commit is contained in:
nbv
2018-04-20 17:00:48 +03:00
committed by bugmaster
parent 395a5977d5
commit 638ad7f3c5
80 changed files with 2394 additions and 748 deletions

View File

@@ -1898,7 +1898,7 @@ void FindSplitPoint(SplitDS &theSplitDS,
anExtCC.SetRange(2, theMinParam, theMaxParam);
anExtCC.Perform();
if (anExtCC.IsDone())
if (anExtCC.IsDone() && !anExtCC.IsParallel())
{
const Standard_Integer aNbExt = anExtCC.NbExt();
for (Standard_Integer anIdx = 1; anIdx <= aNbExt; ++anIdx)