25 #define COMPILE_TIME_ASSERT(N,expr) \ 26 char dummy_constraint##N[expr] 28 #if MRPT_HAS_OPENGL_GLUT 34 if (cs!=0&&
v.size()%cs!=0)
throw std::logic_error(
"Vertices vector does not match chunk size");
42 #if MRPT_HAS_OPENGL_GLUT 50 #if MRPT_HAS_OPENGL_GLUT 51 for_each(enabled.begin(),enabled.end(),
glEnable);
55 glColor4ub(m_color.R,m_color.G,m_color.B,m_color.A);
56 if (normal[0]||normal[1]||normal[2])
glNormal3f(normal[0],normal[1],normal[2]);
59 for_each(vertices.begin(),vertices.end(),
renderFunc);
68 }
while (it!=vertices.end());
70 for_each(enabled.begin(),enabled.end(),
glDisable);
80 writeToStreamRender(out);
81 out<<
type <<vertices<<chunkSize<<enabled;
92 readFromStreamRender(
in);
93 in>>
type>>vertices>>chunkSize>>enabled;
120 m_pose.composePoint(bb_min, bb_min);
121 m_pose.composePoint(bb_max, bb_max);
128 while (it!=enabled.end())
131 it = enabled.erase(it);
Classes for serialization, sockets, ini-file manipulation, streams, list of properties-values, timewatch, extensions to STL.
GLAPI void GLAPIENTRY glEnable(GLenum cap)
#define IMPLEMENTS_SERIALIZABLE(class_name, base, NameSpace)
This must be inserted in all CSerializable classes implementation files.
#define COMPILE_TIME_ASSERT(N, expr)
GLAPI void GLAPIENTRY glNormal3f(GLfloat nx, GLfloat ny, GLfloat nz)
bool traceRay(const mrpt::poses::CPose3D &o, double &dist) const MRPT_OVERRIDE
Ray Tracing.
EIGEN_STRONG_INLINE void notifyChange() const
Must be called to notify that the object has changed (so, the display list must be updated) ...
const Scalar * const_iterator
#define GL_ONE_MINUS_SRC_ALPHA
double z
X,Y,Z coordinates.
void readFromStream(mrpt::utils::CStream &in, int version)
Introduces a pure virtual method responsible for loading from a CStream This can not be used directly...
GLAPI void GLAPIENTRY glShadeModel(GLenum mode)
virtual void render_dl() const MRPT_OVERRIDE
Render.
GLAPI void GLAPIENTRY glBlendFunc(GLenum sfactor, GLenum dfactor)
A renderizable object suitable for rendering with OpenGL's display lists.
static COpenGLStandardObjectPtr Create()
This base class is used to provide a unified interface to files,memory buffers,..Please see the deriv...
This base provides a set of functions for maths stuff.
#define MRPT_UNUSED_PARAM(a)
Can be used to avoid "not used parameters" warnings from the compiler.
#define MRPT_THROW_UNKNOWN_SERIALIZATION_VERSION(__V)
For use in CSerializable implementations.
GLAPI void GLAPIENTRY glBegin(GLenum mode)
Classes for 2D/3D geometry representation, both of single values and probability density distribution...
GLAPI void GLAPIENTRY glVertex3f(GLfloat x, GLfloat y, GLfloat z)
GLAPI void GLAPIENTRY glColor4ub(GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
void disable(_GLENUM flag)
Disable some openGL flag.
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
A class used to store a 3D pose (a 3D translation + a rotation in 3D).
The namespace for 3D scene representation and rendering.
GLAPI void GLAPIENTRY glEnd(void)
Objects of this class represent a generic openGL object without specific geometric properties...
void writeToStream(mrpt::utils::CStream &out, int *getVersion) const
Introduces a pure virtual method responsible for writing to a CStream.
unsigned __int32 uint32_t
GLAPI void GLAPIENTRY glDisable(GLenum cap)
void renderFunc(TPoint3D p)
void getBoundingBox(mrpt::math::TPoint3D &bb_min, mrpt::math::TPoint3D &bb_max) const MRPT_OVERRIDE
Evaluates the bounding box of this object (including possible children) in the coordinate frame of th...
GLuint GLuint GLsizei GLenum type