Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2011-02-10 18:07:24 +0000
committerStijn Buys <ingar@osirion.org>2011-02-10 18:07:24 +0000
commit9ff5cf6184b9c5183c1f55cfa6c0d08586eb02c9 (patch)
treed50dd2d8ed48acfbb7063d4c073f77cb195106f7 /src/render/gl.h
parenta255dbc032d15a4f5024bc60baa19c45ebceecc6 (diff)
Added a local chat channel. The say command defaults to zone chat, global messages can be send with the shout command.
Removed NonSolid flag fro race objects, have race use the local chat channel. Updated to network protocol version 22. Updated developer documentation.
Diffstat (limited to 'src/render/gl.h')
-rw-r--r--src/render/gl.h33
1 files changed, 26 insertions, 7 deletions
diff --git a/src/render/gl.h b/src/render/gl.h
index c230547..51e215c 100644
--- a/src/render/gl.h
+++ b/src/render/gl.h
@@ -20,35 +20,53 @@
#ifdef _WIN32
#ifndef GL_RESCALE_NORMAL
-#define GL_RESCALE_NORMAL 0x803A
+#define GL_RESCALE_NORMAL 0x803A
#endif
#ifndef GL_TEXTURE_MAX_LEVEL
-#define GL_TEXTURE_MAX_LEVEL 0x813D
+#define GL_TEXTURE_MAX_LEVEL 0x813D
#endif
#ifndef GL_GENERATE_MIPMAP
-#define GL_GENERATE_MIPMAP 0x8191
+#define GL_GENERATE_MIPMAP 0x8191
#endif
#ifndef GL_REFLECTION_MAP
-#define GL_REFLECTION_MAP 0x8512
+#define GL_REFLECTION_MAP 0x8512
#endif
#ifndef GL_CLAMP_TO_EDGE
-#define GL_CLAMP_TO_EDGE 0x812F
+#define GL_CLAMP_TO_EDGE 0x812F
#endif
#ifndef GL_ARRAY_BUFFER
-#define GL_ARRAY_BUFFER 0x8892
+#define GL_ARRAY_BUFFER 0x8892
#endif
#ifndef GL_STATIC_DRAW
-#define GL_STATIC_DRAW 0x88E4
+#define GL_STATIC_DRAW 0x88E4
#endif
#endif // _WIN32
+/*
+ * @brief wrapper class for OpenGL functions
+ * The gl class accesses the OpenGL library functions
+ * through function pointers.
+ * This allows loading the library at runtime
+ * and makes static builds possible
+ */
+/*
+class GL {
+
+private:
+ typedef void (* APIENTRY gl_genbuffers_func)(GLuint count, GLuint *id);
+ typedef void (* APIENTRY gl_deletebuffers_func)(GLuint count, GLuint *id);
+ typedef void (* APIENTRY gl_bindbuffer_func)(GLenum target, GLuint id);
+ typedef void (* APIENTRY gl_bufferdata_func)(GLenum target, GLsizei size, const GLvoid *data, GLenum usage);
+
+}
+*/
/// wrapper namespace for OpenGL operations
/** The gl namespace provides a wrapper to the OpenGL library functions.
* All methods take floats or Vector3f and Color as parameters.
@@ -83,6 +101,7 @@ void viewport(GLint x, GLint y, GLsizei width, GLsizei height);
/// set the color used to clear to buffer
void clearcolor(math::Color const &color);
+
void clearcolor(const float r, const float g, const float b, const float a);
/// clear buffers to preset values