diff options
author | Evan Goers <mega@osirion.org> | 2012-11-26 06:29:34 +0000 |
---|---|---|
committer | Evan Goers <mega@osirion.org> | 2012-11-26 06:29:34 +0000 |
commit | a3a57df0be5c9d1d4ebbd153cabadbca48d16e79 (patch) | |
tree | c745f693d46e4f966e9ebc478bf09da795144c2e /src/render/gl.h | |
parent | bc8fb513b967d9c4eaa5f478e112c7f479093bbf (diff) |
Abstracted many more GL functions.
Added in useful texture unit info to State::init().
Cleaned up many non-abstracted GL functions used in draw.cc and state.cc.
Diffstat (limited to 'src/render/gl.h')
-rw-r--r-- | src/render/gl.h | 56 |
1 files changed, 53 insertions, 3 deletions
diff --git a/src/render/gl.h b/src/render/gl.h index 4dea544..8d8e48e 100644 --- a/src/render/gl.h +++ b/src/render/gl.h @@ -116,6 +116,12 @@ void enable(GLenum cap); /// glDisable void disable(GLenum cap); +/// glEnableClientState +void enableclientstate(GLenum cap); + +/// glDisableClientState +void disableclientstate(GLenum cap); + /// glShadeModel void shademodel(GLenum mode); @@ -174,6 +180,18 @@ void texcoord(const math::Vector2f& vector); /// glTexCoord void texcoord(const float x, const float y, const float z); +/// glTexCoordPointer +void texcoordpointer(GLint size, GLenum type, GLsizei stride, const GLvoid* pointer); + +/// glNormalPointer +void normalpointer(GLenum type, GLsizei stride, const GLvoid* pointer); + +/// glVertexPointer +void vertexpointer(GLint size, GLenum type, GLsizei stride, const GLvoid* pointer); + +/// glInterleavedArrays +void interleavedarrays(GLenum format, GLsizei stride, const GLvoid* pointer); + /// glNormal void normal(const math::Vector3f & vector); @@ -250,10 +268,42 @@ void loadidentity(); /// Perspective matrix void frustum(GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble znear, GLdouble zfar); -/// Texture coordinate generation -void texgeni(GLenum coord, GLenum param, GLenum value); +/// Light model +void lightmodel(GLenum pname, GLfloat param); +void lightmodel(GLenum pname, GLint param); +void lightmodel(GLenum pname, const GLfloat* param); +void lightmodel(GLenum pname, const GLint* param); + +/// Polygon mode +void polygonmode(GLenum face, GLenum mode); + +/// Color material parameters +void colormaterial(GLenum face, GLenum mode); -void texgenfv(GLenum coord, GLenum param, const GLfloat* value); +/// Material parameters +void material(GLenum face, GLenum pname, GLfloat param); +void material(GLenum face, GLenum pname, GLint param); +void material(GLenum face, GLenum pname, const GLfloat* param); +void material(GLenum face, GLenum pname, const GLint* param); + +/// Texture environment parameters +void texenv(GLenum target, GLenum pname, GLfloat param); +void texenv(GLenum target, GLenum pname, GLint param); +void texenv(GLenum target, GLenum pname, const GLfloat* param); +void texenv(GLenum target, GLenum pname, const GLint* param); + +/// Texture coordinate generation +void texgen(GLenum coord, GLenum param, GLint value); +void texgen(GLenum coord, GLenum param, GLfloat value); +void texgen(GLenum coord, GLenum param, GLdouble value); +void texgen(GLenum coord, GLenum param, const GLint* value); +void texgen(GLenum coord, GLenum param, const GLfloat* value); +void texgen(GLenum coord, GLenum param, const GLdouble* value); + +/// Active server-side texture +void activetexture(GLenum texture); +/// Active client-side texture +void clientactivetexture(GLenum texture); typedef void (* APIENTRY genbuffers_func)(GLuint count, GLuint *id); typedef void (* APIENTRY deletebuffers_func)(GLuint count, GLuint *id); |