GLC_PointSprite Class Reference

GLC_PointSprite : OpenGL 3D Point Sprite Using extension : GL_ARB_point_parameters. More...

#include <glc_pointsprite.h>

Inheritance diagram for GLC_PointSprite:
GLC_PointCloud GLC_Geometry

List of all members.

Public Member Functions

Constructor / Destructor

 GLC_PointSprite (float, GLC_Material *)
 Default constructor.
 GLC_PointSprite (const GLC_PointSprite &point)
 Copy constructor.
virtual ~GLC_PointSprite ()
 Default destructor.
Set Functions

void setSize (float size)
 Return the point size.
void setPointDistanceAttenuation (QVector< float >)
 Set the point distance attenuation values.
void setFadeThresoldSize (float value)
 Set the fade thresold size.

Private Member Functions

OpenGL Functions

virtual void render (const GLC_RenderProperties &)
 Specific glExecute method.
virtual void glDraw (const GLC_RenderProperties &)
 Virtual interface for OpenGL Geometry set up.

Private Attributes

float m_Size
 The point size.
QVector< float > m_DistanceAttenuation
 The Distance attenuation values.
float m_FadeThresoldSize
 The Fade Thresold Size.

Static Private Attributes

static float m_MaxSize = -1.0f
 The maximum point size.

Get Functions



float size () const
 Return the point size.
virtual GLC_Geometryclone () const
 Return a copy of the geometry.
float fadeThresoldSize ()
 Return the fade thresold size.
static float maximumPointSize ()
 Return the maximum point size.

Detailed Description

GLC_PointSprite : OpenGL 3D Point Sprite Using extension : GL_ARB_point_parameters.

An GLC_PointSprite is just a simple 3D Sprite Point

Definition at line 40 of file glc_pointsprite.h.


Constructor & Destructor Documentation

GLC_PointSprite::GLC_PointSprite ( float  size,
GLC_Material pMaterial 
)

Default constructor.

The material must exist and had texture

Definition at line 36 of file glc_pointsprite.cpp.

References GLC_Geometry::addMaterial(), GLC_PointCloud::addPoint(), GLC_Material::hasTexture(), and m_DistanceAttenuation.

Referenced by clone().

GLC_PointSprite::GLC_PointSprite ( const GLC_PointSprite point  ) 

Copy constructor.

Definition at line 56 of file glc_pointsprite.cpp.

GLC_PointSprite::~GLC_PointSprite (  )  [virtual]

Default destructor.

Definition at line 65 of file glc_pointsprite.cpp.


Member Function Documentation

GLC_Geometry * GLC_PointSprite::clone (  )  const [virtual]

Return a copy of the geometry.

Reimplemented from GLC_PointCloud.

Definition at line 71 of file glc_pointsprite.cpp.

References GLC_PointSprite().

float GLC_PointSprite::fadeThresoldSize (  )  [inline]

Return the fade thresold size.

Definition at line 71 of file glc_pointsprite.h.

void GLC_PointSprite::glDraw ( const GLC_RenderProperties renderProperties  )  [private, virtual]

Virtual interface for OpenGL Geometry set up.

This Virtual function is implemented here.

Reimplemented from GLC_PointCloud.

Definition at line 181 of file glc_pointsprite.cpp.

Referenced by render().

static float GLC_PointSprite::maximumPointSize (  )  [inline, static]

Return the maximum point size.

Return -1 if the size is unknown

Definition at line 76 of file glc_pointsprite.h.

void GLC_PointSprite::render ( const GLC_RenderProperties renderProperties  )  [private, virtual]
void GLC_PointSprite::setFadeThresoldSize ( float  value  )  [inline]

Set the fade thresold size.

Definition at line 95 of file glc_pointsprite.h.

void GLC_PointSprite::setPointDistanceAttenuation ( QVector< float >  parameters  ) 

Set the point distance attenuation values.

Vector size must be equal to 3

Definition at line 89 of file glc_pointsprite.cpp.

References m_DistanceAttenuation.

void GLC_PointSprite::setSize ( float  size  ) 

Return the point size.

Definition at line 77 of file glc_pointsprite.cpp.

References GLC_Geometry::m_GeometryIsValid, m_MaxSize, and m_Size.

float GLC_PointSprite::size (  )  const [inline]

Return the point size.

Definition at line 64 of file glc_pointsprite.h.


Member Data Documentation

QVector<float> GLC_PointSprite::m_DistanceAttenuation [private]

The Distance attenuation values.

Definition at line 121 of file glc_pointsprite.h.

Referenced by GLC_PointSprite(), render(), and setPointDistanceAttenuation().

The Fade Thresold Size.

Definition at line 124 of file glc_pointsprite.h.

Referenced by render().

float GLC_PointSprite::m_MaxSize = -1.0f [static, private]

The maximum point size.

Definition at line 127 of file glc_pointsprite.h.

Referenced by render(), and setSize().

float GLC_PointSprite::m_Size [private]

The point size.

Definition at line 118 of file glc_pointsprite.h.

Referenced by render(), and setSize().


The documentation for this class was generated from the following files:

SourceForge.net Logo

©2005-2011 Laurent Ribon