mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-09 13:22:24 +03:00
0027202: Visualization - add sensitivity Select3D_SensitivePrimitiveArray for Graphic3d_Buffer
New class Select3D_SensitivePrimitiveArray can be initialized directly from presentation data structures Graphic3d_Buffer defining triangulation or point set. This class also can combine several elements into patches to reduce BVH initialization time in at the expense of slower detection time. AIS_PointCloud::ComputeSelection() - selection is now computed on point set using Select3D_SensitivePrimitiveArray by default. PrsMgr_PresentableObject::Compute() - redundant default argument value has been dropped. BVH - store BVH_Set size in local variable to simplify debugging.
This commit is contained in:
@@ -63,6 +63,7 @@
|
||||
#include <Prs3d_IsoAspect.hxx>
|
||||
#include <Prs3d_PointAspect.hxx>
|
||||
#include <Select3D_SensitiveWire.hxx>
|
||||
#include <Select3D_SensitivePrimitiveArray.hxx>
|
||||
#include <SelectMgr_EntityOwner.hxx>
|
||||
#include <StdSelect_BRepOwner.hxx>
|
||||
#include <StdSelect_ViewerSelector3d.hxx>
|
||||
@@ -4508,6 +4509,14 @@ static Standard_Integer VState (Draw_Interpretor& theDI,
|
||||
<< aSen->DynamicType()->Name()
|
||||
<< "\n";
|
||||
}
|
||||
|
||||
Handle(Select3D_SensitivePrimitiveArray) aPrimArr = Handle(Select3D_SensitivePrimitiveArray)::DownCast (anEntity);
|
||||
if (!aPrimArr.IsNull())
|
||||
{
|
||||
theDI << " Detected Element: "
|
||||
<< aPrimArr->LastDetectedElement()
|
||||
<< "\n";
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user