mirror of
https://github.com/YGGverse/xash3d-fwgs.git
synced 2025-01-12 16:18:01 +00:00
ref_gl: add missing non-arb shader functions
This commit is contained in:
parent
2f321b1471
commit
e23b632ce5
@ -355,16 +355,22 @@ static gl2wrap_prog_t *GL2_GetProg( const GLuint flags )
|
||||
pglDeleteObjectARB( fp );
|
||||
|
||||
/// TODO: detect arb/core shaders in engine
|
||||
#if 0 //ndef XASH_GLES
|
||||
|
||||
if( pglProgramiv )
|
||||
pglProgramiv( glprog, GL_OBJECT_LINK_STATUS_ARB, &status );
|
||||
else
|
||||
pglGetObjectParameterivARB( glprog, GL_OBJECT_LINK_STATUS_ARB, &status );
|
||||
if ( status == GL_FALSE )
|
||||
{
|
||||
gEngfuncs.Con_Reportf( S_ERROR "GL2_GetProg(): Failed linking progs for 0x%04x!\n%s\n", prog->flags, GL_PrintInfoLog(glprog) );
|
||||
prog->flags = 0;
|
||||
if( pglDeleteProgram )
|
||||
pglDeleteProgram( glprog );
|
||||
else
|
||||
pglDeleteObjectARB( glprog );
|
||||
return NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
prog->ucolor = pglGetUniformLocationARB( glprog, "uColor" );
|
||||
prog->ualpha = pglGetUniformLocationARB( glprog, "uAlphaTest" );
|
||||
|
@ -1366,6 +1366,10 @@ APIENTRY_LINKAGE void GL_FUNCTION( glGenVertexArrays )( GLsizei n, const GLuint
|
||||
APIENTRY_LINKAGE GLboolean GL_FUNCTION( glIsVertexArray )( GLuint array );
|
||||
APIENTRY_LINKAGE void GL_FUNCTION( glSwapInterval ) ( int interval );
|
||||
|
||||
APIENTRY_LINKAGE void GL_FUNCTION( glDeleteProgram )(GLuint program);
|
||||
APIENTRY_LINKAGE void GL_FUNCTION( glProgramiv )(GLuint program, GLenum e, GLuint *v);
|
||||
|
||||
|
||||
#if !defined( XASH_GL_STATIC ) || (!defined( XASH_GLES ) && !defined( XASH_GL4ES ))
|
||||
APIENTRY_LINKAGE void GL_FUNCTION( glTexImage2DMultisample )(GLenum target, GLsizei samples, GLenum internalformat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
|
||||
#endif /* !XASH_GLES && !XASH_GL4ES */
|
||||
|
@ -354,6 +354,8 @@ static dllfunc_t shaderobjectsfuncs_gles[] =
|
||||
{ "glVertexAttrib2f" , (void **)&pglVertexAttrib2fARB },
|
||||
{ "glVertexAttrib2fv" , (void **)&pglVertexAttrib2fvARB },
|
||||
{ "glVertexAttrib3fv" , (void **)&pglVertexAttrib3fvARB },
|
||||
{ "glProgramiv" , (void**)&pglProgramiv },
|
||||
{ "glDeleteProgram" , (void**)&pglDeleteProgram },
|
||||
//{ "glVertexAttrib4f" , (void **)&pglVertexAttrib4fARB },
|
||||
//{ "glVertexAttrib4fv" , (void **)&pglVertexAttrib4fvARB },
|
||||
//{ "glVertexAttrib4ubv" , (void **)&pglVertexAttrib4ubvARB },
|
||||
|
Loading…
Reference in New Issue
Block a user