glc_pointsprite.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00026
00027 #include "glc_geometry.h"
00028 #include <QVector>
00029
00030 #include "../glc_config.h"
00031
00032 #ifndef GLC_POINTSPRITE_H_
00033 #define GLC_POINTSPRITE_H_
00034
00037
00040
00041
00042 class GLC_LIB_EXPORT GLC_PointSprite : public GLC_Geometry
00043 {
00044 public:
00046
00048
00049
00050
00051 GLC_PointSprite(float, GLC_Material*);
00052
00054 virtual ~GLC_PointSprite();
00056
00057
00059
00060 public:
00061
00063 inline float size() const
00064 {return m_Size;}
00065
00067 virtual const GLC_BoundingBox& boundingBox(void);
00068
00070 virtual GLC_Geometry* clone() const;
00071
00073 inline float fadeThresoldSize()
00074 {return m_FadeThresoldSize;}
00075
00077
00078 inline static float maximumPointSize()
00079 {return m_MaxSize;}
00080
00082
00084
00086
00087 public:
00088
00090 void setSize(float size);
00091
00093
00094 void setPointDistanceAttenuation(QVector<float>);
00095
00097 inline void setFadeThresoldSize(float value)
00098 {m_FadeThresoldSize= value;}
00099
00101
00103
00105
00106 private:
00108 virtual void render(const GLC_RenderProperties&);
00109
00111
00112 virtual void glDraw(const GLC_RenderProperties&);
00114
00115
00117
00118 private:
00120 float m_Size;
00121
00123 QVector<float> m_DistanceAttenuation;
00124
00126 float m_FadeThresoldSize;
00127
00129 static float m_MaxSize;
00130 };
00131
00132 #endif