1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-03 17:56:21 +03:00

0025657: Bad result of Fillet operation

Comments have been precised.

Test case for issue CR25657

Fix of regression

Additional test case.
This commit is contained in:
jgv 2015-01-15 15:04:05 +03:00 committed by bugmaster
parent 97c44f4156
commit 6504f8cd28
3 changed files with 55 additions and 13 deletions

View File

@ -371,29 +371,30 @@ static Standard_Boolean Update(Handle(Adaptor3d_HSurface)& face,
pared = ponc1.Parameter();
parltg = ponc2.Parameter();
if ((parltg > f) && (parltg < l)) {
#ifdef OCC23139
////modified by jgv, 10.05.2012 for the bug 23139////
////modified by jgv, 10.05.2012 for the bug 23139, 25657////
Handle(Geom2d_Curve) PConF = fi.PCurveOnFace();
if (!PConF.IsNull())
{
Handle(Geom2d_TrimmedCurve) aTrCurve = Handle(Geom2d_TrimmedCurve)::DownCast(PConF);
if (!aTrCurve.IsNull())
PConF = aTrCurve->BasisCurve();
if (isfirst)
if (!PConF->IsPeriodic())
{
Standard_Real fpar = PConF->FirstParameter();
if (parltg < fpar)
parltg = fpar;
}
else
{
Standard_Real lpar = PConF->LastParameter();
if (parltg > lpar)
parltg = lpar;
if (isfirst)
{
Standard_Real fpar = PConF->FirstParameter();
if (parltg < fpar)
parltg = fpar;
}
else
{
Standard_Real lpar = PConF->LastParameter();
if (parltg > lpar)
parltg = lpar;
}
}
}
/////////////////////////////////////////////////////
#endif
fi.SetParameter(parltg,isfirst);
cp.SetArc(cp.Tolerance(),cp.Arc(),pared,cp.TransitionOnArc());
return Standard_True;

View File

@ -0,0 +1,25 @@
puts "========"
puts "OCC25657"
puts "========"
puts ""
###########################################################################################
# Bad result of Fillet operation
###########################################################################################
restore [locate_data_file bug25657_r4.brep] r4
explode r4 e
shape c c
add r4_15 c
fillet res r4 20 c
explode res f
pcurve res_2
# exception
pcurve res_5
# exception
smallview
fit
set only_screen_axo 1

View File

@ -0,0 +1,16 @@
puts "========"
puts "OCC25657"
puts "========"
puts ""
###########################################################################################
# Bad result of Fillet operation
###########################################################################################
pcylinder a1 140 220
pcylinder a2 206 120
ttranslate a2 100 100 120
bcut a a1 a2
explode a e
donly a a_9
blend result a 20 a_9