The VgIManipulatorManager interface is used to choose the way the user will interact with the Open GL surface. More...
Public Member Functions | |
virtual | ~VgIManipulatorManager () |
Destructor. | |
virtual bool | selectManipulator (const std::string &pName)=0 |
Selects the current manipulator. | |
virtual std::string | getCurrentManipulator () const =0 |
Returns the current manipulator's name. | |
virtual VgApplication::VgManipulator * | editManipulatorObject (const std::string &pManipulatorName)=0 |
Returns a VgApplication::VgManipulator instance given its name. | |
Protected Member Functions | |
VgIManipulatorManager () | |
Constructor. |
The VgIManipulatorManager interface is used to choose the way the user will interact with the Open GL surface.
Currently, there are two supported manipulators:
For example, the "3D" manipulator supports various user-interactions on a touch-screen :
The below code snippets demonstrates how to select the "3D" manipulator.
bool lSuccess = mVgApp->editManipulatorManager()->selectManipulator("3D");
VgApplication::VgIManipulatorManager::VgIManipulatorManager | ( | ) | [inline, protected] |
Constructor.
virtual VgApplication::VgIManipulatorManager::~VgIManipulatorManager | ( | ) | [inline, virtual] |
Destructor.
virtual VgApplication::VgManipulator* VgApplication::VgIManipulatorManager::editManipulatorObject | ( | const std::string & | pManipulatorName ) | [pure virtual] |
Returns a VgApplication::VgManipulator instance given its name.
It returns NULL if the specified manipulator has no public interface.
pManipulatorName | Name of the manipulator to retrieve. |
virtual std::string VgApplication::VgIManipulatorManager::getCurrentManipulator | ( | ) | const [pure virtual] |
Returns the current manipulator's name.
virtual bool VgApplication::VgIManipulatorManager::selectManipulator | ( | const std::string & | pName ) | [pure virtual] |
Selects the current manipulator.
Having an active manipulator is almost always desired to provide the user with a mechanism to interact with the scene. Interaction is handled intuitively for the various hardware. For touch-screen devices, the view can be manipulated by dragging a finger. For other devices, view manipulation can be detected via the keypad.
pName | The name of the manipulator. Supported manipulators include: "3D" and "animation". |