1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

0031424: Visualization - stop using Prs3d_Drawer::HLRAngle() parameter

Prs3d_Drawer, AIS_Shape, AIS_InteractiveContext - removed properties HLRDeviationCoefficient() and HLRAngle().
Prs3d_Drawer::HLRAngle() is kept as alias to Prs3d_Drawer::DeviationAngle() with deprecated flag.
Prs3d_Drawer::DeviationAngle() default value is changed from 12 to 20 degrees
to match Prs3d_Drawer::HLRAngle() which has been previously used in majority of cases.
Removed unused property HLRBRep_PolyAlgo::Angle().
This commit is contained in:
kgv
2020-03-13 00:35:06 +03:00
parent b5163d2f8d
commit 67441d0ca3
21 changed files with 90 additions and 767 deletions

View File

@@ -336,7 +336,7 @@ void AIS_Shape::ComputeSelection(const Handle(SelectMgr_Selection)& aSelection,
shape,
TypOfSel,
aDeflection,
myDrawer->HLRAngle(),
myDrawer->DeviationAngle(),
myDrawer->IsAutoTriangulation());
}
catch (Standard_Failure const& anException)
@@ -819,20 +819,6 @@ Standard_Boolean AIS_Shape::SetOwnDeviationCoefficient ()
return itSet;
}
//=======================================================================
//function : SetHLROwnDeviationCoefficient
//purpose : resets myhasOwnHLRDeviationCoefficient to Standard_False and
// returns Standard_True if it change
//=======================================================================
Standard_Boolean AIS_Shape::SetOwnHLRDeviationCoefficient ()
{
Standard_Boolean itSet = myDrawer->HasOwnHLRDeviationCoefficient();
if(itSet) myDrawer->SetHLRDeviationCoefficient();
return itSet;
}
//=======================================================================
//function : SetOwnDeviationAngle
//purpose : resets myhasOwnDeviationAngle to Standard_False and
@@ -847,20 +833,6 @@ Standard_Boolean AIS_Shape::SetOwnDeviationAngle ()
}
//=======================================================================
//function : SetOwnHLRDeviationAngle
//purpose : resets myhasOwnHLRDeviationAngle to Standard_False and
// returns Standard_True if it change
//=======================================================================
Standard_Boolean AIS_Shape::SetOwnHLRDeviationAngle ()
{
Standard_Boolean itSet = myDrawer->HasOwnHLRDeviationAngle();
if(itSet) myDrawer->SetHLRAngle();
return itSet;
}
//***** SetOwn
//=======================================================================
//function : SetOwnDeviationCoefficient
//purpose :
@@ -872,17 +844,6 @@ void AIS_Shape::SetOwnDeviationCoefficient ( const Standard_Real aCoefficient )
SetToUpdate();
}
//=======================================================================
//function : SetOwnHLRDeviationCoefficient
//purpose :
//=======================================================================
void AIS_Shape::SetOwnHLRDeviationCoefficient ( const Standard_Real aCoefficient )
{
myDrawer->SetHLRDeviationCoefficient( aCoefficient );
}
//=======================================================================
//function : SetOwnDeviationAngle
//purpose :
@@ -918,31 +879,6 @@ Standard_Real AIS_Shape::UserAngle() const
return myInitAng ==0. ? GetContext()->DeviationAngle(): myInitAng;
}
//=======================================================================
//function : SetHLRAngleAndDeviation
//purpose :
//=======================================================================
void AIS_Shape::SetHLRAngleAndDeviation ( const Standard_Real anAngle )
{
Standard_Real OutAngl,OutDefl;
HLRBRep::PolyHLRAngleAndDeflection(anAngle,OutAngl,OutDefl);
SetOwnHLRDeviationAngle( OutAngl );
SetOwnHLRDeviationCoefficient(OutDefl);
}
//=======================================================================
//function : SetOwnHLRDeviationAngle
//purpose :
//=======================================================================
void AIS_Shape::SetOwnHLRDeviationAngle ( const Standard_Real anAngle )
{
myDrawer->SetHLRAngle( anAngle );
}
//***** GetOwn
//=======================================================================
//function : OwnDeviationCoefficient
//purpose :
@@ -956,20 +892,6 @@ Standard_Boolean AIS_Shape::OwnDeviationCoefficient ( Standard_Real & aCoeffici
return myDrawer->HasOwnDeviationCoefficient() ;
}
//=======================================================================
//function : OwnHLRDeviationCoefficient
//purpose :
//=======================================================================
Standard_Boolean AIS_Shape::OwnHLRDeviationCoefficient ( Standard_Real & aCoefficient,
Standard_Real & aPreviousCoefficient ) const
{
aCoefficient = myDrawer->HLRDeviationCoefficient();
aPreviousCoefficient = myDrawer->PreviousHLRDeviationCoefficient ();
return myDrawer->HasOwnHLRDeviationCoefficient();
}
//=======================================================================
//function : OwnDeviationAngle
//purpose :
@@ -983,19 +905,6 @@ Standard_Boolean AIS_Shape::OwnDeviationAngle ( Standard_Real & anAngle,
return myDrawer->HasOwnDeviationAngle();
}
//=======================================================================
//function : OwnHLRDeviationAngle
//purpose :
//=======================================================================
Standard_Boolean AIS_Shape::OwnHLRDeviationAngle ( Standard_Real & anAngle,
Standard_Real & aPreviousAngle ) const
{
anAngle = myDrawer->HLRAngle();
aPreviousAngle = myDrawer->PreviousHLRDeviationAngle ();
return myDrawer->HasOwnHLRDeviationAngle();
}
//=======================================================================
//function : DumpJson
//purpose :