49 #ifndef _MIRA_LINESTRIPOBJECT_H_ 50 #define _MIRA_LINESTRIPOBJECT_H_ 53 #include <OGRE/OgreMaterial.h> 83 LineStripObject(Ogre::SceneManager* sceneManager, Ogre::SceneNode* parent = NULL);
87 virtual void setColor(
const Ogre::ColourValue& color);
89 virtual void setVisible(
bool visible,
bool cascade =
true);
116 void point(
const Ogre::Vector3&
point,
const Ogre::ColourValue& color);
124 void add(
const Ogre::Vector3&
point);
131 void add(
const Ogre::Vector3&
point,
const Ogre::ColourValue& color);
134 void addLine(
const Ogre::Vector3& p1,
const Ogre::Vector3& p2);
137 void addLine(
const Ogre::Vector3& p1,
const Ogre::Vector3& p2,
const Ogre::ColourValue& color);
144 Point(
const Ogre::Vector3& iP,
const Ogre::ColourValue& iC) :
153 Strip() : pixelLineSection(-1) {}
154 std::list<Point> pts;
155 int pixelLineSection;
160 void regenerateStrip(std::size_t idx);
161 void regenerateAll();
162 void manageVisibility();
166 std::vector<boost::shared_ptr<Strip>> mStrips;
167 boost::shared_ptr<Strip> mActiveStrip;
169 Ogre::BillboardChain* mBillboardLines;
170 Ogre::ManualObject* mPixelLines;
172 Ogre::MaterialPtr mMaterial;
174 Ogre::ColourValue mColor;
void addLine(const Ogre::Vector3 &p1, const Ogre::Vector3 &p2)
Adds a line (a line strip consiting of two points)
virtual void setVisible(bool visible, bool cascade=true)
Declaration of VisualizationObject.
General point class template.
Definition: Point.h:140
specialize cv::DataType for our ImgPixel and inherit from cv::DataType<Vec>
Definition: IOService.h:67
Definition: VisualizationObject.h:70
void add(const Ogre::Vector3 &point)
Adds another point to the last line strip.
void clear()
Clears all line strips and points.
void setLineWidth(float width)
Sets the width of the line.
virtual void setColor(const Ogre::ColourValue &color)
Resets the color of all elements of the line (overwriting all possible individual colors of the line ...
Renders one or more line strips.
Definition: LineStripObject.h:80
bool isVisible() const
Definition: LineStripObject.h:90
void point(const Ogre::Vector3 &point)
Adds another point to the current line strip. This must be called between a call to begin() and end()...
Definition: ImageObject.h:60
virtual ~LineStripObject()
void begin()
Starts a new line strip.
void end()
Finishes the current line strip.
void enableAlphaBlending(bool useAlpha=true)
Enables/disables alpha blending.
LineStripObject(Ogre::SceneManager *sceneManager, Ogre::SceneNode *parent=NULL)