Grip-Reloaded
Grip version visualizaiton interface for DART (DynamicAnimationandRoboticsToolkits)
|
Main window for robot simulation interface. A virtual base class that subclasses QMainWindow. More...
#include <MainWindow.h>
Public Slots | |
void | slotSetStatusBarMessage (QString msg) |
Sets the status bar message. | |
virtual void | slotSetWorldFromPlayback (int sliderTick)=0 |
Slot for setting the state and time of the world based on the playback widget's slider position and the contents of the timeline. | |
virtual void | slotPlaybackStart ()=0 |
Slot for starting the playback. | |
virtual void | slotPlaybackPause ()=0 |
Slot for pausing the playback. | |
virtual void | slotPlaybackReverse ()=0 |
Slot for reversing the playback. | |
virtual void | slotPlaybackTimeStep (bool playForward)=0 |
Slot for going to the beginning of the playback timeline. | |
virtual void | slotPlaybackBeginning ()=0 |
Slot that recursively calls it self to run the playback loop. The recursive call allows the event loop to process other events, (eg. Stop Playback) | |
Public Member Functions | |
MainWindow () | |
Meta object macro to use signals and slots. | |
~MainWindow () | |
Destructs a MainWindow object. | |
void | Toolbar () |
Creates a toolbar. | |
Protected Slots | |
void | loadScene () |
Loads a scene with a dialog box. | |
void | quickLoad () |
Loads the last loaded scene. | |
void | saveScene () |
Saves the loaded scene to file for quick load functionality. | |
void | loadPluginFileWithDialog () |
Loads a plugin file using a file dialog for the user to manually find the plugin file. | |
void | loadPluginDirWithDialog () |
Loads all plugin files inside a directory with a dialog for the user to manually find the plugin directory. | |
virtual void | loadPluginDirectory (QDir pluginsDirName)=0 |
Reads a QDir directory and loads all the plugins inside it. | |
virtual void | loadPluginFile (QString pluginFilename)=0 |
Loads a plugin file (.so) by name. When loaded, the plugin will be added to the bottom tabs area. | |
virtual void | close () |
Closes the Window. | |
void | exit () |
Exits the program. | |
virtual void | front ()=0 |
Sets the view to front view. | |
virtual void | top ()=0 |
Sets the view to top view. | |
virtual void | side ()=0 |
Sets the view to side view. | |
virtual void | startSimulation ()=0 |
Starts the simulation. | |
virtual void | stopSimulation ()=0 |
Stops the simulation. | |
virtual void | simulateSingleStep ()=0 |
Simulates a single time step of the simulation. | |
virtual void | renderDuringSimulation ()=0 |
Turns on rendering during simulation, which will simulation slower than if rendering is turned off. | |
virtual void | white ()=0 |
Sets the background color of the window to white. | |
virtual void | gray ()=0 |
Sets the background color of the window to gray. | |
virtual void | black ()=0 |
Sets the background color of the window to black. | |
virtual void | resetCamera ()=0 |
Puts the camera back to its home position. | |
virtual void | xga1024x768 ()=0 |
virtual void | vga640x480 ()=0 |
virtual void | hd1280x720 ()=0 |
virtual void | simulationStopped ()=0 |
Notifies thread that simulation has stopped. | |
virtual void | setSimulationRelativeTime (double time)=0 |
Sets the time box for simulation time relative to real time. | |
void | about () |
Displays information about the application. | |
void | saveWorkspace () |
Saves the workspace configuration to an existing configuration file. | |
void | saveNewWorkspace () |
Saves the workspace configuration to a new configuration file. | |
void | loadWorkspace (std::string workspaceFile="") |
Loads workspace configuration from a configuration file. | |
Protected Member Functions | |
virtual QDomDocument * | generateWorkspaceXML ()=0 |
Create an XML file for the workspace contains the list of plugins, status of DockWidgets and the loaded scene. | |
virtual void | parseConfig (QDomDocument config)=0 |
Parses the configuration file and manipulates the workspace to match the settings in the configuration file. | |
QToolBar * | _getToolBar () |
QToolBar object for showing/hiding buttons. | |
Protected Attributes | |
const QString | LAST_LOAD_FILE |
Path of the last loaded scene file. | |
QString * | configFilePath |
Stores the path to the workspace configuration file. |
Main window for robot simulation interface. A virtual base class that subclasses QMainWindow.
Meta object macro to use signals and slots.
including the icons for the toolbar
Constructs a MainWindow object
void MainWindow::about | ( | ) | [protected, slot] |
Displays information about the application.
virtual void MainWindow::black | ( | ) | [protected, pure virtual, slot] |
void MainWindow::close | ( | ) | [protected, virtual, slot] |
void MainWindow::exit | ( | ) | [protected, slot] |
Exits the program.
virtual void MainWindow::front | ( | ) | [protected, pure virtual, slot] |
virtual QDomDocument* MainWindow::generateWorkspaceXML | ( | ) | [protected, pure virtual] |
Create an XML file for the workspace contains the list of plugins, status of DockWidgets and the loaded scene.
Implemented in GripMainWindow.
virtual void MainWindow::gray | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::loadPluginDirectory | ( | QDir | pluginsDirName | ) | [protected, pure virtual, slot] |
Reads a QDir directory and loads all the plugins inside it.
pluginsDirName | Name of the QDir containing the plugins |
Implemented in GripMainWindow.
virtual void MainWindow::loadPluginFile | ( | QString | pluginFilename | ) | [protected, pure virtual, slot] |
Loads a plugin file (.so) by name. When loaded, the plugin will be added to the bottom tabs area.
pluginFileName | String representing the path of the plugin |
Implemented in GripMainWindow.
void MainWindow::loadScene | ( | ) | [protected, slot] |
Loads a scene with a dialog box.
void MainWindow::loadWorkspace | ( | std::string | workspaceFile = "" | ) | [protected, slot] |
Loads workspace configuration from a configuration file.
virtual void MainWindow::parseConfig | ( | QDomDocument | config | ) | [protected, pure virtual] |
Parses the configuration file and manipulates the workspace to match the settings in the configuration file.
Implemented in GripMainWindow.
void MainWindow::quickLoad | ( | ) | [protected, slot] |
Loads the last loaded scene.
virtual void MainWindow::resetCamera | ( | ) | [protected, pure virtual, slot] |
void MainWindow::saveNewWorkspace | ( | ) | [protected, slot] |
Saves the workspace configuration to a new configuration file.
void MainWindow::saveScene | ( | ) | [protected, slot] |
Saves the loaded scene to file for quick load functionality.
void MainWindow::saveWorkspace | ( | ) | [protected, slot] |
Saves the workspace configuration to an existing configuration file.
virtual void MainWindow::setSimulationRelativeTime | ( | double | time | ) | [protected, pure virtual, slot] |
Sets the time box for simulation time relative to real time.
time | The simulation time relative to real time |
Implemented in GripMainWindow.
virtual void MainWindow::side | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::simulateSingleStep | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::simulationStopped | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::slotPlaybackBeginning | ( | ) | [pure virtual, slot] |
Slot that recursively calls it self to run the playback loop. The recursive call allows the event loop to process other events, (eg. Stop Playback)
playForward | Whether or not to play back in forward or reverse |
Implemented in GripMainWindow.
void MainWindow::slotSetStatusBarMessage | ( | QString | msg | ) | [slot] |
Sets the status bar message.
msg | Message to display on the status bar |
virtual void MainWindow::slotSetWorldFromPlayback | ( | int | sliderTick | ) | [pure virtual, slot] |
Slot for setting the state and time of the world based on the playback widget's slider position and the contents of the timeline.
sliderTick | Position of the playback widget's slider |
Implemented in GripMainWindow.
virtual void MainWindow::startSimulation | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::stopSimulation | ( | ) | [protected, pure virtual, slot] |
void MainWindow::Toolbar | ( | ) |
Creates a toolbar.
virtual void MainWindow::top | ( | ) | [protected, pure virtual, slot] |
virtual void MainWindow::white | ( | ) | [protected, pure virtual, slot] |