diff options
author | marha <marha@users.sourceforge.net> | 2011-07-26 12:48:28 +0200 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-07-26 12:48:28 +0200 |
commit | dc23661fa1d58aa98d67fae47a919de452b8cd28 (patch) | |
tree | 0a8c7987f3756290e3ba9cfb8cdf23d6e9532037 /mesalib/src/glsl/main.cpp | |
parent | 8680f93ff96770b0a022596d8d4092a29c586435 (diff) | |
parent | ece07bdeaa82ea59e74bcfc588bcabe5e47567c1 (diff) | |
download | vcxsrv-dc23661fa1d58aa98d67fae47a919de452b8cd28.tar.gz vcxsrv-dc23661fa1d58aa98d67fae47a919de452b8cd28.tar.bz2 vcxsrv-dc23661fa1d58aa98d67fae47a919de452b8cd28.zip |
Merge remote-tracking branch 'origin/released'
Conflicts:
libX11/specs/libX11/CH11.xml
mesalib/src/glsl/main.cpp
mesalib/src/mesa/main/compiler.h
mesalib/src/mesa/main/get.c
mesalib/src/mesa/main/texcompress.c
mesalib/src/mesa/main/texparam.c
mesalib/src/mesa/program/ir_to_mesa.cpp
mesalib/src/mesa/program/prog_optimize.c
pixman/pixman/pixman-fast-path.c
pixman/pixman/pixman-fast-path.h
xorg-server/hw/xquartz/GL/indirect.c
xorg-server/hw/xquartz/X11Application.h
xorg-server/hw/xquartz/X11Application.m
xorg-server/hw/xquartz/bundle/Resources/French.lproj/locversion.plist
xorg-server/hw/xquartz/bundle/Resources/French.lproj/main.nib/designable.nib
xorg-server/hw/xquartz/bundle/Resources/German.lproj/locversion.plist
xorg-server/hw/xquartz/bundle/Resources/German.lproj/main.nib/designable.nib
xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/locversion.plist
xorg-server/hw/xquartz/bundle/Resources/Japanese.lproj/main.nib/designable.nib
xorg-server/hw/xquartz/darwinEvents.c
xorg-server/hw/xquartz/darwinEvents.h
xorg-server/hw/xquartz/man/Xquartz.man
xorg-server/hw/xquartz/xpr/dri.c
xorg-server/xkeyboard-config/symbols/ee
Diffstat (limited to 'mesalib/src/glsl/main.cpp')
-rw-r--r-- | mesalib/src/glsl/main.cpp | 60 |
1 files changed, 3 insertions, 57 deletions
diff --git a/mesalib/src/glsl/main.cpp b/mesalib/src/glsl/main.cpp index 54c7099f9..900879638 100644 --- a/mesalib/src/glsl/main.cpp +++ b/mesalib/src/glsl/main.cpp @@ -40,80 +40,26 @@ #include "ir_print_visitor.h"
#include "program.h"
#include "loop_analysis.h"
-
-extern "C" struct gl_shader *
-_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type);
-
-extern "C" void
-_mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr,
- struct gl_shader *sh);
-
-/* Copied from shader_api.c for the stand-alone compiler.
- */
-void
-_mesa_reference_shader(struct gl_context *ctx, struct gl_shader **ptr,
- struct gl_shader *sh)
-{
- *ptr = sh;
-}
-
-struct gl_shader *
-_mesa_new_shader(struct gl_context *ctx, GLuint name, GLenum type)
-{
- struct gl_shader *shader;
-
- (void) ctx;
-
- assert(type == GL_FRAGMENT_SHADER || type == GL_VERTEX_SHADER);
- shader = rzalloc(NULL, struct gl_shader);
- if (shader) {
- shader->Type = type;
- shader->Name = name;
- shader->RefCount = 1;
- }
- return shader;
-}
+#include "standalone_scaffolding.h"
static void
initialize_context(struct gl_context *ctx, gl_api api)
{
- memset(ctx, 0, sizeof(*ctx));
-
- ctx->API = api;
-
- ctx->Extensions.ARB_ES2_compatibility = GL_TRUE;
- ctx->Extensions.ARB_draw_buffers = GL_TRUE;
- ctx->Extensions.ARB_draw_instanced = GL_TRUE;
- ctx->Extensions.ARB_fragment_coord_conventions = GL_TRUE;
- ctx->Extensions.EXT_texture_array = GL_TRUE;
- ctx->Extensions.NV_texture_rectangle = GL_TRUE;
- ctx->Extensions.EXT_texture3D = GL_TRUE;
+ initialize_context_to_defaults(ctx, api);
/* GLSL 1.30 isn't fully supported, but we need to advertise 1.30 so that
* the built-in functions for 1.30 can be built.
*/
ctx->Const.GLSLVersion = 130;
- /* 1.10 minimums. */
- ctx->Const.MaxLights = 8;
ctx->Const.MaxClipPlanes = 8;
- ctx->Const.MaxTextureUnits = 2;
+ ctx->Const.MaxDrawBuffers = 2;
/* More than the 1.10 minimum to appease parser tests taken from
* apps that (hopefully) already checked the number of coords.
*/
ctx->Const.MaxTextureCoordUnits = 4;
- ctx->Const.VertexProgram.MaxAttribs = 16;
- ctx->Const.VertexProgram.MaxUniformComponents = 512;
- ctx->Const.MaxVarying = 8;
- ctx->Const.MaxVertexTextureImageUnits = 0;
- ctx->Const.MaxCombinedTextureImageUnits = 2;
- ctx->Const.MaxTextureImageUnits = 2;
- ctx->Const.FragmentProgram.MaxUniformComponents = 64;
-
- ctx->Const.MaxDrawBuffers = 2;
-
ctx->Driver.NewShader = _mesa_new_shader;
}
|