HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GR_PointGL3.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GR_PointGL3 ( GR Library, C++)
7  *
8  * COMMENTS:
9  * Simple point renderer. Cd, alpha and pscale are supported.
10  */
11 #ifndef GR_PointGL3_h
12 #define GR_PointGL3_h
13 
14 #include "GR_API.h"
15 #include "GR_GeoRender.h"
16 #include <RE/RE_ShaderHandle.h>
17 
19 {
20 public:
22  virtual ~GR_PointGL3();
23 
24  virtual const char *className() const { return "GR_PointGL3"; }
25 
26  virtual void update(RE_Render *r,
27  const GT_PrimitiveHandle &primh,
28  const GR_UpdateParms &parms,
29  const char *cache_name);
30 
31  virtual void draw(RE_Render *r,
34  GR_DrawParms dp);
35 
36  virtual exint getNumGLPrimitives() const;
37  virtual bool hasTransparency() const { return myHasAlpha; }
38 
39 private:
40  void updatePointAttribs(RE_Render *r,
41  const GT_PrimitiveHandle &primh,
42  const GR_UpdateParms &parms);
43  void drawPrivate(RE_Render *r,
46  GR_DrawParms dp);
47 
48  void drawUtility(RE_Render *r,
51  GR_DrawParms dp);
52 
53  static RE_ShaderHandle thePointShader;
54  static RE_ShaderHandle thePixelShader;
55  bool myHasCdAttrib;
56  bool myHasAlphaAttrib;
57  bool myHasAlpha;
58  bool myObjectSelected;
59 };
60 
61 #endif
virtual bool hasTransparency() const
returns true if this drawable renders some transparent elements
Definition: GR_PointGL3.h:37
GLbitfield flags
Definition: glcorearb.h:1595
virtual exint getNumGLPrimitives() const =0
set of parameters sent to GR_Primitive::update()
GR_RenderMode
Definition: GR_Defines.h:42
int64 exint
Definition: SYS_Types.h:115
#define GR_API
Definition: GR_API.h:10
GR_RenderFlags
Definition: GR_Defines.h:77
GLenum mode
Definition: glcorearb.h:98
virtual void update(RE_Render *r, const GT_PrimitiveHandle &primh, const GR_UpdateParms &p, const char *cache_name)=0
GLboolean r
Definition: glcorearb.h:1221
virtual const char * className() const
Definition: GR_PointGL3.h:24
Simple interface to building a shader from a .prog file.
virtual void draw(RE_Render *r, GR_RenderMode mode, GR_RenderFlags flags, GR_DrawParms draw_parms)=0
Normal drawing method. Only issue rendering commands.