From: havoc Date: Fri, 31 Mar 2006 03:38:34 +0000 (+0000) Subject: print out the contents of the GLSL shader when it is compiled when using developer... X-Git-Tag: xonotic-v0.1.0preview~4113 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=fc176f61fe918c379677fd62dadb1beae59dfce8;p=xonotic%2Fdarkplaces.git print out the contents of the GLSL shader when it is compiled when using developer 100 or higher git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@6216 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/gl_backend.c b/gl_backend.c index 16e4377d..c32162a4 100644 --- a/gl_backend.c +++ b/gl_backend.c @@ -724,6 +724,26 @@ unsigned int GL_Backend_CompileProgram(int vertexstrings_count, const char **ver if (!programobject) return 0; + if (developer.integer >= 100) + { + int i; + Con_Printf("Compiling shader:\n"); + if (vertexstrings_count) + { + Con_Printf("------ VERTEX SHADER ------\n"); + for (i = 0;i < vertexstrings_count;i++) + Con_Print(vertexstrings_list[i]); + Con_Print("\n"); + } + if (fragmentstrings_count) + { + Con_Printf("------ FRAGMENT SHADER ------\n"); + for (i = 0;i < fragmentstrings_count;i++) + Con_Print(fragmentstrings_list[i]); + Con_Print("\n"); + } + } + if (vertexstrings_count) { CHECKGLERROR