SOFA API  ca665544
Open source framework for multi-physics simuation
sofa::gl Namespace Reference

Forward declaration. More...

Namespaces

 component
 

Classes

class  Axis
 
class  BasicShapesGL
 
class  BasicShapesGL_Sphere
 
class  BasicShapesGL_FakeSphere
 
class  Capture
 
class  Cylinder
 
class  DrawToolGL
 
struct  fboParameters
 
class  FrameBufferObject
 
class  GLSLFileListener
 
class  GLSLShader
 
class  GlText
 
struct  CleanupCheck
 
struct  Enable
 
struct  Disable
 
class  Texture
 
class  TransformationGL
 
class  VideoRecorderFFMPEG
 

Functions

template<typename V >
void drawCone (const V &p1, const V &p2, const float &radius1, const float &radius2, const int subd=8)
 
template<typename V >
void drawCylinder (const V &p1, const V &p2, const float &rad, const int subd=8)
 
template<typename V >
void drawArrow (const V &p1, const V &p2, const float &rad, const int subd=8)
 
template<typename V >
void drawSphere (const V &center, const float &rad, const int subd1=8, const int subd2=8)
 
template<typename V >
void drawEllipsoid (const V &center, const float &radx, const float &rady, const float &radz, const int subd1=8, const int subd2=8)
 
template<typename V >
void drawWireSphere (const V &center, const float &rad, const int subd1=8, const int subd2=8)
 
template<typename V >
void drawTorus (const float *coordinateMatrix, const float &bodyRad=0.0, const float &rad=1.0, const int precision=20, const V &color=sofa::type::fixed_array< int, 3 >(255, 215, 180))
 
template<typename V >
void drawEmptyParallelepiped (const V &vert1, const V &vert2, const V &vert3, const V &vert4, const V &vecFromFaceToOppositeFace, const float &rad=1.0, const int precision=8, const V &color=sofa::type::RGBAColor::red())
 
SOFA_GL_API void glfntInit (void)
 
SOFA_GL_API void glfntWriteBitmap (float x, float y, char *s)
 
SOFA_GL_API void glfntClose (void)
 
std::string CombineHeaders (std::string header, const std::string &shaderStage, std::string source)
 
SOFA_GL_API void init ()
 Initialize the Sofa.GL library, as well as its dependencies: SofaDefaultType, SofaHelper. More...
 
SOFA_GL_API bool isInitialized ()
 Return true if and only if the Sofa.GL library has been initialized. More...
 
SOFA_GL_API void cleanup ()
 Clean up the resources used by the Sofa.GL library, as well as its dependencies: SofaDefaultType, SofaHelper. More...
 
SOFA_GL_API bool isCleanedUp ()
 Return true if and only if the Sofa.GL library has been cleaned up. More...
 
template<int N>
void glVertexNv (const float *)
 
template<>
void glVertexNv< 3 > (const float *p)
 
template<>
void glVertexNv< 2 > (const float *p)
 
template<>
void glVertexNv< 1 > (const float *p)
 
template<int N>
void glVertexNv (const double *p)
 
template<>
void glVertexNv< 2 > (const double *p)
 
template<>
void glVertexNv< 1 > (const double *p)
 
template<class Coord >
void glVertexT (const Coord &c)
 
template<>
void glVertexT< double > (const double &c)
 
template<>
void glVertexT< float > (const float &c)
 
template<int N>
void glTexCoordNv (const float *)
 
template<>
void glTexCoordNv< 3 > (const float *p)
 
template<>
void glTexCoordNv< 2 > (const float *p)
 
template<>
void glTexCoordNv< 1 > (const float *p)
 
template<int N>
void glTexCoordNv (const double *p)
 
template<>
void glTexCoordNv< 2 > (const double *p)
 
template<>
void glTexCoordNv< 1 > (const double *p)
 
template<class Coord >
void glTexCoordT (const Coord &c)
 
template<>
void glTexCoordT< double > (const double &c)
 
template<>
void glTexCoordT< float > (const float &c)
 
template<int N>
void glNormalNv (const float *p)
 
template<>
void glNormalNv< 2 > (const float *p)
 
template<>
void glNormalNv< 1 > (const float *p)
 
template<int N>
void glNormalNv (const double *p)
 
template<>
void glNormalNv< 2 > (const double *p)
 
template<>
void glNormalNv< 1 > (const double *p)
 
template<class Coord >
void glNormalT (const Coord &c)
 
template<>
void glNormalT< double > (const double &c)
 
template<>
void glNormalT< float > (const float &c)
 
void glTranslate (const float &c1, const float &c2, const float &c3)
 
void glTranslate (const double &c1, const double &c2, const double &c3)
 
template<int N>
void glTranslateNv (const float *p)
 
template<>
void glTranslateNv< 2 > (const float *p)
 
template<>
void glTranslateNv< 1 > (const float *p)
 
template<int N>
void glTranslateNv (const double *p)
 
