From 7ae15eb2b81c268d4b38667bf7ba8a8f35ae6586 Mon Sep 17 00:00:00 2001 From: kaetemi Date: Sun, 30 Mar 2014 16:06:35 +0200 Subject: [PATCH] GL3: Remove ARB_multitexture --HG-- branch : opengl3 --- .../opengl3/driver_opengl_extension.cpp | 92 +------------------ .../driver/opengl3/driver_opengl_extension.h | 40 -------- .../opengl3/driver_opengl_extension_def.h | 37 -------- .../driver/opengl3/driver_opengl_states.cpp | 10 +- 4 files changed, 6 insertions(+), 173 deletions(-) diff --git a/code/nel/src/3d/driver/opengl3/driver_opengl_extension.cpp b/code/nel/src/3d/driver/opengl3/driver_opengl_extension.cpp index 7a6e5483f..b15041011 100644 --- a/code/nel/src/3d/driver/opengl3/driver_opengl_extension.cpp +++ b/code/nel/src/3d/driver/opengl3/driver_opengl_extension.cpp @@ -63,45 +63,7 @@ void (*nglGetProcAddress(const char *procName))() // *************************************************************************** // The exported function names -// ARB_multitexture -NEL_PFNGLACTIVETEXTUREARBPROC nglActiveTextureARB; -NEL_PFNGLCLIENTACTIVETEXTUREARBPROC nglClientActiveTextureARB; - -NEL_PFNGLMULTITEXCOORD1SARBPROC nglMultiTexCoord1sARB; -NEL_PFNGLMULTITEXCOORD1IARBPROC nglMultiTexCoord1iARB; -NEL_PFNGLMULTITEXCOORD1FARBPROC nglMultiTexCoord1fARB; -NEL_PFNGLMULTITEXCOORD1DARBPROC nglMultiTexCoord1dARB; -NEL_PFNGLMULTITEXCOORD2SARBPROC nglMultiTexCoord2sARB; -NEL_PFNGLMULTITEXCOORD2IARBPROC nglMultiTexCoord2iARB; -NEL_PFNGLMULTITEXCOORD2FARBPROC nglMultiTexCoord2fARB; -NEL_PFNGLMULTITEXCOORD2DARBPROC nglMultiTexCoord2dARB; -NEL_PFNGLMULTITEXCOORD3SARBPROC nglMultiTexCoord3sARB; -NEL_PFNGLMULTITEXCOORD3IARBPROC nglMultiTexCoord3iARB; -NEL_PFNGLMULTITEXCOORD3FARBPROC nglMultiTexCoord3fARB; -NEL_PFNGLMULTITEXCOORD3DARBPROC nglMultiTexCoord3dARB; -NEL_PFNGLMULTITEXCOORD4SARBPROC nglMultiTexCoord4sARB; -NEL_PFNGLMULTITEXCOORD4IARBPROC nglMultiTexCoord4iARB; -NEL_PFNGLMULTITEXCOORD4FARBPROC nglMultiTexCoord4fARB; -NEL_PFNGLMULTITEXCOORD4DARBPROC nglMultiTexCoord4dARB; - -NEL_PFNGLMULTITEXCOORD1SVARBPROC nglMultiTexCoord1svARB; -NEL_PFNGLMULTITEXCOORD1IVARBPROC nglMultiTexCoord1ivARB; -NEL_PFNGLMULTITEXCOORD1FVARBPROC nglMultiTexCoord1fvARB; -NEL_PFNGLMULTITEXCOORD1DVARBPROC nglMultiTexCoord1dvARB; -NEL_PFNGLMULTITEXCOORD2SVARBPROC nglMultiTexCoord2svARB; -NEL_PFNGLMULTITEXCOORD2IVARBPROC nglMultiTexCoord2ivARB; -NEL_PFNGLMULTITEXCOORD2FVARBPROC nglMultiTexCoord2fvARB; -NEL_PFNGLMULTITEXCOORD2DVARBPROC nglMultiTexCoord2dvARB; -NEL_PFNGLMULTITEXCOORD3SVARBPROC nglMultiTexCoord3svARB; -NEL_PFNGLMULTITEXCOORD3IVARBPROC nglMultiTexCoord3ivARB; -NEL_PFNGLMULTITEXCOORD3FVARBPROC nglMultiTexCoord3fvARB; -NEL_PFNGLMULTITEXCOORD3DVARBPROC nglMultiTexCoord3dvARB; -NEL_PFNGLMULTITEXCOORD4SVARBPROC nglMultiTexCoord4svARB; -NEL_PFNGLMULTITEXCOORD4IVARBPROC nglMultiTexCoord4ivARB; -NEL_PFNGLMULTITEXCOORD4FVARBPROC nglMultiTexCoord4fvARB; -NEL_PFNGLMULTITEXCOORD4DVARBPROC nglMultiTexCoord4dvARB; - -// Core +// Core 3.30 PFNGLATTACHSHADERPROC nglAttachShader; PFNGLCOMPILESHADERPROC nglCompileShader; PFNGLCREATEPROGRAMPROC nglCreateProgram; @@ -329,53 +291,6 @@ namespace NLDRIVERGL3 { // *************************************************************************** // Extensions registrations, and Windows function Registration. -// ********************************* -static bool setupARBMultiTexture(const char *glext) -{ - H_AUTO_OGL(setupARBMultiTexture); - - CHECK_EXT("GL_ARB_multitexture"); - - CHECK_ADDRESS(NEL_PFNGLACTIVETEXTUREARBPROC, glActiveTextureARB); - CHECK_ADDRESS(NEL_PFNGLCLIENTACTIVETEXTUREARBPROC, glClientActiveTextureARB); - - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1SARBPROC, glMultiTexCoord1sARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1IARBPROC, glMultiTexCoord1iARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1FARBPROC, glMultiTexCoord1fARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1DARBPROC, glMultiTexCoord1dARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2SARBPROC, glMultiTexCoord2sARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2IARBPROC, glMultiTexCoord2iARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2FARBPROC, glMultiTexCoord2fARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2DARBPROC, glMultiTexCoord2dARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3SARBPROC, glMultiTexCoord3sARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3IARBPROC, glMultiTexCoord3iARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3FARBPROC, glMultiTexCoord3fARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3DARBPROC, glMultiTexCoord3dARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4SARBPROC, glMultiTexCoord4sARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4IARBPROC, glMultiTexCoord4iARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4FARBPROC, glMultiTexCoord4fARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4DARBPROC, glMultiTexCoord4dARB); - - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1SVARBPROC, glMultiTexCoord1svARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1IVARBPROC, glMultiTexCoord1ivARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1FVARBPROC, glMultiTexCoord1fvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD1DVARBPROC, glMultiTexCoord1dvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2SVARBPROC, glMultiTexCoord2svARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2IVARBPROC, glMultiTexCoord2ivARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2FVARBPROC, glMultiTexCoord2fvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD2DVARBPROC, glMultiTexCoord2dvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3SVARBPROC, glMultiTexCoord3svARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3IVARBPROC, glMultiTexCoord3ivARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3FVARBPROC, glMultiTexCoord3fvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD3DVARBPROC, glMultiTexCoord3dvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4SVARBPROC, glMultiTexCoord4svARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4IVARBPROC, glMultiTexCoord4ivARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4FVARBPROC, glMultiTexCoord4fvARB); - CHECK_ADDRESS(NEL_PFNGLMULTITEXCOORD4DVARBPROC, glMultiTexCoord4dvARB); - - return true; -} - // ********************************* static bool setupEXTTextureCompressionS3TC(const char *glext) { @@ -659,11 +574,6 @@ void registerGlExtensions(CGlExtensions &ext) GLint nbFragmentTextureUnits; glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &nbFragmentTextureUnits); ext.NbFragmentTextureUnits = (nbFragmentTextureUnits > IDRV_MAT_MAXTEXTURES) ? IDRV_MAT_MAXTEXTURES : nbFragmentTextureUnits; // FIXME GL3 - - // --- - - // Check ARBMultiTexture - ext.ARBMultiTexture= setupARBMultiTexture(glext); } diff --git a/code/nel/src/3d/driver/opengl3/driver_opengl_extension.h b/code/nel/src/3d/driver/opengl3/driver_opengl_extension.h index d75656252..717b65c6e 100644 --- a/code/nel/src/3d/driver/opengl3/driver_opengl_extension.h +++ b/code/nel/src/3d/driver/opengl3/driver_opengl_extension.h @@ -147,46 +147,6 @@ void registerGlExtensions(CGlExtensions &ext); NB: we do it for all (EXT, NV, ARB extension) even it should be useful only for ARB ones. */ -// ARB_multitexture -//================= -extern NEL_PFNGLACTIVETEXTUREARBPROC nglActiveTextureARB; -extern NEL_PFNGLCLIENTACTIVETEXTUREARBPROC nglClientActiveTextureARB; - -extern NEL_PFNGLMULTITEXCOORD1SARBPROC nglMultiTexCoord1sARB; -extern NEL_PFNGLMULTITEXCOORD1IARBPROC nglMultiTexCoord1iARB; -extern NEL_PFNGLMULTITEXCOORD1FARBPROC nglMultiTexCoord1fARB; -extern NEL_PFNGLMULTITEXCOORD1FARBPROC nglMultiTexCoord1fARB; -extern NEL_PFNGLMULTITEXCOORD1DARBPROC nglMultiTexCoord1dARB; -extern NEL_PFNGLMULTITEXCOORD2SARBPROC nglMultiTexCoord2sARB; -extern NEL_PFNGLMULTITEXCOORD2IARBPROC nglMultiTexCoord2iARB; -extern NEL_PFNGLMULTITEXCOORD2FARBPROC nglMultiTexCoord2fARB; -extern NEL_PFNGLMULTITEXCOORD2DARBPROC nglMultiTexCoord2dARB; -extern NEL_PFNGLMULTITEXCOORD3SARBPROC nglMultiTexCoord3sARB; -extern NEL_PFNGLMULTITEXCOORD3IARBPROC nglMultiTexCoord3iARB; -extern NEL_PFNGLMULTITEXCOORD3FARBPROC nglMultiTexCoord3fARB; -extern NEL_PFNGLMULTITEXCOORD3DARBPROC nglMultiTexCoord3dARB; -extern NEL_PFNGLMULTITEXCOORD4SARBPROC nglMultiTexCoord4sARB; -extern NEL_PFNGLMULTITEXCOORD4IARBPROC nglMultiTexCoord4iARB; -extern NEL_PFNGLMULTITEXCOORD4FARBPROC nglMultiTexCoord4fARB; -extern NEL_PFNGLMULTITEXCOORD4DARBPROC nglMultiTexCoord4dARB; - -extern NEL_PFNGLMULTITEXCOORD1SVARBPROC nglMultiTexCoord1svARB; -extern NEL_PFNGLMULTITEXCOORD1IVARBPROC nglMultiTexCoord1ivARB; -extern NEL_PFNGLMULTITEXCOORD1FVARBPROC nglMultiTexCoord1fvARB; -extern NEL_PFNGLMULTITEXCOORD1DVARBPROC nglMultiTexCoord1dvARB; -extern NEL_PFNGLMULTITEXCOORD2SVARBPROC nglMultiTexCoord2svARB; -extern NEL_PFNGLMULTITEXCOORD2IVARBPROC nglMultiTexCoord2ivARB; -extern NEL_PFNGLMULTITEXCOORD2FVARBPROC nglMultiTexCoord2fvARB; -extern NEL_PFNGLMULTITEXCOORD2DVARBPROC nglMultiTexCoord2dvARB; -extern NEL_PFNGLMULTITEXCOORD3SVARBPROC nglMultiTexCoord3svARB; -extern NEL_PFNGLMULTITEXCOORD3IVARBPROC nglMultiTexCoord3ivARB; -extern NEL_PFNGLMULTITEXCOORD3FVARBPROC nglMultiTexCoord3fvARB; -extern NEL_PFNGLMULTITEXCOORD3DVARBPROC nglMultiTexCoord3dvARB; -extern NEL_PFNGLMULTITEXCOORD4SVARBPROC nglMultiTexCoord4svARB; -extern NEL_PFNGLMULTITEXCOORD4IVARBPROC nglMultiTexCoord4ivARB; -extern NEL_PFNGLMULTITEXCOORD4FVARBPROC nglMultiTexCoord4fvARB; -extern NEL_PFNGLMULTITEXCOORD4DVARBPROC nglMultiTexCoord4dvARB; - // Core 3.30 extern PFNGLATTACHSHADERPROC nglAttachShader; extern PFNGLCOMPILESHADERPROC nglCompileShader; diff --git a/code/nel/src/3d/driver/opengl3/driver_opengl_extension_def.h b/code/nel/src/3d/driver/opengl3/driver_opengl_extension_def.h index 55b5c7162..7be954590 100644 --- a/code/nel/src/3d/driver/opengl3/driver_opengl_extension_def.h +++ b/code/nel/src/3d/driver/opengl3/driver_opengl_extension_def.h @@ -35,43 +35,6 @@ extern "C" { #define WGL_COVERAGE_SAMPLES_NV 0x2042 #define WGL_COLOR_SAMPLES_NV 0x20B9 -// ARB_multitexture -//================= -typedef void (APIENTRY * NEL_PFNGLACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRY * NEL_PFNGLCLIENTACTIVETEXTUREARBPROC) (GLenum texture); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1DARBPROC) (GLenum target, GLdouble s); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1FARBPROC) (GLenum target, GLfloat s); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1IARBPROC) (GLenum target, GLint s); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1SARBPROC) (GLenum target, GLshort s); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD1SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2DARBPROC) (GLenum target, GLdouble s, GLdouble t); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2FARBPROC) (GLenum target, GLfloat s, GLfloat t); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2IARBPROC) (GLenum target, GLint s, GLint t); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2SARBPROC) (GLenum target, GLshort s, GLshort t); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD2SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3IARBPROC) (GLenum target, GLint s, GLint t, GLint r); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD3SVARBPROC) (GLenum target, const GLshort *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4DARBPROC) (GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4DVARBPROC) (GLenum target, const GLdouble *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4FARBPROC) (GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4FVARBPROC) (GLenum target, const GLfloat *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4IARBPROC) (GLenum target, GLint s, GLint t, GLint r, GLint q); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4IVARBPROC) (GLenum target, const GLint *v); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4SARBPROC) (GLenum target, GLshort s, GLshort t, GLshort r, GLshort q); -typedef void (APIENTRY * NEL_PFNGLMULTITEXCOORD4SVARBPROC) (GLenum target, const GLshort *v); - #if defined(NL_OS_MAC) // Mac GL extensions diff --git a/code/nel/src/3d/driver/opengl3/driver_opengl_states.cpp b/code/nel/src/3d/driver/opengl3/driver_opengl_states.cpp index b5ad0e9b5..3f72abfce 100644 --- a/code/nel/src/3d/driver/opengl3/driver_opengl_states.cpp +++ b/code/nel/src/3d/driver/opengl3/driver_opengl_states.cpp @@ -137,7 +137,7 @@ void CDriverGLStates3::forceDefaults(uint nbStages) for (stage=0;stage