From dd9742dc9ffc976d3caae87c1302b7b5ed7d3838 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 24 Feb 2009 14:30:51 -0700 Subject: mesa: use quotes for #include --- src/mesa/main/glheader.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/glheader.h b/src/mesa/main/glheader.h index 482a36de93..ad095321e3 100644 --- a/src/mesa/main/glheader.h +++ b/src/mesa/main/glheader.h @@ -52,7 +52,7 @@ #define GL_GLEXT_PROTOTYPES #include "GL/gl.h" #include "GL/glext.h" -#include +#include "GL/internal/glcore.h" #ifndef GL_FIXED -- cgit v1.2.3 From bfdbbfb0251bcd17c1a559668d0f4a0d36847a84 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 24 Feb 2009 17:53:39 -0700 Subject: mesa: fix merge conflict (in comment) --- src/mesa/main/version.h | 4 ---- 1 file changed, 4 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/version.h b/src/mesa/main/version.h index 9287e8515c..f5bf6e2c85 100644 --- a/src/mesa/main/version.h +++ b/src/mesa/main/version.h @@ -1,10 +1,6 @@ /* * Mesa 3-D graphics library -<<<<<<< HEAD:src/mesa/main/version.h * Version: 7.5 -======= - * Version: 7.4 ->>>>>>> origin/gallium-0.2:src/mesa/main/version.h * * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. * -- cgit v1.2.3 From 857ac1e817808f4b6bf985679162d0e3d709e5b5 Mon Sep 17 00:00:00 2001 From: "David S. Miller" Date: Thu, 26 Feb 2009 05:35:15 -0800 Subject: mesa: Resurrect SPARC asm code. This rewrites the sparc GLAPI code so that it's PIC friendly and works with all of the TLS/PTHREADS/64-bit/32-bit combinations properly. As a result we can turn SPARC asm back on. Currently it's only enabled on Linux, as that's the only place where I can test this stuff out. For the moment the cliptest SPARC asm routines are disabled as they are non-working. The problem is that they use register %g7 as a temporary which is where the threading libraries store the thread pointer on SPARC. I will fix that code up in a future change as it's a pretty important routine to optimize. Like x86 we do the runtime patch as a pthread once-invoked initializer in init_glapi_relocs(). Unlike x86, however, our GLAPI stubs on SPARC are just two instruction sequences that branch to a trampoline and put the GLAPI offset into a register. The trampoline is what we run-time patch. The stubs thus all look like: glFoo: ba __glapi_sparc_foo_stub sethi GLAPI_OFFSET(glFOO) * PTR_SIZE, %g3 This actually makes generate_entrypoint() a lot simpler on SPARC. For this case in generate_entrypoint() we generate stubs using a 'call' instead of the 'ba' above to make sure it can reach. In order to get a proper tail call going here, in the unpatched case, we do several tricks. To get the current PC, for example, we save the return address register into a temporary, do a call, save the return address register written by the call to another temporary, then restore the original return address register value. This is to avoid having to allocate a stack frame. This is necessary for PIC address formation. This new GLAPI scheme lets us get rid of the ugly SPARC GLAPI hacks in __glXInitialize() and one_time_init(). Signed-off-by: David S. Miller --- configure.ac | 13 + src/glx/x11/glxext.c | 86 --- src/mesa/glapi/gl_SPARC_asm.py | 228 ++++-- src/mesa/glapi/glapi.c | 131 ++++ src/mesa/glapi/glapi_getproc.c | 78 +- src/mesa/main/context.c | 3 - src/mesa/sparc/glapi_sparc.S | 1645 +++++++++++++--------------------------- src/mesa/sparc/sparc.c | 38 +- src/mesa/sparc/sparc.h | 1 - 9 files changed, 891 insertions(+), 1332 deletions(-) (limited to 'src/mesa/main') diff --git a/configure.ac b/configure.ac index a57e5b3ea7..2f3f0beff1 100644 --- a/configure.ac +++ b/configure.ac @@ -307,6 +307,13 @@ if test "x$enable_asm" = xyes; then ;; esac ;; + sparc*) + case "$host_os" in + linux*) + asm_arch=sparc + ;; + esac + ;; esac case "$asm_arch" in @@ -327,6 +334,12 @@ if test "x$enable_asm" = xyes; then MESA_ASM_SOURCES='$(PPC_SOURCES)' AC_MSG_RESULT([yes, ppc]) ;; + sparc) + ASM_FLAGS="-DUSE_SPARC_ASM" + MESA_ASM_SOURCES='$(SPARC_SOURCES)' + GLAPI_ASM_SOURCES='$(SPARC_API)' + AC_MSG_RESULT([yes, sparc]) + ;; *) AC_MSG_RESULT([no, platform not supported]) ;; diff --git a/src/glx/x11/glxext.c b/src/glx/x11/glxext.c index be6edf9b19..b296b7c651 100644 --- a/src/glx/x11/glxext.c +++ b/src/glx/x11/glxext.c @@ -56,19 +56,6 @@ void __glXDumpDrawBuffer(__GLXcontext * ctx); #endif -#ifdef USE_SPARC_ASM -static void _glx_mesa_init_sparc_glapi_relocs(void); -static int _mesa_sparc_needs_init = 1; -#define INIT_MESA_SPARC do { \ - if (_mesa_sparc_needs_init) { \ - _glx_mesa_init_sparc_glapi_relocs(); \ - _mesa_sparc_needs_init = 0; \ - } \ - } while(0) -#else -#define INIT_MESA_SPARC do { } while(0) -#endif - /* ** You can set this cell to 1 to force the gl drawing stuff to be ** one command per packet @@ -670,7 +657,6 @@ __glXInitialize(Display * dpy) } #endif - INIT_MESA_SPARC; /* The one and only long long lock */ __glXLock(); @@ -785,7 +771,6 @@ __glXSetupForCommand(Display * dpy) if (gc->currentDpy == dpy) { /* Use opcode from gc because its right */ - INIT_MESA_SPARC; return gc->majorOpcode; } else { @@ -979,74 +964,3 @@ __glXDumpDrawBuffer(__GLXcontext * ctx) } } #endif - -#ifdef USE_SPARC_ASM -/* - * This is where our dispatch table's bounds are. - * And the static mesa_init is taken directly from - * Mesa's 'sparc.c' initializer. - * - * We need something like this here, because this version - * of openGL/glx never initializes a Mesa context, and so - * the address of the dispatch table pointer never gets stuffed - * into the dispatch jump table otherwise. - * - * It matters only on SPARC, and only if you are using assembler - * code instead of C-code indirect dispatch. - * - * -- FEM, 04.xii.03 - */ -extern unsigned int _mesa_sparc_glapi_begin; -extern unsigned int _mesa_sparc_glapi_end; -extern void __glapi_sparc_icache_flush(unsigned int *); - -static void -_glx_mesa_init_sparc_glapi_relocs(void) -{ - unsigned int *insn_ptr, *end_ptr; - unsigned long disp_addr; - - insn_ptr = &_mesa_sparc_glapi_begin; - end_ptr = &_mesa_sparc_glapi_end; - disp_addr = (unsigned long) &_glapi_Dispatch; - - /* - * Verbatim from Mesa sparc.c. It's needed because there doesn't - * seem to be a better way to do this: - * - * UNCONDITIONAL_JUMP ( (*_glapi_Dispatch) + entry_offset ) - * - * This code is patching in the ADDRESS of the pointer to the - * dispatch table. Hence, it must be called exactly once, because - * that address is not going to change. - * - * What it points to can change, but Mesa (and hence, we) assume - * that there is only one pointer. - * - */ - while (insn_ptr < end_ptr) { -#if ( defined(__sparc_v9__) && ( !defined(__linux__) || defined(__linux_64__) ) ) -/* - This code patches for 64-bit addresses. This had better - not happen for Sparc/Linux, no matter what architecture we - are building for. So, don't do this. - - The 'defined(__linux_64__)' is used here as a placeholder for - when we do do 64-bit usermode on sparc linux. - */ - insn_ptr[0] |= (disp_addr >> (32 + 10)); - insn_ptr[1] |= ((disp_addr & 0xffffffff) >> 10); - __glapi_sparc_icache_flush(&insn_ptr[0]); - insn_ptr[2] |= ((disp_addr >> 32) & ((1 << 10) - 1)); - insn_ptr[3] |= (disp_addr & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&insn_ptr[2]); - insn_ptr += 11; -#else - insn_ptr[0] |= (disp_addr >> 10); - insn_ptr[1] |= (disp_addr & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&insn_ptr[0]); - insn_ptr += 5; -#endif - } -} -#endif /* sparc ASM in use */ diff --git a/src/mesa/glapi/gl_SPARC_asm.py b/src/mesa/glapi/gl_SPARC_asm.py index 178c00a227..33e752df38 100644 --- a/src/mesa/glapi/gl_SPARC_asm.py +++ b/src/mesa/glapi/gl_SPARC_asm.py @@ -39,80 +39,202 @@ class PrintGenericStubs(gl_XML.gl_print_base): def printRealHeader(self): - print '#include "glapioffsets.h"' + print '#include "glapi/glapioffsets.h"' print '' print '#ifdef __arch64__' - print '# define GL_STUB(fn,off)\t\t\t\t\\' - print 'fn:\t\t\t\t\t\\' - print '\tsethi\t%hi(0xDEADBEEF), %g4 ;\t\t\t\\' - print '\tsethi\t%hi(0xDEADBEEF), %g1 ;\t\t\t\\' - print '\tor\t%g4, %lo(0xDEADBEEF), %g4 ;\t\t\\' - print '\tor\t%g1, %lo(0xDEADBEEF), %g1 ;\t\t\\' - print '\tsllx\t%g4, 32, %g4 ;\t\t\t\t\\' - print '\tldx\t[%g1 + %g4], %g1 ;\t\t\t\\' - print '\tsethi\t%hi(8 * off), %g4 ;\t\t\t\\' - print '\tor\t%g4, %lo(8 * off), %g4 ;\t\t\\' - print '\tldx\t[%g1 + %g4], %g5 ;\t\t\t\\' - print '\tjmpl\t%g5, %g0 ;\t\t\t\t\\' - print '\tnop' + print '#define GL_OFF(N)\t((N) * 8)' + print '#define GL_LL\t\tldx' + print '#define GL_TIE_LD(SYM)\t%tie_ldx(SYM)' + print '#define GL_STACK_SIZE\t128' print '#else' - print '# define GL_STUB(fn,off)\t\t\t\t\\' - print 'fn:\t\t\t\t\t\\' - print '\tsethi\t%hi(0xDEADBEEF), %g1 ;\t\t\t\\' - print '\tld\t[%g1 + %lo(0xDEADBEEF)], %g1 ;\t\t\\' - print '\tld\t[%g1 + (4 * off)], %g5 ;\t\t\\' - print '\tjmpl\t%g5, %g0 ;\t\t\t\t\\' - print '\tnop' + print '#define GL_OFF(N)\t((N) * 4)' + print '#define GL_LL\t\tld' + print '#define GL_TIE_LD(SYM)\t%tie_ld(SYM)' + print '#define GL_STACK_SIZE\t64' print '#endif' print '' - print '#define GL_STUB_ALIAS(fn,alias) fn = alias' + print '#define GLOBL_FN(x) .globl x ; .type x, @function' + print '#define HIDDEN(x) .hidden x' print '' - print '.text' - print '.align 32' - print '\t\t.globl __glapi_sparc_icache_flush ; .type __glapi_sparc_icache_flush,#function' + print '\t.register %g2, #scratch' + print '\t.register %g3, #scratch' + print '' + print '\t.text' + print '' + print '\tGLOBL_FN(__glapi_sparc_icache_flush)' + print '\tHIDDEN(__glapi_sparc_icache_flush)' + print '\t.type\t__glapi_sparc_icache_flush, @function' print '__glapi_sparc_icache_flush: /* %o0 = insn_addr */' print '\tflush\t%o0' print '\tretl' - print '\tnop' + print '\t nop' + print '' + print '\t.align\t32' + print '' + print '\t.type\t__glapi_sparc_get_pc, @function' + print '__glapi_sparc_get_pc:' + print '\tretl' + print '\t add\t%o7, %g2, %g2' + print '\t.size\t__glapi_sparc_get_pc, .-__glapi_sparc_get_pc' + print '' + print '#ifdef GLX_USE_TLS' + print '' + print '\tGLOBL_FN(__glapi_sparc_get_dispatch)' + print '\tHIDDEN(__glapi_sparc_get_dispatch)' + print '__glapi_sparc_get_dispatch:' + print '\tmov\t%o7, %g1' + print '\tsethi\t%hi(_GLOBAL_OFFSET_TABLE_-4), %g2' + print '\tcall\t__glapi_sparc_get_pc' + print '\tadd\t%g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2' + print '\tmov\t%g1, %o7' + print '\tsethi\t%tie_hi22(_glapi_tls_Dispatch), %g1' + print '\tadd\t%g1, %tie_lo10(_glapi_tls_Dispatch), %g1' + print '\tGL_LL\t[%g2 + %g1], %g2, GL_TIE_LD(_glapi_tls_Dispatch)' + print '\tretl' + print '\t mov\t%g2, %o0' + print '' + print '\t.data' + print '\t.align\t32' + print '' + print '\t/* --> sethi %hi(_glapi_tls_Dispatch), %g1 */' + print '\t/* --> or %g1, %lo(_glapi_tls_Dispatch), %g1 */' + print '\tGLOBL_FN(__glapi_sparc_tls_stub)' + print '\tHIDDEN(__glapi_sparc_tls_stub)' + print '__glapi_sparc_tls_stub: /* Call offset in %g3 */' + print '\tmov\t%o7, %g1' + print '\tsethi\t%hi(_GLOBAL_OFFSET_TABLE_-4), %g2' + print '\tcall\t__glapi_sparc_get_pc' + print '\tadd\t%g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2' + print '\tmov\t%g1, %o7' + print '\tsrl\t%g3, 10, %g3' + print '\tsethi\t%tie_hi22(_glapi_tls_Dispatch), %g1' + print '\tadd\t%g1, %tie_lo10(_glapi_tls_Dispatch), %g1' + print '\tGL_LL\t[%g2 + %g1], %g2, GL_TIE_LD(_glapi_tls_Dispatch)' + print '\tGL_LL\t[%g7+%g2], %g1' + print '\tGL_LL\t[%g1 + %g3], %g1' + print '\tjmp\t%g1' + print '\t nop' + print '\t.size\t__glapi_sparc_tls_stub, .-__glapi_sparc_tls_stub' + print '' + print '#define GL_STUB(fn, off)\t\t\t\t\\' + print '\tGLOBL_FN(fn);\t\t\t\t\t\\' + print 'fn:\tba\t__glapi_sparc_tls_stub;\t\t\t\\' + print '\t sethi\tGL_OFF(off), %g3;\t\t\t\\' + print '\t.size\tfn,.-fn;' + print '' + print '#elif defined(PTHREADS)' + print '' + print '\t/* 64-bit 0x00 --> sethi %hh(_glapi_Dispatch), %g1 */' + print '\t/* 64-bit 0x04 --> sethi %lm(_glapi_Dispatch), %g2 */' + print '\t/* 64-bit 0x08 --> or %g1, %hm(_glapi_Dispatch), %g1 */' + print '\t/* 64-bit 0x0c --> sllx %g1, 32, %g1 */' + print '\t/* 64-bit 0x10 --> add %g1, %g2, %g1 */' + print '\t/* 64-bit 0x14 --> ldx [%g1 + %lo(_glapi_Dispatch)], %g1 */' + print '' + print '\t/* 32-bit 0x00 --> sethi %hi(_glapi_Dispatch), %g1 */' + print '\t/* 32-bit 0x04 --> ld [%g1 + %lo(_glapi_Dispatch)], %g1 */' + print '' + print '\t.data' + print '\t.align\t32' + print '' + print '\tGLOBL_FN(__glapi_sparc_pthread_stub)' + print '\tHIDDEN(__glapi_sparc_pthread_stub)' + print '__glapi_sparc_pthread_stub: /* Call offset in %g3 */' + print '\tmov\t%o7, %g1' + print '\tsethi\t%hi(_GLOBAL_OFFSET_TABLE_-4), %g2' + print '\tcall\t__glapi_sparc_get_pc' + print '\t add\t%g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2' + print '\tmov\t%g1, %o7' + print '\tsethi\t%hi(_glapi_Dispatch), %g1' + print '\tor\t%g1, %lo(_glapi_Dispatch), %g1' + print '\tsrl\t%g3, 10, %g3' + print '\tGL_LL\t[%g2+%g1], %g2' + print '\tGL_LL\t[%g2], %g1' + print '\tcmp\t%g1, 0' + print '\tbe\t2f' + print '\t nop' + print '1:\tGL_LL\t[%g1 + %g3], %g1' + print '\tjmp\t%g1' + print '\t nop' + print '2:\tsave\t%sp, GL_STACK_SIZE, %sp' + print '\tmov\t%g3, %l0' + print '\tcall\t_glapi_get_dispatch' + print '\t nop' + print '\tmov\t%o0, %g1' + print '\tmov\t%l0, %g3' + print '\tba\t1b' + print '\t restore %g0, %g0, %g0' + print '\t.size\t__glapi_sparc_pthread_stub, .-__glapi_sparc_pthread_stub' + print '' + print '#define GL_STUB(fn, off)\t\t\t\\' + print '\tGLOBL_FN(fn);\t\t\t\t\\' + print 'fn:\tba\t__glapi_sparc_pthread_stub;\t\\' + print '\t sethi\tGL_OFF(off), %g3;\t\t\\' + print '\t.size\tfn,.-fn;' + print '' + print '#else /* Non-threaded version. */' print '' - print '.data' - print '.align 64' + print '\t.type __glapi_sparc_nothread_stub, @function' + print '__glapi_sparc_nothread_stub: /* Call offset in %g3 */' + print '\tmov\t%o7, %g1' + print '\tsethi\t%hi(_GLOBAL_OFFSET_TABLE_-4), %g2' + print '\tcall\t__glapi_sparc_get_pc' + print '\t add\t%g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2' + print '\tmov\t%g1, %o7' + print '\tsrl\t%g3, 10, %g3' + print '\tsethi\t%hi(_glapi_Dispatch), %g1' + print '\tor\t%g1, %lo(_glapi_Dispatch), %g1' + print '\tGL_LL\t[%g2+%g1], %g2' + print '\tGL_LL\t[%g2], %g1' + print '\tGL_LL\t[%g1 + %g3], %g1' + print '\tjmp\t%g1' + print '\t nop' + print '\t.size\t__glapi_sparc_nothread_stub, .-__glapi_sparc_nothread_stub' + print '' + print '#define GL_STUB(fn, off)\t\t\t\\' + print '\tGLOBL_FN(fn);\t\t\t\t\\' + print 'fn:\tba\t__glapi_sparc_nothread_stub;\t\\' + print '\t sethi\tGL_OFF(off), %g3;\t\t\\' + print '\t.size\tfn,.-fn;' + print '' + print '#endif' + print '' + print '#define GL_STUB_ALIAS(fn, alias) \\' + print ' .globl fn; \\' + print ' .set fn, alias' + print '' + print '\t.text' + print '\t.align\t32' + print '' + print '\t.globl\tgl_dispatch_functions_start' + print '\tHIDDEN(gl_dispatch_functions_start)' + print 'gl_dispatch_functions_start:' print '' return + def printRealFooter(self): + print '' + print '\t.globl\tgl_dispatch_functions_end' + print '\tHIDDEN(gl_dispatch_functions_end)' + print 'gl_dispatch_functions_end:' + return def printBody(self, api): for f in api.functionIterateByOffset(): - if f.is_static_entry_point(f.name): - name = f.name - else: - name = "_dispatch_stub_%u" % (f.offset) + name = f.dispatch_name() - print '\t\t.globl gl%s ; .type gl%s,#function' % (name, name) + print '\tGL_STUB(gl%s, _gloffset_%s)' % (name, f.name) - print '\t\t.globl _mesa_sparc_glapi_begin ; .type _mesa_sparc_glapi_begin,#function' - print '_mesa_sparc_glapi_begin:' - print '' + if not f.is_static_entry_point(f.name): + print '\tHIDDEN(gl%s)' % (name) for f in api.functionIterateByOffset(): - if f.is_static_entry_point(f.name): - name = f.name - else: - name = "_dispatch_stub_%u" % (f.offset) - - print '\tGL_STUB(gl%s, _gloffset_%s)' % (name, name) + name = f.dispatch_name() - print '' - print '\t\t.globl _mesa_sparc_glapi_end ; .type _mesa_sparc_glapi_end,#function' - print '_mesa_sparc_glapi_end:' - print '' - - - for f in api.functionIterateByOffset(): - for n in f.entry_points: - if n != f.name: - if f.is_static_entry_point(n): - text = '\t.globl gl%s ; .type gl%s,#function ; gl%s = gl%s' % (n, n, n, f.name) + if f.is_static_entry_point(f.name): + for n in f.entry_points: + if n != f.name: + text = '\tGL_STUB_ALIAS(gl%s, gl%s)' % (n, f.name) if f.has_different_protocol(n): print '#ifndef GLX_INDIRECT_RENDERING' diff --git a/src/mesa/glapi/glapi.c b/src/mesa/glapi/glapi.c index e20618abc1..2b105d0f17 100644 --- a/src/mesa/glapi/glapi.c +++ b/src/mesa/glapi/glapi.c @@ -318,6 +318,14 @@ extern const GLubyte gl_dispatch_functions_start[]; # endif #endif +#ifdef USE_SPARC_ASM +#ifdef GLX_USE_TLS +extern unsigned int __glapi_sparc_tls_stub; +#else +extern unsigned int __glapi_sparc_pthread_stub; +#endif +#endif + #if !defined(DISPATCH_FUNCTION_SIZE) && !defined(XFree86Server) && !defined(XGLServer) # define NEED_FUNCTION_POINTER #endif @@ -344,6 +352,129 @@ init_glapi_relocs( void ) curr_func += DISPATCH_FUNCTION_SIZE; } #endif +#ifdef USE_SPARC_ASM + extern void __glapi_sparc_icache_flush(unsigned int *); + static const unsigned int template[] = { +#ifdef GLX_USE_TLS + 0x05000000, /* sethi %hi(_glapi_tls_Dispatch), %g2 */ + 0x8730e00a, /* srl %g3, 10, %g3 */ + 0x8410a000, /* or %g2, %lo(_glapi_tls_Dispatch), %g2 */ +#ifdef __arch64__ + 0xc259c002, /* ldx [%g7 + %g2], %g1 */ + 0xc2584003, /* ldx [%g1 + %g3], %g1 */ +#else + 0xc201c002, /* ld [%g7 + %g2], %g1 */ + 0xc2004003, /* ld [%g1 + %g3], %g1 */ +#endif + 0x81c04000, /* jmp %g1 */ + 0x01000000, /* nop */ +#else +#ifdef __arch64__ + 0x03000000, /* 64-bit 0x00 --> sethi %hh(_glapi_Dispatch), %g1 */ + 0x05000000, /* 64-bit 0x04 --> sethi %lm(_glapi_Dispatch), %g2 */ + 0x82106000, /* 64-bit 0x08 --> or %g1, %hm(_glapi_Dispatch), %g1 */ + 0x8730e00a, /* 64-bit 0x0c --> srl %g3, 10, %g3 */ + 0x83287020, /* 64-bit 0x10 --> sllx %g1, 32, %g1 */ + 0x82004002, /* 64-bit 0x14 --> add %g1, %g2, %g1 */ + 0xc2586000, /* 64-bit 0x18 --> ldx [%g1 + %lo(_glapi_Dispatch)], %g1 */ +#else + 0x03000000, /* 32-bit 0x00 --> sethi %hi(_glapi_Dispatch), %g1 */ + 0x8730e00a, /* 32-bit 0x04 --> srl %g3, 10, %g3 */ + 0xc2006000, /* 32-bit 0x08 --> ld [%g1 + %lo(_glapi_Dispatch)], %g1 */ +#endif + 0x80a06000, /* --> cmp %g1, 0 */ + 0x02800005, /* --> be +4*5 */ + 0x01000000, /* --> nop */ +#ifdef __arch64__ + 0xc2584003, /* 64-bit --> ldx [%g1 + %g3], %g1 */ +#else + 0xc2004003, /* 32-bit --> ld [%g1 + %g3], %g1 */ +#endif + 0x81c04000, /* --> jmp %g1 */ + 0x01000000, /* --> nop */ +#ifdef __arch64__ + 0x9de3bf80, /* 64-bit --> save %sp, -128, %sp */ +#else + 0x9de3bfc0, /* 32-bit --> save %sp, -64, %sp */ +#endif + 0xa0100003, /* --> mov %g3, %l0 */ + 0x40000000, /* --> call _glapi_get_dispatch */ + 0x01000000, /* --> nop */ + 0x82100008, /* --> mov %o0, %g1 */ + 0x86100010, /* --> mov %l0, %g3 */ + 0x10bffff7, /* --> ba -4*9 */ + 0x81e80000, /* --> restore */ +#endif + }; +#ifdef GLX_USE_TLS + extern unsigned long __glapi_sparc_get_dispatch(void); + unsigned int *code = &__glapi_sparc_tls_stub; + unsigned long dispatch = __glapi_sparc_get_dispatch(); +#else + unsigned int *code = &__glapi_sparc_pthread_stub; + unsigned long dispatch = (unsigned long) &_glapi_Dispatch; + unsigned long call_dest = (unsigned long ) &_glapi_get_dispatch; + int idx; +#endif + +#if defined(GLX_USE_TLS) + code[0] = template[0] | (dispatch >> 10); + code[1] = template[1]; + __glapi_sparc_icache_flush(&code[0]); + code[2] = template[2] | (dispatch & 0x3ff); + code[3] = template[3]; + __glapi_sparc_icache_flush(&code[2]); + code[4] = template[4]; + code[5] = template[5]; + __glapi_sparc_icache_flush(&code[4]); + code[6] = template[6]; + __glapi_sparc_icache_flush(&code[6]); +#else +#if defined(__arch64__) + code[0] = template[0] | (dispatch >> (32 + 10)); + code[1] = template[1] | ((dispatch & 0xffffffff) >> 10); + __glapi_sparc_icache_flush(&code[0]); + code[2] = template[2] | ((dispatch >> 32) & 0x3ff); + code[3] = template[3]; + __glapi_sparc_icache_flush(&code[2]); + code[4] = template[4]; + code[5] = template[5]; + __glapi_sparc_icache_flush(&code[4]); + code[6] = template[6] | (dispatch & 0x3ff); + idx = 7; +#else + code[0] = template[0] | (dispatch >> 10); + code[1] = template[1]; + __glapi_sparc_icache_flush(&code[0]); + code[2] = template[2] | (dispatch & 0x3ff); + idx = 3; +#endif + code[idx + 0] = template[idx + 0]; + __glapi_sparc_icache_flush(&code[idx - 1]); + code[idx + 1] = template[idx + 1]; + code[idx + 2] = template[idx + 2]; + __glapi_sparc_icache_flush(&code[idx + 1]); + code[idx + 3] = template[idx + 3]; + code[idx + 4] = template[idx + 4]; + __glapi_sparc_icache_flush(&code[idx + 3]); + code[idx + 5] = template[idx + 5]; + code[idx + 6] = template[idx + 6]; + __glapi_sparc_icache_flush(&code[idx + 5]); + code[idx + 7] = template[idx + 7]; + code[idx + 8] = template[idx + 8] | + (((call_dest - ((unsigned long) &code[idx + 8])) + >> 2) & 0x3fffffff); + __glapi_sparc_icache_flush(&code[idx + 7]); + code[idx + 9] = template[idx + 9]; + code[idx + 10] = template[idx + 10]; + __glapi_sparc_icache_flush(&code[idx + 9]); + code[idx + 11] = template[idx + 11]; + code[idx + 12] = template[idx + 12]; + __glapi_sparc_icache_flush(&code[idx + 11]); + code[idx + 13] = template[idx + 13]; + __glapi_sparc_icache_flush(&code[idx + 13]); +#endif +#endif } #endif /* defined(PTHREADS) || defined(GLX_USE_TLS) */ diff --git a/src/mesa/glapi/glapi_getproc.c b/src/mesa/glapi/glapi_getproc.c index 4adc1aece0..764e2ef98e 100644 --- a/src/mesa/glapi/glapi_getproc.c +++ b/src/mesa/glapi/glapi_getproc.c @@ -259,53 +259,30 @@ generate_entrypoint(GLuint functionOffset) } return (_glapi_proc) code; -#elif defined(USE_SPARC_ASM) - -#ifdef __arch64__ - static const unsigned int insn_template[] = { - 0x05000000, /* sethi %uhi(_glapi_Dispatch), %g2 */ - 0x03000000, /* sethi %hi(_glapi_Dispatch), %g1 */ - 0x8410a000, /* or %g2, %ulo(_glapi_Dispatch), %g2 */ - 0x82106000, /* or %g1, %lo(_glapi_Dispatch), %g1 */ - 0x8528b020, /* sllx %g2, 32, %g2 */ - 0xc2584002, /* ldx [%g1 + %g2], %g1 */ - 0x05000000, /* sethi %hi(8 * glapioffset), %g2 */ - 0x8410a000, /* or %g2, %lo(8 * glapioffset), %g2 */ - 0xc6584002, /* ldx [%g1 + %g2], %g3 */ - 0x81c0c000, /* jmpl %g3, %g0 */ - 0x01000000 /* nop */ +#elif defined(USE_SPARC_ASM) && (defined(PTHREADS) || defined(GLX_USE_TLS)) + static const unsigned int template[] = { + 0x07000000, /* sethi %hi(0), %g3 */ + 0x8210000f, /* mov %o7, %g1 */ + 0x40000000, /* call */ + 0x9e100001, /* mov %g1, %o7 */ }; +#ifdef GLX_USE_TLS + extern unsigned int __glapi_sparc_tls_stub; + unsigned long call_dest = (unsigned long ) &__glapi_sparc_tls_stub; #else - static const unsigned int insn_template[] = { - 0x03000000, /* sethi %hi(_glapi_Dispatch), %g1 */ - 0xc2006000, /* ld [%g1 + %lo(_glapi_Dispatch)], %g1 */ - 0xc6006000, /* ld [%g1 + %lo(4*glapioffset)], %g3 */ - 0x81c0c000, /* jmpl %g3, %g0 */ - 0x01000000 /* nop */ - }; -#endif /* __arch64__ */ - unsigned int *code = (unsigned int *) malloc(sizeof(insn_template)); - unsigned long glapi_addr = (unsigned long) &_glapi_Dispatch; + extern unsigned int __glapi_sparc_pthread_stub; + unsigned long call_dest = (unsigned long ) &__glapi_sparc_pthread_stub; +#endif + unsigned int *code = (unsigned int *) malloc(sizeof(template)); if (code) { - memcpy(code, insn_template, sizeof(insn_template)); - -#ifdef __arch64__ - code[0] |= (glapi_addr >> (32 + 10)); - code[1] |= ((glapi_addr & 0xffffffff) >> 10); + code[0] = template[0] | (functionOffset & 0x3fffff); + code[1] = template[1]; __glapi_sparc_icache_flush(&code[0]); - code[2] |= ((glapi_addr >> 32) & ((1 << 10) - 1)); - code[3] |= (glapi_addr & ((1 << 10) - 1)); + code[2] = template[2] | + (((call_dest - ((unsigned long) &code[2])) + >> 2) & 0x3fffffff); + code[3] = template[3]; __glapi_sparc_icache_flush(&code[2]); - code[6] |= ((functionOffset * 8) >> 10); - code[7] |= ((functionOffset * 8) & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&code[6]); -#else - code[0] |= (glapi_addr >> 10); - code[1] |= (glapi_addr & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&code[0]); - code[2] |= (functionOffset * 4); - __glapi_sparc_icache_flush(&code[2]); -#endif /* __arch64__ */ } return (_glapi_proc) code; #else @@ -337,21 +314,10 @@ fill_in_entrypoint_offset(_glapi_proc entrypoint, GLuint offset) #endif #elif defined(USE_SPARC_ASM) - - /* XXX this hasn't been tested! */ unsigned int *code = (unsigned int *) entrypoint; -#ifdef __arch64__ - code[6] = 0x05000000; /* sethi %hi(8 * glapioffset), %g2 */ - code[7] = 0x8410a000; /* or %g2, %lo(8 * glapioffset), %g2 */ - code[6] |= ((offset * 8) >> 10); - code[7] |= ((offset * 8) & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&code[6]); -#else /* __arch64__ */ - code[2] = 0xc6006000; /* ld [%g1 + %lo(4*glapioffset)], %g3 */ - code[2] |= (offset * 4); - __glapi_sparc_icache_flush(&code[2]); -#endif /* __arch64__ */ - + code[0] &= ~0x3fffff; + code[0] |= (offset * sizeof(void *)) & 0x3fffff; + __glapi_sparc_icache_flush(&code[0]); #else /* an unimplemented architecture */ diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index a94bbf3fdf..fb43054cdd 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -390,9 +390,6 @@ one_time_init( GLcontext *ctx ) _mesa_ubyte_to_float_color_tab[i] = (float) i / 255.0F; } -#ifdef USE_SPARC_ASM - _mesa_init_sparc_glapi_relocs(); -#endif if (_mesa_getenv("MESA_DEBUG")) { _glapi_noop_enable_warnings(GL_TRUE); _glapi_set_warning_func( (_glapi_warning_func) _mesa_warning ); diff --git a/src/mesa/sparc/glapi_sparc.S b/src/mesa/sparc/glapi_sparc.S index 7d215939b4..bf70fceef5 100644 --- a/src/mesa/sparc/glapi_sparc.S +++ b/src/mesa/sparc/glapi_sparc.S @@ -26,818 +26,176 @@ * SOFTWARE. */ -#include "glapioffsets.h" +#include "glapi/glapioffsets.h" #ifdef __arch64__ -# define GL_STUB(fn,off) \ -fn: \ - sethi %hi(0xDEADBEEF), %g4 ; \ - sethi %hi(0xDEADBEEF), %g1 ; \ - or %g4, %lo(0xDEADBEEF), %g4 ; \ - or %g1, %lo(0xDEADBEEF), %g1 ; \ - sllx %g4, 32, %g4 ; \ - ldx [%g1 + %g4], %g1 ; \ - sethi %hi(8 * off), %g4 ; \ - or %g4, %lo(8 * off), %g4 ; \ - ldx [%g1 + %g4], %g5 ; \ - jmpl %g5, %g0 ; \ - nop +#define GL_OFF(N) ((N) * 8) +#define GL_LL ldx +#define GL_TIE_LD(SYM) %tie_ldx(SYM) +#define GL_STACK_SIZE 128 #else -# define GL_STUB(fn,off) \ -fn: \ - sethi %hi(0xDEADBEEF), %g1 ; \ - ld [%g1 + %lo(0xDEADBEEF)], %g1 ; \ - ld [%g1 + (4 * off)], %g5 ; \ - jmpl %g5, %g0 ; \ - nop +#define GL_OFF(N) ((N) * 4) +#define GL_LL ld +#define GL_TIE_LD(SYM) %tie_ld(SYM) +#define GL_STACK_SIZE 64 #endif -#define GL_STUB_ALIAS(fn,alias) fn = alias +#define GLOBL_FN(x) .globl x ; .type x, @function +#define HIDDEN(x) .hidden x -.text -.align 32 - .globl __glapi_sparc_icache_flush ; .type __glapi_sparc_icache_flush,#function + .register %g2, #scratch + .register %g3, #scratch + + .text + + GLOBL_FN(__glapi_sparc_icache_flush) + HIDDEN(__glapi_sparc_icache_flush) + .type __glapi_sparc_icache_flush, @function __glapi_sparc_icache_flush: /* %o0 = insn_addr */ flush %o0 retl - nop + nop + + .align 32 + + .type __glapi_sparc_get_pc, @function +__glapi_sparc_get_pc: + retl + add %o7, %g2, %g2 + .size __glapi_sparc_get_pc, .-__glapi_sparc_get_pc + +#ifdef GLX_USE_TLS + + GLOBL_FN(__glapi_sparc_get_dispatch) + HIDDEN(__glapi_sparc_get_dispatch) +__glapi_sparc_get_dispatch: + mov %o7, %g1 + sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %g2 + call __glapi_sparc_get_pc + add %g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2 + mov %g1, %o7 + sethi %tie_hi22(_glapi_tls_Dispatch), %g1 + add %g1, %tie_lo10(_glapi_tls_Dispatch), %g1 + GL_LL [%g2 + %g1], %g2, GL_TIE_LD(_glapi_tls_Dispatch) + retl + mov %g2, %o0 + + .data + .align 32 + + /* --> sethi %hi(_glapi_tls_Dispatch), %g1 */ + /* --> or %g1, %lo(_glapi_tls_Dispatch), %g1 */ + GLOBL_FN(__glapi_sparc_tls_stub) + HIDDEN(__glapi_sparc_tls_stub) +__glapi_sparc_tls_stub: /* Call offset in %g3 */ + mov %o7, %g1 + sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %g2 + call __glapi_sparc_get_pc + add %g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2 + mov %g1, %o7 + srl %g3, 10, %g3 + sethi %tie_hi22(_glapi_tls_Dispatch), %g1 + add %g1, %tie_lo10(_glapi_tls_Dispatch), %g1 + GL_LL [%g2 + %g1], %g2, GL_TIE_LD(_glapi_tls_Dispatch) + GL_LL [%g7+%g2], %g1 + GL_LL [%g1 + %g3], %g1 + jmp %g1 + nop + .size __glapi_sparc_tls_stub, .-__glapi_sparc_tls_stub + +#define GL_STUB(fn, off) \ + GLOBL_FN(fn); \ +fn: ba __glapi_sparc_tls_stub; \ + sethi GL_OFF(off), %g3; \ + .size fn,.-fn; + +#elif defined(PTHREADS) + + /* 64-bit 0x00 --> sethi %hh(_glapi_Dispatch), %g1 */ + /* 64-bit 0x04 --> sethi %lm(_glapi_Dispatch), %g2 */ + /* 64-bit 0x08 --> or %g1, %hm(_glapi_Dispatch), %g1 */ + /* 64-bit 0x0c --> sllx %g1, 32, %g1 */ + /* 64-bit 0x10 --> add %g1, %g2, %g1 */ + /* 64-bit 0x14 --> ldx [%g1 + %lo(_glapi_Dispatch)], %g1 */ -.data -.align 64 + /* 32-bit 0x00 --> sethi %hi(_glapi_Dispatch), %g1 */ + /* 32-bit 0x04 --> ld [%g1 + %lo(_glapi_Dispatch)], %g1 */ - .globl glNewList ; .type glNewList,#function - .globl glEndList ; .type glEndList,#function - .globl glCallList ; .type glCallList,#function - .globl glCallLists ; .type glCallLists,#function - .globl glDeleteLists ; .type glDeleteLists,#function - .globl glGenLists ; .type glGenLists,#function - .globl glListBase ; .type glListBase,#function - .globl glBegin ; .type glBegin,#function - .globl glBitmap ; .type glBitmap,#function - .globl glColor3b ; .type glColor3b,#function - .globl glColor3bv ; .type glColor3bv,#function - .globl glColor3d ; .type glColor3d,#function - .globl glColor3dv ; .type glColor3dv,#function - .globl glColor3f ; .type glColor3f,#function - .globl glColor3fv ; .type glColor3fv,#function - .globl glColor3i ; .type glColor3i,#function - .globl glColor3iv ; .type glColor3iv,#function - .globl glColor3s ; .type glColor3s,#function - .globl glColor3sv ; .type glColor3sv,#function - .globl glColor3ub ; .type glColor3ub,#function - .globl glColor3ubv ; .type glColor3ubv,#function - .globl glColor3ui ; .type glColor3ui,#function - .globl glColor3uiv ; .type glColor3uiv,#function - .globl glColor3us ; .type glColor3us,#function - .globl glColor3usv ; .type glColor3usv,#function - .globl glColor4b ; .type glColor4b,#function - .globl glColor4bv ; .type glColor4bv,#function - .globl glColor4d ; .type glColor4d,#function - .globl glColor4dv ; .type glColor4dv,#function - .globl glColor4f ; .type glColor4f,#function - .globl glColor4fv ; .type glColor4fv,#function - .globl glColor4i ; .type glColor4i,#function - .globl glColor4iv ; .type glColor4iv,#function - .globl glColor4s ; .type glColor4s,#function - .globl glColor4sv ; .type glColor4sv,#function - .globl glColor4ub ; .type glColor4ub,#function - .globl glColor4ubv ; .type glColor4ubv,#function - .globl glColor4ui ; .type glColor4ui,#function - .globl glColor4uiv ; .type glColor4uiv,#function - .globl glColor4us ; .type glColor4us,#function - .globl glColor4usv ; .type glColor4usv,#function - .globl glEdgeFlag ; .type glEdgeFlag,#function - .globl glEdgeFlagv ; .type glEdgeFlagv,#function - .globl glEnd ; .type glEnd,#function - .globl glIndexd ; .type glIndexd,#function - .globl glIndexdv ; .type glIndexdv,#function - .globl glIndexf ; .type glIndexf,#function - .globl glIndexfv ; .type glIndexfv,#function - .globl glIndexi ; .type glIndexi,#function - .globl glIndexiv ; .type glIndexiv,#function - .globl glIndexs ; .type glIndexs,#function - .globl glIndexsv ; .type glIndexsv,#function - .globl glNormal3b ; .type glNormal3b,#function - .globl glNormal3bv ; .type glNormal3bv,#function - .globl glNormal3d ; .type glNormal3d,#function - .globl glNormal3dv ; .type glNormal3dv,#function - .globl glNormal3f ; .type glNormal3f,#function - .globl glNormal3fv ; .type glNormal3fv,#function - .globl glNormal3i ; .type glNormal3i,#function - .globl glNormal3iv ; .type glNormal3iv,#function - .globl glNormal3s ; .type glNormal3s,#function - .globl glNormal3sv ; .type glNormal3sv,#function - .globl glRasterPos2d ; .type glRasterPos2d,#function - .globl glRasterPos2dv ; .type glRasterPos2dv,#function - .globl glRasterPos2f ; .type glRasterPos2f,#function - .globl glRasterPos2fv ; .type glRasterPos2fv,#function - .globl glRasterPos2i ; .type glRasterPos2i,#function - .globl glRasterPos2iv ; .type glRasterPos2iv,#function - .globl glRasterPos2s ; .type glRasterPos2s,#function - .globl glRasterPos2sv ; .type glRasterPos2sv,#function - .globl glRasterPos3d ; .type glRasterPos3d,#function - .globl glRasterPos3dv ; .type glRasterPos3dv,#function - .globl glRasterPos3f ; .type glRasterPos3f,#function - .globl glRasterPos3fv ; .type glRasterPos3fv,#function - .globl glRasterPos3i ; .type glRasterPos3i,#function - .globl glRasterPos3iv ; .type glRasterPos3iv,#function - .globl glRasterPos3s ; .type glRasterPos3s,#function - .globl glRasterPos3sv ; .type glRasterPos3sv,#function - .globl glRasterPos4d ; .type glRasterPos4d,#function - .globl glRasterPos4dv ; .type glRasterPos4dv,#function - .globl glRasterPos4f ; .type glRasterPos4f,#function - .globl glRasterPos4fv ; .type glRasterPos4fv,#function - .globl glRasterPos4i ; .type glRasterPos4i,#function - .globl glRasterPos4iv ; .type glRasterPos4iv,#function - .globl glRasterPos4s ; .type glRasterPos4s,#function - .globl glRasterPos4sv ; .type glRasterPos4sv,#function - .globl glRectd ; .type glRectd,#function - .globl glRectdv ; .type glRectdv,#function - .globl glRectf ; .type glRectf,#function - .globl glRectfv ; .type glRectfv,#function - .globl glRecti ; .type glRecti,#function - .globl glRectiv ; .type glRectiv,#function - .globl glRects ; .type glRects,#function - .globl glRectsv ; .type glRectsv,#function - .globl glTexCoord1d ; .type glTexCoord1d,#function - .globl glTexCoord1dv ; .type glTexCoord1dv,#function - .globl glTexCoord1f ; .type glTexCoord1f,#function - .globl glTexCoord1fv ; .type glTexCoord1fv,#function - .globl glTexCoord1i ; .type glTexCoord1i,#function - .globl glTexCoord1iv ; .type glTexCoord1iv,#function - .globl glTexCoord1s ; .type glTexCoord1s,#function - .globl glTexCoord1sv ; .type glTexCoord1sv,#function - .globl glTexCoord2d ; .type glTexCoord2d,#function - .globl glTexCoord2dv ; .type glTexCoord2dv,#function - .globl glTexCoord2f ; .type glTexCoord2f,#function - .globl glTexCoord2fv ; .type glTexCoord2fv,#function - .globl glTexCoord2i ; .type glTexCoord2i,#function - .globl glTexCoord2iv ; .type glTexCoord2iv,#function - .globl glTexCoord2s ; .type glTexCoord2s,#function - .globl glTexCoord2sv ; .type glTexCoord2sv,#function - .globl glTexCoord3d ; .type glTexCoord3d,#function - .globl glTexCoord3dv ; .type glTexCoord3dv,#function - .globl glTexCoord3f ; .type glTexCoord3f,#function - .globl glTexCoord3fv ; .type glTexCoord3fv,#function - .globl glTexCoord3i ; .type glTexCoord3i,#function - .globl glTexCoord3iv ; .type glTexCoord3iv,#function - .globl glTexCoord3s ; .type glTexCoord3s,#function - .globl glTexCoord3sv ; .type glTexCoord3sv,#function - .globl glTexCoord4d ; .type glTexCoord4d,#function - .globl glTexCoord4dv ; .type glTexCoord4dv,#function - .globl glTexCoord4f ; .type glTexCoord4f,#function - .globl glTexCoord4fv ; .type glTexCoord4fv,#function - .globl glTexCoord4i ; .type glTexCoord4i,#function - .globl glTexCoord4iv ; .type glTexCoord4iv,#function - .globl glTexCoord4s ; .type glTexCoord4s,#function - .globl glTexCoord4sv ; .type glTexCoord4sv,#function - .globl glVertex2d ; .type glVertex2d,#function - .globl glVertex2dv ; .type glVertex2dv,#function - .globl glVertex2f ; .type glVertex2f,#function - .globl glVertex2fv ; .type glVertex2fv,#function - .globl glVertex2i ; .type glVertex2i,#function - .globl glVertex2iv ; .type glVertex2iv,#function - .globl glVertex2s ; .type glVertex2s,#function - .globl glVertex2sv ; .type glVertex2sv,#function - .globl glVertex3d ; .type glVertex3d,#function - .globl glVertex3dv ; .type glVertex3dv,#function - .globl glVertex3f ; .type glVertex3f,#function - .globl glVertex3fv ; .type glVertex3fv,#function - .globl glVertex3i ; .type glVertex3i,#function - .globl glVertex3iv ; .type glVertex3iv,#function - .globl glVertex3s ; .type glVertex3s,#function - .globl glVertex3sv ; .type glVertex3sv,#function - .globl glVertex4d ; .type glVertex4d,#function - .globl glVertex4dv ; .type glVertex4dv,#function - .globl glVertex4f ; .type glVertex4f,#function - .globl glVertex4fv ; .type glVertex4fv,#function - .globl glVertex4i ; .type glVertex4i,#function - .globl glVertex4iv ; .type glVertex4iv,#function - .globl glVertex4s ; .type glVertex4s,#function - .globl glVertex4sv ; .type glVertex4sv,#function - .globl glClipPlane ; .type glClipPlane,#function - .globl glColorMaterial ; .type glColorMaterial,#function - .globl glCullFace ; .type glCullFace,#function - .globl glFogf ; .type glFogf,#function - .globl glFogfv ; .type glFogfv,#function - .globl glFogi ; .type glFogi,#function - .globl glFogiv ; .type glFogiv,#function - .globl glFrontFace ; .type glFrontFace,#function - .globl glHint ; .type glHint,#function - .globl glLightf ; .type glLightf,#function - .globl glLightfv ; .type glLightfv,#function - .globl glLighti ; .type glLighti,#function - .globl glLightiv ; .type glLightiv,#function - .globl glLightModelf ; .type glLightModelf,#function - .globl glLightModelfv ; .type glLightModelfv,#function - .globl glLightModeli ; .type glLightModeli,#function - .globl glLightModeliv ; .type glLightModeliv,#function - .globl glLineStipple ; .type glLineStipple,#function - .globl glLineWidth ; .type glLineWidth,#function - .globl glMaterialf ; .type glMaterialf,#function - .globl glMaterialfv ; .type glMaterialfv,#function - .globl glMateriali ; .type glMateriali,#function - .globl glMaterialiv ; .type glMaterialiv,#function - .globl glPointSize ; .type glPointSize,#function - .globl glPolygonMode ; .type glPolygonMode,#function - .globl glPolygonStipple ; .type glPolygonStipple,#function - .globl glScissor ; .type glScissor,#function - .globl glShadeModel ; .type glShadeModel,#function - .globl glTexParameterf ; .type glTexParameterf,#function - .globl glTexParameterfv ; .type glTexParameterfv,#function - .globl glTexParameteri ; .type glTexParameteri,#function - .globl glTexParameteriv ; .type glTexParameteriv,#function - .globl glTexImage1D ; .type glTexImage1D,#function - .globl glTexImage2D ; .type glTexImage2D,#function - .globl glTexEnvf ; .type glTexEnvf,#function - .globl glTexEnvfv ; .type glTexEnvfv,#function - .globl glTexEnvi ; .type glTexEnvi,#function - .globl glTexEnviv ; .type glTexEnviv,#function - .globl glTexGend ; .type glTexGend,#function - .globl glTexGendv ; .type glTexGendv,#function - .globl glTexGenf ; .type glTexGenf,#function - .globl glTexGenfv ; .type glTexGenfv,#function - .globl glTexGeni ; .type glTexGeni,#function - .globl glTexGeniv ; .type glTexGeniv,#function - .globl glFeedbackBuffer ; .type glFeedbackBuffer,#function - .globl glSelectBuffer ; .type glSelectBuffer,#function - .globl glRenderMode ; .type glRenderMode,#function - .globl glInitNames ; .type glInitNames,#function - .globl glLoadName ; .type glLoadName,#function - .globl glPassThrough ; .type glPassThrough,#function - .globl glPopName ; .type glPopName,#function - .globl glPushName ; .type glPushName,#function - .globl glDrawBuffer ; .type glDrawBuffer,#function - .globl glClear ; .type glClear,#function - .globl glClearAccum ; .type glClearAccum,#function - .globl glClearIndex ; .type glClearIndex,#function - .globl glClearColor ; .type glClearColor,#function - .globl glClearStencil ; .type glClearStencil,#function - .globl glClearDepth ; .type glClearDepth,#function - .globl glStencilMask ; .type glStencilMask,#function - .globl glColorMask ; .type glColorMask,#function - .globl glDepthMask ; .type glDepthMask,#function - .globl glIndexMask ; .type glIndexMask,#function - .globl glAccum ; .type glAccum,#function - .globl glDisable ; .type glDisable,#function - .globl glEnable ; .type glEnable,#function - .globl glFinish ; .type glFinish,#function - .globl glFlush ; .type glFlush,#function - .globl glPopAttrib ; .type glPopAttrib,#function - .globl glPushAttrib ; .type glPushAttrib,#function - .globl glMap1d ; .type glMap1d,#function - .globl glMap1f ; .type glMap1f,#function - .globl glMap2d ; .type glMap2d,#function - .globl glMap2f ; .type glMap2f,#function - .globl glMapGrid1d ; .type glMapGrid1d,#function - .globl glMapGrid1f ; .type glMapGrid1f,#function - .globl glMapGrid2d ; .type glMapGrid2d,#function - .globl glMapGrid2f ; .type glMapGrid2f,#function - .globl glEvalCoord1d ; .type glEvalCoord1d,#function - .globl glEvalCoord1dv ; .type glEvalCoord1dv,#function - .globl glEvalCoord1f ; .type glEvalCoord1f,#function - .globl glEvalCoord1fv ; .type glEvalCoord1fv,#function - .globl glEvalCoord2d ; .type glEvalCoord2d,#function - .globl glEvalCoord2dv ; .type glEvalCoord2dv,#function - .globl glEvalCoord2f ; .type glEvalCoord2f,#function - .globl glEvalCoord2fv ; .type glEvalCoord2fv,#function - .globl glEvalMesh1 ; .type glEvalMesh1,#function - .globl glEvalPoint1 ; .type glEvalPoint1,#function - .globl glEvalMesh2 ; .type glEvalMesh2,#function - .globl glEvalPoint2 ; .type glEvalPoint2,#function - .globl glAlphaFunc ; .type glAlphaFunc,#function - .globl glBlendFunc ; .type glBlendFunc,#function - .globl glLogicOp ; .type glLogicOp,#function - .globl glStencilFunc ; .type glStencilFunc,#function - .globl glStencilOp ; .type glStencilOp,#function - .globl glDepthFunc ; .type glDepthFunc,#function - .globl glPixelZoom ; .type glPixelZoom,#function - .globl glPixelTransferf ; .type glPixelTransferf,#function - .globl glPixelTransferi ; .type glPixelTransferi,#function - .globl glPixelStoref ; .type glPixelStoref,#function - .globl glPixelStorei ; .type glPixelStorei,#function - .globl glPixelMapfv ; .type glPixelMapfv,#function - .globl glPixelMapuiv ; .type glPixelMapuiv,#function - .globl glPixelMapusv ; .type glPixelMapusv,#function - .globl glReadBuffer ; .type glReadBuffer,#function - .globl glCopyPixels ; .type glCopyPixels,#function - .globl glReadPixels ; .type glReadPixels,#function - .globl glDrawPixels ; .type glDrawPixels,#function - .globl glGetBooleanv ; .type glGetBooleanv,#function - .globl glGetClipPlane ; .type glGetClipPlane,#function - .globl glGetDoublev ; .type glGetDoublev,#function - .globl glGetError ; .type glGetError,#function - .globl glGetFloatv ; .type glGetFloatv,#function - .globl glGetIntegerv ; .type glGetIntegerv,#function - .globl glGetLightfv ; .type glGetLightfv,#function - .globl glGetLightiv ; .type glGetLightiv,#function - .globl glGetMapdv ; .type glGetMapdv,#function - .globl glGetMapfv ; .type glGetMapfv,#function - .globl glGetMapiv ; .type glGetMapiv,#function - .globl glGetMaterialfv ; .type glGetMaterialfv,#function - .globl glGetMaterialiv ; .type glGetMaterialiv,#function - .globl glGetPixelMapfv ; .type glGetPixelMapfv,#function - .globl glGetPixelMapuiv ; .type glGetPixelMapuiv,#function - .globl glGetPixelMapusv ; .type glGetPixelMapusv,#function - .globl glGetPolygonStipple ; .type glGetPolygonStipple,#function - .globl glGetString ; .type glGetString,#function - .globl glGetTexEnvfv ; .type glGetTexEnvfv,#function - .globl glGetTexEnviv ; .type glGetTexEnviv,#function - .globl glGetTexGendv ; .type glGetTexGendv,#function - .globl glGetTexGenfv ; .type glGetTexGenfv,#function - .globl glGetTexGeniv ; .type glGetTexGeniv,#function - .globl glGetTexImage ; .type glGetTexImage,#function - .globl glGetTexParameterfv ; .type glGetTexParameterfv,#function - .globl glGetTexParameteriv ; .type glGetTexParameteriv,#function - .globl glGetTexLevelParameterfv ; .type glGetTexLevelParameterfv,#function - .globl glGetTexLevelParameteriv ; .type glGetTexLevelParameteriv,#function - .globl glIsEnabled ; .type glIsEnabled,#function - .globl glIsList ; .type glIsList,#function - .globl glDepthRange ; .type glDepthRange,#function - .globl glFrustum ; .type glFrustum,#function - .globl glLoadIdentity ; .type glLoadIdentity,#function - .globl glLoadMatrixf ; .type glLoadMatrixf,#function - .globl glLoadMatrixd ; .type glLoadMatrixd,#function - .globl glMatrixMode ; .type glMatrixMode,#function - .globl glMultMatrixf ; .type glMultMatrixf,#function - .globl glMultMatrixd ; .type glMultMatrixd,#function - .globl glOrtho ; .type glOrtho,#function - .globl glPopMatrix ; .type glPopMatrix,#function - .globl glPushMatrix ; .type glPushMatrix,#function - .globl glRotated ; .type glRotated,#function - .globl glRotatef ; .type glRotatef,#function - .globl glScaled ; .type glScaled,#function - .globl glScalef ; .type glScalef,#function - .globl glTranslated ; .type glTranslated,#function - .globl glTranslatef ; .type glTranslatef,#function - .globl glViewport ; .type glViewport,#function - .globl glArrayElement ; .type glArrayElement,#function - .globl glBindTexture ; .type glBindTexture,#function - .globl glColorPointer ; .type glColorPointer,#function - .globl glDisableClientState ; .type glDisableClientState,#function - .globl glDrawArrays ; .type glDrawArrays,#function - .globl glDrawElements ; .type glDrawElements,#function - .globl glEdgeFlagPointer ; .type glEdgeFlagPointer,#function - .globl glEnableClientState ; .type glEnableClientState,#function - .globl glIndexPointer ; .type glIndexPointer,#function - .globl glIndexub ; .type glIndexub,#function - .globl glIndexubv ; .type glIndexubv,#function - .globl glInterleavedArrays ; .type glInterleavedArrays,#function - .globl glNormalPointer ; .type glNormalPointer,#function - .globl glPolygonOffset ; .type glPolygonOffset,#function - .globl glTexCoordPointer ; .type glTexCoordPointer,#function - .globl glVertexPointer ; .type glVertexPointer,#function - .globl glAreTexturesResident ; .type glAreTexturesResident,#function - .globl glCopyTexImage1D ; .type glCopyTexImage1D,#function - .globl glCopyTexImage2D ; .type glCopyTexImage2D,#function - .globl glCopyTexSubImage1D ; .type glCopyTexSubImage1D,#function - .globl glCopyTexSubImage2D ; .type glCopyTexSubImage2D,#function - .globl glDeleteTextures ; .type glDeleteTextures,#function - .globl glGenTextures ; .type glGenTextures,#function - .globl glGetPointerv ; .type glGetPointerv,#function - .globl glIsTexture ; .type glIsTexture,#function - .globl glPrioritizeTextures ; .type glPrioritizeTextures,#function - .globl glTexSubImage1D ; .type glTexSubImage1D,#function - .globl glTexSubImage2D ; .type glTexSubImage2D,#function - .globl glPopClientAttrib ; .type glPopClientAttrib,#function - .globl glPushClientAttrib ; .type glPushClientAttrib,#function - .globl glBlendColor ; .type glBlendColor,#function - .globl glBlendEquation ; .type glBlendEquation,#function - .globl glDrawRangeElements ; .type glDrawRangeElements,#function - .globl glColorTable ; .type glColorTable,#function - .globl glColorTableParameterfv ; .type glColorTableParameterfv,#function - .globl glColorTableParameteriv ; .type glColorTableParameteriv,#function - .globl glCopyColorTable ; .type glCopyColorTable,#function - .globl glGetColorTable ; .type glGetColorTable,#function - .globl glGetColorTableParameterfv ; .type glGetColorTableParameterfv,#function - .globl glGetColorTableParameteriv ; .type glGetColorTableParameteriv,#function - .globl glColorSubTable ; .type glColorSubTable,#function - .globl glCopyColorSubTable ; .type glCopyColorSubTable,#function - .globl glConvolutionFilter1D ; .type glConvolutionFilter1D,#function - .globl glConvolutionFilter2D ; .type glConvolutionFilter2D,#function - .globl glConvolutionParameterf ; .type glConvolutionParameterf,#function - .globl glConvolutionParameterfv ; .type glConvolutionParameterfv,#function - .globl glConvolutionParameteri ; .type glConvolutionParameteri,#function - .globl glConvolutionParameteriv ; .type glConvolutionParameteriv,#function - .globl glCopyConvolutionFilter1D ; .type glCopyConvolutionFilter1D,#function - .globl glCopyConvolutionFilter2D ; .type glCopyConvolutionFilter2D,#function - .globl glGetConvolutionFilter ; .type glGetConvolutionFilter,#function - .globl glGetConvolutionParameterfv ; .type glGetConvolutionParameterfv,#function - .globl glGetConvolutionParameteriv ; .type glGetConvolutionParameteriv,#function - .globl glGetSeparableFilter ; .type glGetSeparableFilter,#function - .globl glSeparableFilter2D ; .type glSeparableFilter2D,#function - .globl glGetHistogram ; .type glGetHistogram,#function - .globl glGetHistogramParameterfv ; .type glGetHistogramParameterfv,#function - .globl glGetHistogramParameteriv ; .type glGetHistogramParameteriv,#function - .globl glGetMinmax ; .type glGetMinmax,#function - .globl glGetMinmaxParameterfv ; .type glGetMinmaxParameterfv,#function - .globl glGetMinmaxParameteriv ; .type glGetMinmaxParameteriv,#function - .globl glHistogram ; .type glHistogram,#function - .globl glMinmax ; .type glMinmax,#function - .globl glResetHistogram ; .type glResetHistogram,#function - .globl glResetMinmax ; .type glResetMinmax,#function - .globl glTexImage3D ; .type glTexImage3D,#function - .globl glTexSubImage3D ; .type glTexSubImage3D,#function - .globl glCopyTexSubImage3D ; .type glCopyTexSubImage3D,#function - .globl glActiveTextureARB ; .type glActiveTextureARB,#function - .globl glClientActiveTextureARB ; .type glClientActiveTextureARB,#function - .globl glMultiTexCoord1dARB ; .type glMultiTexCoord1dARB,#function - .globl glMultiTexCoord1dvARB ; .type glMultiTexCoord1dvARB,#function - .globl glMultiTexCoord1fARB ; .type glMultiTexCoord1fARB,#function - .globl glMultiTexCoord1fvARB ; .type glMultiTexCoord1fvARB,#function - .globl glMultiTexCoord1iARB ; .type glMultiTexCoord1iARB,#function - .globl glMultiTexCoord1ivARB ; .type glMultiTexCoord1ivARB,#function - .globl glMultiTexCoord1sARB ; .type glMultiTexCoord1sARB,#function - .globl glMultiTexCoord1svARB ; .type glMultiTexCoord1svARB,#function - .globl glMultiTexCoord2dARB ; .type glMultiTexCoord2dARB,#function - .globl glMultiTexCoord2dvARB ; .type glMultiTexCoord2dvARB,#function - .globl glMultiTexCoord2fARB ; .type glMultiTexCoord2fARB,#function - .globl glMultiTexCoord2fvARB ; .type glMultiTexCoord2fvARB,#function - .globl glMultiTexCoord2iARB ; .type glMultiTexCoord2iARB,#function - .globl glMultiTexCoord2ivARB ; .type glMultiTexCoord2ivARB,#function - .globl glMultiTexCoord2sARB ; .type glMultiTexCoord2sARB,#function - .globl glMultiTexCoord2svARB ; .type glMultiTexCoord2svARB,#function - .globl glMultiTexCoord3dARB ; .type glMultiTexCoord3dARB,#function - .globl glMultiTexCoord3dvARB ; .type glMultiTexCoord3dvARB,#function - .globl glMultiTexCoord3fARB ; .type glMultiTexCoord3fARB,#function - .globl glMultiTexCoord3fvARB ; .type glMultiTexCoord3fvARB,#function - .globl glMultiTexCoord3iARB ; .type glMultiTexCoord3iARB,#function - .globl glMultiTexCoord3ivARB ; .type glMultiTexCoord3ivARB,#function - .globl glMultiTexCoord3sARB ; .type glMultiTexCoord3sARB,#function - .globl glMultiTexCoord3svARB ; .type glMultiTexCoord3svARB,#function - .globl glMultiTexCoord4dARB ; .type glMultiTexCoord4dARB,#function - .globl glMultiTexCoord4dvARB ; .type glMultiTexCoord4dvARB,#function - .globl glMultiTexCoord4fARB ; .type glMultiTexCoord4fARB,#function - .globl glMultiTexCoord4fvARB ; .type glMultiTexCoord4fvARB,#function - .globl glMultiTexCoord4iARB ; .type glMultiTexCoord4iARB,#function - .globl glMultiTexCoord4ivARB ; .type glMultiTexCoord4ivARB,#function - .globl glMultiTexCoord4sARB ; .type glMultiTexCoord4sARB,#function - .globl glMultiTexCoord4svARB ; .type glMultiTexCoord4svARB,#function - .globl glAttachShader ; .type glAttachShader,#function - .globl glCreateProgram ; .type glCreateProgram,#function - .globl glCreateShader ; .type glCreateShader,#function - .globl glDeleteProgram ; .type glDeleteProgram,#function - .globl glDeleteShader ; .type glDeleteShader,#function - .globl glDetachShader ; .type glDetachShader,#function - .globl glGetAttachedShaders ; .type glGetAttachedShaders,#function - .globl glGetProgramInfoLog ; .type glGetProgramInfoLog,#function - .globl glGetProgramiv ; .type glGetProgramiv,#function - .globl glGetShaderInfoLog ; .type glGetShaderInfoLog,#function - .globl glGetShaderiv ; .type glGetShaderiv,#function - .globl glIsProgram ; .type glIsProgram,#function - .globl glIsShader ; .type glIsShader,#function - .globl glStencilFuncSeparate ; .type glStencilFuncSeparate,#function - .globl glStencilMaskSeparate ; .type glStencilMaskSeparate,#function - .globl glStencilOpSeparate ; .type glStencilOpSeparate,#function - .globl glUniformMatrix2x3fv ; .type glUniformMatrix2x3fv,#function - .globl glUniformMatrix2x4fv ; .type glUniformMatrix2x4fv,#function - .globl glUniformMatrix3x2fv ; .type glUniformMatrix3x2fv,#function - .globl glUniformMatrix3x4fv ; .type glUniformMatrix3x4fv,#function - .globl glUniformMatrix4x2fv ; .type glUniformMatrix4x2fv,#function - .globl glUniformMatrix4x3fv ; .type glUniformMatrix4x3fv,#function - .globl glLoadTransposeMatrixdARB ; .type glLoadTransposeMatrixdARB,#function - .globl glLoadTransposeMatrixfARB ; .type glLoadTransposeMatrixfARB,#function - .globl glMultTransposeMatrixdARB ; .type glMultTransposeMatrixdARB,#function - .globl glMultTransposeMatrixfARB ; .type glMultTransposeMatrixfARB,#function - .globl glSampleCoverageARB ; .type glSampleCoverageARB,#function - .globl glCompressedTexImage1DARB ; .type glCompressedTexImage1DARB,#function - .globl glCompressedTexImage2DARB ; .type glCompressedTexImage2DARB,#function - .globl glCompressedTexImage3DARB ; .type glCompressedTexImage3DARB,#function - .globl glCompressedTexSubImage1DARB ; .type glCompressedTexSubImage1DARB,#function - .globl glCompressedTexSubImage2DARB ; .type glCompressedTexSubImage2DARB,#function - .globl glCompressedTexSubImage3DARB ; .type glCompressedTexSubImage3DARB,#function - .globl glGetCompressedTexImageARB ; .type glGetCompressedTexImageARB,#function - .globl glDisableVertexAttribArrayARB ; .type glDisableVertexAttribArrayARB,#function - .globl glEnableVertexAttribArrayARB ; .type glEnableVertexAttribArrayARB,#function - .globl glGetProgramEnvParameterdvARB ; .type glGetProgramEnvParameterdvARB,#function - .globl glGetProgramEnvParameterfvARB ; .type glGetProgramEnvParameterfvARB,#function - .globl glGetProgramLocalParameterdvARB ; .type glGetProgramLocalParameterdvARB,#function - .globl glGetProgramLocalParameterfvARB ; .type glGetProgramLocalParameterfvARB,#function - .globl glGetProgramStringARB ; .type glGetProgramStringARB,#function - .globl glGetProgramivARB ; .type glGetProgramivARB,#function - .globl glGetVertexAttribdvARB ; .type glGetVertexAttribdvARB,#function - .globl glGetVertexAttribfvARB ; .type glGetVertexAttribfvARB,#function - .globl glGetVertexAttribivARB ; .type glGetVertexAttribivARB,#function - .globl glProgramEnvParameter4dARB ; .type glProgramEnvParameter4dARB,#function - .globl glProgramEnvParameter4dvARB ; .type glProgramEnvParameter4dvARB,#function - .globl glProgramEnvParameter4fARB ; .type glProgramEnvParameter4fARB,#function - .globl glProgramEnvParameter4fvARB ; .type glProgramEnvParameter4fvARB,#function - .globl glProgramLocalParameter4dARB ; .type glProgramLocalParameter4dARB,#function - .globl glProgramLocalParameter4dvARB ; .type glProgramLocalParameter4dvARB,#function - .globl glProgramLocalParameter4fARB ; .type glProgramLocalParameter4fARB,#function - .globl glProgramLocalParameter4fvARB ; .type glProgramLocalParameter4fvARB,#function - .globl glProgramStringARB ; .type glProgramStringARB,#function - .globl glVertexAttrib1dARB ; .type glVertexAttrib1dARB,#function - .globl glVertexAttrib1dvARB ; .type glVertexAttrib1dvARB,#function - .globl glVertexAttrib1fARB ; .type glVertexAttrib1fARB,#function - .globl glVertexAttrib1fvARB ; .type glVertexAttrib1fvARB,#function - .globl glVertexAttrib1sARB ; .type glVertexAttrib1sARB,#function - .globl glVertexAttrib1svARB ; .type glVertexAttrib1svARB,#function - .globl glVertexAttrib2dARB ; .type glVertexAttrib2dARB,#function - .globl glVertexAttrib2dvARB ; .type glVertexAttrib2dvARB,#function - .globl glVertexAttrib2fARB ; .type glVertexAttrib2fARB,#function - .globl glVertexAttrib2fvARB ; .type glVertexAttrib2fvARB,#function - .globl glVertexAttrib2sARB ; .type glVertexAttrib2sARB,#function - .globl glVertexAttrib2svARB ; .type glVertexAttrib2svARB,#function - .globl glVertexAttrib3dARB ; .type glVertexAttrib3dARB,#function - .globl glVertexAttrib3dvARB ; .type glVertexAttrib3dvARB,#function - .globl glVertexAttrib3fARB ; .type glVertexAttrib3fARB,#function - .globl glVertexAttrib3fvARB ; .type glVertexAttrib3fvARB,#function - .globl glVertexAttrib3sARB ; .type glVertexAttrib3sARB,#function - .globl glVertexAttrib3svARB ; .type glVertexAttrib3svARB,#function - .globl glVertexAttrib4NbvARB ; .type glVertexAttrib4NbvARB,#function - .globl glVertexAttrib4NivARB ; .type glVertexAttrib4NivARB,#function - .globl glVertexAttrib4NsvARB ; .type glVertexAttrib4NsvARB,#function - .globl glVertexAttrib4NubARB ; .type glVertexAttrib4NubARB,#function - .globl glVertexAttrib4NubvARB ; .type glVertexAttrib4NubvARB,#function - .globl glVertexAttrib4NuivARB ; .type glVertexAttrib4NuivARB,#function - .globl glVertexAttrib4NusvARB ; .type glVertexAttrib4NusvARB,#function - .globl glVertexAttrib4bvARB ; .type glVertexAttrib4bvARB,#function - .globl glVertexAttrib4dARB ; .type glVertexAttrib4dARB,#function - .globl glVertexAttrib4dvARB ; .type glVertexAttrib4dvARB,#function - .globl glVertexAttrib4fARB ; .type glVertexAttrib4fARB,#function - .globl glVertexAttrib4fvARB ; .type glVertexAttrib4fvARB,#function - .globl glVertexAttrib4ivARB ; .type glVertexAttrib4ivARB,#function - .globl glVertexAttrib4sARB ; .type glVertexAttrib4sARB,#function - .globl glVertexAttrib4svARB ; .type glVertexAttrib4svARB,#function - .globl glVertexAttrib4ubvARB ; .type glVertexAttrib4ubvARB,#function - .globl glVertexAttrib4uivARB ; .type glVertexAttrib4uivARB,#function - .globl glVertexAttrib4usvARB ; .type glVertexAttrib4usvARB,#function - .globl glVertexAttribPointerARB ; .type glVertexAttribPointerARB,#function - .globl glBindBufferARB ; .type glBindBufferARB,#function - .globl glBufferDataARB ; .type glBufferDataARB,#function - .globl glBufferSubDataARB ; .type glBufferSubDataARB,#function - .globl glDeleteBuffersARB ; .type glDeleteBuffersARB,#function - .globl glGenBuffersARB ; .type glGenBuffersARB,#function - .globl glGetBufferParameterivARB ; .type glGetBufferParameterivARB,#function - .globl glGetBufferPointervARB ; .type glGetBufferPointervARB,#function - .globl glGetBufferSubDataARB ; .type glGetBufferSubDataARB,#function - .globl glIsBufferARB ; .type glIsBufferARB,#function - .globl glMapBufferARB ; .type glMapBufferARB,#function - .globl glUnmapBufferARB ; .type glUnmapBufferARB,#function - .globl glBeginQueryARB ; .type glBeginQueryARB,#function - .globl glDeleteQueriesARB ; .type glDeleteQueriesARB,#function - .globl glEndQueryARB ; .type glEndQueryARB,#function - .globl glGenQueriesARB ; .type glGenQueriesARB,#function - .globl glGetQueryObjectivARB ; .type glGetQueryObjectivARB,#function - .globl glGetQueryObjectuivARB ; .type glGetQueryObjectuivARB,#function - .globl glGetQueryivARB ; .type glGetQueryivARB,#function - .globl glIsQueryARB ; .type glIsQueryARB,#function - .globl glAttachObjectARB ; .type glAttachObjectARB,#function - .globl glCompileShaderARB ; .type glCompileShaderARB,#function - .globl glCreateProgramObjectARB ; .type glCreateProgramObjectARB,#function - .globl glCreateShaderObjectARB ; .type glCreateShaderObjectARB,#function - .globl glDeleteObjectARB ; .type glDeleteObjectARB,#function - .globl glDetachObjectARB ; .type glDetachObjectARB,#function - .globl glGetActiveUniformARB ; .type glGetActiveUniformARB,#function - .globl glGetAttachedObjectsARB ; .type glGetAttachedObjectsARB,#function - .globl glGetHandleARB ; .type glGetHandleARB,#function - .globl glGetInfoLogARB ; .type glGetInfoLogARB,#function - .globl glGetObjectParameterfvARB ; .type glGetObjectParameterfvARB,#function - .globl glGetObjectParameterivARB ; .type glGetObjectParameterivARB,#function - .globl glGetShaderSourceARB ; .type glGetShaderSourceARB,#function - .globl glGetUniformLocationARB ; .type glGetUniformLocationARB,#function - .globl glGetUniformfvARB ; .type glGetUniformfvARB,#function - .globl glGetUniformivARB ; .type glGetUniformivARB,#function - .globl glLinkProgramARB ; .type glLinkProgramARB,#function - .globl glShaderSourceARB ; .type glShaderSourceARB,#function - .globl glUniform1fARB ; .type glUniform1fARB,#function - .globl glUniform1fvARB ; .type glUniform1fvARB,#function - .globl glUniform1iARB ; .type glUniform1iARB,#function - .globl glUniform1ivARB ; .type glUniform1ivARB,#function - .globl glUniform2fARB ; .type glUniform2fARB,#function - .globl glUniform2fvARB ; .type glUniform2fvARB,#function - .globl glUniform2iARB ; .type glUniform2iARB,#function - .globl glUniform2ivARB ; .type glUniform2ivARB,#function - .globl glUniform3fARB ; .type glUniform3fARB,#function - .globl glUniform3fvARB ; .type glUniform3fvARB,#function - .globl glUniform3iARB ; .type glUniform3iARB,#function - .globl glUniform3ivARB ; .type glUniform3ivARB,#function - .globl glUniform4fARB ; .type glUniform4fARB,#function - .globl glUniform4fvARB ; .type glUniform4fvARB,#function - .globl glUniform4iARB ; .type glUniform4iARB,#function - .globl glUniform4ivARB ; .type glUniform4ivARB,#function - .globl glUniformMatrix2fvARB ; .type glUniformMatrix2fvARB,#function - .globl glUniformMatrix3fvARB ; .type glUniformMatrix3fvARB,#function - .globl glUniformMatrix4fvARB ; .type glUniformMatrix4fvARB,#function - .globl glUseProgramObjectARB ; .type glUseProgramObjectARB,#function - .globl glValidateProgramARB ; .type glValidateProgramARB,#function - .globl glBindAttribLocationARB ; .type glBindAttribLocationARB,#function - .globl glGetActiveAttribARB ; .type glGetActiveAttribARB,#function - .globl glGetAttribLocationARB ; .type glGetAttribLocationARB,#function - .globl glDrawBuffersARB ; .type glDrawBuffersARB,#function - .globl glRenderbufferStorageMultisample ; .type glRenderbufferStorageMultisample,#function - .globl glPolygonOffsetEXT ; .type glPolygonOffsetEXT,#function - .globl gl_dispatch_stub_563 ; .type gl_dispatch_stub_563,#function - .globl gl_dispatch_stub_564 ; .type gl_dispatch_stub_564,#function - .globl gl_dispatch_stub_565 ; .type gl_dispatch_stub_565,#function - .globl gl_dispatch_stub_566 ; .type gl_dispatch_stub_566,#function - .globl gl_dispatch_stub_567 ; .type gl_dispatch_stub_567,#function - .globl gl_dispatch_stub_568 ; .type gl_dispatch_stub_568,#function - .globl gl_dispatch_stub_569 ; .type gl_dispatch_stub_569,#function - .globl gl_dispatch_stub_570 ; .type gl_dispatch_stub_570,#function - .globl glColorPointerEXT ; .type glColorPointerEXT,#function - .globl glEdgeFlagPointerEXT ; .type glEdgeFlagPointerEXT,#function - .globl glIndexPointerEXT ; .type glIndexPointerEXT,#function - .globl glNormalPointerEXT ; .type glNormalPointerEXT,#function - .globl glTexCoordPointerEXT ; .type glTexCoordPointerEXT,#function - .globl glVertexPointerEXT ; .type glVertexPointerEXT,#function - .globl glPointParameterfEXT ; .type glPointParameterfEXT,#function - .globl glPointParameterfvEXT ; .type glPointParameterfvEXT,#function - .globl glLockArraysEXT ; .type glLockArraysEXT,#function - .globl glUnlockArraysEXT ; .type glUnlockArraysEXT,#function - .globl gl_dispatch_stub_581 ; .type gl_dispatch_stub_581,#function - .globl gl_dispatch_stub_582 ; .type gl_dispatch_stub_582,#function - .globl glSecondaryColor3bEXT ; .type glSecondaryColor3bEXT,#function - .globl glSecondaryColor3bvEXT ; .type glSecondaryColor3bvEXT,#function - .globl glSecondaryColor3dEXT ; .type glSecondaryColor3dEXT,#function - .globl glSecondaryColor3dvEXT ; .type glSecondaryColor3dvEXT,#function - .globl glSecondaryColor3fEXT ; .type glSecondaryColor3fEXT,#function - .globl glSecondaryColor3fvEXT ; .type glSecondaryColor3fvEXT,#function - .globl glSecondaryColor3iEXT ; .type glSecondaryColor3iEXT,#function - .globl glSecondaryColor3ivEXT ; .type glSecondaryColor3ivEXT,#function - .globl glSecondaryColor3sEXT ; .type glSecondaryColor3sEXT,#function - .globl glSecondaryColor3svEXT ; .type glSecondaryColor3svEXT,#function - .globl glSecondaryColor3ubEXT ; .type glSecondaryColor3ubEXT,#function - .globl glSecondaryColor3ubvEXT ; .type glSecondaryColor3ubvEXT,#function - .globl glSecondaryColor3uiEXT ; .type glSecondaryColor3uiEXT,#function - .globl glSecondaryColor3uivEXT ; .type glSecondaryColor3uivEXT,#function - .globl glSecondaryColor3usEXT ; .type glSecondaryColor3usEXT,#function - .globl glSecondaryColor3usvEXT ; .type glSecondaryColor3usvEXT,#function - .globl glSecondaryColorPointerEXT ; .type glSecondaryColorPointerEXT,#function - .globl glMultiDrawArraysEXT ; .type glMultiDrawArraysEXT,#function - .globl glMultiDrawElementsEXT ; .type glMultiDrawElementsEXT,#function - .globl glFogCoordPointerEXT ; .type glFogCoordPointerEXT,#function - .globl glFogCoorddEXT ; .type glFogCoorddEXT,#function - .globl glFogCoorddvEXT ; .type glFogCoorddvEXT,#function - .globl glFogCoordfEXT ; .type glFogCoordfEXT,#function - .globl glFogCoordfvEXT ; .type glFogCoordfvEXT,#function - .globl gl_dispatch_stub_607 ; .type gl_dispatch_stub_607,#function - .globl glBlendFuncSeparateEXT ; .type glBlendFuncSeparateEXT,#function - .globl glFlushVertexArrayRangeNV ; .type glFlushVertexArrayRangeNV,#function - .globl glVertexArrayRangeNV ; .type glVertexArrayRangeNV,#function - .globl glCombinerInputNV ; .type glCombinerInputNV,#function - .globl glCombinerOutputNV ; .type glCombinerOutputNV,#function - .globl glCombinerParameterfNV ; .type glCombinerParameterfNV,#function - .globl glCombinerParameterfvNV ; .type glCombinerParameterfvNV,#function - .globl glCombinerParameteriNV ; .type glCombinerParameteriNV,#function - .globl glCombinerParameterivNV ; .type glCombinerParameterivNV,#function - .globl glFinalCombinerInputNV ; .type glFinalCombinerInputNV,#function - .globl glGetCombinerInputParameterfvNV ; .type glGetCombinerInputParameterfvNV,#function - .globl glGetCombinerInputParameterivNV ; .type glGetCombinerInputParameterivNV,#function - .globl glGetCombinerOutputParameterfvNV ; .type glGetCombinerOutputParameterfvNV,#function - .globl glGetCombinerOutputParameterivNV ; .type glGetCombinerOutputParameterivNV,#function - .globl glGetFinalCombinerInputParameterfvNV ; .type glGetFinalCombinerInputParameterfvNV,#function - .globl glGetFinalCombinerInputParameterivNV ; .type glGetFinalCombinerInputParameterivNV,#function - .globl glResizeBuffersMESA ; .type glResizeBuffersMESA,#function - .globl glWindowPos2dMESA ; .type glWindowPos2dMESA,#function - .globl glWindowPos2dvMESA ; .type glWindowPos2dvMESA,#function - .globl glWindowPos2fMESA ; .type glWindowPos2fMESA,#function - .globl glWindowPos2fvMESA ; .type glWindowPos2fvMESA,#function - .globl glWindowPos2iMESA ; .type glWindowPos2iMESA,#function - .globl glWindowPos2ivMESA ; .type glWindowPos2ivMESA,#function - .globl glWindowPos2sMESA ; .type glWindowPos2sMESA,#function - .globl glWindowPos2svMESA ; .type glWindowPos2svMESA,#function - .globl glWindowPos3dMESA ; .type glWindowPos3dMESA,#function - .globl glWindowPos3dvMESA ; .type glWindowPos3dvMESA,#function - .globl glWindowPos3fMESA ; .type glWindowPos3fMESA,#function - .globl glWindowPos3fvMESA ; .type glWindowPos3fvMESA,#function - .globl glWindowPos3iMESA ; .type glWindowPos3iMESA,#function - .globl glWindowPos3ivMESA ; .type glWindowPos3ivMESA,#function - .globl glWindowPos3sMESA ; .type glWindowPos3sMESA,#function - .globl glWindowPos3svMESA ; .type glWindowPos3svMESA,#function - .globl glWindowPos4dMESA ; .type glWindowPos4dMESA,#function - .globl glWindowPos4dvMESA ; .type glWindowPos4dvMESA,#function - .globl glWindowPos4fMESA ; .type glWindowPos4fMESA,#function - .globl glWindowPos4fvMESA ; .type glWindowPos4fvMESA,#function - .globl glWindowPos4iMESA ; .type glWindowPos4iMESA,#function - .globl glWindowPos4ivMESA ; .type glWindowPos4ivMESA,#function - .globl glWindowPos4sMESA ; .type glWindowPos4sMESA,#function - .globl glWindowPos4svMESA ; .type glWindowPos4svMESA,#function - .globl gl_dispatch_stub_649 ; .type gl_dispatch_stub_649,#function - .globl gl_dispatch_stub_650 ; .type gl_dispatch_stub_650,#function - .globl gl_dispatch_stub_651 ; .type gl_dispatch_stub_651,#function - .globl gl_dispatch_stub_652 ; .type gl_dispatch_stub_652,#function - .globl gl_dispatch_stub_653 ; .type gl_dispatch_stub_653,#function - .globl gl_dispatch_stub_654 ; .type gl_dispatch_stub_654,#function - .globl gl_dispatch_stub_655 ; .type gl_dispatch_stub_655,#function - .globl gl_dispatch_stub_656 ; .type gl_dispatch_stub_656,#function - .globl gl_dispatch_stub_657 ; .type gl_dispatch_stub_657,#function - .globl glAreProgramsResidentNV ; .type glAreProgramsResidentNV,#function - .globl glBindProgramNV ; .type glBindProgramNV,#function - .globl glDeleteProgramsNV ; .type glDeleteProgramsNV,#function - .globl glExecuteProgramNV ; .type glExecuteProgramNV,#function - .globl glGenProgramsNV ; .type glGenProgramsNV,#function - .globl glGetProgramParameterdvNV ; .type glGetProgramParameterdvNV,#function - .globl glGetProgramParameterfvNV ; .type glGetProgramParameterfvNV,#function - .globl glGetProgramStringNV ; .type glGetProgramStringNV,#function - .globl glGetProgramivNV ; .type glGetProgramivNV,#function - .globl glGetTrackMatrixivNV ; .type glGetTrackMatrixivNV,#function - .globl glGetVertexAttribPointervNV ; .type glGetVertexAttribPointervNV,#function - .globl glGetVertexAttribdvNV ; .type glGetVertexAttribdvNV,#function - .globl glGetVertexAttribfvNV ; .type glGetVertexAttribfvNV,#function - .globl glGetVertexAttribivNV ; .type glGetVertexAttribivNV,#function - .globl glIsProgramNV ; .type glIsProgramNV,#function - .globl glLoadProgramNV ; .type glLoadProgramNV,#function - .globl glProgramParameters4dvNV ; .type glProgramParameters4dvNV,#function - .globl glProgramParameters4fvNV ; .type glProgramParameters4fvNV,#function - .globl glRequestResidentProgramsNV ; .type glRequestResidentProgramsNV,#function - .globl glTrackMatrixNV ; .type glTrackMatrixNV,#function - .globl glVertexAttrib1dNV ; .type glVertexAttrib1dNV,#function - .globl glVertexAttrib1dvNV ; .type glVertexAttrib1dvNV,#function - .globl glVertexAttrib1fNV ; .type glVertexAttrib1fNV,#function - .globl glVertexAttrib1fvNV ; .type glVertexAttrib1fvNV,#function - .globl glVertexAttrib1sNV ; .type glVertexAttrib1sNV,#function - .globl glVertexAttrib1svNV ; .type glVertexAttrib1svNV,#function - .globl glVertexAttrib2dNV ; .type glVertexAttrib2dNV,#function - .globl glVertexAttrib2dvNV ; .type glVertexAttrib2dvNV,#function - .globl glVertexAttrib2fNV ; .type glVertexAttrib2fNV,#function - .globl glVertexAttrib2fvNV ; .type glVertexAttrib2fvNV,#function - .globl glVertexAttrib2sNV ; .type glVertexAttrib2sNV,#function - .globl glVertexAttrib2svNV ; .type glVertexAttrib2svNV,#function - .globl glVertexAttrib3dNV ; .type glVertexAttrib3dNV,#function - .globl glVertexAttrib3dvNV ; .type glVertexAttrib3dvNV,#function - .globl glVertexAttrib3fNV ; .type glVertexAttrib3fNV,#function - .globl glVertexAttrib3fvNV ; .type glVertexAttrib3fvNV,#function - .globl glVertexAttrib3sNV ; .type glVertexAttrib3sNV,#function - .globl glVertexAttrib3svNV ; .type glVertexAttrib3svNV,#function - .globl glVertexAttrib4dNV ; .type glVertexAttrib4dNV,#function - .globl glVertexAttrib4dvNV ; .type glVertexAttrib4dvNV,#function - .globl glVertexAttrib4fNV ; .type glVertexAttrib4fNV,#function - .globl glVertexAttrib4fvNV ; .type glVertexAttrib4fvNV,#function - .globl glVertexAttrib4sNV ; .type glVertexAttrib4sNV,#function - .globl glVertexAttrib4svNV ; .type glVertexAttrib4svNV,#function - .globl glVertexAttrib4ubNV ; .type glVertexAttrib4ubNV,#function - .globl glVertexAttrib4ubvNV ; .type glVertexAttrib4ubvNV,#function - .globl glVertexAttribPointerNV ; .type glVertexAttribPointerNV,#function - .globl glVertexAttribs1dvNV ; .type glVertexAttribs1dvNV,#function - .globl glVertexAttribs1fvNV ; .type glVertexAttribs1fvNV,#function - .globl glVertexAttribs1svNV ; .type glVertexAttribs1svNV,#function - .globl glVertexAttribs2dvNV ; .type glVertexAttribs2dvNV,#function - .globl glVertexAttribs2fvNV ; .type glVertexAttribs2fvNV,#function - .globl glVertexAttribs2svNV ; .type glVertexAttribs2svNV,#function - .globl glVertexAttribs3dvNV ; .type glVertexAttribs3dvNV,#function - .globl glVertexAttribs3fvNV ; .type glVertexAttribs3fvNV,#function - .globl glVertexAttribs3svNV ; .type glVertexAttribs3svNV,#function - .globl glVertexAttribs4dvNV ; .type glVertexAttribs4dvNV,#function - .globl glVertexAttribs4fvNV ; .type glVertexAttribs4fvNV,#function - .globl glVertexAttribs4svNV ; .type glVertexAttribs4svNV,#function - .globl glVertexAttribs4ubvNV ; .type glVertexAttribs4ubvNV,#function - .globl glAlphaFragmentOp1ATI ; .type glAlphaFragmentOp1ATI,#function - .globl glAlphaFragmentOp2ATI ; .type glAlphaFragmentOp2ATI,#function - .globl glAlphaFragmentOp3ATI ; .type glAlphaFragmentOp3ATI,#function - .globl glBeginFragmentShaderATI ; .type glBeginFragmentShaderATI,#function - .globl glBindFragmentShaderATI ; .type glBindFragmentShaderATI,#function - .globl glColorFragmentOp1ATI ; .type glColorFragmentOp1ATI,#function - .globl glColorFragmentOp2ATI ; .type glColorFragmentOp2ATI,#function - .globl glColorFragmentOp3ATI ; .type glColorFragmentOp3ATI,#function - .globl glDeleteFragmentShaderATI ; .type glDeleteFragmentShaderATI,#function - .globl glEndFragmentShaderATI ; .type glEndFragmentShaderATI,#function - .globl glGenFragmentShadersATI ; .type glGenFragmentShadersATI,#function - .globl glPassTexCoordATI ; .type glPassTexCoordATI,#function - .globl glSampleMapATI ; .type glSampleMapATI,#function - .globl glSetFragmentShaderConstantATI ; .type glSetFragmentShaderConstantATI,#function - .globl glPointParameteriNV ; .type glPointParameteriNV,#function - .globl glPointParameterivNV ; .type glPointParameterivNV,#function - .globl gl_dispatch_stub_734 ; .type gl_dispatch_stub_734,#function - .globl gl_dispatch_stub_735 ; .type gl_dispatch_stub_735,#function - .globl gl_dispatch_stub_736 ; .type gl_dispatch_stub_736,#function - .globl gl_dispatch_stub_737 ; .type gl_dispatch_stub_737,#function - .globl gl_dispatch_stub_738 ; .type gl_dispatch_stub_738,#function - .globl glGetProgramNamedParameterdvNV ; .type glGetProgramNamedParameterdvNV,#function - .globl glGetProgramNamedParameterfvNV ; .type glGetProgramNamedParameterfvNV,#function - .globl glProgramNamedParameter4dNV ; .type glProgramNamedParameter4dNV,#function - .globl glProgramNamedParameter4dvNV ; .type glProgramNamedParameter4dvNV,#function - .globl glProgramNamedParameter4fNV ; .type glProgramNamedParameter4fNV,#function - .globl glProgramNamedParameter4fvNV ; .type glProgramNamedParameter4fvNV,#function - .globl gl_dispatch_stub_745 ; .type gl_dispatch_stub_745,#function - .globl gl_dispatch_stub_746 ; .type gl_dispatch_stub_746,#function - .globl glBindFramebufferEXT ; .type glBindFramebufferEXT,#function - .globl glBindRenderbufferEXT ; .type glBindRenderbufferEXT,#function - .globl glCheckFramebufferStatusEXT ; .type glCheckFramebufferStatusEXT,#function - .globl glDeleteFramebuffersEXT ; .type glDeleteFramebuffersEXT,#function - .globl glDeleteRenderbuffersEXT ; .type glDeleteRenderbuffersEXT,#function - .globl glFramebufferRenderbufferEXT ; .type glFramebufferRenderbufferEXT,#function - .globl glFramebufferTexture1DEXT ; .type glFramebufferTexture1DEXT,#function - .globl glFramebufferTexture2DEXT ; .type glFramebufferTexture2DEXT,#function - .globl glFramebufferTexture3DEXT ; .type glFramebufferTexture3DEXT,#function - .globl glGenFramebuffersEXT ; .type glGenFramebuffersEXT,#function - .globl glGenRenderbuffersEXT ; .type glGenRenderbuffersEXT,#function - .globl glGenerateMipmapEXT ; .type glGenerateMipmapEXT,#function - .globl glGetFramebufferAttachmentParameterivEXT ; .type glGetFramebufferAttachmentParameterivEXT,#function - .globl glGetRenderbufferParameterivEXT ; .type glGetRenderbufferParameterivEXT,#function - .globl glIsFramebufferEXT ; .type glIsFramebufferEXT,#function - .globl glIsRenderbufferEXT ; .type glIsRenderbufferEXT,#function - .globl glRenderbufferStorageEXT ; .type glRenderbufferStorageEXT,#function - .globl gl_dispatch_stub_764 ; .type gl_dispatch_stub_764,#function - .globl glFramebufferTextureLayerEXT ; .type glFramebufferTextureLayerEXT,#function - .globl gl_dispatch_stub_766 ; .type gl_dispatch_stub_766,#function - .globl gl_dispatch_stub_767 ; .type gl_dispatch_stub_767,#function - .globl gl_dispatch_stub_768 ; .type gl_dispatch_stub_768,#function - .globl gl_dispatch_stub_769 ; .type gl_dispatch_stub_769,#function - .globl gl_dispatch_stub_770 ; .type gl_dispatch_stub_770,#function - .globl _mesa_sparc_glapi_begin ; .type _mesa_sparc_glapi_begin,#function -_mesa_sparc_glapi_begin: + .data + .align 32 + + GLOBL_FN(__glapi_sparc_pthread_stub) + HIDDEN(__glapi_sparc_pthread_stub) +__glapi_sparc_pthread_stub: /* Call offset in %g3 */ + mov %o7, %g1 + sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %g2 + call __glapi_sparc_get_pc + add %g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2 + mov %g1, %o7 + sethi %hi(_glapi_Dispatch), %g1 + or %g1, %lo(_glapi_Dispatch), %g1 + srl %g3, 10, %g3 + GL_LL [%g2+%g1], %g2 + GL_LL [%g2], %g1 + cmp %g1, 0 + be 2f + nop +1: GL_LL [%g1 + %g3], %g1 + jmp %g1 + nop +2: save %sp, GL_STACK_SIZE, %sp + mov %g3, %l0 + call _glapi_get_dispatch + nop + mov %o0, %g1 + mov %l0, %g3 + ba 1b + restore %g0, %g0, %g0 + .size __glapi_sparc_pthread_stub, .-__glapi_sparc_pthread_stub + +#define GL_STUB(fn, off) \ + GLOBL_FN(fn); \ +fn: ba __glapi_sparc_pthread_stub; \ + sethi GL_OFF(off), %g3; \ + .size fn,.-fn; + +#else /* Non-threaded version. */ + + .type __glapi_sparc_nothread_stub, @function +__glapi_sparc_nothread_stub: /* Call offset in %g3 */ + mov %o7, %g1 + sethi %hi(_GLOBAL_OFFSET_TABLE_-4), %g2 + call __glapi_sparc_get_pc + add %g2, %lo(_GLOBAL_OFFSET_TABLE_+4), %g2 + mov %g1, %o7 + srl %g3, 10, %g3 + sethi %hi(_glapi_Dispatch), %g1 + or %g1, %lo(_glapi_Dispatch), %g1 + GL_LL [%g2+%g1], %g2 + GL_LL [%g2], %g1 + GL_LL [%g1 + %g3], %g1 + jmp %g1 + nop + .size __glapi_sparc_nothread_stub, .-__glapi_sparc_nothread_stub + +#define GL_STUB(fn, off) \ + GLOBL_FN(fn); \ +fn: ba __glapi_sparc_nothread_stub; \ + sethi GL_OFF(off), %g3; \ + .size fn,.-fn; + +#endif + +#define GL_STUB_ALIAS(fn, alias) \ + .globl fn; \ + .set fn, alias + + .text + .align 32 + + .globl gl_dispatch_functions_start + HIDDEN(gl_dispatch_functions_start) +gl_dispatch_functions_start: GL_STUB(glNewList, _gloffset_NewList) GL_STUB(glEndList, _gloffset_EndList) @@ -1402,14 +760,22 @@ _mesa_sparc_glapi_begin: GL_STUB(glDrawBuffersARB, _gloffset_DrawBuffersARB) GL_STUB(glRenderbufferStorageMultisample, _gloffset_RenderbufferStorageMultisample) GL_STUB(glPolygonOffsetEXT, _gloffset_PolygonOffsetEXT) - GL_STUB(gl_dispatch_stub_563, _gloffset__dispatch_stub_563) - GL_STUB(gl_dispatch_stub_564, _gloffset__dispatch_stub_564) - GL_STUB(gl_dispatch_stub_565, _gloffset__dispatch_stub_565) - GL_STUB(gl_dispatch_stub_566, _gloffset__dispatch_stub_566) - GL_STUB(gl_dispatch_stub_567, _gloffset__dispatch_stub_567) - GL_STUB(gl_dispatch_stub_568, _gloffset__dispatch_stub_568) - GL_STUB(gl_dispatch_stub_569, _gloffset__dispatch_stub_569) - GL_STUB(gl_dispatch_stub_570, _gloffset__dispatch_stub_570) + GL_STUB(gl_dispatch_stub_563, _gloffset_GetPixelTexGenParameterfvSGIS) + HIDDEN(gl_dispatch_stub_563) + GL_STUB(gl_dispatch_stub_564, _gloffset_GetPixelTexGenParameterivSGIS) + HIDDEN(gl_dispatch_stub_564) + GL_STUB(gl_dispatch_stub_565, _gloffset_PixelTexGenParameterfSGIS) + HIDDEN(gl_dispatch_stub_565) + GL_STUB(gl_dispatch_stub_566, _gloffset_PixelTexGenParameterfvSGIS) + HIDDEN(gl_dispatch_stub_566) + GL_STUB(gl_dispatch_stub_567, _gloffset_PixelTexGenParameteriSGIS) + HIDDEN(gl_dispatch_stub_567) + GL_STUB(gl_dispatch_stub_568, _gloffset_PixelTexGenParameterivSGIS) + HIDDEN(gl_dispatch_stub_568) + GL_STUB(gl_dispatch_stub_569, _gloffset_SampleMaskSGIS) + HIDDEN(gl_dispatch_stub_569) + GL_STUB(gl_dispatch_stub_570, _gloffset_SamplePatternSGIS) + HIDDEN(gl_dispatch_stub_570) GL_STUB(glColorPointerEXT, _gloffset_ColorPointerEXT) GL_STUB(glEdgeFlagPointerEXT, _gloffset_EdgeFlagPointerEXT) GL_STUB(glIndexPointerEXT, _gloffset_IndexPointerEXT) @@ -1420,8 +786,10 @@ _mesa_sparc_glapi_begin: GL_STUB(glPointParameterfvEXT, _gloffset_PointParameterfvEXT) GL_STUB(glLockArraysEXT, _gloffset_LockArraysEXT) GL_STUB(glUnlockArraysEXT, _gloffset_UnlockArraysEXT) - GL_STUB(gl_dispatch_stub_581, _gloffset__dispatch_stub_581) - GL_STUB(gl_dispatch_stub_582, _gloffset__dispatch_stub_582) + GL_STUB(gl_dispatch_stub_581, _gloffset_CullParameterdvEXT) + HIDDEN(gl_dispatch_stub_581) + GL_STUB(gl_dispatch_stub_582, _gloffset_CullParameterfvEXT) + HIDDEN(gl_dispatch_stub_582) GL_STUB(glSecondaryColor3bEXT, _gloffset_SecondaryColor3bEXT) GL_STUB(glSecondaryColor3bvEXT, _gloffset_SecondaryColor3bvEXT) GL_STUB(glSecondaryColor3dEXT, _gloffset_SecondaryColor3dEXT) @@ -1446,7 +814,8 @@ _mesa_sparc_glapi_begin: GL_STUB(glFogCoorddvEXT, _gloffset_FogCoorddvEXT) GL_STUB(glFogCoordfEXT, _gloffset_FogCoordfEXT) GL_STUB(glFogCoordfvEXT, _gloffset_FogCoordfvEXT) - GL_STUB(gl_dispatch_stub_607, _gloffset__dispatch_stub_607) + GL_STUB(gl_dispatch_stub_607, _gloffset_PixelTexGenSGIX) + HIDDEN(gl_dispatch_stub_607) GL_STUB(glBlendFuncSeparateEXT, _gloffset_BlendFuncSeparateEXT) GL_STUB(glFlushVertexArrayRangeNV, _gloffset_FlushVertexArrayRangeNV) GL_STUB(glVertexArrayRangeNV, _gloffset_VertexArrayRangeNV) @@ -1488,15 +857,24 @@ _mesa_sparc_glapi_begin: GL_STUB(glWindowPos4ivMESA, _gloffset_WindowPos4ivMESA) GL_STUB(glWindowPos4sMESA, _gloffset_WindowPos4sMESA) GL_STUB(glWindowPos4svMESA, _gloffset_WindowPos4svMESA) - GL_STUB(gl_dispatch_stub_649, _gloffset__dispatch_stub_649) - GL_STUB(gl_dispatch_stub_650, _gloffset__dispatch_stub_650) - GL_STUB(gl_dispatch_stub_651, _gloffset__dispatch_stub_651) - GL_STUB(gl_dispatch_stub_652, _gloffset__dispatch_stub_652) - GL_STUB(gl_dispatch_stub_653, _gloffset__dispatch_stub_653) - GL_STUB(gl_dispatch_stub_654, _gloffset__dispatch_stub_654) - GL_STUB(gl_dispatch_stub_655, _gloffset__dispatch_stub_655) - GL_STUB(gl_dispatch_stub_656, _gloffset__dispatch_stub_656) - GL_STUB(gl_dispatch_stub_657, _gloffset__dispatch_stub_657) + GL_STUB(gl_dispatch_stub_649, _gloffset_MultiModeDrawArraysIBM) + HIDDEN(gl_dispatch_stub_649) + GL_STUB(gl_dispatch_stub_650, _gloffset_MultiModeDrawElementsIBM) + HIDDEN(gl_dispatch_stub_650) + GL_STUB(gl_dispatch_stub_651, _gloffset_DeleteFencesNV) + HIDDEN(gl_dispatch_stub_651) + GL_STUB(gl_dispatch_stub_652, _gloffset_FinishFenceNV) + HIDDEN(gl_dispatch_stub_652) + GL_STUB(gl_dispatch_stub_653, _gloffset_GenFencesNV) + HIDDEN(gl_dispatch_stub_653) + GL_STUB(gl_dispatch_stub_654, _gloffset_GetFenceivNV) + HIDDEN(gl_dispatch_stub_654) + GL_STUB(gl_dispatch_stub_655, _gloffset_IsFenceNV) + HIDDEN(gl_dispatch_stub_655) + GL_STUB(gl_dispatch_stub_656, _gloffset_SetFenceNV) + HIDDEN(gl_dispatch_stub_656) + GL_STUB(gl_dispatch_stub_657, _gloffset_TestFenceNV) + HIDDEN(gl_dispatch_stub_657) GL_STUB(glAreProgramsResidentNV, _gloffset_AreProgramsResidentNV) GL_STUB(glBindProgramNV, _gloffset_BindProgramNV) GL_STUB(glDeleteProgramsNV, _gloffset_DeleteProgramsNV) @@ -1573,19 +951,26 @@ _mesa_sparc_glapi_begin: GL_STUB(glSetFragmentShaderConstantATI, _gloffset_SetFragmentShaderConstantATI) GL_STUB(glPointParameteriNV, _gloffset_PointParameteriNV) GL_STUB(glPointParameterivNV, _gloffset_PointParameterivNV) - GL_STUB(gl_dispatch_stub_734, _gloffset__dispatch_stub_734) - GL_STUB(gl_dispatch_stub_735, _gloffset__dispatch_stub_735) - GL_STUB(gl_dispatch_stub_736, _gloffset__dispatch_stub_736) - GL_STUB(gl_dispatch_stub_737, _gloffset__dispatch_stub_737) - GL_STUB(gl_dispatch_stub_738, _gloffset__dispatch_stub_738) + GL_STUB(gl_dispatch_stub_734, _gloffset_ActiveStencilFaceEXT) + HIDDEN(gl_dispatch_stub_734) + GL_STUB(gl_dispatch_stub_735, _gloffset_BindVertexArrayAPPLE) + HIDDEN(gl_dispatch_stub_735) + GL_STUB(gl_dispatch_stub_736, _gloffset_DeleteVertexArraysAPPLE) + HIDDEN(gl_dispatch_stub_736) + GL_STUB(gl_dispatch_stub_737, _gloffset_GenVertexArraysAPPLE) + HIDDEN(gl_dispatch_stub_737) + GL_STUB(gl_dispatch_stub_738, _gloffset_IsVertexArrayAPPLE) + HIDDEN(gl_dispatch_stub_738) GL_STUB(glGetProgramNamedParameterdvNV, _gloffset_GetProgramNamedParameterdvNV) GL_STUB(glGetProgramNamedParameterfvNV, _gloffset_GetProgramNamedParameterfvNV) GL_STUB(glProgramNamedParameter4dNV, _gloffset_ProgramNamedParameter4dNV) GL_STUB(glProgramNamedParameter4dvNV, _gloffset_ProgramNamedParameter4dvNV) GL_STUB(glProgramNamedParameter4fNV, _gloffset_ProgramNamedParameter4fNV) GL_STUB(glProgramNamedParameter4fvNV, _gloffset_ProgramNamedParameter4fvNV) - GL_STUB(gl_dispatch_stub_745, _gloffset__dispatch_stub_745) - GL_STUB(gl_dispatch_stub_746, _gloffset__dispatch_stub_746) + GL_STUB(gl_dispatch_stub_745, _gloffset_DepthBoundsEXT) + HIDDEN(gl_dispatch_stub_745) + GL_STUB(gl_dispatch_stub_746, _gloffset_BlendEquationSeparateEXT) + HIDDEN(gl_dispatch_stub_746) GL_STUB(glBindFramebufferEXT, _gloffset_BindFramebufferEXT) GL_STUB(glBindRenderbufferEXT, _gloffset_BindRenderbufferEXT) GL_STUB(glCheckFramebufferStatusEXT, _gloffset_CheckFramebufferStatusEXT) @@ -1603,287 +988,353 @@ _mesa_sparc_glapi_begin: GL_STUB(glIsFramebufferEXT, _gloffset_IsFramebufferEXT) GL_STUB(glIsRenderbufferEXT, _gloffset_IsRenderbufferEXT) GL_STUB(glRenderbufferStorageEXT, _gloffset_RenderbufferStorageEXT) - GL_STUB(gl_dispatch_stub_764, _gloffset__dispatch_stub_764) + GL_STUB(gl_dispatch_stub_764, _gloffset_BlitFramebufferEXT) + HIDDEN(gl_dispatch_stub_764) GL_STUB(glFramebufferTextureLayerEXT, _gloffset_FramebufferTextureLayerEXT) - GL_STUB(gl_dispatch_stub_766, _gloffset__dispatch_stub_766) - GL_STUB(gl_dispatch_stub_767, _gloffset__dispatch_stub_767) - GL_STUB(gl_dispatch_stub_768, _gloffset__dispatch_stub_768) - GL_STUB(gl_dispatch_stub_769, _gloffset__dispatch_stub_769) - GL_STUB(gl_dispatch_stub_770, _gloffset__dispatch_stub_770) - - .globl _mesa_sparc_glapi_end ; .type _mesa_sparc_glapi_end,#function -_mesa_sparc_glapi_end: - - .globl glArrayElementEXT ; .type glArrayElementEXT,#function ; glArrayElementEXT = glArrayElement - .globl glBindTextureEXT ; .type glBindTextureEXT,#function ; glBindTextureEXT = glBindTexture - .globl glDrawArraysEXT ; .type glDrawArraysEXT,#function ; glDrawArraysEXT = glDrawArrays + GL_STUB(gl_dispatch_stub_766, _gloffset_StencilFuncSeparateATI) + HIDDEN(gl_dispatch_stub_766) + GL_STUB(gl_dispatch_stub_767, _gloffset_ProgramEnvParameters4fvEXT) + HIDDEN(gl_dispatch_stub_767) + GL_STUB(gl_dispatch_stub_768, _gloffset_ProgramLocalParameters4fvEXT) + HIDDEN(gl_dispatch_stub_768) + GL_STUB(gl_dispatch_stub_769, _gloffset_GetQueryObjecti64vEXT) + HIDDEN(gl_dispatch_stub_769) + GL_STUB(gl_dispatch_stub_770, _gloffset_GetQueryObjectui64vEXT) + HIDDEN(gl_dispatch_stub_770) + GL_STUB_ALIAS(glArrayElementEXT, glArrayElement) + GL_STUB_ALIAS(glBindTextureEXT, glBindTexture) + GL_STUB_ALIAS(glDrawArraysEXT, glDrawArrays) +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glAreTexturesResidentEXT, glAreTexturesResident) +#endif + GL_STUB_ALIAS(glCopyTexImage1DEXT, glCopyTexImage1D) + GL_STUB_ALIAS(glCopyTexImage2DEXT, glCopyTexImage2D) + GL_STUB_ALIAS(glCopyTexSubImage1DEXT, glCopyTexSubImage1D) + GL_STUB_ALIAS(glCopyTexSubImage2DEXT, glCopyTexSubImage2D) +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glDeleteTexturesEXT, glDeleteTextures) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGenTexturesEXT, glGenTextures) +#endif + GL_STUB_ALIAS(glGetPointervEXT, glGetPointerv) +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glIsTextureEXT, glIsTexture) +#endif + GL_STUB_ALIAS(glPrioritizeTexturesEXT, glPrioritizeTextures) + GL_STUB_ALIAS(glTexSubImage1DEXT, glTexSubImage1D) + GL_STUB_ALIAS(glTexSubImage2DEXT, glTexSubImage2D) + GL_STUB_ALIAS(glBlendColorEXT, glBlendColor) + GL_STUB_ALIAS(glBlendEquationEXT, glBlendEquation) + GL_STUB_ALIAS(glDrawRangeElementsEXT, glDrawRangeElements) + GL_STUB_ALIAS(glColorTableSGI, glColorTable) + GL_STUB_ALIAS(glColorTableEXT, glColorTable) + GL_STUB_ALIAS(glColorTableParameterfvSGI, glColorTableParameterfv) + GL_STUB_ALIAS(glColorTableParameterivSGI, glColorTableParameteriv) + GL_STUB_ALIAS(glCopyColorTableSGI, glCopyColorTable) +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetColorTableSGI, glGetColorTable) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetColorTableEXT, glGetColorTable) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetColorTableParameterfvSGI, glGetColorTableParameterfv) +#endif #ifndef GLX_INDIRECT_RENDERING - .globl glAreTexturesResidentEXT ; .type glAreTexturesResidentEXT,#function ; glAreTexturesResidentEXT = glAreTexturesResident + GL_STUB_ALIAS(glGetColorTableParameterfvEXT, glGetColorTableParameterfv) #endif - .globl glCopyTexImage1DEXT ; .type glCopyTexImage1DEXT,#function ; glCopyTexImage1DEXT = glCopyTexImage1D - .globl glCopyTexImage2DEXT ; .type glCopyTexImage2DEXT,#function ; glCopyTexImage2DEXT = glCopyTexImage2D - .globl glCopyTexSubImage1DEXT ; .type glCopyTexSubImage1DEXT,#function ; glCopyTexSubImage1DEXT = glCopyTexSubImage1D - .globl glCopyTexSubImage2DEXT ; .type glCopyTexSubImage2DEXT,#function ; glCopyTexSubImage2DEXT = glCopyTexSubImage2D #ifndef GLX_INDIRECT_RENDERING - .globl glDeleteTexturesEXT ; .type glDeleteTexturesEXT,#function ; glDeleteTexturesEXT = glDeleteTextures + GL_STUB_ALIAS(glGetColorTableParameterivSGI, glGetColorTableParameteriv) #endif #ifndef GLX_INDIRECT_RENDERING - .globl glGenTexturesEXT ; .type glGenTexturesEXT,#function ; glGenTexturesEXT = glGenTextures + GL_STUB_ALIAS(glGetColorTableParameterivEXT, glGetColorTableParameteriv) #endif - .globl glGetPointervEXT ; .type glGetPointervEXT,#function ; glGetPointervEXT = glGetPointerv + GL_STUB_ALIAS(glColorSubTableEXT, glColorSubTable) + GL_STUB_ALIAS(glCopyColorSubTableEXT, glCopyColorSubTable) + GL_STUB_ALIAS(glConvolutionFilter1DEXT, glConvolutionFilter1D) + GL_STUB_ALIAS(glConvolutionFilter2DEXT, glConvolutionFilter2D) + GL_STUB_ALIAS(glConvolutionParameterfEXT, glConvolutionParameterf) + GL_STUB_ALIAS(glConvolutionParameterfvEXT, glConvolutionParameterfv) + GL_STUB_ALIAS(glConvolutionParameteriEXT, glConvolutionParameteri) + GL_STUB_ALIAS(glConvolutionParameterivEXT, glConvolutionParameteriv) + GL_STUB_ALIAS(glCopyConvolutionFilter1DEXT, glCopyConvolutionFilter1D) + GL_STUB_ALIAS(glCopyConvolutionFilter2DEXT, glCopyConvolutionFilter2D) #ifndef GLX_INDIRECT_RENDERING - .globl glIsTextureEXT ; .type glIsTextureEXT,#function ; glIsTextureEXT = glIsTexture + GL_STUB_ALIAS(glGetConvolutionFilterEXT, glGetConvolutionFilter) #endif - .globl glPrioritizeTexturesEXT ; .type glPrioritizeTexturesEXT,#function ; glPrioritizeTexturesEXT = glPrioritizeTextures - .globl glTexSubImage1DEXT ; .type glTexSubImage1DEXT,#function ; glTexSubImage1DEXT = glTexSubImage1D - .globl glTexSubImage2DEXT ; .type glTexSubImage2DEXT,#function ; glTexSubImage2DEXT = glTexSubImage2D - .globl glBlendColorEXT ; .type glBlendColorEXT,#function ; glBlendColorEXT = glBlendColor - .globl glBlendEquationEXT ; .type glBlendEquationEXT,#function ; glBlendEquationEXT = glBlendEquation - .globl glDrawRangeElementsEXT ; .type glDrawRangeElementsEXT,#function ; glDrawRangeElementsEXT = glDrawRangeElements - .globl glColorTableEXT ; .type glColorTableEXT,#function ; glColorTableEXT = glColorTable #ifndef GLX_INDIRECT_RENDERING - .globl glGetColorTableEXT ; .type glGetColorTableEXT,#function ; glGetColorTableEXT = glGetColorTable + GL_STUB_ALIAS(glGetConvolutionParameterfvEXT, glGetConvolutionParameterfv) #endif #ifndef GLX_INDIRECT_RENDERING - .globl glGetColorTableParameterfvEXT ; .type glGetColorTableParameterfvEXT,#function ; glGetColorTableParameterfvEXT = glGetColorTableParameterfv + GL_STUB_ALIAS(glGetConvolutionParameterivEXT, glGetConvolutionParameteriv) #endif #ifndef GLX_INDIRECT_RENDERING - .globl glGetColorTableParameterivEXT ; .type glGetColorTableParameterivEXT,#function ; glGetColorTableParameterivEXT = glGetColorTableParameteriv + GL_STUB_ALIAS(glGetSeparableFilterEXT, glGetSeparableFilter) #endif - .globl glTexImage3DEXT ; .type glTexImage3DEXT,#function ; glTexImage3DEXT = glTexImage3D - .globl glTexSubImage3DEXT ; .type glTexSubImage3DEXT,#function ; glTexSubImage3DEXT = glTexSubImage3D - .globl glCopyTexSubImage3DEXT ; .type glCopyTexSubImage3DEXT,#function ; glCopyTexSubImage3DEXT = glCopyTexSubImage3D - .globl glActiveTexture ; .type glActiveTexture,#function ; glActiveTexture = glActiveTextureARB - .globl glClientActiveTexture ; .type glClientActiveTexture,#function ; glClientActiveTexture = glClientActiveTextureARB - .globl glMultiTexCoord1d ; .type glMultiTexCoord1d,#function ; glMultiTexCoord1d = glMultiTexCoord1dARB - .globl glMultiTexCoord1dv ; .type glMultiTexCoord1dv,#function ; glMultiTexCoord1dv = glMultiTexCoord1dvARB - .globl glMultiTexCoord1f ; .type glMultiTexCoord1f,#function ; glMultiTexCoord1f = glMultiTexCoord1fARB - .globl glMultiTexCoord1fv ; .type glMultiTexCoord1fv,#function ; glMultiTexCoord1fv = glMultiTexCoord1fvARB - .globl glMultiTexCoord1i ; .type glMultiTexCoord1i,#function ; glMultiTexCoord1i = glMultiTexCoord1iARB - .globl glMultiTexCoord1iv ; .type glMultiTexCoord1iv,#function ; glMultiTexCoord1iv = glMultiTexCoord1ivARB - .globl glMultiTexCoord1s ; .type glMultiTexCoord1s,#function ; glMultiTexCoord1s = glMultiTexCoord1sARB - .globl glMultiTexCoord1sv ; .type glMultiTexCoord1sv,#function ; glMultiTexCoord1sv = glMultiTexCoord1svARB - .globl glMultiTexCoord2d ; .type glMultiTexCoord2d,#function ; glMultiTexCoord2d = glMultiTexCoord2dARB - .globl glMultiTexCoord2dv ; .type glMultiTexCoord2dv,#function ; glMultiTexCoord2dv = glMultiTexCoord2dvARB - .globl glMultiTexCoord2f ; .type glMultiTexCoord2f,#function ; glMultiTexCoord2f = glMultiTexCoord2fARB - .globl glMultiTexCoord2fv ; .type glMultiTexCoord2fv,#function ; glMultiTexCoord2fv = glMultiTexCoord2fvARB - .globl glMultiTexCoord2i ; .type glMultiTexCoord2i,#function ; glMultiTexCoord2i = glMultiTexCoord2iARB - .globl glMultiTexCoord2iv ; .type glMultiTexCoord2iv,#function ; glMultiTexCoord2iv = glMultiTexCoord2ivARB - .globl glMultiTexCoord2s ; .type glMultiTexCoord2s,#function ; glMultiTexCoord2s = glMultiTexCoord2sARB - .globl glMultiTexCoord2sv ; .type glMultiTexCoord2sv,#function ; glMultiTexCoord2sv = glMultiTexCoord2svARB - .globl glMultiTexCoord3d ; .type glMultiTexCoord3d,#function ; glMultiTexCoord3d = glMultiTexCoord3dARB - .globl glMultiTexCoord3dv ; .type glMultiTexCoord3dv,#function ; glMultiTexCoord3dv = glMultiTexCoord3dvARB - .globl glMultiTexCoord3f ; .type glMultiTexCoord3f,#function ; glMultiTexCoord3f = glMultiTexCoord3fARB - .globl glMultiTexCoord3fv ; .type glMultiTexCoord3fv,#function ; glMultiTexCoord3fv = glMultiTexCoord3fvARB - .globl glMultiTexCoord3i ; .type glMultiTexCoord3i,#function ; glMultiTexCoord3i = glMultiTexCoord3iARB - .globl glMultiTexCoord3iv ; .type glMultiTexCoord3iv,#function ; glMultiTexCoord3iv = glMultiTexCoord3ivARB - .globl glMultiTexCoord3s ; .type glMultiTexCoord3s,#function ; glMultiTexCoord3s = glMultiTexCoord3sARB - .globl glMultiTexCoord3sv ; .type glMultiTexCoord3sv,#function ; glMultiTexCoord3sv = glMultiTexCoord3svARB - .globl glMultiTexCoord4d ; .type glMultiTexCoord4d,#function ; glMultiTexCoord4d = glMultiTexCoord4dARB - .globl glMultiTexCoord4dv ; .type glMultiTexCoord4dv,#function ; glMultiTexCoord4dv = glMultiTexCoord4dvARB - .globl glMultiTexCoord4f ; .type glMultiTexCoord4f,#function ; glMultiTexCoord4f = glMultiTexCoord4fARB - .globl glMultiTexCoord4fv ; .type glMultiTexCoord4fv,#function ; glMultiTexCoord4fv = glMultiTexCoord4fvARB - .globl glMultiTexCoord4i ; .type glMultiTexCoord4i,#function ; glMultiTexCoord4i = glMultiTexCoord4iARB - .globl glMultiTexCoord4iv ; .type glMultiTexCoord4iv,#function ; glMultiTexCoord4iv = glMultiTexCoord4ivARB - .globl glMultiTexCoord4s ; .type glMultiTexCoord4s,#function ; glMultiTexCoord4s = glMultiTexCoord4sARB - .globl glMultiTexCoord4sv ; .type glMultiTexCoord4sv,#function ; glMultiTexCoord4sv = glMultiTexCoord4svARB - .globl glLoadTransposeMatrixd ; .type glLoadTransposeMatrixd,#function ; glLoadTransposeMatrixd = glLoadTransposeMatrixdARB - .globl glLoadTransposeMatrixf ; .type glLoadTransposeMatrixf,#function ; glLoadTransposeMatrixf = glLoadTransposeMatrixfARB - .globl glMultTransposeMatrixd ; .type glMultTransposeMatrixd,#function ; glMultTransposeMatrixd = glMultTransposeMatrixdARB - .globl glMultTransposeMatrixf ; .type glMultTransposeMatrixf,#function ; glMultTransposeMatrixf = glMultTransposeMatrixfARB - .globl glSampleCoverage ; .type glSampleCoverage,#function ; glSampleCoverage = glSampleCoverageARB - .globl glCompressedTexImage1D ; .type glCompressedTexImage1D,#function ; glCompressedTexImage1D = glCompressedTexImage1DARB - .globl glCompressedTexImage2D ; .type glCompressedTexImage2D,#function ; glCompressedTexImage2D = glCompressedTexImage2DARB - .globl glCompressedTexImage3D ; .type glCompressedTexImage3D,#function ; glCompressedTexImage3D = glCompressedTexImage3DARB - .globl glCompressedTexSubImage1D ; .type glCompressedTexSubImage1D,#function ; glCompressedTexSubImage1D = glCompressedTexSubImage1DARB - .globl glCompressedTexSubImage2D ; .type glCompressedTexSubImage2D,#function ; glCompressedTexSubImage2D = glCompressedTexSubImage2DARB - .globl glCompressedTexSubImage3D ; .type glCompressedTexSubImage3D,#function ; glCompressedTexSubImage3D = glCompressedTexSubImage3DARB - .globl glGetCompressedTexImage ; .type glGetCompressedTexImage,#function ; glGetCompressedTexImage = glGetCompressedTexImageARB - .globl glDisableVertexAttribArray ; .type glDisableVertexAttribArray,#function ; glDisableVertexAttribArray = glDisableVertexAttribArrayARB - .globl glEnableVertexAttribArray ; .type glEnableVertexAttribArray,#function ; glEnableVertexAttribArray = glEnableVertexAttribArrayARB - .globl glGetVertexAttribdv ; .type glGetVertexAttribdv,#function ; glGetVertexAttribdv = glGetVertexAttribdvARB - .globl glGetVertexAttribfv ; .type glGetVertexAttribfv,#function ; glGetVertexAttribfv = glGetVertexAttribfvARB - .globl glGetVertexAttribiv ; .type glGetVertexAttribiv,#function ; glGetVertexAttribiv = glGetVertexAttribivARB - .globl glProgramParameter4dNV ; .type glProgramParameter4dNV,#function ; glProgramParameter4dNV = glProgramEnvParameter4dARB - .globl glProgramParameter4dvNV ; .type glProgramParameter4dvNV,#function ; glProgramParameter4dvNV = glProgramEnvParameter4dvARB - .globl glProgramParameter4fNV ; .type glProgramParameter4fNV,#function ; glProgramParameter4fNV = glProgramEnvParameter4fARB - .globl glProgramParameter4fvNV ; .type glProgramParameter4fvNV,#function ; glProgramParameter4fvNV = glProgramEnvParameter4fvARB - .globl glVertexAttrib1d ; .type glVertexAttrib1d,#function ; glVertexAttrib1d = glVertexAttrib1dARB - .globl glVertexAttrib1dv ; .type glVertexAttrib1dv,#function ; glVertexAttrib1dv = glVertexAttrib1dvARB - .globl glVertexAttrib1f ; .type glVertexAttrib1f,#function ; glVertexAttrib1f = glVertexAttrib1fARB - .globl glVertexAttrib1fv ; .type glVertexAttrib1fv,#function ; glVertexAttrib1fv = glVertexAttrib1fvARB - .globl glVertexAttrib1s ; .type glVertexAttrib1s,#function ; glVertexAttrib1s = glVertexAttrib1sARB - .globl glVertexAttrib1sv ; .type glVertexAttrib1sv,#function ; glVertexAttrib1sv = glVertexAttrib1svARB - .globl glVertexAttrib2d ; .type glVertexAttrib2d,#function ; glVertexAttrib2d = glVertexAttrib2dARB - .globl glVertexAttrib2dv ; .type glVertexAttrib2dv,#function ; glVertexAttrib2dv = glVertexAttrib2dvARB - .globl glVertexAttrib2f ; .type glVertexAttrib2f,#function ; glVertexAttrib2f = glVertexAttrib2fARB - .globl glVertexAttrib2fv ; .type glVertexAttrib2fv,#function ; glVertexAttrib2fv = glVertexAttrib2fvARB - .globl glVertexAttrib2s ; .type glVertexAttrib2s,#function ; glVertexAttrib2s = glVertexAttrib2sARB - .globl glVertexAttrib2sv ; .type glVertexAttrib2sv,#function ; glVertexAttrib2sv = glVertexAttrib2svARB - .globl glVertexAttrib3d ; .type glVertexAttrib3d,#function ; glVertexAttrib3d = glVertexAttrib3dARB - .globl glVertexAttrib3dv ; .type glVertexAttrib3dv,#function ; glVertexAttrib3dv = glVertexAttrib3dvARB - .globl glVertexAttrib3f ; .type glVertexAttrib3f,#function ; glVertexAttrib3f = glVertexAttrib3fARB - .globl glVertexAttrib3fv ; .type glVertexAttrib3fv,#function ; glVertexAttrib3fv = glVertexAttrib3fvARB - .globl glVertexAttrib3s ; .type glVertexAttrib3s,#function ; glVertexAttrib3s = glVertexAttrib3sARB - .globl glVertexAttrib3sv ; .type glVertexAttrib3sv,#function ; glVertexAttrib3sv = glVertexAttrib3svARB - .globl glVertexAttrib4Nbv ; .type glVertexAttrib4Nbv,#function ; glVertexAttrib4Nbv = glVertexAttrib4NbvARB - .globl glVertexAttrib4Niv ; .type glVertexAttrib4Niv,#function ; glVertexAttrib4Niv = glVertexAttrib4NivARB - .globl glVertexAttrib4Nsv ; .type glVertexAttrib4Nsv,#function ; glVertexAttrib4Nsv = glVertexAttrib4NsvARB - .globl glVertexAttrib4Nub ; .type glVertexAttrib4Nub,#function ; glVertexAttrib4Nub = glVertexAttrib4NubARB - .globl glVertexAttrib4Nubv ; .type glVertexAttrib4Nubv,#function ; glVertexAttrib4Nubv = glVertexAttrib4NubvARB - .globl glVertexAttrib4Nuiv ; .type glVertexAttrib4Nuiv,#function ; glVertexAttrib4Nuiv = glVertexAttrib4NuivARB - .globl glVertexAttrib4Nusv ; .type glVertexAttrib4Nusv,#function ; glVertexAttrib4Nusv = glVertexAttrib4NusvARB - .globl glVertexAttrib4bv ; .type glVertexAttrib4bv,#function ; glVertexAttrib4bv = glVertexAttrib4bvARB - .globl glVertexAttrib4d ; .type glVertexAttrib4d,#function ; glVertexAttrib4d = glVertexAttrib4dARB - .globl glVertexAttrib4dv ; .type glVertexAttrib4dv,#function ; glVertexAttrib4dv = glVertexAttrib4dvARB - .globl glVertexAttrib4f ; .type glVertexAttrib4f,#function ; glVertexAttrib4f = glVertexAttrib4fARB - .globl glVertexAttrib4fv ; .type glVertexAttrib4fv,#function ; glVertexAttrib4fv = glVertexAttrib4fvARB - .globl glVertexAttrib4iv ; .type glVertexAttrib4iv,#function ; glVertexAttrib4iv = glVertexAttrib4ivARB - .globl glVertexAttrib4s ; .type glVertexAttrib4s,#function ; glVertexAttrib4s = glVertexAttrib4sARB - .globl glVertexAttrib4sv ; .type glVertexAttrib4sv,#function ; glVertexAttrib4sv = glVertexAttrib4svARB - .globl glVertexAttrib4ubv ; .type glVertexAttrib4ubv,#function ; glVertexAttrib4ubv = glVertexAttrib4ubvARB - .globl glVertexAttrib4uiv ; .type glVertexAttrib4uiv,#function ; glVertexAttrib4uiv = glVertexAttrib4uivARB - .globl glVertexAttrib4usv ; .type glVertexAttrib4usv,#function ; glVertexAttrib4usv = glVertexAttrib4usvARB - .globl glVertexAttribPointer ; .type glVertexAttribPointer,#function ; glVertexAttribPointer = glVertexAttribPointerARB - .globl glBindBuffer ; .type glBindBuffer,#function ; glBindBuffer = glBindBufferARB - .globl glBufferData ; .type glBufferData,#function ; glBufferData = glBufferDataARB - .globl glBufferSubData ; .type glBufferSubData,#function ; glBufferSubData = glBufferSubDataARB - .globl glDeleteBuffers ; .type glDeleteBuffers,#function ; glDeleteBuffers = glDeleteBuffersARB - .globl glGenBuffers ; .type glGenBuffers,#function ; glGenBuffers = glGenBuffersARB - .globl glGetBufferParameteriv ; .type glGetBufferParameteriv,#function ; glGetBufferParameteriv = glGetBufferParameterivARB - .globl glGetBufferPointerv ; .type glGetBufferPointerv,#function ; glGetBufferPointerv = glGetBufferPointervARB - .globl glGetBufferSubData ; .type glGetBufferSubData,#function ; glGetBufferSubData = glGetBufferSubDataARB - .globl glIsBuffer ; .type glIsBuffer,#function ; glIsBuffer = glIsBufferARB - .globl glMapBuffer ; .type glMapBuffer,#function ; glMapBuffer = glMapBufferARB - .globl glUnmapBuffer ; .type glUnmapBuffer,#function ; glUnmapBuffer = glUnmapBufferARB - .globl glBeginQuery ; .type glBeginQuery,#function ; glBeginQuery = glBeginQueryARB - .globl glDeleteQueries ; .type glDeleteQueries,#function ; glDeleteQueries = glDeleteQueriesARB - .globl glEndQuery ; .type glEndQuery,#function ; glEndQuery = glEndQueryARB - .globl glGenQueries ; .type glGenQueries,#function ; glGenQueries = glGenQueriesARB - .globl glGetQueryObjectiv ; .type glGetQueryObjectiv,#function ; glGetQueryObjectiv = glGetQueryObjectivARB - .globl glGetQueryObjectuiv ; .type glGetQueryObjectuiv,#function ; glGetQueryObjectuiv = glGetQueryObjectuivARB - .globl glGetQueryiv ; .type glGetQueryiv,#function ; glGetQueryiv = glGetQueryivARB - .globl glIsQuery ; .type glIsQuery,#function ; glIsQuery = glIsQueryARB - .globl glCompileShader ; .type glCompileShader,#function ; glCompileShader = glCompileShaderARB - .globl glGetActiveUniform ; .type glGetActiveUniform,#function ; glGetActiveUniform = glGetActiveUniformARB - .globl glGetShaderSource ; .type glGetShaderSource,#function ; glGetShaderSource = glGetShaderSourceARB - .globl glGetUniformLocation ; .type glGetUniformLocation,#function ; glGetUniformLocation = glGetUniformLocationARB - .globl glGetUniformfv ; .type glGetUniformfv,#function ; glGetUniformfv = glGetUniformfvARB - .globl glGetUniformiv ; .type glGetUniformiv,#function ; glGetUniformiv = glGetUniformivARB - .globl glLinkProgram ; .type glLinkProgram,#function ; glLinkProgram = glLinkProgramARB - .globl glShaderSource ; .type glShaderSource,#function ; glShaderSource = glShaderSourceARB - .globl glUniform1f ; .type glUniform1f,#function ; glUniform1f = glUniform1fARB - .globl glUniform1fv ; .type glUniform1fv,#function ; glUniform1fv = glUniform1fvARB - .globl glUniform1i ; .type glUniform1i,#function ; glUniform1i = glUniform1iARB - .globl glUniform1iv ; .type glUniform1iv,#function ; glUniform1iv = glUniform1ivARB - .globl glUniform2f ; .type glUniform2f,#function ; glUniform2f = glUniform2fARB - .globl glUniform2fv ; .type glUniform2fv,#function ; glUniform2fv = glUniform2fvARB - .globl glUniform2i ; .type glUniform2i,#function ; glUniform2i = glUniform2iARB - .globl glUniform2iv ; .type glUniform2iv,#function ; glUniform2iv = glUniform2ivARB - .globl glUniform3f ; .type glUniform3f,#function ; glUniform3f = glUniform3fARB - .globl glUniform3fv ; .type glUniform3fv,#function ; glUniform3fv = glUniform3fvARB - .globl glUniform3i ; .type glUniform3i,#function ; glUniform3i = glUniform3iARB - .globl glUniform3iv ; .type glUniform3iv,#function ; glUniform3iv = glUniform3ivARB - .globl glUniform4f ; .type glUniform4f,#function ; glUniform4f = glUniform4fARB - .globl glUniform4fv ; .type glUniform4fv,#function ; glUniform4fv = glUniform4fvARB - .globl glUniform4i ; .type glUniform4i,#function ; glUniform4i = glUniform4iARB - .globl glUniform4iv ; .type glUniform4iv,#function ; glUniform4iv = glUniform4ivARB - .globl glUniformMatrix2fv ; .type glUniformMatrix2fv,#function ; glUniformMatrix2fv = glUniformMatrix2fvARB - .globl glUniformMatrix3fv ; .type glUniformMatrix3fv,#function ; glUniformMatrix3fv = glUniformMatrix3fvARB - .globl glUniformMatrix4fv ; .type glUniformMatrix4fv,#function ; glUniformMatrix4fv = glUniformMatrix4fvARB - .globl glUseProgram ; .type glUseProgram,#function ; glUseProgram = glUseProgramObjectARB - .globl glValidateProgram ; .type glValidateProgram,#function ; glValidateProgram = glValidateProgramARB - .globl glBindAttribLocation ; .type glBindAttribLocation,#function ; glBindAttribLocation = glBindAttribLocationARB - .globl glGetActiveAttrib ; .type glGetActiveAttrib,#function ; glGetActiveAttrib = glGetActiveAttribARB - .globl glGetAttribLocation ; .type glGetAttribLocation,#function ; glGetAttribLocation = glGetAttribLocationARB - .globl glDrawBuffers ; .type glDrawBuffers,#function ; glDrawBuffers = glDrawBuffersARB - .globl glDrawBuffersATI ; .type glDrawBuffersATI,#function ; glDrawBuffersATI = glDrawBuffersARB - .globl glPointParameterf ; .type glPointParameterf,#function ; glPointParameterf = glPointParameterfEXT - .globl glPointParameterfARB ; .type glPointParameterfARB,#function ; glPointParameterfARB = glPointParameterfEXT - .globl glPointParameterfv ; .type glPointParameterfv,#function ; glPointParameterfv = glPointParameterfvEXT - .globl glPointParameterfvARB ; .type glPointParameterfvARB,#function ; glPointParameterfvARB = glPointParameterfvEXT - .globl glSecondaryColor3b ; .type glSecondaryColor3b,#function ; glSecondaryColor3b = glSecondaryColor3bEXT - .globl glSecondaryColor3bv ; .type glSecondaryColor3bv,#function ; glSecondaryColor3bv = glSecondaryColor3bvEXT - .globl glSecondaryColor3d ; .type glSecondaryColor3d,#function ; glSecondaryColor3d = glSecondaryColor3dEXT - .globl glSecondaryColor3dv ; .type glSecondaryColor3dv,#function ; glSecondaryColor3dv = glSecondaryColor3dvEXT - .globl glSecondaryColor3f ; .type glSecondaryColor3f,#function ; glSecondaryColor3f = glSecondaryColor3fEXT - .globl glSecondaryColor3fv ; .type glSecondaryColor3fv,#function ; glSecondaryColor3fv = glSecondaryColor3fvEXT - .globl glSecondaryColor3i ; .type glSecondaryColor3i,#function ; glSecondaryColor3i = glSecondaryColor3iEXT - .globl glSecondaryColor3iv ; .type glSecondaryColor3iv,#function ; glSecondaryColor3iv = glSecondaryColor3ivEXT - .globl glSecondaryColor3s ; .type glSecondaryColor3s,#function ; glSecondaryColor3s = glSecondaryColor3sEXT - .globl glSecondaryColor3sv ; .type glSecondaryColor3sv,#function ; glSecondaryColor3sv = glSecondaryColor3svEXT - .globl glSecondaryColor3ub ; .type glSecondaryColor3ub,#function ; glSecondaryColor3ub = glSecondaryColor3ubEXT - .globl glSecondaryColor3ubv ; .type glSecondaryColor3ubv,#function ; glSecondaryColor3ubv = glSecondaryColor3ubvEXT - .globl glSecondaryColor3ui ; .type glSecondaryColor3ui,#function ; glSecondaryColor3ui = glSecondaryColor3uiEXT - .globl glSecondaryColor3uiv ; .type glSecondaryColor3uiv,#function ; glSecondaryColor3uiv = glSecondaryColor3uivEXT - .globl glSecondaryColor3us ; .type glSecondaryColor3us,#function ; glSecondaryColor3us = glSecondaryColor3usEXT - .globl glSecondaryColor3usv ; .type glSecondaryColor3usv,#function ; glSecondaryColor3usv = glSecondaryColor3usvEXT - .globl glSecondaryColorPointer ; .type glSecondaryColorPointer,#function ; glSecondaryColorPointer = glSecondaryColorPointerEXT - .globl glMultiDrawArrays ; .type glMultiDrawArrays,#function ; glMultiDrawArrays = glMultiDrawArraysEXT - .globl glMultiDrawElements ; .type glMultiDrawElements,#function ; glMultiDrawElements = glMultiDrawElementsEXT - .globl glFogCoordPointer ; .type glFogCoordPointer,#function ; glFogCoordPointer = glFogCoordPointerEXT - .globl glFogCoordd ; .type glFogCoordd,#function ; glFogCoordd = glFogCoorddEXT - .globl glFogCoorddv ; .type glFogCoorddv,#function ; glFogCoorddv = glFogCoorddvEXT - .globl glFogCoordf ; .type glFogCoordf,#function ; glFogCoordf = glFogCoordfEXT - .globl glFogCoordfv ; .type glFogCoordfv,#function ; glFogCoordfv = glFogCoordfvEXT - .globl glBlendFuncSeparate ; .type glBlendFuncSeparate,#function ; glBlendFuncSeparate = glBlendFuncSeparateEXT - .globl glWindowPos2d ; .type glWindowPos2d,#function ; glWindowPos2d = glWindowPos2dMESA - .globl glWindowPos2dARB ; .type glWindowPos2dARB,#function ; glWindowPos2dARB = glWindowPos2dMESA - .globl glWindowPos2dv ; .type glWindowPos2dv,#function ; glWindowPos2dv = glWindowPos2dvMESA - .globl glWindowPos2dvARB ; .type glWindowPos2dvARB,#function ; glWindowPos2dvARB = glWindowPos2dvMESA - .globl glWindowPos2f ; .type glWindowPos2f,#function ; glWindowPos2f = glWindowPos2fMESA - .globl glWindowPos2fARB ; .type glWindowPos2fARB,#function ; glWindowPos2fARB = glWindowPos2fMESA - .globl glWindowPos2fv ; .type glWindowPos2fv,#function ; glWindowPos2fv = glWindowPos2fvMESA - .globl glWindowPos2fvARB ; .type glWindowPos2fvARB,#function ; glWindowPos2fvARB = glWindowPos2fvMESA - .globl glWindowPos2i ; .type glWindowPos2i,#function ; glWindowPos2i = glWindowPos2iMESA - .globl glWindowPos2iARB ; .type glWindowPos2iARB,#function ; glWindowPos2iARB = glWindowPos2iMESA - .globl glWindowPos2iv ; .type glWindowPos2iv,#function ; glWindowPos2iv = glWindowPos2ivMESA - .globl glWindowPos2ivARB ; .type glWindowPos2ivARB,#function ; glWindowPos2ivARB = glWindowPos2ivMESA - .globl glWindowPos2s ; .type glWindowPos2s,#function ; glWindowPos2s = glWindowPos2sMESA - .globl glWindowPos2sARB ; .type glWindowPos2sARB,#function ; glWindowPos2sARB = glWindowPos2sMESA - .globl glWindowPos2sv ; .type glWindowPos2sv,#function ; glWindowPos2sv = glWindowPos2svMESA - .globl glWindowPos2svARB ; .type glWindowPos2svARB,#function ; glWindowPos2svARB = glWindowPos2svMESA - .globl glWindowPos3d ; .type glWindowPos3d,#function ; glWindowPos3d = glWindowPos3dMESA - .globl glWindowPos3dARB ; .type glWindowPos3dARB,#function ; glWindowPos3dARB = glWindowPos3dMESA - .globl glWindowPos3dv ; .type glWindowPos3dv,#function ; glWindowPos3dv = glWindowPos3dvMESA - .globl glWindowPos3dvARB ; .type glWindowPos3dvARB,#function ; glWindowPos3dvARB = glWindowPos3dvMESA - .globl glWindowPos3f ; .type glWindowPos3f,#function ; glWindowPos3f = glWindowPos3fMESA - .globl glWindowPos3fARB ; .type glWindowPos3fARB,#function ; glWindowPos3fARB = glWindowPos3fMESA - .globl glWindowPos3fv ; .type glWindowPos3fv,#function ; glWindowPos3fv = glWindowPos3fvMESA - .globl glWindowPos3fvARB ; .type glWindowPos3fvARB,#function ; glWindowPos3fvARB = glWindowPos3fvMESA - .globl glWindowPos3i ; .type glWindowPos3i,#function ; glWindowPos3i = glWindowPos3iMESA - .globl glWindowPos3iARB ; .type glWindowPos3iARB,#function ; glWindowPos3iARB = glWindowPos3iMESA - .globl glWindowPos3iv ; .type glWindowPos3iv,#function ; glWindowPos3iv = glWindowPos3ivMESA - .globl glWindowPos3ivARB ; .type glWindowPos3ivARB,#function ; glWindowPos3ivARB = glWindowPos3ivMESA - .globl glWindowPos3s ; .type glWindowPos3s,#function ; glWindowPos3s = glWindowPos3sMESA - .globl glWindowPos3sARB ; .type glWindowPos3sARB,#function ; glWindowPos3sARB = glWindowPos3sMESA - .globl glWindowPos3sv ; .type glWindowPos3sv,#function ; glWindowPos3sv = glWindowPos3svMESA - .globl glWindowPos3svARB ; .type glWindowPos3svARB,#function ; glWindowPos3svARB = glWindowPos3svMESA - .globl glBindProgramARB ; .type glBindProgramARB,#function ; glBindProgramARB = glBindProgramNV - .globl glDeleteProgramsARB ; .type glDeleteProgramsARB,#function ; glDeleteProgramsARB = glDeleteProgramsNV - .globl glGenProgramsARB ; .type glGenProgramsARB,#function ; glGenProgramsARB = glGenProgramsNV - .globl glGetVertexAttribPointerv ; .type glGetVertexAttribPointerv,#function ; glGetVertexAttribPointerv = glGetVertexAttribPointervNV - .globl glGetVertexAttribPointervARB ; .type glGetVertexAttribPointervARB,#function ; glGetVertexAttribPointervARB = glGetVertexAttribPointervNV - .globl glIsProgramARB ; .type glIsProgramARB,#function ; glIsProgramARB = glIsProgramNV - .globl glPointParameteri ; .type glPointParameteri,#function ; glPointParameteri = glPointParameteriNV - .globl glPointParameteriv ; .type glPointParameteriv,#function ; glPointParameteriv = glPointParameterivNV - .globl glBlendEquationSeparate ; .type glBlendEquationSeparate,#function ; glBlendEquationSeparate = glBlendEquationSeparateEXT - .globl glBindFramebuffer ; .type glBindFramebuffer,#function ; glBindFramebuffer = glBindFramebufferEXT - .globl glBindRenderbuffer ; .type glBindRenderbuffer,#function ; glBindRenderbuffer = glBindRenderbufferEXT - .globl glCheckFramebufferStatus ; .type glCheckFramebufferStatus,#function ; glCheckFramebufferStatus = glCheckFramebufferStatusEXT - .globl glDeleteFramebuffers ; .type glDeleteFramebuffers,#function ; glDeleteFramebuffers = glDeleteFramebuffersEXT - .globl glDeleteRenderbuffers ; .type glDeleteRenderbuffers,#function ; glDeleteRenderbuffers = glDeleteRenderbuffersEXT - .globl glFramebufferRenderbuffer ; .type glFramebufferRenderbuffer,#function ; glFramebufferRenderbuffer = glFramebufferRenderbufferEXT - .globl glFramebufferTexture1D ; .type glFramebufferTexture1D,#function ; glFramebufferTexture1D = glFramebufferTexture1DEXT - .globl glFramebufferTexture2D ; .type glFramebufferTexture2D,#function ; glFramebufferTexture2D = glFramebufferTexture2DEXT - .globl glFramebufferTexture3D ; .type glFramebufferTexture3D,#function ; glFramebufferTexture3D = glFramebufferTexture3DEXT - .globl glGenFramebuffers ; .type glGenFramebuffers,#function ; glGenFramebuffers = glGenFramebuffersEXT - .globl glGenRenderbuffers ; .type glGenRenderbuffers,#function ; glGenRenderbuffers = glGenRenderbuffersEXT - .globl glGenerateMipmap ; .type glGenerateMipmap,#function ; glGenerateMipmap = glGenerateMipmapEXT - .globl glGetFramebufferAttachmentParameteriv ; .type glGetFramebufferAttachmentParameteriv,#function ; glGetFramebufferAttachmentParameteriv = glGetFramebufferAttachmentParameterivEXT - .globl glGetRenderbufferParameteriv ; .type glGetRenderbufferParameteriv,#function ; glGetRenderbufferParameteriv = glGetRenderbufferParameterivEXT - .globl glIsFramebuffer ; .type glIsFramebuffer,#function ; glIsFramebuffer = glIsFramebufferEXT - .globl glIsRenderbuffer ; .type glIsRenderbuffer,#function ; glIsRenderbuffer = glIsRenderbufferEXT - .globl glRenderbufferStorage ; .type glRenderbufferStorage,#function ; glRenderbufferStorage = glRenderbufferStorageEXT - .globl glBlitFramebuffer ; .type glBlitFramebuffer,#function ; glBlitFramebuffer = glBlitFramebufferEXT - .globl glFramebufferTextureLayer ; .type glFramebufferTextureLayer,#function ; glFramebufferTextureLayer = glFramebufferTextureLayerEXT + GL_STUB_ALIAS(glSeparableFilter2DEXT, glSeparableFilter2D) +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetHistogramEXT, glGetHistogram) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetHistogramParameterfvEXT, glGetHistogramParameterfv) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetHistogramParameterivEXT, glGetHistogramParameteriv) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetMinmaxEXT, glGetMinmax) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetMinmaxParameterfvEXT, glGetMinmaxParameterfv) +#endif +#ifndef GLX_INDIRECT_RENDERING + GL_STUB_ALIAS(glGetMinmaxParameterivEXT, glGetMinmaxParameteriv) +#endif + GL_STUB_ALIAS(glHistogramEXT, glHistogram) + GL_STUB_ALIAS(glMinmaxEXT, glMinmax) + GL_STUB_ALIAS(glResetHistogramEXT, glResetHistogram) + GL_STUB_ALIAS(glResetMinmaxEXT, glResetMinmax) + GL_STUB_ALIAS(glTexImage3DEXT, glTexImage3D) + GL_STUB_ALIAS(glTexSubImage3DEXT, glTexSubImage3D) + GL_STUB_ALIAS(glCopyTexSubImage3DEXT, glCopyTexSubImage3D) + GL_STUB_ALIAS(glActiveTexture, glActiveTextureARB) + GL_STUB_ALIAS(glClientActiveTexture, glClientActiveTextureARB) + GL_STUB_ALIAS(glMultiTexCoord1d, glMultiTexCoord1dARB) + GL_STUB_ALIAS(glMultiTexCoord1dv, glMultiTexCoord1dvARB) + GL_STUB_ALIAS(glMultiTexCoord1f, glMultiTexCoord1fARB) + GL_STUB_ALIAS(glMultiTexCoord1fv, glMultiTexCoord1fvARB) + GL_STUB_ALIAS(glMultiTexCoord1i, glMultiTexCoord1iARB) + GL_STUB_ALIAS(glMultiTexCoord1iv, glMultiTexCoord1ivARB) + GL_STUB_ALIAS(glMultiTexCoord1s, glMultiTexCoord1sARB) + GL_STUB_ALIAS(glMultiTexCoord1sv, glMultiTexCoord1svARB) + GL_STUB_ALIAS(glMultiTexCoord2d, glMultiTexCoord2dARB) + GL_STUB_ALIAS(glMultiTexCoord2dv, glMultiTexCoord2dvARB) + GL_STUB_ALIAS(glMultiTexCoord2f, glMultiTexCoord2fARB) + GL_STUB_ALIAS(glMultiTexCoord2fv, glMultiTexCoord2fvARB) + GL_STUB_ALIAS(glMultiTexCoord2i, glMultiTexCoord2iARB) + GL_STUB_ALIAS(glMultiTexCoord2iv, glMultiTexCoord2ivARB) + GL_STUB_ALIAS(glMultiTexCoord2s, glMultiTexCoord2sARB) + GL_STUB_ALIAS(glMultiTexCoord2sv, glMultiTexCoord2svARB) + GL_STUB_ALIAS(glMultiTexCoord3d, glMultiTexCoord3dARB) + GL_STUB_ALIAS(glMultiTexCoord3dv, glMultiTexCoord3dvARB) + GL_STUB_ALIAS(glMultiTexCoord3f, glMultiTexCoord3fARB) + GL_STUB_ALIAS(glMultiTexCoord3fv, glMultiTexCoord3fvARB) + GL_STUB_ALIAS(glMultiTexCoord3i, glMultiTexCoord3iARB) + GL_STUB_ALIAS(glMultiTexCoord3iv, glMultiTexCoord3ivARB) + GL_STUB_ALIAS(glMultiTexCoord3s, glMultiTexCoord3sARB) + GL_STUB_ALIAS(glMultiTexCoord3sv, glMultiTexCoord3svARB) + GL_STUB_ALIAS(glMultiTexCoord4d, glMultiTexCoord4dARB) + GL_STUB_ALIAS(glMultiTexCoord4dv, glMultiTexCoord4dvARB) + GL_STUB_ALIAS(glMultiTexCoord4f, glMultiTexCoord4fARB) + GL_STUB_ALIAS(glMultiTexCoord4fv, glMultiTexCoord4fvARB) + GL_STUB_ALIAS(glMultiTexCoord4i, glMultiTexCoord4iARB) + GL_STUB_ALIAS(glMultiTexCoord4iv, glMultiTexCoord4ivARB) + GL_STUB_ALIAS(glMultiTexCoord4s, glMultiTexCoord4sARB) + GL_STUB_ALIAS(glMultiTexCoord4sv, glMultiTexCoord4svARB) + GL_STUB_ALIAS(glStencilOpSeparateATI, glStencilOpSeparate) + GL_STUB_ALIAS(glLoadTransposeMatrixd, glLoadTransposeMatrixdARB) + GL_STUB_ALIAS(glLoadTransposeMatrixf, glLoadTransposeMatrixfARB) + GL_STUB_ALIAS(glMultTransposeMatrixd, glMultTransposeMatrixdARB) + GL_STUB_ALIAS(glMultTransposeMatrixf, glMultTransposeMatrixfARB) + GL_STUB_ALIAS(glSampleCoverage, glSampleCoverageARB) + GL_STUB_ALIAS(glCompressedTexImage1D, glCompressedTexImage1DARB) + GL_STUB_ALIAS(glCompressedTexImage2D, glCompressedTexImage2DARB) + GL_STUB_ALIAS(glCompressedTexImage3D, glCompressedTexImage3DARB) + GL_STUB_ALIAS(glCompressedTexSubImage1D, glCompressedTexSubImage1DARB) + GL_STUB_ALIAS(glCompressedTexSubImage2D, glCompressedTexSubImage2DARB) + GL_STUB_ALIAS(glCompressedTexSubImage3D, glCompressedTexSubImage3DARB) + GL_STUB_ALIAS(glGetCompressedTexImage, glGetCompressedTexImageARB) + GL_STUB_ALIAS(glDisableVertexAttribArray, glDisableVertexAttribArrayARB) + GL_STUB_ALIAS(glEnableVertexAttribArray, glEnableVertexAttribArrayARB) + GL_STUB_ALIAS(glGetVertexAttribdv, glGetVertexAttribdvARB) + GL_STUB_ALIAS(glGetVertexAttribfv, glGetVertexAttribfvARB) + GL_STUB_ALIAS(glGetVertexAttribiv, glGetVertexAttribivARB) + GL_STUB_ALIAS(glProgramParameter4dNV, glProgramEnvParameter4dARB) + GL_STUB_ALIAS(glProgramParameter4dvNV, glProgramEnvParameter4dvARB) + GL_STUB_ALIAS(glProgramParameter4fNV, glProgramEnvParameter4fARB) + GL_STUB_ALIAS(glProgramParameter4fvNV, glProgramEnvParameter4fvARB) + GL_STUB_ALIAS(glVertexAttrib1d, glVertexAttrib1dARB) + GL_STUB_ALIAS(glVertexAttrib1dv, glVertexAttrib1dvARB) + GL_STUB_ALIAS(glVertexAttrib1f, glVertexAttrib1fARB) + GL_STUB_ALIAS(glVertexAttrib1fv, glVertexAttrib1fvARB) + GL_STUB_ALIAS(glVertexAttrib1s, glVertexAttrib1sARB) + GL_STUB_ALIAS(glVertexAttrib1sv, glVertexAttrib1svARB) + GL_STUB_ALIAS(glVertexAttrib2d, glVertexAttrib2dARB) + GL_STUB_ALIAS(glVertexAttrib2dv, glVertexAttrib2dvARB) + GL_STUB_ALIAS(glVertexAttrib2f, glVertexAttrib2fARB) + GL_STUB_ALIAS(glVertexAttrib2fv, glVertexAttrib2fvARB) + GL_STUB_ALIAS(glVertexAttrib2s, glVertexAttrib2sARB) + GL_STUB_ALIAS(glVertexAttrib2sv, glVertexAttrib2svARB) + GL_STUB_ALIAS(glVertexAttrib3d, glVertexAttrib3dARB) + GL_STUB_ALIAS(glVertexAttrib3dv, glVertexAttrib3dvARB) + GL_STUB_ALIAS(glVertexAttrib3f, glVertexAttrib3fARB) + GL_STUB_ALIAS(glVertexAttrib3fv, glVertexAttrib3fvARB) + GL_STUB_ALIAS(glVertexAttrib3s, glVertexAttrib3sARB) + GL_STUB_ALIAS(glVertexAttrib3sv, glVertexAttrib3svARB) + GL_STUB_ALIAS(glVertexAttrib4Nbv, glVertexAttrib4NbvARB) + GL_STUB_ALIAS(glVertexAttrib4Niv, glVertexAttrib4NivARB) + GL_STUB_ALIAS(glVertexAttrib4Nsv, glVertexAttrib4NsvARB) + GL_STUB_ALIAS(glVertexAttrib4Nub, glVertexAttrib4NubARB) + GL_STUB_ALIAS(glVertexAttrib4Nubv, glVertexAttrib4NubvARB) + GL_STUB_ALIAS(glVertexAttrib4Nuiv, glVertexAttrib4NuivARB) + GL_STUB_ALIAS(glVertexAttrib4Nusv, glVertexAttrib4NusvARB) + GL_STUB_ALIAS(glVertexAttrib4bv, glVertexAttrib4bvARB) + GL_STUB_ALIAS(glVertexAttrib4d, glVertexAttrib4dARB) + GL_STUB_ALIAS(glVertexAttrib4dv, glVertexAttrib4dvARB) + GL_STUB_ALIAS(glVertexAttrib4f, glVertexAttrib4fARB) + GL_STUB_ALIAS(glVertexAttrib4fv, glVertexAttrib4fvARB) + GL_STUB_ALIAS(glVertexAttrib4iv, glVertexAttrib4ivARB) + GL_STUB_ALIAS(glVertexAttrib4s, glVertexAttrib4sARB) + GL_STUB_ALIAS(glVertexAttrib4sv, glVertexAttrib4svARB) + GL_STUB_ALIAS(glVertexAttrib4ubv, glVertexAttrib4ubvARB) + GL_STUB_ALIAS(glVertexAttrib4uiv, glVertexAttrib4uivARB) + GL_STUB_ALIAS(glVertexAttrib4usv, glVertexAttrib4usvARB) + GL_STUB_ALIAS(glVertexAttribPointer, glVertexAttribPointerARB) + GL_STUB_ALIAS(glBindBuffer, glBindBufferARB) + GL_STUB_ALIAS(glBufferData, glBufferDataARB) + GL_STUB_ALIAS(glBufferSubData, glBufferSubDataARB) + GL_STUB_ALIAS(glDeleteBuffers, glDeleteBuffersARB) + GL_STUB_ALIAS(glGenBuffers, glGenBuffersARB) + GL_STUB_ALIAS(glGetBufferParameteriv, glGetBufferParameterivARB) + GL_STUB_ALIAS(glGetBufferPointerv, glGetBufferPointervARB) + GL_STUB_ALIAS(glGetBufferSubData, glGetBufferSubDataARB) + GL_STUB_ALIAS(glIsBuffer, glIsBufferARB) + GL_STUB_ALIAS(glMapBuffer, glMapBufferARB) + GL_STUB_ALIAS(glUnmapBuffer, glUnmapBufferARB) + GL_STUB_ALIAS(glBeginQuery, glBeginQueryARB) + GL_STUB_ALIAS(glDeleteQueries, glDeleteQueriesARB) + GL_STUB_ALIAS(glEndQuery, glEndQueryARB) + GL_STUB_ALIAS(glGenQueries, glGenQueriesARB) + GL_STUB_ALIAS(glGetQueryObjectiv, glGetQueryObjectivARB) + GL_STUB_ALIAS(glGetQueryObjectuiv, glGetQueryObjectuivARB) + GL_STUB_ALIAS(glGetQueryiv, glGetQueryivARB) + GL_STUB_ALIAS(glIsQuery, glIsQueryARB) + GL_STUB_ALIAS(glCompileShader, glCompileShaderARB) + GL_STUB_ALIAS(glGetActiveUniform, glGetActiveUniformARB) + GL_STUB_ALIAS(glGetShaderSource, glGetShaderSourceARB) + GL_STUB_ALIAS(glGetUniformLocation, glGetUniformLocationARB) + GL_STUB_ALIAS(glGetUniformfv, glGetUniformfvARB) + GL_STUB_ALIAS(glGetUniformiv, glGetUniformivARB) + GL_STUB_ALIAS(glLinkProgram, glLinkProgramARB) + GL_STUB_ALIAS(glShaderSource, glShaderSourceARB) + GL_STUB_ALIAS(glUniform1f, glUniform1fARB) + GL_STUB_ALIAS(glUniform1fv, glUniform1fvARB) + GL_STUB_ALIAS(glUniform1i, glUniform1iARB) + GL_STUB_ALIAS(glUniform1iv, glUniform1ivARB) + GL_STUB_ALIAS(glUniform2f, glUniform2fARB) + GL_STUB_ALIAS(glUniform2fv, glUniform2fvARB) + GL_STUB_ALIAS(glUniform2i, glUniform2iARB) + GL_STUB_ALIAS(glUniform2iv, glUniform2ivARB) + GL_STUB_ALIAS(glUniform3f, glUniform3fARB) + GL_STUB_ALIAS(glUniform3fv, glUniform3fvARB) + GL_STUB_ALIAS(glUniform3i, glUniform3iARB) + GL_STUB_ALIAS(glUniform3iv, glUniform3ivARB) + GL_STUB_ALIAS(glUniform4f, glUniform4fARB) + GL_STUB_ALIAS(glUniform4fv, glUniform4fvARB) + GL_STUB_ALIAS(glUniform4i, glUniform4iARB) + GL_STUB_ALIAS(glUniform4iv, glUniform4ivARB) + GL_STUB_ALIAS(glUniformMatrix2fv, glUniformMatrix2fvARB) + GL_STUB_ALIAS(glUniformMatrix3fv, glUniformMatrix3fvARB) + GL_STUB_ALIAS(glUniformMatrix4fv, glUniformMatrix4fvARB) + GL_STUB_ALIAS(glUseProgram, glUseProgramObjectARB) + GL_STUB_ALIAS(glValidateProgram, glValidateProgramARB) + GL_STUB_ALIAS(glBindAttribLocation, glBindAttribLocationARB) + GL_STUB_ALIAS(glGetActiveAttrib, glGetActiveAttribARB) + GL_STUB_ALIAS(glGetAttribLocation, glGetAttribLocationARB) + GL_STUB_ALIAS(glDrawBuffers, glDrawBuffersARB) + GL_STUB_ALIAS(glDrawBuffersATI, glDrawBuffersARB) + GL_STUB_ALIAS(glPointParameterf, glPointParameterfEXT) + GL_STUB_ALIAS(glPointParameterfARB, glPointParameterfEXT) + GL_STUB_ALIAS(glPointParameterfSGIS, glPointParameterfEXT) + GL_STUB_ALIAS(glPointParameterfv, glPointParameterfvEXT) + GL_STUB_ALIAS(glPointParameterfvARB, glPointParameterfvEXT) + GL_STUB_ALIAS(glPointParameterfvSGIS, glPointParameterfvEXT) + GL_STUB_ALIAS(glSecondaryColor3b, glSecondaryColor3bEXT) + GL_STUB_ALIAS(glSecondaryColor3bv, glSecondaryColor3bvEXT) + GL_STUB_ALIAS(glSecondaryColor3d, glSecondaryColor3dEXT) + GL_STUB_ALIAS(glSecondaryColor3dv, glSecondaryColor3dvEXT) + GL_STUB_ALIAS(glSecondaryColor3f, glSecondaryColor3fEXT) + GL_STUB_ALIAS(glSecondaryColor3fv, glSecondaryColor3fvEXT) + GL_STUB_ALIAS(glSecondaryColor3i, glSecondaryColor3iEXT) + GL_STUB_ALIAS(glSecondaryColor3iv, glSecondaryColor3ivEXT) + GL_STUB_ALIAS(glSecondaryColor3s, glSecondaryColor3sEXT) + GL_STUB_ALIAS(glSecondaryColor3sv, glSecondaryColor3svEXT) + GL_STUB_ALIAS(glSecondaryColor3ub, glSecondaryColor3ubEXT) + GL_STUB_ALIAS(glSecondaryColor3ubv, glSecondaryColor3ubvEXT) + GL_STUB_ALIAS(glSecondaryColor3ui, glSecondaryColor3uiEXT) + GL_STUB_ALIAS(glSecondaryColor3uiv, glSecondaryColor3uivEXT) + GL_STUB_ALIAS(glSecondaryColor3us, glSecondaryColor3usEXT) + GL_STUB_ALIAS(glSecondaryColor3usv, glSecondaryColor3usvEXT) + GL_STUB_ALIAS(glSecondaryColorPointer, glSecondaryColorPointerEXT) + GL_STUB_ALIAS(glMultiDrawArrays, glMultiDrawArraysEXT) + GL_STUB_ALIAS(glMultiDrawElements, glMultiDrawElementsEXT) + GL_STUB_ALIAS(glFogCoordPointer, glFogCoordPointerEXT) + GL_STUB_ALIAS(glFogCoordd, glFogCoorddEXT) + GL_STUB_ALIAS(glFogCoorddv, glFogCoorddvEXT) + GL_STUB_ALIAS(glFogCoordf, glFogCoordfEXT) + GL_STUB_ALIAS(glFogCoordfv, glFogCoordfvEXT) + GL_STUB_ALIAS(glBlendFuncSeparate, glBlendFuncSeparateEXT) + GL_STUB_ALIAS(glBlendFuncSeparateINGR, glBlendFuncSeparateEXT) + GL_STUB_ALIAS(glWindowPos2d, glWindowPos2dMESA) + GL_STUB_ALIAS(glWindowPos2dARB, glWindowPos2dMESA) + GL_STUB_ALIAS(glWindowPos2dv, glWindowPos2dvMESA) + GL_STUB_ALIAS(glWindowPos2dvARB, glWindowPos2dvMESA) + GL_STUB_ALIAS(glWindowPos2f, glWindowPos2fMESA) + GL_STUB_ALIAS(glWindowPos2fARB, glWindowPos2fMESA) + GL_STUB_ALIAS(glWindowPos2fv, glWindowPos2fvMESA) + GL_STUB_ALIAS(glWindowPos2fvARB, glWindowPos2fvMESA) + GL_STUB_ALIAS(glWindowPos2i, glWindowPos2iMESA) + GL_STUB_ALIAS(glWindowPos2iARB, glWindowPos2iMESA) + GL_STUB_ALIAS(glWindowPos2iv, glWindowPos2ivMESA) + GL_STUB_ALIAS(glWindowPos2ivARB, glWindowPos2ivMESA) + GL_STUB_ALIAS(glWindowPos2s, glWindowPos2sMESA) + GL_STUB_ALIAS(glWindowPos2sARB, glWindowPos2sMESA) + GL_STUB_ALIAS(glWindowPos2sv, glWindowPos2svMESA) + GL_STUB_ALIAS(glWindowPos2svARB, glWindowPos2svMESA) + GL_STUB_ALIAS(glWindowPos3d, glWindowPos3dMESA) + GL_STUB_ALIAS(glWindowPos3dARB, glWindowPos3dMESA) + GL_STUB_ALIAS(glWindowPos3dv, glWindowPos3dvMESA) + GL_STUB_ALIAS(glWindowPos3dvARB, glWindowPos3dvMESA) + GL_STUB_ALIAS(glWindowPos3f, glWindowPos3fMESA) + GL_STUB_ALIAS(glWindowPos3fARB, glWindowPos3fMESA) + GL_STUB_ALIAS(glWindowPos3fv, glWindowPos3fvMESA) + GL_STUB_ALIAS(glWindowPos3fvARB, glWindowPos3fvMESA) + GL_STUB_ALIAS(glWindowPos3i, glWindowPos3iMESA) + GL_STUB_ALIAS(glWindowPos3iARB, glWindowPos3iMESA) + GL_STUB_ALIAS(glWindowPos3iv, glWindowPos3ivMESA) + GL_STUB_ALIAS(glWindowPos3ivARB, glWindowPos3ivMESA) + GL_STUB_ALIAS(glWindowPos3s, glWindowPos3sMESA) + GL_STUB_ALIAS(glWindowPos3sARB, glWindowPos3sMESA) + GL_STUB_ALIAS(glWindowPos3sv, glWindowPos3svMESA) + GL_STUB_ALIAS(glWindowPos3svARB, glWindowPos3svMESA) + GL_STUB_ALIAS(glBindProgramARB, glBindProgramNV) + GL_STUB_ALIAS(glDeleteProgramsARB, glDeleteProgramsNV) + GL_STUB_ALIAS(glGenProgramsARB, glGenProgramsNV) + GL_STUB_ALIAS(glGetVertexAttribPointerv, glGetVertexAttribPointervNV) + GL_STUB_ALIAS(glGetVertexAttribPointervARB, glGetVertexAttribPointervNV) + GL_STUB_ALIAS(glIsProgramARB, glIsProgramNV) + GL_STUB_ALIAS(glPointParameteri, glPointParameteriNV) + GL_STUB_ALIAS(glPointParameteriv, glPointParameterivNV) + GL_STUB_ALIAS(glBindFramebuffer, glBindFramebufferEXT) + GL_STUB_ALIAS(glBindRenderbuffer, glBindRenderbufferEXT) + GL_STUB_ALIAS(glCheckFramebufferStatus, glCheckFramebufferStatusEXT) + GL_STUB_ALIAS(glDeleteFramebuffers, glDeleteFramebuffersEXT) + GL_STUB_ALIAS(glDeleteRenderbuffers, glDeleteRenderbuffersEXT) + GL_STUB_ALIAS(glFramebufferRenderbuffer, glFramebufferRenderbufferEXT) + GL_STUB_ALIAS(glFramebufferTexture1D, glFramebufferTexture1DEXT) + GL_STUB_ALIAS(glFramebufferTexture2D, glFramebufferTexture2DEXT) + GL_STUB_ALIAS(glFramebufferTexture3D, glFramebufferTexture3DEXT) + GL_STUB_ALIAS(glGenFramebuffers, glGenFramebuffersEXT) + GL_STUB_ALIAS(glGenRenderbuffers, glGenRenderbuffersEXT) + GL_STUB_ALIAS(glGenerateMipmap, glGenerateMipmapEXT) + GL_STUB_ALIAS(glGetFramebufferAttachmentParameteriv, glGetFramebufferAttachmentParameterivEXT) + GL_STUB_ALIAS(glGetRenderbufferParameteriv, glGetRenderbufferParameterivEXT) + GL_STUB_ALIAS(glIsFramebuffer, glIsFramebufferEXT) + GL_STUB_ALIAS(glIsRenderbuffer, glIsRenderbufferEXT) + GL_STUB_ALIAS(glRenderbufferStorage, glRenderbufferStorageEXT) + GL_STUB_ALIAS(glFramebufferTextureLayer, glFramebufferTextureLayerEXT) + + .globl gl_dispatch_functions_end + HIDDEN(gl_dispatch_functions_end) +gl_dispatch_functions_end: diff --git a/src/mesa/sparc/sparc.c b/src/mesa/sparc/sparc.c index 84e8ac6723..3bde98e34b 100644 --- a/src/mesa/sparc/sparc.c +++ b/src/mesa/sparc/sparc.c @@ -109,10 +109,10 @@ void _mesa_init_all_sparc_transform_asm(void) ASSIGN_XFORM_GROUP(sparc, 2) ASSIGN_XFORM_GROUP(sparc, 3) ASSIGN_XFORM_GROUP(sparc, 4) - +#if 0 _mesa_clip_tab[4] = _mesa_sparc_cliptest_points4; _mesa_clip_np_tab[4] = _mesa_sparc_cliptest_points4_np; - +#endif #if 0 /* disable these too. See bug 673938 */ _mesa_normal_tab[NORM_TRANSFORM | NORM_NORMALIZE] = @@ -140,38 +140,4 @@ void _mesa_init_all_sparc_transform_asm(void) #endif } -extern unsigned int _mesa_sparc_glapi_begin; -extern unsigned int _mesa_sparc_glapi_end; -extern void __glapi_sparc_icache_flush(unsigned int *); - -#endif /* USE_SPARC_ASM */ - - -void _mesa_init_sparc_glapi_relocs(void) -{ -#ifdef USE_SPARC_ASM - unsigned int *insn_ptr, *end_ptr; - unsigned long disp_addr; - - insn_ptr = &_mesa_sparc_glapi_begin; - end_ptr = &_mesa_sparc_glapi_end; - disp_addr = (unsigned long) &_glapi_Dispatch; - - while (insn_ptr < end_ptr) { -#ifdef __arch64__ - insn_ptr[0] |= (disp_addr >> (32 + 10)); - insn_ptr[1] |= ((disp_addr & 0xffffffff) >> 10); - __glapi_sparc_icache_flush(&insn_ptr[0]); - insn_ptr[2] |= ((disp_addr >> 32) & ((1 << 10) - 1)); - insn_ptr[3] |= (disp_addr & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&insn_ptr[2]); - insn_ptr += 11; -#else - insn_ptr[0] |= (disp_addr >> 10); - insn_ptr[1] |= (disp_addr & ((1 << 10) - 1)); - __glapi_sparc_icache_flush(&insn_ptr[0]); - insn_ptr += 5; -#endif - } #endif /* USE_SPARC_ASM */ -} diff --git a/src/mesa/sparc/sparc.h b/src/mesa/sparc/sparc.h index a98e4d0e40..b9ea336856 100644 --- a/src/mesa/sparc/sparc.h +++ b/src/mesa/sparc/sparc.h @@ -32,6 +32,5 @@ #define SPARC_H extern void _mesa_init_all_sparc_transform_asm(void); -extern void _mesa_init_sparc_glapi_relocs(void); #endif /* !(SPARC_H) */ -- cgit v1.2.3 From 16144632354cb310f090c8713a11d3c65696969e Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 26 Feb 2009 14:49:24 -0700 Subject: mesa: avoid extraneous calls to ctx->Driver.BindFramebuffer() Only call this driver function when we really need to bind different buffers. --- src/mesa/main/fbobject.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 23b3fb68fb..151e29053a 100644 --- a/src/mesa/main/fbobject.c +++ b/src/mesa/main/fbobject.c @@ -1229,19 +1229,26 @@ _mesa_BindFramebufferEXT(GLenum target, GLuint framebuffer) ASSERT(newFb != &DummyFramebuffer); /* - * XXX check if re-binding same buffer and skip some of this code. + * OK, now bind the new Draw/Read framebuffers, if they're changing. */ if (bindReadBuf) { - _mesa_reference_framebuffer(&ctx->ReadBuffer, newFbread); + if (ctx->ReadBuffer == newFbread) + bindReadBuf = GL_FALSE; /* no change */ + else + _mesa_reference_framebuffer(&ctx->ReadBuffer, newFbread); } if (bindDrawBuf) { /* check if old FB had any texture attachments */ - check_end_texture_render(ctx, ctx->DrawBuffer); + if (ctx->DrawBuffer->Name != 0) { + check_end_texture_render(ctx, ctx->DrawBuffer); + } - /* check if time to delete this framebuffer */ - _mesa_reference_framebuffer(&ctx->DrawBuffer, newFb); + if (ctx->DrawBuffer == newFb) + bindDrawBuf = GL_FALSE; /* no change */ + else + _mesa_reference_framebuffer(&ctx->DrawBuffer, newFb); if (newFb->Name != 0) { /* check if newly bound framebuffer has any texture attachments */ @@ -1249,7 +1256,7 @@ _mesa_BindFramebufferEXT(GLenum target, GLuint framebuffer) } } - if (ctx->Driver.BindFramebuffer) { + if ((bindDrawBuf || bindReadBuf) && ctx->Driver.BindFramebuffer) { ctx->Driver.BindFramebuffer(ctx, target, newFb, newFbread); } } -- cgit v1.2.3 From 75e3ccf6a5b639834bcda0ff6f9035b148fca8f1 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 12:30:21 -0700 Subject: mesa: fix incorrect error handling in glBufferDataARB() If glBufferDataARB() is called while a buffer object is currently mapped we're supposed to unmap the current buffer, then replace it. Don't generate an error. --- src/mesa/main/bufferobj.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index 016543da01..e4bdc6f1e7 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -951,8 +951,10 @@ _mesa_BufferDataARB(GLenum target, GLsizeiptrARB size, } if (bufObj->Pointer) { - _mesa_error(ctx, GL_INVALID_OPERATION, "glBufferDataARB(buffer is mapped)" ); - return; + /* Unmap the existing buffer. We'll replace it now. Not an error. */ + ctx->Driver.UnmapBuffer(ctx, target, bufObj); + bufObj->Access = DEFAULT_ACCESS; + bufObj->Pointer = NULL; } ASSERT(ctx->Driver.BufferData); -- cgit v1.2.3 From 395bcad8c095e78621e7aca18af1dab71fe69813 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 12:41:11 -0700 Subject: mesa: updated comments --- src/mesa/main/bufferobj.c | 42 ++++++++++++++++++------------------------ 1 file changed, 18 insertions(+), 24 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index e4bdc6f1e7..1f41565fe2 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -1,8 +1,9 @@ /* * Mesa 3-D graphics library - * Version: 7.2 + * Version: 7.5 * * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. + * Copyright (C) 1999-2009 VMware, Inc. All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -25,7 +26,7 @@ /** * \file bufferobj.c - * \brief Functions for the GL_ARB_vertex_buffer_object extension. + * \brief Functions for the GL_ARB_vertex/pixel_buffer_object extensions. * \author Brian Paul, Ian Romanick */ @@ -144,8 +145,7 @@ buffer_object_subdata_range_good( GLcontext * ctx, GLenum target, /** * Allocate and initialize a new buffer object. * - * This function is intended to be called via - * \c dd_function_table::NewBufferObject. + * Default callback for the \c dd_function_table::NewBufferObject() hook. */ struct gl_buffer_object * _mesa_new_buffer_object( GLcontext *ctx, GLuint name, GLenum target ) @@ -163,8 +163,7 @@ _mesa_new_buffer_object( GLcontext *ctx, GLuint name, GLenum target ) /** * Delete a buffer object. * - * This function is intended to be called via - * \c dd_function_table::DeleteBuffer. + * Default callback for the \c dd_function_table::DeleteBuffer() hook. */ void _mesa_delete_buffer_object( GLcontext *ctx, struct gl_buffer_object *bufObj ) @@ -271,9 +270,8 @@ _mesa_initialize_buffer_object( struct gl_buffer_object *obj, * previously stored in the buffer object is lost. If \c data is \c NULL, * memory will be allocated, but no copy will occur. * - * This function is intended to be called via - * \c dd_function_table::BufferData. This function need not set GL error - * codes. The input parameters will have been tested before calling. + * This is the default callback for \c dd_function_table::BufferData() + * Note that all GL error checking will have been done already. * * \param ctx GL context. * \param target Buffer object target on which to operate. @@ -312,9 +310,8 @@ _mesa_buffer_data( GLcontext *ctx, GLenum target, GLsizeiptrARB size, * specified by \c size + \c offset extends beyond the end of the buffer or * if \c data is \c NULL, no copy is performed. * - * This function is intended to be called by - * \c dd_function_table::BufferSubData. This function need not set GL error - * codes. The input parameters will have been tested before calling. + * This is the default callback for \c dd_function_table::BufferSubData() + * Note that all GL error checking will have been done already. * * \param ctx GL context. * \param target Buffer object target on which to operate. @@ -346,15 +343,14 @@ _mesa_buffer_subdata( GLcontext *ctx, GLenum target, GLintptrARB offset, * specified by \c size + \c offset extends beyond the end of the buffer or * if \c data is \c NULL, no copy is performed. * - * This function is intended to be called by - * \c dd_function_table::BufferGetSubData. This function need not set GL error - * codes. The input parameters will have been tested before calling. + * This is the default callback for \c dd_function_table::GetBufferSubData() + * Note that all GL error checking will have been done already. * * \param ctx GL context. * \param target Buffer object target on which to operate. - * \param offset Offset of the first byte to be modified. + * \param offset Offset of the first byte to be fetched. * \param size Size, in bytes, of the data range. - * \param data Pointer to the data to store in the buffer object. + * \param data Destination for data * \param bufObj Object to be used. * * \sa glBufferGetSubDataARB, dd_function_table::GetBufferSubData. @@ -373,9 +369,7 @@ _mesa_buffer_get_subdata( GLcontext *ctx, GLenum target, GLintptrARB offset, /** - * Fallback function called via ctx->Driver.MapBuffer(). - * Hardware drivers that really implement buffer objects should never use - * this function. + * Default callback for \c dd_function_tabel::MapBuffer(). * * The function parameters will have been already tested for errors. * @@ -407,9 +401,7 @@ _mesa_buffer_map( GLcontext *ctx, GLenum target, GLenum access, /** - * Fallback function called via ctx->Driver.MapBuffer(). - * Hardware drivers that really implement buffer objects should never use - * function. + * Default callback for \c dd_function_table::MapBuffer(). * * The input parameters will have been already tested for errors. * @@ -446,6 +438,7 @@ _mesa_init_buffer_objects( GLcontext *ctx ) ctx->Array.ElementArrayBufferObj = ctx->Array.NullBufferObj; } + /** * Bind the specified target to buffer for the specified context. */ @@ -796,11 +789,11 @@ _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) for (i = 0; i < n; i++) { struct gl_buffer_object *bufObj = _mesa_lookup_bufferobj(ctx, ids[i]); if (bufObj) { - /* unbind any vertex pointers bound to this buffer */ GLuint j; ASSERT(bufObj->Name == ids[i]); + /* unbind any vertex pointers bound to this buffer */ unbind(ctx, &ctx->Array.ArrayObj->Vertex.BufferObj, bufObj); unbind(ctx, &ctx->Array.ArrayObj->Normal.BufferObj, bufObj); unbind(ctx, &ctx->Array.ArrayObj->Color.BufferObj, bufObj); @@ -822,6 +815,7 @@ _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) _mesa_BindBufferARB( GL_ELEMENT_ARRAY_BUFFER_ARB, 0 ); } + /* unbind any pixel pack/unpack pointers bound to this buffer */ if (ctx->Pack.BufferObj == bufObj) { _mesa_BindBufferARB( GL_PIXEL_PACK_BUFFER_EXT, 0 ); } -- cgit v1.2.3 From a7f434b486187129ae8d5507170c42a9ce750258 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 13:04:38 -0700 Subject: mesa: if a buffer object is mapped when glDeleteBuffers() is called, unmap it --- src/mesa/main/bufferobj.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/mesa/main') diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index 1f41565fe2..8df0a5b1a1 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -793,6 +793,11 @@ _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) ASSERT(bufObj->Name == ids[i]); + if (bufObj->Pointer) { + /* if mapped, unmap it now */ + ctx->Driver.UnmapBuffer(ctx, 0, bufObj); + } + /* unbind any vertex pointers bound to this buffer */ unbind(ctx, &ctx->Array.ArrayObj->Vertex.BufferObj, bufObj); unbind(ctx, &ctx->Array.ArrayObj->Normal.BufferObj, bufObj); -- cgit v1.2.3 From 67025f789324163a69771436e852975d3acbcd86 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 13:10:45 -0700 Subject: mesa: set bufObj->Pointer = NULL after unmapping Also, ctx->Driver.UnmapBuffer can never be null, so remove conditional. --- src/mesa/main/bufferobj.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/bufferobj.c b/src/mesa/main/bufferobj.c index 8df0a5b1a1..c8d160baa9 100644 --- a/src/mesa/main/bufferobj.c +++ b/src/mesa/main/bufferobj.c @@ -796,6 +796,8 @@ _mesa_DeleteBuffersARB(GLsizei n, const GLuint *ids) if (bufObj->Pointer) { /* if mapped, unmap it now */ ctx->Driver.UnmapBuffer(ctx, 0, bufObj); + bufObj->Access = DEFAULT_ACCESS; + bufObj->Pointer = NULL; } /* unbind any vertex pointers bound to this buffer */ @@ -1069,10 +1071,7 @@ _mesa_UnmapBufferARB(GLenum target) return GL_FALSE; } - if (ctx->Driver.UnmapBuffer) { - status = ctx->Driver.UnmapBuffer( ctx, target, bufObj ); - } - + status = ctx->Driver.UnmapBuffer( ctx, target, bufObj ); bufObj->Access = DEFAULT_ACCESS; bufObj->Pointer = NULL; -- cgit v1.2.3 From bedd20743b80b5a6d7d9954e4479a44a76c7ea02 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 21:39:04 -0700 Subject: mesa: lots of updated comments, formatting clean-ups --- src/mesa/main/mtypes.h | 189 +++++++++++++++++++++++-------------------------- 1 file changed, 89 insertions(+), 100 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index e80d3db043..ee49e5d178 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -623,9 +623,7 @@ struct gl_current_attrib * \note Index and Edgeflag current values are stored as floats in the * SIX and SEVEN attribute slots. */ - /*@{*/ GLfloat Attrib[VERT_ATTRIB_MAX][4]; /**< Position, color, texcoords, etc */ - /*@}*/ /** * \name Current raster position attributes (always valid). @@ -822,11 +820,11 @@ struct gl_hint_attrib */ struct gl_histogram_attrib { - GLuint Width; /**< number of table entries */ - GLint Format; /**< GL_ALPHA, GL_RGB, etc */ - GLuint Count[HISTOGRAM_TABLE_SIZE][4]; /**< the histogram */ - GLboolean Sink; /**< terminate image transfer? */ - GLubyte RedSize; /**< Bits per counter */ + GLuint Width; /**< number of table entries */ + GLint Format; /**< GL_ALPHA, GL_RGB, etc */ + GLuint Count[HISTOGRAM_TABLE_SIZE][4]; /**< the histogram */ + GLboolean Sink; /**< terminate image transfer? */ + GLubyte RedSize; /**< Bits per counter */ GLubyte GreenSize; GLubyte BlueSize; GLubyte AlphaSize; @@ -1005,13 +1003,15 @@ struct gl_pixel_attrib /*--- Begin Pixel Transfer State ---*/ /* Fields are in the order in which they're applied... */ - /* Scale & Bias (index shift, offset) */ + /** Scale & Bias (index shift, offset) */ + /*@{*/ GLfloat RedBias, RedScale; GLfloat GreenBias, GreenScale; GLfloat BlueBias, BlueScale; GLfloat AlphaBias, AlphaScale; GLfloat DepthBias, DepthScale; GLint IndexShift, IndexOffset; + /*@}*/ /* Pixel Maps */ /* Note: actual pixel maps are not part of this attrib group */ @@ -1027,7 +1027,7 @@ struct gl_pixel_attrib GLboolean Convolution1DEnabled; GLboolean Convolution2DEnabled; GLboolean Separable2DEnabled; - GLfloat ConvolutionBorderColor[3][4]; + GLfloat ConvolutionBorderColor[3][4]; /**< RGBA */ GLenum ConvolutionBorderMode[3]; GLfloat ConvolutionFilterScale[3][4]; /**< RGBA */ GLfloat ConvolutionFilterBias[3][4]; /**< RGBA */ @@ -1538,24 +1538,12 @@ struct gl_texture_unit }; - /** * Texture attribute group (GL_TEXTURE_BIT). */ struct gl_texture_attrib { - /** - * name multitexture - */ - /**@{*/ - GLuint CurrentUnit; /**< Active texture unit [0, MaxTextureImageUnits-1] */ - GLbitfield _EnabledUnits; /**< one bit set for each really-enabled unit */ - GLbitfield _EnabledCoordUnits; /**< one bit per enabled coordinate unit */ - GLbitfield _GenFlags; /**< for texgen */ - GLbitfield _TexGenEnabled; /**< Mask of ENABLE_TEXGEN flags */ - GLbitfield _TexMatEnabled; /**< Mask of ENABLE_TEXMAT flags */ - /**@}*/ - + GLuint CurrentUnit; /**< GL_ACTIVE_TEXTURE */ struct gl_texture_unit Unit[MAX_TEXTURE_UNITS]; struct gl_texture_object *ProxyTex[NUM_TEXTURE_TARGETS]; @@ -1563,6 +1551,15 @@ struct gl_texture_attrib /** GL_EXT_shared_texture_palette */ GLboolean SharedPalette; struct gl_color_table Palette; + + /** Per-unit flags */ + /*@{*/ + GLbitfield _EnabledUnits; /**< one bit set for each really-enabled unit */ + GLbitfield _EnabledCoordUnits; /**< one bit per enabled coordinate unit */ + GLbitfield _GenFlags; /**< for texgen */ + GLbitfield _TexGenEnabled; /**< Mask of ENABLE_TEXGEN flags */ + GLbitfield _TexMatEnabled; /**< Mask of ENABLE_TEXMAT flags */ + /*@}*/ }; @@ -1624,7 +1621,6 @@ struct gl_buffer_object }; - /** * Client pixel packing/unpacking attributes */ @@ -1634,8 +1630,8 @@ struct gl_pixelstore_attrib GLint RowLength; GLint SkipPixels; GLint SkipRows; - GLint ImageHeight; /**< for GL_EXT_texture3D */ - GLint SkipImages; /**< for GL_EXT_texture3D */ + GLint ImageHeight; + GLint SkipImages; GLboolean SwapBytes; GLboolean LsbFirst; GLboolean ClientStorage; /**< GL_APPLE_client_storage */ @@ -1644,7 +1640,6 @@ struct gl_pixelstore_attrib }; - /** * Client vertex array attributes */ @@ -1724,7 +1719,7 @@ struct gl_array_attrib struct gl_feedback { GLenum Type; - GLbitfield _Mask; /* FB_* bits */ + GLbitfield _Mask; /**< FB_* bits */ GLfloat *Buffer; GLuint BufferSize; GLuint Count; @@ -1948,14 +1943,14 @@ struct gl_program_state */ struct gl_vertex_program_state { - GLboolean Enabled; /**< User-set GL_VERTEX_PROGRAM_ARB/NV flag */ - GLboolean _Enabled; /**< Enabled and _valid_ user program? */ - GLboolean PointSizeEnabled; /**< GL_VERTEX_PROGRAM_POINT_SIZE_ARB/NV */ - GLboolean TwoSideEnabled; /**< GL_VERTEX_PROGRAM_TWO_SIDE_ARB/NV */ + GLboolean Enabled; /**< User-set GL_VERTEX_PROGRAM_ARB/NV flag */ + GLboolean _Enabled; /**< Enabled and _valid_ user program? */ + GLboolean PointSizeEnabled; /**< GL_VERTEX_PROGRAM_POINT_SIZE_ARB/NV */ + GLboolean TwoSideEnabled; /**< GL_VERTEX_PROGRAM_TWO_SIDE_ARB/NV */ struct gl_vertex_program *Current; /**< User-bound vertex program */ - /** Currently enabled and valid vertex program (including internal programs, - * user-defined vertex programs and GLSL vertex shaders). + /** Currently enabled and valid vertex program (including internal + * programs, user-defined vertex programs and GLSL vertex shaders). * This is the program we must use when rendering. */ struct gl_vertex_program *_Current; @@ -1995,8 +1990,8 @@ struct gl_fragment_program_state GLboolean _Enabled; /**< Enabled and _valid_ user program? */ struct gl_fragment_program *Current; /**< User-bound fragment program */ - /** Currently enabled and valid fragment program (including internal programs, - * user-defined fragment programs and GLSL fragment shaders). + /** Currently enabled and valid fragment program (including internal + * programs, user-defined fragment programs and GLSL fragment shaders). * This is the program we must use when rendering. */ struct gl_fragment_program *_Current; @@ -2339,9 +2334,8 @@ struct gl_renderbuffer /** - * A renderbuffer attachment point points to either a texture object - * (and specifies a mipmap level, cube face or 3D texture slice) or - * points to a renderbuffer. + * A renderbuffer attachment points to either a texture object (and specifies + * a mipmap level, cube face or 3D texture slice) or points to a renderbuffer. */ struct gl_renderbuffer_attachment { @@ -2373,14 +2367,16 @@ struct gl_renderbuffer_attachment */ struct gl_framebuffer { - _glthread_Mutex Mutex; /**< for thread safety */ - GLuint Name; /* if zero, this is a window system framebuffer */ + _glthread_Mutex Mutex; /**< for thread safety */ + GLuint Name; /**< if zero, this is a window system framebuffer */ GLint RefCount; GLboolean DeletePending; - GLvisual Visual; /**< The framebuffer's visual. - Immutable if this is a window system buffer. - Computed from attachments if user-made FBO. */ + /** + * The framebuffer's visual. Immutable if this is a window system buffer. + * Computed from attachments if user-made FBO. + */ + GLvisual Visual; GLboolean Initialized; @@ -2399,9 +2395,10 @@ struct gl_framebuffer GLfloat _MRD; /**< minimum resolvable difference in Z values */ /*@}*/ - GLenum _Status; /* One of the GL_FRAMEBUFFER_(IN)COMPLETE_* tokens */ + /** One of the GL_FRAMEBUFFER_(IN)COMPLETE_* tokens */ + GLenum _Status; - /* Array of all renderbuffer attachments, indexed by BUFFER_* tokens. */ + /** Array of all renderbuffer attachments, indexed by BUFFER_* tokens. */ struct gl_renderbuffer_attachment Attachment[BUFFER_COUNT]; /* In unextended OpenGL these vars are part of the GL_COLOR_BUFFER @@ -2463,52 +2460,58 @@ struct gl_program_constants */ struct gl_constants { - GLint MaxTextureLevels; /**< Maximum number of allowed mipmap levels. */ - GLint Max3DTextureLevels; /**< Maximum number of allowed mipmap levels for 3D texture targets. */ - GLint MaxCubeTextureLevels; /**< Maximum number of allowed mipmap levels for GL_ARB_texture_cube_map */ - GLint MaxArrayTextureLayers; /**< Maximum number of layers in an array texture. */ - GLint MaxTextureRectSize; /* GL_NV_texture_rectangle */ + GLint MaxTextureLevels; /**< Max mipmap levels. */ + GLint Max3DTextureLevels; /**< Max mipmap levels for 3D textures */ + GLint MaxCubeTextureLevels; /**< Max mipmap levels for cube textures */ + GLint MaxArrayTextureLayers; /**< Max layers in array textures */ + GLint MaxTextureRectSize; /**< Max rectangle texture size, in pixes */ GLuint MaxTextureCoordUnits; GLuint MaxTextureImageUnits; - GLuint MaxTextureUnits; /**< = MIN(CoordUnits, ImageUnits) */ - GLfloat MaxTextureMaxAnisotropy; /**< GL_EXT_texture_filter_anisotropic */ - GLfloat MaxTextureLodBias; /**< GL_EXT_texture_lod_bias */ + GLuint MaxVertexTextureImageUnits; + GLuint MaxTextureUnits; /**< = MIN(CoordUnits, ImageUnits) */ + GLfloat MaxTextureMaxAnisotropy; /**< GL_EXT_texture_filter_anisotropic */ + GLfloat MaxTextureLodBias; /**< GL_EXT_texture_lod_bias */ + GLuint MaxArrayLockSize; + GLint SubPixelBits; - GLfloat MinPointSize, MaxPointSize; /* aliased */ - GLfloat MinPointSizeAA, MaxPointSizeAA; /* antialiased */ + + GLfloat MinPointSize, MaxPointSize; /**< aliased */ + GLfloat MinPointSizeAA, MaxPointSizeAA; /**< antialiased */ GLfloat PointSizeGranularity; - GLfloat MinLineWidth, MaxLineWidth; /* aliased */ - GLfloat MinLineWidthAA, MaxLineWidthAA; /* antialiased */ + GLfloat MinLineWidth, MaxLineWidth; /**< aliased */ + GLfloat MinLineWidthAA, MaxLineWidthAA; /**< antialiased */ GLfloat LineWidthGranularity; + GLuint MaxColorTableSize; GLuint MaxConvolutionWidth; GLuint MaxConvolutionHeight; + GLuint MaxClipPlanes; GLuint MaxLights; - GLfloat MaxShininess; /* GL_NV_light_max_exponent */ - GLfloat MaxSpotExponent; /* GL_NV_light_max_exponent */ + GLfloat MaxShininess; /**< GL_NV_light_max_exponent */ + GLfloat MaxSpotExponent; /**< GL_NV_light_max_exponent */ + GLuint MaxViewportWidth, MaxViewportHeight; - struct gl_program_constants VertexProgram; /* GL_ARB_vertex_program */ - struct gl_program_constants FragmentProgram; /* GL_ARB_fragment_program */ - /* shared by vertex and fragment program: */ + + struct gl_program_constants VertexProgram; /**< GL_ARB_vertex_program */ + struct gl_program_constants FragmentProgram; /**< GL_ARB_fragment_program */ GLuint MaxProgramMatrices; GLuint MaxProgramMatrixStackDepth; - /* vertex array / buffer object bounds checking */ + + /** vertex array / buffer object bounds checking */ GLboolean CheckArrayBounds; - /* GL_ARB_draw_buffers */ - GLuint MaxDrawBuffers; - /* GL_OES_read_format */ - GLenum ColorReadFormat; - GLenum ColorReadType; - /* GL_EXT_framebuffer_object */ - GLuint MaxColorAttachments; - GLuint MaxRenderbufferSize; - /* GL_ARB_vertex_shader */ - GLuint MaxVertexTextureImageUnits; - GLuint MaxVarying; /**< Number of float[4] vectors */ - /* GL_ARB_framebuffer_object */ - GLuint MaxSamples; + + GLuint MaxDrawBuffers; /**< GL_ARB_draw_buffers */ + + GLenum ColorReadFormat; /**< GL_OES_read_format */ + GLenum ColorReadType; /**< GL_OES_read_format */ + + GLuint MaxColorAttachments; /**< GL_EXT_framebuffer_object */ + GLuint MaxRenderbufferSize; /**< GL_EXT_framebuffer_object */ + GLuint MaxSamples; /**< GL_ARB_framebuffer_object */ + + GLuint MaxVarying; /**< Number of float[4] varying parameters */ }; @@ -2518,12 +2521,6 @@ struct gl_constants */ struct gl_extensions { - /** - * \name Flags to quickly test if certain extensions are available. - * - * Not every extension needs to have such a flag, but it's encouraged. - */ - /*@{*/ GLboolean dummy; /* don't remove this! */ GLboolean ARB_depth_texture; GLboolean ARB_draw_buffers; @@ -2641,8 +2638,7 @@ struct gl_extensions GLboolean SGIS_texture_lod; GLboolean TDFX_texture_compression_FXT1; GLboolean S3_s3tc; - /*@}*/ - /* The extension string */ + /** The extension string */ const GLubyte *String; }; @@ -2662,7 +2658,6 @@ struct gl_matrix_stack /** * \name Bits for image transfer operations - * * \sa __GLcontextRec::ImageTransferState. */ /*@{*/ @@ -2677,7 +2672,7 @@ struct gl_matrix_stack #define IMAGE_POST_COLOR_MATRIX_COLOR_TABLE_BIT 0x100 #define IMAGE_HISTOGRAM_BIT 0x200 #define IMAGE_MIN_MAX_BIT 0x400 -#define IMAGE_CLAMP_BIT 0x800 /* extra */ +#define IMAGE_CLAMP_BIT 0x800 /** Pixel Transfer ops up to convolution */ @@ -3040,21 +3035,15 @@ struct __GLcontextRec struct gl_color_table ColorTable[COLORTABLE_MAX]; struct gl_color_table ProxyColorTable[COLORTABLE_MAX]; -#if 0 - struct gl_color_table PostConvolutionColorTable; - struct gl_color_table ProxyPostConvolutionColorTable; - struct gl_color_table PostColorMatrixColorTable; - struct gl_color_table ProxyPostColorMatrixColorTable; -#endif - - struct gl_program_state Program; /**< for vertex or fragment progs */ - struct gl_vertex_program_state VertexProgram; /**< GL_ARB/NV_vertex_program */ - struct gl_fragment_program_state FragmentProgram; /**< GL_ARB/NV_vertex_program */ - struct gl_ati_fragment_shader_state ATIFragmentShader; /**< GL_ATI_fragment_shader */ - struct gl_query_state Query; /**< GL_ARB_occlusion_query */ + struct gl_program_state Program; /**< general program state */ + struct gl_vertex_program_state VertexProgram; + struct gl_fragment_program_state FragmentProgram; + struct gl_ati_fragment_shader_state ATIFragmentShader; struct gl_shader_state Shader; /**< GLSL shader object state */ + + struct gl_query_state Query; /**< occlusion, timer queries */ /*@}*/ #if FEATURE_EXT_framebuffer_object @@ -3078,9 +3067,9 @@ struct __GLcontextRec GLfloat _ModelViewInvScale; GLboolean _NeedEyeCoords; GLboolean _ForceEyeCoords; - GLenum _CurrentProgram; /* currently executing program */ + GLenum _CurrentProgram; /**< currently executing program */ - GLuint TextureStateTimestamp; /* detect changes to shared state */ + GLuint TextureStateTimestamp; /**< detect changes to shared state */ struct gl_shine_tab *_ShineTable[2]; /**< Active shine tables */ struct gl_shine_tab *_ShineTabList; /**< MRU list of inactive shine tables */ -- cgit v1.2.3 From 55399c29511a47bd52c39862a246f29e6f35c3cf Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 21:41:26 -0700 Subject: mesa: move gl_enable_attrib struct to attrib.c, the only place it's used --- src/mesa/main/attrib.c | 84 ++++++++++++++++++++++++++++++++++++++++++++++++++ src/mesa/main/mtypes.h | 78 ---------------------------------------------- 2 files changed, 84 insertions(+), 78 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c index 996033a2d8..baad214263 100644 --- a/src/mesa/main/attrib.c +++ b/src/mesa/main/attrib.c @@ -58,6 +58,90 @@ #include "mtypes.h" +/** + * glEnable()/glDisable() attribute group (GL_ENABLE_BIT). + */ +struct gl_enable_attrib +{ + GLboolean AlphaTest; + GLboolean AutoNormal; + GLboolean Blend; + GLbitfield ClipPlanes; + GLboolean ColorMaterial; + GLboolean ColorTable[COLORTABLE_MAX]; + GLboolean Convolution1D; + GLboolean Convolution2D; + GLboolean Separable2D; + GLboolean CullFace; + GLboolean DepthTest; + GLboolean Dither; + GLboolean Fog; + GLboolean Histogram; + GLboolean Light[MAX_LIGHTS]; + GLboolean Lighting; + GLboolean LineSmooth; + GLboolean LineStipple; + GLboolean IndexLogicOp; + GLboolean ColorLogicOp; + + GLboolean Map1Color4; + GLboolean Map1Index; + GLboolean Map1Normal; + GLboolean Map1TextureCoord1; + GLboolean Map1TextureCoord2; + GLboolean Map1TextureCoord3; + GLboolean Map1TextureCoord4; + GLboolean Map1Vertex3; + GLboolean Map1Vertex4; + GLboolean Map1Attrib[16]; /* GL_NV_vertex_program */ + GLboolean Map2Color4; + GLboolean Map2Index; + GLboolean Map2Normal; + GLboolean Map2TextureCoord1; + GLboolean Map2TextureCoord2; + GLboolean Map2TextureCoord3; + GLboolean Map2TextureCoord4; + GLboolean Map2Vertex3; + GLboolean Map2Vertex4; + GLboolean Map2Attrib[16]; /* GL_NV_vertex_program */ + + GLboolean MinMax; + GLboolean Normalize; + GLboolean PixelTexture; + GLboolean PointSmooth; + GLboolean PolygonOffsetPoint; + GLboolean PolygonOffsetLine; + GLboolean PolygonOffsetFill; + GLboolean PolygonSmooth; + GLboolean PolygonStipple; + GLboolean RescaleNormals; + GLboolean Scissor; + GLboolean Stencil; + GLboolean StencilTwoSide; /* GL_EXT_stencil_two_side */ + GLboolean MultisampleEnabled; /* GL_ARB_multisample */ + GLboolean SampleAlphaToCoverage; /* GL_ARB_multisample */ + GLboolean SampleAlphaToOne; /* GL_ARB_multisample */ + GLboolean SampleCoverage; /* GL_ARB_multisample */ + GLboolean SampleCoverageInvert; /* GL_ARB_multisample */ + GLboolean RasterPositionUnclipped; /* GL_IBM_rasterpos_clip */ + + GLbitfield Texture[MAX_TEXTURE_UNITS]; + GLbitfield TexGen[MAX_TEXTURE_UNITS]; + + /* SGI_texture_color_table */ + GLboolean TextureColorTable[MAX_TEXTURE_UNITS]; + + /* GL_ARB_vertex_program / GL_NV_vertex_program */ + GLboolean VertexProgram; + GLboolean VertexProgramPointSize; + GLboolean VertexProgramTwoSide; + + /* GL_ARB_point_sprite / GL_NV_point_sprite */ + GLboolean PointSprite; + GLboolean FragmentShaderATI; +}; + + /** * Special struct for saving/restoring texture state (GL_TEXTURE_BIT) */ diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index ee49e5d178..a758c12d6f 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -655,84 +655,6 @@ struct gl_depthbuffer_attrib }; -/** - * glEnable()/glDisable() attribute group (GL_ENABLE_BIT). - */ -struct gl_enable_attrib -{ - GLboolean AlphaTest; - GLboolean AutoNormal; - GLboolean Blend; - GLbitfield ClipPlanes; - GLboolean ColorMaterial; - GLboolean ColorTable[COLORTABLE_MAX]; - GLboolean Convolution1D; - GLboolean Convolution2D; - GLboolean Separable2D; - GLboolean CullFace; - GLboolean DepthTest; - GLboolean Dither; - GLboolean Fog; - GLboolean Histogram; - GLboolean Light[MAX_LIGHTS]; - GLboolean Lighting; - GLboolean LineSmooth; - GLboolean LineStipple; - GLboolean IndexLogicOp; - GLboolean ColorLogicOp; - GLboolean Map1Color4; - GLboolean Map1Index; - GLboolean Map1Normal; - GLboolean Map1TextureCoord1; - GLboolean Map1TextureCoord2; - GLboolean Map1TextureCoord3; - GLboolean Map1TextureCoord4; - GLboolean Map1Vertex3; - GLboolean Map1Vertex4; - GLboolean Map1Attrib[16]; /* GL_NV_vertex_program */ - GLboolean Map2Color4; - GLboolean Map2Index; - GLboolean Map2Normal; - GLboolean Map2TextureCoord1; - GLboolean Map2TextureCoord2; - GLboolean Map2TextureCoord3; - GLboolean Map2TextureCoord4; - GLboolean Map2Vertex3; - GLboolean Map2Vertex4; - GLboolean Map2Attrib[16]; /* GL_NV_vertex_program */ - GLboolean MinMax; - GLboolean Normalize; - GLboolean PixelTexture; - GLboolean PointSmooth; - GLboolean PolygonOffsetPoint; - GLboolean PolygonOffsetLine; - GLboolean PolygonOffsetFill; - GLboolean PolygonSmooth; - GLboolean PolygonStipple; - GLboolean RescaleNormals; - GLboolean Scissor; - GLboolean Stencil; - GLboolean StencilTwoSide; /* GL_EXT_stencil_two_side */ - GLboolean MultisampleEnabled; /* GL_ARB_multisample */ - GLboolean SampleAlphaToCoverage; /* GL_ARB_multisample */ - GLboolean SampleAlphaToOne; /* GL_ARB_multisample */ - GLboolean SampleCoverage; /* GL_ARB_multisample */ - GLboolean SampleCoverageInvert; /* GL_ARB_multisample */ - GLboolean RasterPositionUnclipped; /* GL_IBM_rasterpos_clip */ - GLuint Texture[MAX_TEXTURE_UNITS]; - GLuint TexGen[MAX_TEXTURE_UNITS]; - /* SGI_texture_color_table */ - GLboolean TextureColorTable[MAX_TEXTURE_UNITS]; - /* GL_ARB_vertex_program / GL_NV_vertex_program */ - GLboolean VertexProgram; - GLboolean VertexProgramPointSize; - GLboolean VertexProgramTwoSide; - /* GL_ARB_point_sprite / GL_NV_point_sprite */ - GLboolean PointSprite; - GLboolean FragmentShaderATI; -}; - - /** * Evaluator attribute group (GL_EVAL_BIT). */ -- cgit v1.2.3 From 7f25d9ebb4856273c46ea4bbba4152b85f610a91 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:01:40 -0700 Subject: mesa: move gl_attrib_node struct to attrib.c too --- src/mesa/main/attrib.c | 12 ++++++++++++ src/mesa/main/mtypes.h | 12 +----------- 2 files changed, 13 insertions(+), 11 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/attrib.c b/src/mesa/main/attrib.c index baad214263..de27917709 100644 --- a/src/mesa/main/attrib.c +++ b/src/mesa/main/attrib.c @@ -142,6 +142,18 @@ struct gl_enable_attrib }; +/** + * Node for the attribute stack. + */ +struct gl_attrib_node +{ + GLbitfield kind; + void *data; + struct gl_attrib_node *next; +}; + + + /** * Special struct for saving/restoring texture state (GL_TEXTURE_BIT) */ diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index a758c12d6f..315295b5b3 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -115,6 +115,7 @@ typedef int GLfixed; */ /*@{*/ struct _mesa_HashTable; +struct gl_attrib_node; struct gl_pixelstore_attrib; struct gl_program_cache; struct gl_texture_format; @@ -1516,17 +1517,6 @@ struct gl_viewport_attrib }; -/** - * Node for the attribute stack. - */ -struct gl_attrib_node -{ - GLbitfield kind; - void *data; - struct gl_attrib_node *next; -}; - - /** * GL_ARB_vertex/pixel_buffer_object buffer object */ -- cgit v1.2.3 From f6021ab3c631345d013437d53a7bc1a4e2359ad4 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:04:58 -0700 Subject: mesa: remove dead code --- src/mesa/main/feedback.c | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/feedback.c b/src/mesa/main/feedback.c index 48c2ccbff3..69b235a3e5 100644 --- a/src/mesa/main/feedback.c +++ b/src/mesa/main/feedback.c @@ -126,20 +126,8 @@ void _mesa_feedback_vertex( GLcontext *ctx, GLfloat index, const GLfloat texcoord[4] ) { -#if 0 - { - /* snap window x, y to fractional pixel position */ - const GLint snapMask = ~((FIXED_ONE / (1 << SUB_PIXEL_BITS)) - 1); - GLfixed x, y; - x = FloatToFixed(win[0]) & snapMask; - y = FloatToFixed(win[1]) & snapMask; - FEEDBACK_TOKEN(ctx, FixedToFloat(x)); - FEEDBACK_TOKEN(ctx, FixedToFloat(y) ); - } -#else FEEDBACK_TOKEN( ctx, win[0] ); FEEDBACK_TOKEN( ctx, win[1] ); -#endif if (ctx->Feedback._Mask & FB_3D) { FEEDBACK_TOKEN( ctx, win[2] ); } -- cgit v1.2.3 From 559aec47015b741e045d57362f7732b3a04f9450 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:12:31 -0700 Subject: mesa: comments, whitespace, reformatting --- src/mesa/main/feedback.c | 37 ++++++++++++++++++++----------------- src/mesa/main/feedback.h | 28 +++++++++++++--------------- 2 files changed, 33 insertions(+), 32 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/feedback.c b/src/mesa/main/feedback.c index 69b235a3e5..9a62db0be3 100644 --- a/src/mesa/main/feedback.c +++ b/src/mesa/main/feedback.c @@ -1,13 +1,9 @@ -/** - * \file feedback.c - * Selection and feedback modes functions. - */ - /* * Mesa 3-D graphics library - * Version: 5.1 + * Version: 7.5 * - * Copyright (C) 1999-2003 Brian Paul All Rights Reserved. + * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. + * Copyright (C) 2009 VMware, Inc. All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -27,6 +23,11 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ +/** + * \file feedback.c + * Selection and feedback modes functions. + */ + #include "glheader.h" #include "colormac.h" @@ -116,15 +117,15 @@ _mesa_PassThrough( GLfloat token ) } - -/* +/** * Put a vertex into the feedback buffer. */ -void _mesa_feedback_vertex( GLcontext *ctx, - const GLfloat win[4], - const GLfloat color[4], - GLfloat index, - const GLfloat texcoord[4] ) +void +_mesa_feedback_vertex(GLcontext *ctx, + const GLfloat win[4], + const GLfloat color[4], + GLfloat index, + const GLfloat texcoord[4]) { FEEDBACK_TOKEN( ctx, win[0] ); FEEDBACK_TOKEN( ctx, win[1] ); @@ -151,7 +152,7 @@ void _mesa_feedback_vertex( GLcontext *ctx, } } -#endif +#endif /* _HAVE_FULL_GL */ /**********************************************************************/ @@ -217,7 +218,8 @@ _mesa_SelectBuffer( GLsizei size, GLuint *buffer ) * Sets gl_selection::HitFlag and updates gl_selection::HitMinZ and * gl_selection::HitMaxZ. */ -void _mesa_update_hitflag( GLcontext *ctx, GLfloat z ) +void +_mesa_update_hitflag(GLcontext *ctx, GLfloat z) { ctx->Select.HitFlag = GL_TRUE; if (z < ctx->Select.HitMinZ) { @@ -240,7 +242,8 @@ void _mesa_update_hitflag( GLcontext *ctx, GLfloat z ) * * \sa gl_selection. */ -static void write_hit_record( GLcontext *ctx ) +static void +write_hit_record(GLcontext *ctx) { GLuint i; GLuint zmin, zmax, zscale = (~0u); diff --git a/src/mesa/main/feedback.h b/src/mesa/main/feedback.h index 6c448ad631..c6478b02e1 100644 --- a/src/mesa/main/feedback.h +++ b/src/mesa/main/feedback.h @@ -1,13 +1,9 @@ -/** - * \file feedback.h - * Selection and feedback modes functions. - */ - /* * Mesa 3-D graphics library - * Version: 3.5 + * Version: 7.5 * - * Copyright (C) 1999-2001 Brian Paul All Rights Reserved. + * Copyright (C) 1999-2008 Brian Paul All Rights Reserved. + * Copyright (C) 2009 VMware, Inc. All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -27,7 +23,6 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ - #ifndef FEEDBACK_H #define FEEDBACK_H @@ -42,16 +37,19 @@ CTX->Feedback.Count++; -extern void _mesa_init_feedback( GLcontext * ctx ); +extern void +_mesa_init_feedback( GLcontext *ctx ); -extern void _mesa_feedback_vertex( GLcontext *ctx, - const GLfloat win[4], - const GLfloat color[4], - GLfloat index, - const GLfloat texcoord[4] ); +extern void +_mesa_feedback_vertex( GLcontext *ctx, + const GLfloat win[4], + const GLfloat color[4], + GLfloat index, + const GLfloat texcoord[4] ); -extern void _mesa_update_hitflag( GLcontext *ctx, GLfloat z ); +extern void +_mesa_update_hitflag( GLcontext *ctx, GLfloat z ); extern void GLAPIENTRY -- cgit v1.2.3 From bf8a187f71bd667a0dc0f70164a897d8e62361a8 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:18:33 -0700 Subject: mesa: replace FEEDBACK_TOKEN macro with _mesa_feedback_token() inline function --- src/mesa/main/drawpix.c | 8 ++++---- src/mesa/main/feedback.c | 31 ++++++++++++++++--------------- src/mesa/main/feedback.h | 17 ++++++++++------- src/mesa/swrast/s_feedback.c | 8 ++++---- 4 files changed, 34 insertions(+), 30 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/drawpix.c b/src/mesa/main/drawpix.c index 13cfa0e756..e9de0c097a 100644 --- a/src/mesa/main/drawpix.c +++ b/src/mesa/main/drawpix.c @@ -103,7 +103,7 @@ _mesa_DrawPixels( GLsizei width, GLsizei height, else if (ctx->RenderMode == GL_FEEDBACK) { /* Feedback the current raster pos info */ FLUSH_CURRENT( ctx, 0 ); - FEEDBACK_TOKEN( ctx, (GLfloat) (GLint) GL_DRAW_PIXEL_TOKEN ); + _mesa_feedback_token( ctx, (GLfloat) (GLint) GL_DRAW_PIXEL_TOKEN ); _mesa_feedback_vertex( ctx, ctx->Current.RasterPos, ctx->Current.RasterColor, @@ -166,7 +166,7 @@ _mesa_CopyPixels( GLint srcx, GLint srcy, GLsizei width, GLsizei height, } else if (ctx->RenderMode == GL_FEEDBACK) { FLUSH_CURRENT( ctx, 0 ); - FEEDBACK_TOKEN( ctx, (GLfloat) (GLint) GL_COPY_PIXEL_TOKEN ); + _mesa_feedback_token( ctx, (GLfloat) (GLint) GL_COPY_PIXEL_TOKEN ); _mesa_feedback_vertex( ctx, ctx->Current.RasterPos, ctx->Current.RasterColor, @@ -243,7 +243,7 @@ _mesa_Bitmap( GLsizei width, GLsizei height, #if _HAVE_FULL_GL else if (ctx->RenderMode == GL_FEEDBACK) { FLUSH_CURRENT(ctx, 0); - FEEDBACK_TOKEN( ctx, (GLfloat) (GLint) GL_BITMAP_TOKEN ); + _mesa_feedback_token( ctx, (GLfloat) (GLint) GL_BITMAP_TOKEN ); _mesa_feedback_vertex( ctx, ctx->Current.RasterPos, ctx->Current.RasterColor, @@ -311,7 +311,7 @@ _mesa_DrawDepthPixelsMESA( GLsizei width, GLsizei height, else if (ctx->RenderMode == GL_FEEDBACK) { /* Feedback the current raster pos info */ FLUSH_CURRENT( ctx, 0 ); - FEEDBACK_TOKEN( ctx, (GLfloat) (GLint) GL_DRAW_PIXEL_TOKEN ); + _mesa_feedback_token( ctx, (GLfloat) (GLint) GL_DRAW_PIXEL_TOKEN ); _mesa_feedback_vertex( ctx, ctx->Current.RasterPos, ctx->Current.RasterColor, diff --git a/src/mesa/main/feedback.c b/src/mesa/main/feedback.c index 9a62db0be3..5073ccbef5 100644 --- a/src/mesa/main/feedback.c +++ b/src/mesa/main/feedback.c @@ -111,8 +111,8 @@ _mesa_PassThrough( GLfloat token ) if (ctx->RenderMode==GL_FEEDBACK) { FLUSH_VERTICES(ctx, 0); - FEEDBACK_TOKEN( ctx, (GLfloat) (GLint) GL_PASS_THROUGH_TOKEN ); - FEEDBACK_TOKEN( ctx, token ); + _mesa_feedback_token( ctx, (GLfloat) (GLint) GL_PASS_THROUGH_TOKEN ); + _mesa_feedback_token( ctx, token ); } } @@ -127,31 +127,32 @@ _mesa_feedback_vertex(GLcontext *ctx, GLfloat index, const GLfloat texcoord[4]) { - FEEDBACK_TOKEN( ctx, win[0] ); - FEEDBACK_TOKEN( ctx, win[1] ); + _mesa_feedback_token( ctx, win[0] ); + _mesa_feedback_token( ctx, win[1] ); if (ctx->Feedback._Mask & FB_3D) { - FEEDBACK_TOKEN( ctx, win[2] ); + _mesa_feedback_token( ctx, win[2] ); } if (ctx->Feedback._Mask & FB_4D) { - FEEDBACK_TOKEN( ctx, win[3] ); + _mesa_feedback_token( ctx, win[3] ); } if (ctx->Feedback._Mask & FB_INDEX) { - FEEDBACK_TOKEN( ctx, (GLfloat) index ); + _mesa_feedback_token( ctx, (GLfloat) index ); } if (ctx->Feedback._Mask & FB_COLOR) { - FEEDBACK_TOKEN( ctx, color[0] ); - FEEDBACK_TOKEN( ctx, color[1] ); - FEEDBACK_TOKEN( ctx, color[2] ); - FEEDBACK_TOKEN( ctx, color[3] ); + _mesa_feedback_token( ctx, color[0] ); + _mesa_feedback_token( ctx, color[1] ); + _mesa_feedback_token( ctx, color[2] ); + _mesa_feedback_token( ctx, color[3] ); } if (ctx->Feedback._Mask & FB_TEXTURE) { - FEEDBACK_TOKEN( ctx, texcoord[0] ); - FEEDBACK_TOKEN( ctx, texcoord[1] ); - FEEDBACK_TOKEN( ctx, texcoord[2] ); - FEEDBACK_TOKEN( ctx, texcoord[3] ); + _mesa_feedback_token( ctx, texcoord[0] ); + _mesa_feedback_token( ctx, texcoord[1] ); + _mesa_feedback_token( ctx, texcoord[2] ); + _mesa_feedback_token( ctx, texcoord[3] ); } } + #endif /* _HAVE_FULL_GL */ diff --git a/src/mesa/main/feedback.h b/src/mesa/main/feedback.h index c6478b02e1..72c2acd5ed 100644 --- a/src/mesa/main/feedback.h +++ b/src/mesa/main/feedback.h @@ -30,13 +30,6 @@ #include "mtypes.h" -#define FEEDBACK_TOKEN( CTX, T ) \ - if (CTX->Feedback.Count < CTX->Feedback.BufferSize) { \ - CTX->Feedback.Buffer[CTX->Feedback.Count] = (GLfloat) (T); \ - } \ - CTX->Feedback.Count++; - - extern void _mesa_init_feedback( GLcontext *ctx ); @@ -48,6 +41,16 @@ _mesa_feedback_vertex( GLcontext *ctx, const GLfloat texcoord[4] ); +static INLINE void +_mesa_feedback_token( GLcontext *ctx, GLfloat token ) +{ + if (ctx->Feedback.Count < ctx->Feedback.BufferSize) { + ctx->Feedback.Buffer[ctx->Feedback.Count] = token; + } + ctx->Feedback.Count++; +} + + extern void _mesa_update_hitflag( GLcontext *ctx, GLfloat z ); diff --git a/src/mesa/swrast/s_feedback.c b/src/mesa/swrast/s_feedback.c index aa79531277..7bb914b658 100644 --- a/src/mesa/swrast/s_feedback.c +++ b/src/mesa/swrast/s_feedback.c @@ -59,8 +59,8 @@ _swrast_feedback_triangle(GLcontext *ctx, const SWvertex *v0, const SWvertex *v1, const SWvertex *v2) { if (_swrast_culltriangle(ctx, v0, v1, v2)) { - FEEDBACK_TOKEN(ctx, (GLfloat) (GLint) GL_POLYGON_TOKEN); - FEEDBACK_TOKEN(ctx, (GLfloat) 3); /* three vertices */ + _mesa_feedback_token(ctx, (GLfloat) (GLint) GL_POLYGON_TOKEN); + _mesa_feedback_token(ctx, (GLfloat) 3); /* three vertices */ if (ctx->Light.ShadeModel == GL_SMOOTH) { feedback_vertex(ctx, v0, v0); @@ -86,7 +86,7 @@ _swrast_feedback_line(GLcontext *ctx, const SWvertex *v0, if (swrast->StippleCounter == 0) token = GL_LINE_RESET_TOKEN; - FEEDBACK_TOKEN(ctx, (GLfloat) (GLint) token); + _mesa_feedback_token(ctx, (GLfloat) (GLint) token); if (ctx->Light.ShadeModel == GL_SMOOTH) { feedback_vertex(ctx, v0, v0); @@ -104,7 +104,7 @@ _swrast_feedback_line(GLcontext *ctx, const SWvertex *v0, void _swrast_feedback_point(GLcontext *ctx, const SWvertex *v) { - FEEDBACK_TOKEN(ctx, (GLfloat) (GLint) GL_POINT_TOKEN); + _mesa_feedback_token(ctx, (GLfloat) (GLint) GL_POINT_TOKEN); feedback_vertex(ctx, v, v); } -- cgit v1.2.3 From 8bf25a17d2f8f888e8e8a4f7a2c6d68c6c06f6e8 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:21:42 -0700 Subject: mesa: convert macro to inline function --- src/mesa/main/feedback.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/feedback.c b/src/mesa/main/feedback.c index 5073ccbef5..beab535b15 100644 --- a/src/mesa/main/feedback.c +++ b/src/mesa/main/feedback.c @@ -203,11 +203,14 @@ _mesa_SelectBuffer( GLsizei size, GLuint *buffer ) * Verifies there is free space in the buffer to write the value and * increments the pointer. */ -#define WRITE_RECORD( CTX, V ) \ - if (CTX->Select.BufferCount < CTX->Select.BufferSize) { \ - CTX->Select.Buffer[CTX->Select.BufferCount] = (V); \ - } \ - CTX->Select.BufferCount++; +static INLINE void +write_record(GLcontext *ctx, GLuint value) +{ + if (ctx->Select.BufferCount < ctx->Select.BufferSize) { + ctx->Select.Buffer[ctx->Select.BufferCount] = value; + } + ctx->Select.BufferCount++; +} /** @@ -256,11 +259,11 @@ write_hit_record(GLcontext *ctx) zmin = (GLuint) ((GLfloat) zscale * ctx->Select.HitMinZ); zmax = (GLuint) ((GLfloat) zscale * ctx->Select.HitMaxZ); - WRITE_RECORD( ctx, ctx->Select.NameStackDepth ); - WRITE_RECORD( ctx, zmin ); - WRITE_RECORD( ctx, zmax ); + write_record( ctx, ctx->Select.NameStackDepth ); + write_record( ctx, zmin ); + write_record( ctx, zmax ); for (i = 0; i < ctx->Select.NameStackDepth; i++) { - WRITE_RECORD( ctx, ctx->Select.NameStack[i] ); + write_record( ctx, ctx->Select.NameStack[i] ); } ctx->Select.Hits++; -- cgit v1.2.3 From 389d50baff8234fdf4d7bcddeb09658d7d17012d Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 22:26:18 -0700 Subject: mesa: move GLfixed type and related macros to swrast module Fixed point is only used in swrast and sw-based drivers. --- src/mesa/main/mtypes.h | 32 -------------------------------- src/mesa/swrast/s_context.h | 28 ++++++++++++++++++++++++++++ src/mesa/swrast/swrast.h | 6 ++++++ 3 files changed, 34 insertions(+), 32 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 315295b5b3..2801f61948 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -78,38 +78,6 @@ #endif -/** - * Fixed point data type. - */ -typedef int GLfixed; -/* - * Fixed point arithmetic macros - */ -#ifndef FIXED_FRAC_BITS -#define FIXED_FRAC_BITS 11 -#endif - -#define FIXED_SHIFT FIXED_FRAC_BITS -#define FIXED_ONE (1 << FIXED_SHIFT) -#define FIXED_HALF (1 << (FIXED_SHIFT-1)) -#define FIXED_FRAC_MASK (FIXED_ONE - 1) -#define FIXED_INT_MASK (~FIXED_FRAC_MASK) -#define FIXED_EPSILON 1 -#define FIXED_SCALE ((float) FIXED_ONE) -#define FIXED_DBL_SCALE ((double) FIXED_ONE) -#define FloatToFixed(X) (IROUND((X) * FIXED_SCALE)) -#define FixedToDouble(X) ((X) * (1.0 / FIXED_DBL_SCALE)) -#define IntToFixed(I) ((I) << FIXED_SHIFT) -#define FixedToInt(X) ((X) >> FIXED_SHIFT) -#define FixedToUns(X) (((unsigned int)(X)) >> FIXED_SHIFT) -#define FixedCeil(X) (((X) + FIXED_ONE - FIXED_EPSILON) & FIXED_INT_MASK) -#define FixedFloor(X) ((X) & FIXED_INT_MASK) -#define FixedToFloat(X) ((X) * (1.0F / FIXED_SCALE)) -#define PosFloatToFixed(X) FloatToFixed(X) -#define SignedFloatToFixed(X) FloatToFixed(X) - - - /** * \name Some forward type declarations */ diff --git a/src/mesa/swrast/s_context.h b/src/mesa/swrast/s_context.h index cdd6fa5048..6e8d080704 100644 --- a/src/mesa/swrast/s_context.h +++ b/src/mesa/swrast/s_context.h @@ -288,6 +288,34 @@ swrast_render_finish(GLcontext *ctx) +/* + * Fixed point arithmetic macros + */ +#ifndef FIXED_FRAC_BITS +#define FIXED_FRAC_BITS 11 +#endif + +#define FIXED_SHIFT FIXED_FRAC_BITS +#define FIXED_ONE (1 << FIXED_SHIFT) +#define FIXED_HALF (1 << (FIXED_SHIFT-1)) +#define FIXED_FRAC_MASK (FIXED_ONE - 1) +#define FIXED_INT_MASK (~FIXED_FRAC_MASK) +#define FIXED_EPSILON 1 +#define FIXED_SCALE ((float) FIXED_ONE) +#define FIXED_DBL_SCALE ((double) FIXED_ONE) +#define FloatToFixed(X) (IROUND((X) * FIXED_SCALE)) +#define FixedToDouble(X) ((X) * (1.0 / FIXED_DBL_SCALE)) +#define IntToFixed(I) ((I) << FIXED_SHIFT) +#define FixedToInt(X) ((X) >> FIXED_SHIFT) +#define FixedToUns(X) (((unsigned int)(X)) >> FIXED_SHIFT) +#define FixedCeil(X) (((X) + FIXED_ONE - FIXED_EPSILON) & FIXED_INT_MASK) +#define FixedFloor(X) ((X) & FIXED_INT_MASK) +#define FixedToFloat(X) ((X) * (1.0F / FIXED_SCALE)) +#define PosFloatToFixed(X) FloatToFixed(X) +#define SignedFloatToFixed(X) FloatToFixed(X) + + + /* * XXX these macros are just bandages for now in order to make * CHAN_BITS==32 compile cleanly. diff --git a/src/mesa/swrast/swrast.h b/src/mesa/swrast/swrast.h index 047f7991e6..015f8a05c3 100644 --- a/src/mesa/swrast/swrast.h +++ b/src/mesa/swrast/swrast.h @@ -75,6 +75,12 @@ typedef struct { } SWvertex; +/** + * Fixed point data type. + */ +typedef int GLfixed; + + #define FRAG_ATTRIB_CI FRAG_ATTRIB_COL0 -- cgit v1.2.3 From ae5c06b9ce1191afaa95dd784d7315f25ec729ff Mon Sep 17 00:00:00 2001 From: David Miller Date: Fri, 27 Feb 2009 23:34:41 -0800 Subject: mesa: Sparc's IROUND() optimization is invalid. We can't use the "fstoi" instruction like this. Unlike other floating point instructions, "fstoi" always rounds towards zero no matter what rounding mode the FPU has been set to. This was validated using the following test program: -------------------- static inline int iround(float f) { int r; __asm__ ("fstoi %1, %0" : "=f" (r) : "f" (f)); return r; } #define IROUND(x) iround(x) #define IROUND_REF(f) ((int) (((f) >= 0.0F) ? ((f) + 0.5F) : ((f) - 0.5F))) int main(void) { float f = -2.0; while (f < 3.0f) { int sparc_val = IROUND(f); int ref_val = IROUND_REF(f); if (sparc_val != ref_val) printf("DIFFERENT[%f]: REF==%d SPARC==%d\n", f, ref_val, sparc_val); f += 0.1f; } return 0; } -------------------- which prints out things like: -------------------- DIFFERENT[-1.900000]: REF==-2 SPARC==-1 DIFFERENT[-1.800000]: REF==-2 SPARC==-1 DIFFERENT[-1.700000]: REF==-2 SPARC==-1 DIFFERENT[-1.600000]: REF==-2 SPARC==-1 DIFFERENT[-1.000000]: REF==-1 SPARC==0 DIFFERENT[-0.900000]: REF==-1 SPARC==0 DIFFERENT[-0.800000]: REF==-1 SPARC==0 DIFFERENT[-0.700000]: REF==-1 SPARC==0 DIFFERENT[-0.600000]: REF==-1 SPARC==0 DIFFERENT[0.500000]: REF==1 SPARC==0 DIFFERENT[0.600000]: REF==1 SPARC==0 ... -------------------- So we have to remove Sparc's IROUND() definition, it's wrong. Signed-off-by: David S. Miller --- src/mesa/main/imports.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h index 4192f037c0..7b61e22e93 100644 --- a/src/mesa/main/imports.h +++ b/src/mesa/main/imports.h @@ -256,15 +256,7 @@ static INLINE int GET_FLOAT_BITS( float x ) /*** *** IROUND: return (as an integer) float rounded to nearest integer ***/ -#if defined(USE_SPARC_ASM) && defined(__GNUC__) && defined(__sparc__) -static INLINE int iround(float f) -{ - int r; - __asm__ ("fstoi %1, %0" : "=f" (r) : "f" (f)); - return r; -} -#define IROUND(x) iround(x) -#elif defined(USE_X86_ASM) && defined(__GNUC__) && defined(__i386__) && \ +#if defined(USE_X86_ASM) && defined(__GNUC__) && defined(__i386__) && \ (!(defined(__BEOS__) || defined(__HAIKU__)) || \ (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95))) static INLINE int iround(float f) -- cgit v1.2.3 From b7ebc270a4b464eb2136e9c45fdfeed798c007c8 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Sat, 28 Feb 2009 10:08:22 -0700 Subject: mesa: move #include "bitset.h" out of mtypes.h - not needed in core Mesa --- src/mesa/main/mtypes.h | 1 - src/mesa/tnl/t_context.h | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 2801f61948..f608ac42a8 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -38,7 +38,6 @@ #include "main/config.h" #include "main/compiler.h" #include "main/mfeatures.h" -#include "main/bitset.h" #include "glapi/glapi.h" #include "math/m_matrix.h" /* GLmatrix */ diff --git a/src/mesa/tnl/t_context.h b/src/mesa/tnl/t_context.h index 0a6ce04614..c19eb3df3c 100644 --- a/src/mesa/tnl/t_context.h +++ b/src/mesa/tnl/t_context.h @@ -50,6 +50,7 @@ #define _T_CONTEXT_H #include "main/glheader.h" +#include "main/bitset.h" #include "main/mtypes.h" #include "math/m_matrix.h" -- cgit v1.2.3 From c50c2e4e986024c728cc35e56e56250e947080a6 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 27 Feb 2009 16:44:28 -0700 Subject: mesa: move _GenFlags = 0x0 to texgen loop --- src/mesa/main/texstate.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/texstate.c b/src/mesa/main/texstate.c index 3e6b09baa1..e25c9e732c 100644 --- a/src/mesa/main/texstate.c +++ b/src/mesa/main/texstate.c @@ -550,7 +550,6 @@ update_texture_state( GLcontext *ctx ) texUnit->_Current = NULL; texUnit->_ReallyEnabled = 0x0; - texUnit->_GenFlags = 0x0; /* Get the bitmask of texture target enables. * enableBits will be a mask of the TEXTURE_*_BIT flags indicating @@ -609,6 +608,8 @@ update_texture_state( GLcontext *ctx ) for (unit = 0; unit < ctx->Const.MaxTextureCoordUnits; unit++) { struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit]; + texUnit->_GenFlags = 0x0; + if (!(ctx->Texture._EnabledCoordUnits & (1 << unit))) continue; -- cgit v1.2.3 From 4c4268dd31ce119d5d3db090adf0935bf3c27831 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Sat, 28 Feb 2009 10:58:57 -0700 Subject: mesa: convert some #defines to enums This makes debugging with gdb a bit easier. Ex: (gdb) p ctx->DrawBuffer.Attachment[BUFFER_STENCIL] Note however that gdb only seems to recognize enum types that are actually used to declare a variable somewhere. For example, gl_buffer_index isn't used to declare any vars so it's invisible to gdb. Work around this by adding a dummy function in context.c that declares some vars with these new types. --- src/mesa/main/context.c | 32 +++++++++++++++ src/mesa/main/mtypes.h | 103 +++++++++++++++++++++++++----------------------- 2 files changed, 86 insertions(+), 49 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c index fb43054cdd..97ee925c0b 100644 --- a/src/mesa/main/context.c +++ b/src/mesa/main/context.c @@ -351,6 +351,36 @@ _mesa_destroy_visual( GLvisual *vis ) /**********************************************************************/ /*@{*/ + +/** + * This is lame. gdb only seems to recognize enum types that are + * actually used somewhere. We want to be able to print/use enum + * values such as TEXTURE_2D_INDEX in gdb. But we don't actually use + * the gl_texture_index type anywhere. Thus, this lame function. + */ +static void +dummy_enum_func(void) +{ + gl_buffer_index bi; + gl_colortable_index ci; + gl_face_index fi; + gl_frag_attrib fa; + gl_frag_result fr; + gl_texture_index ti; + gl_vert_attrib va; + gl_vert_result vr; + + (void) bi; + (void) ci; + (void) fi; + (void) fa; + (void) fr; + (void) ti; + (void) va; + (void) vr; +} + + /** * One-time initialization mutex lock. * @@ -406,6 +436,8 @@ one_time_init( GLcontext *ctx ) alreadyCalled = GL_TRUE; } _glthread_UNLOCK_MUTEX(OneTimeLock); + + dummy_enum_func(); } diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index f608ac42a8..22add9d975 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -103,7 +103,7 @@ typedef struct gl_framebuffer GLframebuffer; * In GL_ARB_vertex_shader / OpenGL 2.0 the aliasing is disallowed (the * generic attributes are distinct/separate). */ -enum +typedef enum { VERT_ATTRIB_POS = 0, VERT_ATTRIB_WEIGHT = 1, @@ -139,7 +139,7 @@ enum VERT_ATTRIB_GENERIC14 = 30, VERT_ATTRIB_GENERIC15 = 31, VERT_ATTRIB_MAX = 32 -}; +} gl_vert_attrib; /** * Bitflags for vertex attributes. @@ -187,8 +187,7 @@ enum /** * Indexes for vertex program result attributes */ -/*@{*/ -enum +typedef enum { VERT_RESULT_HPOS = 0, VERT_RESULT_COL0 = 1, @@ -208,14 +207,13 @@ enum VERT_RESULT_EDGE = 15, VERT_RESULT_VAR0 = 16 /**< shader varying */, VERT_RESULT_MAX = (VERT_RESULT_VAR0 + MAX_VARYING) -}; -/*@}*/ +} gl_vert_result; /** * Indexes for fragment program input attributes. */ -enum +typedef enum { FRAG_ATTRIB_WPOS = 0, FRAG_ATTRIB_COL0 = 1, @@ -231,7 +229,7 @@ enum FRAG_ATTRIB_TEX7 = 11, FRAG_ATTRIB_VAR0 = 12, /**< shader varying */ FRAG_ATTRIB_MAX = (FRAG_ATTRIB_VAR0 + MAX_VARYING) -}; +} gl_frag_attrib; /** * Bitflags for fragment program input attributes. @@ -268,41 +266,45 @@ enum /** * Fragment program results */ -enum +typedef enum { FRAG_RESULT_COLR = 0, FRAG_RESULT_COLH = 1, FRAG_RESULT_DEPR = 2, FRAG_RESULT_DATA0 = 3, FRAG_RESULT_MAX = (FRAG_RESULT_DATA0 + MAX_DRAW_BUFFERS) -}; +} gl_frag_result; /** * Indexes for all renderbuffers */ -enum { - BUFFER_FRONT_LEFT = 0, /* the four standard color buffers */ - BUFFER_BACK_LEFT = 1, - BUFFER_FRONT_RIGHT = 2, - BUFFER_BACK_RIGHT = 3, - BUFFER_AUX0 = 4, /* optional aux buffer */ - BUFFER_AUX1 = 5, - BUFFER_AUX2 = 6, - BUFFER_AUX3 = 7, - BUFFER_DEPTH = 8, - BUFFER_STENCIL = 9, - BUFFER_ACCUM = 10, - BUFFER_COLOR0 = 11, /* generic renderbuffers */ - BUFFER_COLOR1 = 12, - BUFFER_COLOR2 = 13, - BUFFER_COLOR3 = 14, - BUFFER_COLOR4 = 15, - BUFFER_COLOR5 = 16, - BUFFER_COLOR6 = 17, - BUFFER_COLOR7 = 18, - BUFFER_COUNT = 19 -}; +typedef enum +{ + /* the four standard color buffers */ + BUFFER_FRONT_LEFT, + BUFFER_BACK_LEFT, + BUFFER_FRONT_RIGHT, + BUFFER_BACK_RIGHT, + /* optional aux buffers */ + BUFFER_AUX0, + BUFFER_AUX1, + BUFFER_AUX2, + BUFFER_AUX3, + BUFFER_DEPTH, + BUFFER_STENCIL, + BUFFER_ACCUM, + /* generic renderbuffers */ + BUFFER_COLOR0, + BUFFER_COLOR1, + BUFFER_COLOR2, + BUFFER_COLOR3, + BUFFER_COLOR4, + BUFFER_COLOR5, + BUFFER_COLOR6, + BUFFER_COLOR7, + BUFFER_COUNT +} gl_buffer_index; /** * Bit flags for all renderbuffers @@ -349,12 +351,13 @@ enum { /** The pixel transfer path has three color tables: */ -/*@{*/ -#define COLORTABLE_PRECONVOLUTION 0 -#define COLORTABLE_POSTCONVOLUTION 1 -#define COLORTABLE_POSTCOLORMATRIX 2 -#define COLORTABLE_MAX 3 -/*@}*/ +typedef enum +{ + COLORTABLE_PRECONVOLUTION, + COLORTABLE_POSTCONVOLUTION, + COLORTABLE_POSTCOLORMATRIX, + COLORTABLE_MAX +} gl_colortable_index; /** @@ -1034,7 +1037,8 @@ struct gl_stencil_attrib * target target enums, such as GL_TEXTURE_2D, GL_TEXTURE_CUBE_MAP, etc. * Note: the order is from highest priority to lowest priority. */ -enum { +typedef enum +{ TEXTURE_2D_ARRAY_INDEX, TEXTURE_1D_ARRAY_INDEX, TEXTURE_CUBE_INDEX, @@ -1043,7 +1047,7 @@ enum { TEXTURE_2D_INDEX, TEXTURE_1D_INDEX, NUM_TEXTURE_TARGETS -}; +} gl_texture_index; /** @@ -1273,15 +1277,16 @@ struct gl_texture_image /** * Indexes for cube map faces. */ -/*@{*/ -#define FACE_POS_X 0 -#define FACE_NEG_X 1 -#define FACE_POS_Y 2 -#define FACE_NEG_Y 3 -#define FACE_POS_Z 4 -#define FACE_NEG_Z 5 -#define MAX_FACES 6 -/*@}*/ +typedef enum +{ + FACE_POS_X = 0, + FACE_NEG_X = 1, + FACE_POS_Y = 2, + FACE_NEG_Y = 3, + FACE_POS_Z = 4, + FACE_NEG_Z = 5, + MAX_FACES = 6 +} gl_face_index; /** -- cgit v1.2.3 From 8d475822e6e19fa79719c856a2db5b6a205db1b9 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Sat, 28 Feb 2009 11:49:46 -0700 Subject: mesa: rename, reorder FRAG_RESULT_x tokens s/FRAG_RESULT_DEPR/FRAG_RESULT_DEPTH/ s/FRAG_RESULT_COLR/FRAG_RESULT/COLOR/ Remove FRAG_RESULT_COLH (NV half-precision) output since we never used it. Next, we might merge the COLOR and DATA outputs (COLOR0, COLOR1, etc). --- src/mesa/drivers/dri/i915/i915_fragprog.c | 4 +-- src/mesa/drivers/dri/i965/brw_wm.c | 2 +- src/mesa/drivers/dri/i965/brw_wm_fp.c | 8 ++--- src/mesa/drivers/dri/i965/brw_wm_state.c | 2 +- src/mesa/drivers/dri/r300/r300_fragprog.c | 4 +-- src/mesa/drivers/dri/r300/r500_fragprog.c | 4 +-- src/mesa/drivers/dri/r300/radeon_nqssadce.c | 2 +- src/mesa/drivers/dri/r300/radeon_program_pair.c | 4 +-- src/mesa/main/mtypes.h | 7 ++--- src/mesa/main/texenvprogram.c | 6 ++-- src/mesa/shader/arbprogparse.c | 4 +-- src/mesa/shader/nvfragparse.c | 40 ++++++++----------------- src/mesa/shader/nvfragparse.h | 5 ---- src/mesa/shader/prog_debug.c | 12 +++----- src/mesa/shader/program.c | 6 ++-- src/mesa/shader/programopt.c | 6 ++-- src/mesa/shader/slang/slang_codegen.c | 4 +-- src/mesa/shader/slang/slang_link.c | 2 +- src/mesa/state_tracker/st_atom_pixeltransfer.c | 4 +-- src/mesa/state_tracker/st_cb_drawpixels.c | 10 +++---- src/mesa/state_tracker/st_program.c | 10 +++---- src/mesa/swrast/s_context.c | 2 +- src/mesa/swrast/s_fragprog.c | 12 ++++---- 23 files changed, 68 insertions(+), 92 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/drivers/dri/i915/i915_fragprog.c b/src/mesa/drivers/dri/i915/i915_fragprog.c index f091d600c3..52f09a4b1b 100644 --- a/src/mesa/drivers/dri/i915/i915_fragprog.c +++ b/src/mesa/drivers/dri/i915/i915_fragprog.c @@ -180,9 +180,9 @@ get_result_vector(struct i915_fragment_program *p, switch (inst->DstReg.File) { case PROGRAM_OUTPUT: switch (inst->DstReg.Index) { - case FRAG_RESULT_COLR: + case FRAG_RESULT_COLOR: return UREG(REG_TYPE_OC, 0); - case FRAG_RESULT_DEPR: + case FRAG_RESULT_DEPTH: p->depth_written = 1; return UREG(REG_TYPE_OD, 0); default: diff --git a/src/mesa/drivers/dri/i965/brw_wm.c b/src/mesa/drivers/dri/i965/brw_wm.c index 10f38e02a4..06a6f3f0f4 100644 --- a/src/mesa/drivers/dri/i965/brw_wm.c +++ b/src/mesa/drivers/dri/i965/brw_wm.c @@ -198,7 +198,7 @@ static void brw_wm_populate_key( struct brw_context *brw, ctx->Color.AlphaEnabled) lookup |= IZ_PS_KILL_ALPHATEST_BIT; - if (fp->program.Base.OutputsWritten & (1<program.Base.OutputsWritten & (1<Aux = (i<<1); if (c->fp_fragcolor_emitted) { - outcolor = src_reg(PROGRAM_OUTPUT, FRAG_RESULT_COLR); + outcolor = src_reg(PROGRAM_OUTPUT, FRAG_RESULT_COLOR); last_inst = inst = emit_op(c, WM_FB_WRITE, dst_mask(dst_undef(),0), 0, outcolor, payload_r0_depth, outdepth); inst->Aux = (i<<1); @@ -892,7 +892,7 @@ static void emit_fb_write( struct brw_wm_compile *c ) if (c->fp->program.Base.OutputsWritten & (1 << FRAG_RESULT_DATA0)) outcolor = src_reg(PROGRAM_OUTPUT, FRAG_RESULT_DATA0); else - outcolor = src_reg(PROGRAM_OUTPUT, FRAG_RESULT_COLR); + outcolor = src_reg(PROGRAM_OUTPUT, FRAG_RESULT_COLOR); inst = emit_op(c, WM_FB_WRITE, dst_mask(dst_undef(),0), 0, outcolor, payload_r0_depth, outdepth); @@ -928,7 +928,7 @@ static void validate_dst_regs( struct brw_wm_compile *c, { if (inst->DstReg.File == PROGRAM_OUTPUT) { GLuint idx = inst->DstReg.Index; - if (idx == FRAG_RESULT_COLR) + if (idx == FRAG_RESULT_COLOR) c->fp_fragcolor_emitted = 1; } } diff --git a/src/mesa/drivers/dri/i965/brw_wm_state.c b/src/mesa/drivers/dri/i965/brw_wm_state.c index 3c3b3473d6..f7ea756fb0 100644 --- a/src/mesa/drivers/dri/i965/brw_wm_state.c +++ b/src/mesa/drivers/dri/i965/brw_wm_state.c @@ -103,7 +103,7 @@ wm_unit_populate_key(struct brw_context *brw, struct brw_wm_unit_key *key) /* as far as we can tell */ key->computes_depth = - (fp->Base.OutputsWritten & (1 << FRAG_RESULT_DEPR)) != 0; + (fp->Base.OutputsWritten & (1 << FRAG_RESULT_DEPTH)) != 0; /* _NEW_COLOR */ key->uses_kill = fp->UsesKill || ctx->Color.AlphaEnabled; diff --git a/src/mesa/drivers/dri/r300/r300_fragprog.c b/src/mesa/drivers/dri/r300/r300_fragprog.c index 8d030c63fb..32182bb667 100644 --- a/src/mesa/drivers/dri/r300/r300_fragprog.c +++ b/src/mesa/drivers/dri/r300/r300_fragprog.c @@ -356,8 +356,8 @@ static void insert_WPOS_trailer(struct r300_fragment_program_compiler *compiler) static void nqssadce_init(struct nqssadce_state* s) { - s->Outputs[FRAG_RESULT_COLR].Sourced = WRITEMASK_XYZW; - s->Outputs[FRAG_RESULT_DEPR].Sourced = WRITEMASK_W; + s->Outputs[FRAG_RESULT_COLOR].Sourced = WRITEMASK_XYZW; + s->Outputs[FRAG_RESULT_DEPTH].Sourced = WRITEMASK_W; } diff --git a/src/mesa/drivers/dri/r300/r500_fragprog.c b/src/mesa/drivers/dri/r300/r500_fragprog.c index 926ddd5964..07a2a7b17c 100644 --- a/src/mesa/drivers/dri/r300/r500_fragprog.c +++ b/src/mesa/drivers/dri/r300/r500_fragprog.c @@ -298,8 +298,8 @@ static void insert_WPOS_trailer(struct r500_fragment_program_compiler *compiler) static void nqssadce_init(struct nqssadce_state* s) { - s->Outputs[FRAG_RESULT_COLR].Sourced = WRITEMASK_XYZW; - s->Outputs[FRAG_RESULT_DEPR].Sourced = WRITEMASK_W; + s->Outputs[FRAG_RESULT_COLOR].Sourced = WRITEMASK_XYZW; + s->Outputs[FRAG_RESULT_DEPTH].Sourced = WRITEMASK_W; } static GLboolean is_native_swizzle(GLuint opcode, struct prog_src_register reg) diff --git a/src/mesa/drivers/dri/r300/radeon_nqssadce.c b/src/mesa/drivers/dri/r300/radeon_nqssadce.c index 97ce016c99..a083c3d243 100644 --- a/src/mesa/drivers/dri/r300/radeon_nqssadce.c +++ b/src/mesa/drivers/dri/r300/radeon_nqssadce.c @@ -191,7 +191,7 @@ static void process_instruction(struct nqssadce_state* s) if (inst->Opcode != OPCODE_KIL) { if (s->Descr->RewriteDepthOut) { - if (inst->DstReg.File == PROGRAM_OUTPUT && inst->DstReg.Index == FRAG_RESULT_DEPR) + if (inst->DstReg.File == PROGRAM_OUTPUT && inst->DstReg.Index == FRAG_RESULT_DEPTH) rewrite_depth_out(inst); } diff --git a/src/mesa/drivers/dri/r300/radeon_program_pair.c b/src/mesa/drivers/dri/r300/radeon_program_pair.c index 58bc0d5843..365e7c1722 100644 --- a/src/mesa/drivers/dri/r300/radeon_program_pair.c +++ b/src/mesa/drivers/dri/r300/radeon_program_pair.c @@ -778,10 +778,10 @@ static void fill_dest_into_pair(struct pair_state *s, struct radeon_pair_instruc struct prog_instruction *inst = s->Program->Instructions + ip; if (inst->DstReg.File == PROGRAM_OUTPUT) { - if (inst->DstReg.Index == FRAG_RESULT_COLR) { + if (inst->DstReg.Index == FRAG_RESULT_COLOR) { pair->RGB.OutputWriteMask |= inst->DstReg.WriteMask & WRITEMASK_XYZ; pair->Alpha.OutputWriteMask |= GET_BIT(inst->DstReg.WriteMask, 3); - } else if (inst->DstReg.Index == FRAG_RESULT_DEPR) { + } else if (inst->DstReg.Index == FRAG_RESULT_DEPTH) { pair->Alpha.DepthWriteMask |= GET_BIT(inst->DstReg.WriteMask, 3); } } else { diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h index 22add9d975..f17b9e1e71 100644 --- a/src/mesa/main/mtypes.h +++ b/src/mesa/main/mtypes.h @@ -268,10 +268,9 @@ typedef enum */ typedef enum { - FRAG_RESULT_COLR = 0, - FRAG_RESULT_COLH = 1, - FRAG_RESULT_DEPR = 2, - FRAG_RESULT_DATA0 = 3, + FRAG_RESULT_DEPTH = 0, + FRAG_RESULT_COLOR = 1, + FRAG_RESULT_DATA0 = 2, FRAG_RESULT_MAX = (FRAG_RESULT_DATA0 + MAX_DRAW_BUFFERS) } gl_frag_result; diff --git a/src/mesa/main/texenvprogram.c b/src/mesa/main/texenvprogram.c index d2a9e35dd5..51c13a563d 100644 --- a/src/mesa/main/texenvprogram.c +++ b/src/mesa/main/texenvprogram.c @@ -1098,7 +1098,7 @@ emit_texenv(struct texenv_fragment_program *p, GLuint unit) rgb_shift) dest = get_temp( p ); else - dest = make_ureg(PROGRAM_OUTPUT, FRAG_RESULT_COLR); + dest = make_ureg(PROGRAM_OUTPUT, FRAG_RESULT_COLOR); /* Emit the RGB and A combine ops */ @@ -1278,7 +1278,7 @@ create_new_program(GLcontext *ctx, struct state_key *key, p.program->Base.Parameters = _mesa_new_parameter_list(); p.program->Base.InputsRead = 0; - p.program->Base.OutputsWritten = 1 << FRAG_RESULT_COLR; + p.program->Base.OutputsWritten = 1 << FRAG_RESULT_COLOR; for (unit = 0; unit < ctx->Const.MaxTextureUnits; unit++) p.src_texture[unit] = undef; @@ -1313,7 +1313,7 @@ create_new_program(GLcontext *ctx, struct state_key *key, } cf = get_source( &p, SRC_PREVIOUS, 0 ); - out = make_ureg( PROGRAM_OUTPUT, FRAG_RESULT_COLR ); + out = make_ureg( PROGRAM_OUTPUT, FRAG_RESULT_COLOR ); if (key->separate_specular) { /* Emit specular add. diff --git a/src/mesa/shader/arbprogparse.c b/src/mesa/shader/arbprogparse.c index 62edb7f595..ccc0318a53 100644 --- a/src/mesa/shader/arbprogparse.c +++ b/src/mesa/shader/arbprogparse.c @@ -1688,7 +1688,7 @@ parse_result_binding(GLcontext *ctx, const GLubyte **inst, */ parse_output_color_num(ctx, inst, Program, &out_color); ASSERT(out_color < MAX_DRAW_BUFFERS); - *outputReg = FRAG_RESULT_COLR; + *outputReg = FRAG_RESULT_COLOR; } else { /* for vtx programs, this is VERTEX_RESULT_POSITION */ @@ -1699,7 +1699,7 @@ parse_result_binding(GLcontext *ctx, const GLubyte **inst, case FRAGMENT_RESULT_DEPTH: if (Program->Base.Target == GL_FRAGMENT_PROGRAM_ARB) { /* for frag programs, this is FRAGMENT_RESULT_DEPTH */ - *outputReg = FRAG_RESULT_DEPR; + *outputReg = FRAG_RESULT_DEPTH; } else { /* for vtx programs, this is VERTEX_RESULT_COLOR */ diff --git a/src/mesa/shader/nvfragparse.c b/src/mesa/shader/nvfragparse.c index 20e4781372..37418ffb6e 100644 --- a/src/mesa/shader/nvfragparse.c +++ b/src/mesa/shader/nvfragparse.c @@ -384,18 +384,12 @@ static const char *InputRegisters[MAX_NV_FRAGMENT_PROGRAM_INPUTS + 1] = { "TEX0", "TEX1", "TEX2", "TEX3", "TEX4", "TEX5", "TEX6", "TEX7", NULL }; + static const char *OutputRegisters[MAX_NV_FRAGMENT_PROGRAM_OUTPUTS + 1] = { - "COLR", "COLH", - /* These are only allows for register combiners */ - /* - "TEX0", "TEX1", "TEX2", "TEX3", - */ - "DEPR", NULL + "DEPR", "COLR", "DATA0", NULL }; - - /**********************************************************************/ /** @@ -828,7 +822,6 @@ static GLboolean Parse_OutputReg(struct parse_state *parseState, GLint *outputRegNum) { GLubyte token[100]; - GLint j; /* Match "o[" */ if (!Parse_String(parseState, "o[")) @@ -839,19 +832,19 @@ Parse_OutputReg(struct parse_state *parseState, GLint *outputRegNum) RETURN_ERROR; /* try to match an output register name */ - for (j = 0; OutputRegisters[j]; j++) { - if (_mesa_strcmp((const char *) token, OutputRegisters[j]) == 0) { - static GLuint bothColors = (1 << FRAG_RESULT_COLR) | (1 << FRAG_RESULT_COLH); - *outputRegNum = j; - parseState->outputsWritten |= (1 << j); - if ((parseState->outputsWritten & bothColors) == bothColors) { - RETURN_ERROR1("Illegal to write to both o[COLR] and o[COLH]"); - } - break; - } + if (_mesa_strcmp((char *) token, "COLR") == 0 || + _mesa_strcmp((char *) token, "COLH") == 0) { + /* note that we don't distinguish between COLR and COLH */ + *outputRegNum = FRAG_RESULT_COLOR; + parseState->outputsWritten |= (1 << FRAG_RESULT_COLOR); } - if (!OutputRegisters[j]) + else if (_mesa_strcmp((char *) token, "DEPR") == 0) { + *outputRegNum = FRAG_RESULT_DEPTH; + parseState->outputsWritten |= (1 << FRAG_RESULT_DEPTH); + } + else { RETURN_ERROR1("Invalid output register name"); + } /* Match ']' */ if (!Parse_String(parseState, "]")) @@ -1826,10 +1819,3 @@ _mesa_nv_fragment_input_register_name(GLuint i) return InputRegisters[i]; } - -const char * -_mesa_nv_fragment_output_register_name(GLuint i) -{ - ASSERT(i < MAX_NV_FRAGMENT_PROGRAM_OUTPUTS); - return OutputRegisters[i]; -} diff --git a/src/mesa/shader/nvfragparse.h b/src/mesa/shader/nvfragparse.h index de45cf543d..ac97921080 100644 --- a/src/mesa/shader/nvfragparse.h +++ b/src/mesa/shader/nvfragparse.h @@ -44,9 +44,4 @@ _mesa_print_nv_fragment_program(const struct gl_fragment_program *program); extern const char * _mesa_nv_fragment_input_register_name(GLuint i); - -extern const char * -_mesa_nv_fragment_output_register_name(GLuint i); - - #endif diff --git a/src/mesa/shader/prog_debug.c b/src/mesa/shader/prog_debug.c index 7bcb2ef734..35ce37d5ce 100644 --- a/src/mesa/shader/prog_debug.c +++ b/src/mesa/shader/prog_debug.c @@ -222,20 +222,16 @@ _mesa_GetProgramRegisterfvMESA(GLenum target, "glGetProgramRegisterfvMESA(registerName)"); return; } - else if (_mesa_strcmp(reg, "o[COLR]") == 0) { + else if (_mesa_strcmp(reg, "o[COLR]") == 0 || + _mesa_strcmp(reg, "o[COLH]") == 0) { /* Fragment output color */ ctx->Driver.GetProgramRegister(ctx, PROGRAM_OUTPUT, - FRAG_RESULT_COLR, v); - } - else if (_mesa_strcmp(reg, "o[COLH]") == 0) { - /* Fragment output color */ - ctx->Driver.GetProgramRegister(ctx, PROGRAM_OUTPUT, - FRAG_RESULT_COLH, v); + FRAG_RESULT_COLOR, v); } else if (_mesa_strcmp(reg, "o[DEPR]") == 0) { /* Fragment output depth */ ctx->Driver.GetProgramRegister(ctx, PROGRAM_OUTPUT, - FRAG_RESULT_DEPR, v); + FRAG_RESULT_DEPTH, v); } else { /* try user-defined identifiers */ diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c index 00655f0288..2e5632710e 100644 --- a/src/mesa/shader/program.c +++ b/src/mesa/shader/program.c @@ -738,7 +738,7 @@ _mesa_combine_programs(GLcontext *ctx, /* Connect color outputs of fprogA to color inputs of fprogB, via a * new temporary register. */ - if ((progA->OutputsWritten & (1 << FRAG_RESULT_COLR)) && + if ((progA->OutputsWritten & (1 << FRAG_RESULT_COLOR)) && (progB_inputsRead & FRAG_BIT_COL0)) { GLint tempReg = _mesa_find_free_register(newProg, PROGRAM_TEMPORARY); if (tempReg < 0) { @@ -748,7 +748,7 @@ _mesa_combine_programs(GLcontext *ctx, } /* replace writes to result.color[0] with tempReg */ replace_registers(newInst, lenA, - PROGRAM_OUTPUT, FRAG_RESULT_COLR, + PROGRAM_OUTPUT, FRAG_RESULT_COLOR, PROGRAM_TEMPORARY, tempReg); /* replace reads from the input color with tempReg */ replace_registers(newInst + lenA, lenB, @@ -758,7 +758,7 @@ _mesa_combine_programs(GLcontext *ctx, /* compute combined program's InputsRead */ inputsB = progB_inputsRead; - if (progA->OutputsWritten & (1 << FRAG_RESULT_COLR)) { + if (progA->OutputsWritten & (1 << FRAG_RESULT_COLOR)) { inputsB &= ~(1 << FRAG_ATTRIB_COL0); } newProg->InputsRead = progA->InputsRead | inputsB; diff --git a/src/mesa/shader/programopt.c b/src/mesa/shader/programopt.c index 56f1eb832e..05d9bdf7ec 100644 --- a/src/mesa/shader/programopt.c +++ b/src/mesa/shader/programopt.c @@ -171,7 +171,7 @@ _mesa_append_fog_code(GLcontext *ctx, struct gl_fragment_program *fprog) if (inst->Opcode == OPCODE_END) break; if (inst->DstReg.File == PROGRAM_OUTPUT && - inst->DstReg.Index == FRAG_RESULT_COLR) { + inst->DstReg.Index == FRAG_RESULT_COLOR) { /* change the instruction to write to colorTemp w/ clamping */ inst->DstReg.File = PROGRAM_TEMPORARY; inst->DstReg.Index = colorTemp; @@ -249,7 +249,7 @@ _mesa_append_fog_code(GLcontext *ctx, struct gl_fragment_program *fprog) /* LRP result.color.xyz, fogFactorTemp.xxxx, colorTemp, fogColorRef; */ inst->Opcode = OPCODE_LRP; inst->DstReg.File = PROGRAM_OUTPUT; - inst->DstReg.Index = FRAG_RESULT_COLR; + inst->DstReg.Index = FRAG_RESULT_COLOR; inst->DstReg.WriteMask = WRITEMASK_XYZ; inst->SrcReg[0].File = PROGRAM_TEMPORARY; inst->SrcReg[0].Index = fogFactorTemp; @@ -264,7 +264,7 @@ _mesa_append_fog_code(GLcontext *ctx, struct gl_fragment_program *fprog) /* MOV result.color.w, colorTemp.x; # copy alpha */ inst->Opcode = OPCODE_MOV; inst->DstReg.File = PROGRAM_OUTPUT; - inst->DstReg.Index = FRAG_RESULT_COLR; + inst->DstReg.Index = FRAG_RESULT_COLOR; inst->DstReg.WriteMask = WRITEMASK_W; inst->SrcReg[0].File = PROGRAM_TEMPORARY; inst->SrcReg[0].Index = colorTemp; diff --git a/src/mesa/shader/slang/slang_codegen.c b/src/mesa/shader/slang/slang_codegen.c index 5e2ce0ce3a..ee24e2e138 100644 --- a/src/mesa/shader/slang/slang_codegen.c +++ b/src/mesa/shader/slang/slang_codegen.c @@ -450,8 +450,8 @@ _slang_output_index(const char *name, GLenum target) { NULL, 0 } }; static const struct output_info fragOutputs[] = { - { "gl_FragColor", FRAG_RESULT_COLR }, - { "gl_FragDepth", FRAG_RESULT_DEPR }, + { "gl_FragColor", FRAG_RESULT_COLOR }, + { "gl_FragDepth", FRAG_RESULT_DEPTH }, { "gl_FragData", FRAG_RESULT_DATA0 }, { NULL, 0 } }; diff --git a/src/mesa/shader/slang/slang_link.c b/src/mesa/shader/slang/slang_link.c index bcabe71bfa..f98434892b 100644 --- a/src/mesa/shader/slang/slang_link.c +++ b/src/mesa/shader/slang/slang_link.c @@ -686,7 +686,7 @@ _slang_link(GLcontext *ctx, /* check that gl_FragColor and gl_FragData are not both written to */ if (shProg->FragmentProgram) { GLbitfield outputsWritten = shProg->FragmentProgram->Base.OutputsWritten; - if ((outputsWritten & ((1 << FRAG_RESULT_COLR))) && + if ((outputsWritten & ((1 << FRAG_RESULT_COLOR))) && (outputsWritten >= (1 << FRAG_RESULT_DATA0))) { link_error(shProg, "Fragment program cannot write both gl_FragColor" " and gl_FragData[].\n"); diff --git a/src/mesa/state_tracker/st_atom_pixeltransfer.c b/src/mesa/state_tracker/st_atom_pixeltransfer.c index ce872458e3..05b69c9d00 100644 --- a/src/mesa/state_tracker/st_atom_pixeltransfer.c +++ b/src/mesa/state_tracker/st_atom_pixeltransfer.c @@ -212,7 +212,7 @@ get_pixel_transfer_program(GLcontext *ctx, const struct state_key *key) inst[ic].TexSrcTarget = TEXTURE_2D_INDEX; ic++; fp->Base.InputsRead = (1 << FRAG_ATTRIB_TEX0); - fp->Base.OutputsWritten = (1 << FRAG_RESULT_COLR); + fp->Base.OutputsWritten = (1 << FRAG_RESULT_COLOR); fp->Base.SamplersUsed = 0x1; /* sampler 0 (bit 0) is used */ if (key->scaleAndBias) { @@ -400,7 +400,7 @@ get_pixel_transfer_program(GLcontext *ctx, const struct state_key *key) { struct prog_instruction *last = &inst[ic - 1]; last->DstReg.File = PROGRAM_OUTPUT; - last->DstReg.Index = FRAG_RESULT_COLR; + last->DstReg.Index = FRAG_RESULT_COLOR; } /* END; */ diff --git a/src/mesa/state_tracker/st_cb_drawpixels.c b/src/mesa/state_tracker/st_cb_drawpixels.c index c73d0080ca..cc7a9e7890 100644 --- a/src/mesa/state_tracker/st_cb_drawpixels.c +++ b/src/mesa/state_tracker/st_cb_drawpixels.c @@ -75,7 +75,7 @@ is_passthrough_program(const struct gl_fragment_program *prog) if (inst[0].Opcode == OPCODE_MOV && inst[1].Opcode == OPCODE_END && inst[0].DstReg.File == PROGRAM_OUTPUT && - inst[0].DstReg.Index == FRAG_RESULT_COLR && + inst[0].DstReg.Index == FRAG_RESULT_COLOR && inst[0].DstReg.WriteMask == WRITEMASK_XYZW && inst[0].SrcReg[0].File == PROGRAM_INPUT && inst[0].SrcReg[0].Index == FRAG_ATTRIB_COL0 && @@ -158,7 +158,7 @@ combined_drawpix_fragment_program(GLcontext *ctx) /** * Create fragment shader that does a TEX() instruction to get a Z - * value, then writes to FRAG_RESULT_DEPR. + * value, then writes to FRAG_RESULT_DEPTH. * Pass fragment color through as-is. */ static struct st_fragment_program * @@ -191,7 +191,7 @@ make_fragment_shader_z(struct st_context *st) /* TEX result.depth, fragment.texcoord[0], texture[0], 2D; */ p->Instructions[ic].Opcode = OPCODE_TEX; p->Instructions[ic].DstReg.File = PROGRAM_OUTPUT; - p->Instructions[ic].DstReg.Index = FRAG_RESULT_DEPR; + p->Instructions[ic].DstReg.Index = FRAG_RESULT_DEPTH; p->Instructions[ic].DstReg.WriteMask = WRITEMASK_Z; p->Instructions[ic].SrcReg[0].File = PROGRAM_INPUT; p->Instructions[ic].SrcReg[0].Index = FRAG_ATTRIB_TEX0; @@ -202,7 +202,7 @@ make_fragment_shader_z(struct st_context *st) /* MOV result.color, fragment.color */ p->Instructions[ic].Opcode = OPCODE_MOV; p->Instructions[ic].DstReg.File = PROGRAM_OUTPUT; - p->Instructions[ic].DstReg.Index = FRAG_RESULT_COLR; + p->Instructions[ic].DstReg.Index = FRAG_RESULT_COLOR; p->Instructions[ic].SrcReg[0].File = PROGRAM_INPUT; p->Instructions[ic].SrcReg[0].Index = FRAG_ATTRIB_COL0; ic++; @@ -213,7 +213,7 @@ make_fragment_shader_z(struct st_context *st) assert(ic == p->NumInstructions); p->InputsRead = FRAG_BIT_TEX0 | FRAG_BIT_COL0; - p->OutputsWritten = (1 << FRAG_RESULT_COLR) | (1 << FRAG_RESULT_DEPR); + p->OutputsWritten = (1 << FRAG_RESULT_COLOR) | (1 << FRAG_RESULT_DEPTH); p->SamplersUsed = 0x1; /* sampler 0 (bit 0) is used */ st->drawpix.z_shader = (struct st_fragment_program *) p; diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c index d2535b6a2f..f825204915 100644 --- a/src/mesa/state_tracker/st_program.c +++ b/src/mesa/state_tracker/st_program.c @@ -466,23 +466,23 @@ st_translate_fragment_program(struct st_context *st, GLbitfield outputsWritten = stfp->Base.Base.OutputsWritten; /* if z is written, emit that first */ - if (outputsWritten & (1 << FRAG_RESULT_DEPR)) { + if (outputsWritten & (1 << FRAG_RESULT_DEPTH)) { fs_output_semantic_name[fs_num_outputs] = TGSI_SEMANTIC_POSITION; fs_output_semantic_index[fs_num_outputs] = 0; - outputMapping[FRAG_RESULT_DEPR] = fs_num_outputs; + outputMapping[FRAG_RESULT_DEPTH] = fs_num_outputs; fs_num_outputs++; - outputsWritten &= ~(1 << FRAG_RESULT_DEPR); + outputsWritten &= ~(1 << FRAG_RESULT_DEPTH); } /* handle remaning outputs (color) */ for (attr = 0; attr < FRAG_RESULT_MAX; attr++) { if (outputsWritten & (1 << attr)) { switch (attr) { - case FRAG_RESULT_DEPR: + case FRAG_RESULT_DEPTH: /* handled above */ assert(0); break; - case FRAG_RESULT_COLR: + case FRAG_RESULT_COLOR: fs_output_semantic_name[fs_num_outputs] = TGSI_SEMANTIC_COLOR; fs_output_semantic_index[fs_num_outputs] = numColors; outputMapping[attr] = fs_num_outputs; diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c index 297940adbd..719e6b8296 100644 --- a/src/mesa/swrast/s_context.c +++ b/src/mesa/swrast/s_context.c @@ -206,7 +206,7 @@ _swrast_update_deferred_texture(GLcontext *ctx) else { const struct gl_fragment_program *fprog = ctx->FragmentProgram._Current; - if (fprog && (fprog->Base.OutputsWritten & (1 << FRAG_RESULT_DEPR))) { + if (fprog && (fprog->Base.OutputsWritten & (1 << FRAG_RESULT_DEPTH))) { /* Z comes from fragment program/shader */ swrast->_DeferredTexture = GL_FALSE; } diff --git a/src/mesa/swrast/s_fragprog.c b/src/mesa/swrast/s_fragprog.c index c6601f5593..3735f041d6 100644 --- a/src/mesa/swrast/s_fragprog.c +++ b/src/mesa/swrast/s_fragprog.c @@ -202,9 +202,9 @@ run_program(GLcontext *ctx, SWspan *span, GLuint start, GLuint end) if (_mesa_execute_program(ctx, &program->Base, machine)) { /* Store result color */ - if (outputsWritten & (1 << FRAG_RESULT_COLR)) { + if (outputsWritten & (1 << FRAG_RESULT_COLOR)) { COPY_4V(span->array->attribs[FRAG_ATTRIB_COL0][i], - machine->Outputs[FRAG_RESULT_COLR]); + machine->Outputs[FRAG_RESULT_COLOR]); } else { /* Multiple drawbuffers / render targets @@ -221,8 +221,8 @@ run_program(GLcontext *ctx, SWspan *span, GLuint start, GLuint end) } /* Store result depth/z */ - if (outputsWritten & (1 << FRAG_RESULT_DEPR)) { - const GLfloat depth = machine->Outputs[FRAG_RESULT_DEPR][2]; + if (outputsWritten & (1 << FRAG_RESULT_DEPTH)) { + const GLfloat depth = machine->Outputs[FRAG_RESULT_DEPTH][2]; if (depth <= 0.0) span->array->z[i] = 0; else if (depth >= 1.0) @@ -259,12 +259,12 @@ _swrast_exec_fragment_program( GLcontext *ctx, SWspan *span ) run_program(ctx, span, 0, span->end); - if (program->Base.OutputsWritten & (1 << FRAG_RESULT_COLR)) { + if (program->Base.OutputsWritten & (1 << FRAG_RESULT_COLOR)) { span->interpMask &= ~SPAN_RGBA; span->arrayMask |= SPAN_RGBA; } - if (program->Base.OutputsWritten & (1 << FRAG_RESULT_DEPR)) { + if (program->Base.OutputsWritten & (1 << FRAG_RESULT_DEPTH)) { span->interpMask &= ~SPAN_Z; span->arrayMask |= SPAN_Z; } -- cgit v1.2.3