template<>
void glTranslateNv< 2 > (const double *p)
 
template<>
void glTranslateNv< 1 > (const double *p)
 
template<class Coord >
void glTranslateT (const Coord &c)
 
template<>
void glTranslateT< double > (const double &c)
 
template<>
void glTranslateT< float > (const float &c)
 
void glScale (const float &c1, const float &c2, const float &c3)
 
void glScale (const double &c1, const double &c2, const double &c3)
 
void glRotate (const GLfloat &value, const float &c1, const float &c2, const float &c3)
 
void glRotate (const GLdouble &value, const double &c1, const double &c2, const double &c3)
 
void glMultMatrix (const float *p)
 
void glMultMatrix (const double *p)
 

Variables

bool GLSLIsSupported = false
 

Detailed Description

Forward declaration.

Function Documentation

◆ cleanup()

SOFA_GL_API void sofa::gl::cleanup ( )

Clean up the resources used by the Sofa.GL library, as well as its dependencies: SofaDefaultType, SofaHelper.

◆ CombineHeaders()

std::string sofa::gl::CombineHeaders ( std::string  header,
const std::string &  shaderStage,
std::string  source 
)

◆ drawArrow()

template<typename V >
void sofa::gl::drawArrow ( const V &  p1,
const V &  p2,
const float rad,
const int  subd = 8 
)

◆ drawCone()

template<typename V >
void sofa::gl::drawCone ( const V &  p1,
const V &  p2,
const float radius1,
const float radius2,
const int  subd = 8 
)

◆ drawCylinder()

template<typename V >
void sofa::gl::drawCylinder ( const V &  p1,
const V &  p2,
const float rad,
const int  subd = 8 
)

◆ drawEllipsoid()

template<typename V >
void sofa::gl::drawEllipsoid ( const V &  center,
const float radx,
const float rady,
const float radz,
const int  subd1 = 8,
const int  subd2 = 8 
)

◆ drawEmptyParallelepiped()

template<typename V >
void sofa::gl::drawEmptyParallelepiped ( const V &  vert1,
const V &  vert2,
const V &  vert3,
const V &  vert4,
const V &  vecFromFaceToOppositeFace,
const float rad = 1.0,
const int  precision = 8,
const V &  color = sofa::type::RGBAColor::red() 
)

◆ drawSphere()

template<typename V >
void sofa::gl::drawSphere ( const V &  center,
const float rad,
const int  subd1 = 8,
const int  subd2 = 8 
)

◆ drawTorus()

template<typename V >
void sofa::gl::drawTorus ( const float coordinateMatrix,
const float bodyRad = 0.0,
const float rad = 1.0,
const int  precision = 20,
const V &  color = sofa::type::fixed_array<int,3>(255,215,180) 
)

◆ drawWireSphere()

template<typename V >
void sofa::gl::drawWireSphere ( const V &  center,
const float rad,
const int  subd1 = 8,
const int  subd2 = 8 
)

◆ glfntClose()

SOFA_GL_API void sofa::gl::glfntClose ( void  )

◆ glfntInit()

SOFA_GL_API void sofa::gl::glfntInit ( void  )

◆ glfntWriteBitmap()

SOFA_GL_API void sofa::gl::glfntWriteBitmap ( float  x,
float  y,
char s 
)

◆ glMultMatrix() [1/2]

void sofa::gl::glMultMatrix ( const double *  p)
inline

◆ glMultMatrix() [2/2]

void sofa::gl::glMultMatrix ( const float p)
inline

◆ glNormalNv() [1/2]

template<int N>
void sofa::gl::glNormalNv ( const double *  p)
inline

◆ glNormalNv() [2/2]

template<int N>
void sofa::gl::glNormalNv ( const float p)
inline

◆ glNormalNv< 1 >() [1/2]

template<>
void sofa::gl::glNormalNv< 1 > ( const double *  p)
inline

◆ glNormalNv< 1 >() [2/2]

template<>
void sofa::gl::glNormalNv< 1 > ( const float p)
inline

◆ glNormalNv< 2 >() [1/2]

template<>
void sofa::gl::glNormalNv< 2 > ( const double *  p)
inline

◆ glNormalNv< 2 >() [2/2]

template<>
void sofa::gl::glNormalNv< 2 > ( const float p)
inline

◆ glNormalT()

template<class Coord >
void sofa::gl::glNormalT ( const Coord &  c)
inline

◆ glNormalT< double >()

template<>
void sofa::gl::glNormalT< double > ( const double &  c)
inline

◆ glNormalT< float >()

template<>
void sofa::gl::glNormalT< float > ( const float c)
inline

◆ glRotate() [1/2]

void sofa::gl::glRotate ( const GLdouble &  value,
const double &  c1,
const double &  c2,
const double &  c3 
)
inline

◆ glRotate() [2/2]

void sofa::gl::glRotate ( const GLfloat value,
const float c1,
const float c2,
const float c3 
)
inline

