mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0028801: Visualization, Select3D_SensitivePrimitiveArray - add option to keep index map of detected elements
Select3D_SensitiveGroup - added option to force overlap check for all entities in the group. Added interface for accessing last detected entity in the group. Select3D_SensitivePrimitiveArray - added option to keep index map of detected elements and option to split array into groups for faster initialization of extra-large arrays. BVH_Geometry, BVH_Object - added missing accessor ::IsDirty() for checking BVH tree state.
This commit is contained in:
@@ -437,9 +437,11 @@ void AIS_PointCloud::ComputeSelection (const Handle(SelectMgr_Selection)& theSel
|
||||
if (!aPoints.IsNull()
|
||||
&& !aPoints->Attributes().IsNull())
|
||||
{
|
||||
// split large point clouds into several groups
|
||||
const Standard_Integer aNbGroups = aPoints->Attributes()->NbElements > 500000 ? 8 : 1;
|
||||
Handle(Select3D_SensitivePrimitiveArray) aSensitive = new Select3D_SensitivePrimitiveArray (anOwner);
|
||||
aSensitive->SetSensitivityFactor (8);
|
||||
aSensitive->InitPoints (aPoints->Attributes(), aPoints->Indices(), TopLoc_Location());
|
||||
aSensitive->InitPoints (aPoints->Attributes(), aPoints->Indices(), TopLoc_Location(), true, aNbGroups);
|
||||
aSensitive->BVH();
|
||||
theSelection->Add (aSensitive);
|
||||
return;
|
||||
|
Reference in New Issue
Block a user