mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-09-13 14:27:08 +03:00
0026159: Visualization - revise tolerance implementation for selection
Max tolerance is now applied to all objects and entities by default; if there is an entity with a lower tolerance, selecting frustum will be recalculated for it. The ability to set sensitivity for each entity individually is moved to protected section of SelectBasics_SensitiveEntity SetPixelTolerance from AIS_InteractiveContext now sets custom tolerance that is applied to all sensitives. Added -unset option to vselprecision command to disable custom tolerances. Test case for issue #26159
This commit is contained in:
@@ -187,7 +187,7 @@ void IVtkOCC_ViewerSelector::Activate (const Handle(SelectMgr_Selection)& theSel
|
||||
theSelection->SetSelectionState (SelectMgr_SOS_Activated);
|
||||
|
||||
myTolerances.Add (theSelection->Sensitivity());
|
||||
mytolerance = myTolerances.Largest();
|
||||
mytolerance = myTolerances.Tolerance();
|
||||
myToUpdateTolerance = Standard_True;
|
||||
}
|
||||
|
||||
@@ -205,6 +205,6 @@ void IVtkOCC_ViewerSelector::Deactivate (const Handle(SelectMgr_Selection)& theS
|
||||
theSelection->SetSelectionState (SelectMgr_SOS_Deactivated);
|
||||
|
||||
myTolerances.Decrement (theSelection->Sensitivity());
|
||||
mytolerance = myTolerances.Largest();
|
||||
mytolerance = myTolerances.Tolerance();
|
||||
myToUpdateTolerance = Standard_True;
|
||||
}
|
||||
|
Reference in New Issue
Block a user