◆ glScale() [1/2]

void sofa::gl::glScale ( const double &  c1,
const double &  c2,
const double &  c3 
)
inline

◆ glScale() [2/2]

void sofa::gl::glScale ( const float c1,
const float c2,
const float c3 
)
inline

◆ glTexCoordNv() [1/2]

template<int N>
void sofa::gl::glTexCoordNv ( const double *  p)
inline

◆ glTexCoordNv() [2/2]

template<int N>
void sofa::gl::glTexCoordNv ( const float )
inline

◆ glTexCoordNv< 1 >() [1/2]

template<>
void sofa::gl::glTexCoordNv< 1 > ( const double *  p)
inline

◆ glTexCoordNv< 1 >() [2/2]

template<>
void sofa::gl::glTexCoordNv< 1 > ( const float p)
inline

◆ glTexCoordNv< 2 >() [1/2]

template<>
void sofa::gl::glTexCoordNv< 2 > ( const double *  p)
inline

◆ glTexCoordNv< 2 >() [2/2]

template<>
void sofa::gl::glTexCoordNv< 2 > ( const float p)
inline

◆ glTexCoordNv< 3 >()

template<>
void sofa::gl::glTexCoordNv< 3 > ( const float p)
inline

◆ glTexCoordT()

template<class Coord >
void sofa::gl::glTexCoordT ( const Coord &  c)
inline

◆ glTexCoordT< double >()

template<>
void sofa::gl::glTexCoordT< double > ( const double &  c)
inline

◆ glTexCoordT< float >()

template<>
void sofa::gl::glTexCoordT< float > ( const float c)
inline

◆ glTranslate() [1/2]

void sofa::gl::glTranslate ( const double &  c1,
const double &  c2,
const double &  c3 
)
inline

◆ glTranslate() [2/2]

void sofa::gl::glTranslate ( const float c1,
const float c2,
const float c3 
)
inline

◆ glTranslateNv() [1/2]

template<int N>
void sofa::gl::glTranslateNv ( const double *  p)
inline

◆ glTranslateNv() [2/2]

template<int N>
void sofa::gl::glTranslateNv ( const float p)
inline

◆ glTranslateNv< 1 >() [1/2]

template<>
void sofa::gl::glTranslateNv< 1 > ( const double *  p)
inline

◆ glTranslateNv< 1 >() [2/2]

template<>
void sofa::gl::glTranslateNv< 1 > ( const float p)
inline

◆ glTranslateNv< 2 >() [1/2]

template<>
void sofa::gl::glTranslateNv< 2 > ( const double *  p)
inline

◆ glTranslateNv< 2 >() [2/2]

template<>
void sofa::gl::glTranslateNv< 2 > ( const float p)
inline

◆ glTranslateT()

template<class Coord >
void sofa::gl::glTranslateT ( const Coord &  c)
inline

◆ glTranslateT< double >()

template<>
void sofa::gl::glTranslateT< double > ( const double &  c)
inline

◆ glTranslateT< float >()

template<>
void sofa::gl::glTranslateT< float > ( const float c)
inline

◆ glVertexNv() [1/2]

template<int N>
void sofa::gl::glVertexNv ( const double *  p)
inline

◆ glVertexNv() [2/2]

template<int N>
void sofa::gl::glVertexNv ( const float )
inline

◆ glVertexNv< 1 >() [1/2]

template<>
void sofa::gl::glVertexNv< 1 > ( const double *  p)
inline

◆ glVertexNv< 1 >() [2/2]

template<>
void sofa::gl::glVertexNv< 1 > ( const float p)
inline

◆ glVertexNv< 2 >() [1/2]

template<>
void sofa::gl::glVertexNv< 2 > ( const double *  p)
inline

◆ glVertexNv< 2 >() [2/2]

template<>
void sofa::gl::glVertexNv< 2 > ( const float p)
inline

◆ glVertexNv< 3 >()

template<>
void sofa::gl::glVertexNv< 3 > ( const float p)
inline

◆ glVertexT()

template<class Coord >
void sofa::gl::glVertexT ( const Coord &  c)
inline

◆ glVertexT< double >()

template<>
void sofa::gl::glVertexT< double > ( const double &  c)
inline

◆ glVertexT< float >()

template<>
void sofa::gl::glVertexT< float > ( const float c)
inline

◆ init()

SOFA_GL_API void sofa::gl::init ( )

Initialize the Sofa.GL library, as well as its dependencies: SofaDefaultType, SofaHelper.

◆ isCleanedUp()

SOFA_GL_API bool sofa::gl::isCleanedUp ( )

Return true if and only if the Sofa.GL library has been cleaned up.

◆ isInitialized()

SOFA_GL_API bool sofa::gl::isInitialized ( )

Return true if and only if the Sofa.GL library has been initialized.

Variable Documentation

◆ GLSLIsSupported

bool sofa::gl::GLSLIsSupported = false