Go to the documentation of this file.
32 #include <boost/bind/bind.hpp>
34 #include <OgreSceneNode.h>
35 #include <OgreSceneManager.h>
52 "The TF frame this grid will use for its origin.",
this,
nullptr,
true);
55 new IntProperty(
"Plane Cell Count", 10,
"The number of cells to draw in the plane of the grid.",
60 "The number of cells to draw along the normal vector of the grid. "
61 " Setting to anything but 0 makes the grid 3D.",
66 new FloatProperty(
"Cell Size", 1.0
f,
"The length, in meters, of the side of each cell.",
this,
71 new EnumProperty(
"Line Style",
"Lines",
"The rendering operation to use to draw the grid lines.",
85 new FloatProperty(
"Alpha", 0.5
f,
"The amount of transparency to apply to the grid lines.",
this,
97 "Offset", Ogre::Vector3::ZERO,
98 "Allows you to offset the grid from the origin of the reference frame. In meters.",
this,
127 std::string frame = qframe.toStdString();
129 Ogre::Vector3 position;
130 Ogre::Quaternion orientation;
147 "Could not transform from [" + qframe +
"] to [" +
fixed_frame_ +
"]");
210 Ogre::Quaternion orient;
214 orient = Ogre::Quaternion(1, 0, 0, 0);
217 orient = Ogre::Quaternion(Ogre::Vector3(0, -1, 0), Ogre::Vector3(0, 0, 1), Ogre::Vector3(1, 0, 0));
221 orient = Ogre::Quaternion(Ogre::Vector3(1, 0, 0), Ogre::Vector3(0, 0, -1), Ogre::Vector3(0, 1, 0));
virtual int getOptionInt()
Return the int value of the currently-chosen option, or 0 if the current option string does not have ...
virtual QColor getColor() const
FloatProperty * line_width_property_
Ogre::ColourValue qtToOgre(const QColor &c)
virtual void queueRender()=0
Queues a render. Multiple calls before a render happens will only cause a single render.
bool initialized() const
Returns true if the display has been initialized.
Grid * grid_
Handles actually drawing the grid.
void show()
Show this Property in any PropertyTreeWidgets.
void setLineWidth(float width)
QString fixed_frame_
A convenience variable equal to context_->getFixedFrame().
Property specialized to enforce floating point max/min.
FloatProperty * cell_size_property_
void hide()
Hide this Property in any PropertyTreeWidgets.
virtual void setStatus(StatusProperty::Level level, const QString &name, const QString &text)
Show status level and text. This is thread-safe.
#define PLUGINLIB_EXPORT_CLASS(class_type, base_class_type)
virtual float getFloat() const
void setColor(const Ogre::ColourValue &color)
virtual void addOption(const QString &option, int value=0)
void setHeight(uint32_t count)
Ogre::SceneNode * scene_node_
The Ogre::SceneNode to hold all 3D scene elements shown by this Display.
IntProperty * height_property_
Ogre::SceneManager * scene_manager_
A convenience variable equal to context_->getSceneManager().
Ogre::SceneNode * getSceneNode()
Get the Ogre scene node associated with this grid.
void setCellCount(uint32_t count)
virtual FrameManager * getFrameManager() const =0
Return the FrameManager instance.
FloatProperty * alpha_property_
Displays a grid of cells, drawn with lines.
EnumProperty * plane_property_
bool getTransform(const Header &header, Ogre::Vector3 &position, Ogre::Quaternion &orientation)
Return the pose for a header, relative to the fixed frame, in Ogre classes.
static const QString FIXED_FRAME_STRING
DisplayContext * context_
This DisplayContext pointer is the main connection a Display has into the rest of rviz....
VectorProperty * offset_property_
Displays a grid in either the XY, YZ, or XZ plane.
IntProperty * cell_count_property_
TfFrameProperty * frame_property_
void setStyle(Style style)
void onInitialize() override
Override this function to do subclass-specific initialization.
virtual int getInt() const
Return the internal property value as an integer.
void setFrameManager(FrameManager *frame_manager)
void update(float dt, float ros_dt) override
Called periodically by the visualization manager.
virtual Ogre::Vector3 getVector() const
EnumProperty * style_property_
void setCellLength(float len)
bool transformHasProblems(const std::string &frame, ros::Time time, std::string &error)
Check to see if a transform is known between a given frame and the fixed frame.
Property specialized to provide max/min enforcement for integers.
ColorProperty * color_property_
rviz
Author(s): Dave Hershberger, David Gossow, Josh Faust, William Woodall
autogenerated on Fri Aug 2 2024 08:43:09