mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-19 13:40:49 +03:00
0028668: Point Cloud Rendering - standard selection API returns invalid values
Added an argument to OpenGl_GraphicDriver::GetSharedContext() for returning only currently bound OpenGL context. SelectMgr_SelectingVolumeManager::GetMousePosition() - added getter returning mouse coordinates.
This commit is contained in:
@@ -196,6 +196,17 @@ public:
|
||||
//! correspondingly) onto far view frustum plane
|
||||
Standard_EXPORT virtual gp_Pnt GetFarPickedPnt() const Standard_OVERRIDE;
|
||||
|
||||
//! Return mouse coordinates for Point selection mode.
|
||||
virtual gp_Pnt2d GetMousePosition() const Standard_OVERRIDE
|
||||
{
|
||||
if (myActiveSelectionType != Point)
|
||||
{
|
||||
return gp_Pnt2d (RealLast(), RealLast());
|
||||
}
|
||||
const SelectMgr_RectangularFrustum* aFr = reinterpret_cast<const SelectMgr_RectangularFrustum*> (mySelectingVolumes[myActiveSelectionType / 2].get());
|
||||
return aFr->GetMousePosition();
|
||||
}
|
||||
|
||||
//! Returns active selecting volume that was built during last
|
||||
//! run of OCCT selection mechanism
|
||||
Handle(SelectMgr_BaseFrustum) ActiveVolume() const
|
||||
|
Reference in New Issue
Block a user