/diverses/stuff/work/glslShader-0.0.1/glslShader.h

00001 /***************************************************************************
00002  * GLSL - Utilities                                                        *
00003  *                                                                         *
00004  * This library provide simple using of glsl-Language in your              *
00005  * appliations. Syntax is similar to CG's one.                             *
00006  *                                                                         *
00007  *                                                                         *
00008  *   (c) Art Tevs, MPI Informatik Saarbruecken                             *
00009  *       mailto: <tevs@mpi-sb.mpg.de>                                      *
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  **************************************************************************/
00017 
00018 #ifndef _GLSL_SHADER_H_
00019 #define _GLSL_SHADER_H_
00020 
00021 #ifdef __cplusplus
00022 extern "C" {
00023 #endif /* __cplusplus */
00024 
00025 
00026 /* Platform configuration script */
00027 #include "glslTypes.h"
00028 
00029 
00056 GLSLAPI void GLSLAPIENTRY glslPush();
00057 
00058 
00064 GLSLAPI void GLSLAPIENTRY glslPop();
00065 
00066 
00074 GLSLAPI GLSLprogram GLSLAPIENTRY glslCreateProgram();
00075 
00076 
00077 
00092 GLSLAPI void GLSLAPIENTRY       glslAttachShader(GLSLprogram obj, const char* filename, GLSL_ShaderType shaderType);
00093 
00094 
00100 GLSLAPI void GLSLAPIENTRY       glslAttachVertexShader(GLSLprogram obj, const char* filename);
00101 
00107 GLSLAPI void GLSLAPIENTRY       glslAttachFragmentShader(GLSLprogram obj, const char* filename);
00108 
00120 GLSLAPI void GLSLAPIENTRY       glslAttachShaderFromMemory(GLSLprogram obj, const char* prog, size_t size, GLSL_ShaderType shaderType);
00121 
00122 
00128 GLSLAPI void GLSLAPIENTRY       glslAttachVertexShaderFromMemory(GLSLprogram obj, const char* prog, size_t size);
00129 
00135 GLSLAPI void GLSLAPIENTRY       glslAttachFragmentShaderFromMemory(GLSLprogram obj, const char* prog, size_t size);
00136 
00137 
00150 GLSLAPI void GLSLAPIENTRY       glslLinkProgram(GLSLprogram obj);
00151 
00152 
00158 GLSLAPI void GLSLAPIENTRY       glslDeleteProgram(GLSLprogram obj);
00159 
00160 
00166 GLSLAPI void GLSLAPIENTRY       glslEnableProgram(GLSLprogram obj);
00167 
00168 
00175 GLSLAPI void GLSLAPIENTRY       glslDisableProgram(GLSLprogram obj);
00176 
00177 
00182 GLSLAPI void GLSLAPIENTRY       glslDisable();
00183 
00184 
00185 
00186 /*---------------------------------------------------------------------------------*/
00187 /* Error Handling                                                                  */
00188 /*---------------------------------------------------------------------------------*/
00189 
00196 GLSLAPI const char* GLSLAPIENTRY        glslGetLastErrorString();
00197 
00198 
00203 GLSLAPI void GLSLAPIENTRY       glslSetErrorCallback(GLSLerrorCallback pCallback, void* callbackParam);
00204 
00205 
00210 GLSLAPI GLSLbool GLSLAPIENTRY   glslHasError();
00211 
00212 
00213 
00214 /*---------------------------------------------------------------------------------*/
00215 /* Parameter Handling                                                              */
00216 /*---------------------------------------------------------------------------------*/
00217 
00229 GLSLAPI void GLSLAPIENTRY       glslBindAttribute(GLSLprogram obj, GLSLint32 attrIndex, char* name);
00230 
00231 
00239 GLSLAPI GLSLint32 GLSLAPIENTRY  glslGetUniformParameterCount(GLSLprogram obj);
00240 
00241 
00258 GLSLAPI void GLSLAPIENTRY       glslSetParameterf(GLSLprogram obj, const char* name, GLSLint8 size, const GLSLfloat32* value);
00259 
00260 
00266 GLSLAPI void GLSLAPIENTRY       glslSetParameter1f(GLSLprogram obj, const char* name, const GLSLfloat32 value);
00267 
00268 
00274 GLSLAPI void GLSLAPIENTRY       glslSetParameter2f(GLSLprogram obj, const char* name, const GLSLfloat32* value);
00275 
00276 
00282 GLSLAPI void GLSLAPIENTRY       glslSetParameter3f(GLSLprogram obj, const char* name, const GLSLfloat32* value);
00283 
00284 
00290 GLSLAPI void GLSLAPIENTRY       glslSetParameter4f(GLSLprogram obj, const char* name, const GLSLfloat32* value);
00291 
00300 GLSLAPI void GLSLAPIENTRY       glslSetParameteri(GLSLprogram obj, const char* name, GLSLint8 size, const GLSLint32* value);
00301 
00302 
00308 GLSLAPI void GLSLAPIENTRY       glslSetParameter1i(GLSLprogram obj, const char* name, const GLSLint32 value);
00309 
00310 
00316 GLSLAPI void GLSLAPIENTRY       glslSetParameter2i(GLSLprogram obj, const char* name, const GLSLint32* value);
00317 
00318 
00324 GLSLAPI void GLSLAPIENTRY       glslSetParameter3i(GLSLprogram obj, const char* name, const GLSLint32* value);
00325 
00326 
00332 GLSLAPI void GLSLAPIENTRY       glslSetParameter4i(GLSLprogram obj, const char* name, const GLSLint32* value);
00333 
00334 
00335 
00349 GLSLAPI void GLSLAPIENTRY       glslSetMatrixParameter(GLSLprogram obj, const char* name, GLSLint8 size, const GLSLfloat32* mat, GLSLbool trans);
00350 
00351 
00352 
00358 GLSLAPI void GLSLAPIENTRY       glslSetMatrixParameter4(GLSLprogram obj, const char* name, const GLSLfloat32* mat, GLSLbool trans);
00359 
00365 GLSLAPI void GLSLAPIENTRY       glslSetMatrixParameter9(GLSLprogram obj, const char* name, const GLSLfloat32* mat, GLSLbool trans);
00366 
00367 
00373 GLSLAPI void GLSLAPIENTRY       glslSetMatrixParameter16(GLSLprogram obj, const char* name, const GLSLfloat32* mat, GLSLbool trans);
00374 
00375 
00386 GLSLAPI void GLSLAPIENTRY       glslSetTexture(GLSLprogram obj, const char* name, GLSLuint32 texture_unit);
00387 
00388 
00396 GLSLAPI GLint GLSLAPIENTRY       glslGetUniformLocation(GLuint active_program, const char *name);
00397 
00407 GLSLAPI void GLSLAPIENTRY         glslCreateProgram_Quick(GLSLprogram *new_program, char *vshader_filename, char *fshader_filename);
00408 
00409 
00410 #ifdef __cplusplus
00411 }
00412 #endif /* __cplusplus */
00413 
00414 #endif
00415 

Generated on Sat Apr 7 18:49:42 2007 for glslShader by  doxygen 1.5.1