Gui: Bring back removed lookAtPoint(SbVec3f&)

This commit is contained in:
Rexbas
2023-10-24 21:33:42 +02:00
committed by wwmayer
parent a2c2bf5a4b
commit 7bb97c1882
2 changed files with 8 additions and 2 deletions

View File

@@ -323,11 +323,16 @@ SbBool NavigationStyle::lookAtPoint(const SbVec2s screenpos)
SbVec3f hitpoint;
hitpoint = picked->getPoint();
this->rotationCenterFound = false;
translateCamera(hitpoint - getFocalPoint());
lookAtPoint(hitpoint);
return true;
}
void NavigationStyle::lookAtPoint(const SbVec3f& position)
{
this->rotationCenterFound = false;
translateCamera(position - getFocalPoint());
}
SoCamera* NavigationStyle::getCamera() const
{
return this->viewer->getCamera();

View File

@@ -194,6 +194,7 @@ protected:
SbBool seekToPoint(const SbVec2s screenpos);
void seekToPoint(const SbVec3f& scenepos);
SbBool lookAtPoint(const SbVec2s screenpos);
void lookAtPoint(const SbVec3f& position);
void panCamera(SoCamera * camera,
float vpaspect,