Implements the functionalities of the robot visualization widget. Inherits form QWidget and Ui_robotVisualization (auto created from ui file) More...
#include <stdr_robot_visualization.h>
Public Member Functions | |
void | closeEvent (QCloseEvent *event) |
Called when the close event is triggered. More... | |
CRobotVisualisation (QString name, float resolution) | |
Default contructor. More... | |
void | destruct (void) |
Destroys the visualizer. More... | |
bool | getActive (void) |
Returns true if the visualizer is active. More... | |
int | getInternalImageSize (void) |
Returns the internal image size. More... | |
void | setCurrentPose (geometry_msgs::Pose2D pose) |
Sets the robot's current pose. More... | |
void | setCurrentSpeed (std::vector< float > msg) |
Sets the robot's current speed. More... | |
void | setImage (QImage img) |
Sets the image to be shown. More... | |
~CRobotVisualisation (void) | |
Default destructor. More... | |
Private Attributes | |
bool | active_ |
< True if the visualizer is active More... | |
QImage | internal_image_ |
A void image. More... | |
QString | name_ |
float | resolution_ |
The image to draw into. More... | |
QImage | void_image_ |
The robot frame id. More... | |
Implements the functionalities of the robot visualization widget. Inherits form QWidget and Ui_robotVisualization (auto created from ui file)
Definition at line 38 of file stdr_robot_visualization.h.
stdr_gui::CRobotVisualisation::CRobotVisualisation | ( | QString | name, |
float | resolution | ||
) |
Default contructor.
name | [QString] Robot frame id |
resolution | [float] Map resolution |
Definition at line 32 of file stdr_robot_visualization.cpp.
stdr_gui::CRobotVisualisation::~CRobotVisualisation | ( | void | ) |
void stdr_gui::CRobotVisualisation::closeEvent | ( | QCloseEvent * | event | ) |
Called when the close event is triggered.
event | [QCloseEvent*] The close event |
Definition at line 75 of file stdr_robot_visualization.cpp.
void stdr_gui::CRobotVisualisation::destruct | ( | void | ) |
bool stdr_gui::CRobotVisualisation::getActive | ( | void | ) |
Returns true if the visualizer is active.
Definition at line 85 of file stdr_robot_visualization.cpp.
int stdr_gui::CRobotVisualisation::getInternalImageSize | ( | void | ) |
Returns the internal image size.
void stdr_gui::CRobotVisualisation::setCurrentPose | ( | geometry_msgs::Pose2D | pose | ) |
Sets the robot's current pose.
pose | [geometry_msgs::Pose2D] the robot pose |
Definition at line 107 of file stdr_robot_visualization.cpp.
void stdr_gui::CRobotVisualisation::setCurrentSpeed | ( | std::vector< float > | msg | ) |
Sets the robot's current speed.
msg | [std::vector<float>] the robot speeds |
msg | [std::pair<float,float>] the robot speeds |
Definition at line 122 of file stdr_robot_visualization.cpp.
void stdr_gui::CRobotVisualisation::setImage | ( | QImage | img | ) |
Sets the image to be shown.
img | [QImage] The drawn image |
Definition at line 95 of file stdr_robot_visualization.cpp.
|
private |
< True if the visualizer is active
The map resolution
Definition at line 45 of file stdr_robot_visualization.h.
|
private |
A void image.
Definition at line 49 of file stdr_robot_visualization.h.
|
private |
Definition at line 53 of file stdr_robot_visualization.h.
|
private |
The image to draw into.
Definition at line 47 of file stdr_robot_visualization.h.
|
private |
The robot frame id.
Definition at line 51 of file stdr_robot_visualization.h.