mesa.git
17 years agoMerge branch 'master' into i915-unification
Eric Anholt [Fri, 18 May 2007 21:14:12 +0000 (14:14 -0700)]
Merge branch 'master' into i915-unification

Conflicts:

src/mesa/drivers/dri/common/dri_bufmgr.c
src/mesa/drivers/dri/common/dri_drmpool.c
src/mesa/drivers/dri/i915tex/intel_batchpool.c
src/mesa/drivers/dri/i915tex/intel_buffer_objects.c
src/mesa/drivers/dri/i915tex/intel_regions.c
src/mesa/drivers/dri/i915tex/intel_screen.c
src/mesa/drivers/dri/i915tex/intel_screen.h

17 years agoFix a refcounting mistake with first_swap_fence.
Eric Anholt [Fri, 18 May 2007 20:47:46 +0000 (13:47 -0700)]
Fix a refcounting mistake with first_swap_fence.

17 years agoFix another mis-calling of _fence_wait_internal.
Eric Anholt [Fri, 18 May 2007 20:47:21 +0000 (13:47 -0700)]
Fix another mis-calling of _fence_wait_internal.

17 years agoAllow unreference with a NULL argument.
Eric Anholt [Fri, 18 May 2007 19:59:39 +0000 (12:59 -0700)]
Allow unreference with a NULL argument.

17 years agoFix double-counting of low_offset in block->virtual.
Eric Anholt [Fri, 18 May 2007 19:57:34 +0000 (12:57 -0700)]
Fix double-counting of low_offset in block->virtual.

17 years agoZero out bufmgr_fake on alloc.
Eric Anholt [Fri, 18 May 2007 19:39:00 +0000 (12:39 -0700)]
Zero out bufmgr_fake on alloc.

17 years agoDead code elimination and fix bufmgr_fake_wait_idle.
Eric Anholt [Fri, 18 May 2007 19:10:05 +0000 (12:10 -0700)]
Dead code elimination and fix bufmgr_fake_wait_idle.

17 years agoKill old struct bufmgr members.
Eric Anholt [Fri, 18 May 2007 19:09:34 +0000 (12:09 -0700)]
Kill old struct bufmgr members.

17 years agoFix some use-before-initialize in bufmgr_fake.
Eric Anholt [Fri, 18 May 2007 18:55:00 +0000 (11:55 -0700)]
Fix some use-before-initialize in bufmgr_fake.

17 years agoRatchet required version down to 1.5 (pre-TTM).
Eric Anholt [Fri, 18 May 2007 18:29:55 +0000 (11:29 -0700)]
Ratchet required version down to 1.5 (pre-TTM).

17 years agofix STATE_HALF_VECTOR value (bug 10987)
Brian [Fri, 18 May 2007 13:46:27 +0000 (07:46 -0600)]
fix STATE_HALF_VECTOR value (bug 10987)

17 years agochange max anisotropy test
Christoff Brill [Thu, 17 May 2007 23:18:13 +0000 (17:18 -0600)]
change max anisotropy test

17 years agouse R200_DEBUG for debug output
Christoff Brill [Thu, 17 May 2007 23:17:25 +0000 (17:17 -0600)]
use R200_DEBUG for debug output

17 years agoremove CVS/XFree86 keywords
Christoff Brill [Thu, 17 May 2007 23:16:37 +0000 (17:16 -0600)]
remove CVS/XFree86 keywords

17 years agoRestore missing intel_batchbuffer_reset() which was needed.
Eric Anholt [Thu, 17 May 2007 22:36:43 +0000 (15:36 -0700)]
Restore missing intel_batchbuffer_reset() which was needed.

17 years agoRename the i915tex_dri.so driver to just i915_dri.so again.
Eric Anholt [Thu, 17 May 2007 22:36:26 +0000 (15:36 -0700)]
Rename the i915tex_dri.so driver to just i915_dri.so again.

17 years agoConvert i915tex to the new interface and make it compile.
Eric Anholt [Thu, 17 May 2007 22:28:01 +0000 (15:28 -0700)]
Convert i915tex to the new interface and make it compile.

17 years agoget rid of needless static function declarations at top of file
Brian [Thu, 17 May 2007 21:28:20 +0000 (15:28 -0600)]
get rid of needless static function declarations at top of file

17 years agoIn DestroyPbuffer(), use GetReq() intead of GetReqExtra(). See bug 10983.
Brian [Thu, 17 May 2007 21:25:26 +0000 (15:25 -0600)]
In DestroyPbuffer(), use GetReq() intead of GetReqExtra(). See bug 10983.

17 years agoAdd missing _EXT suffix to 2D_ARRAY target enums.
Ian Romanick [Thu, 17 May 2007 18:54:22 +0000 (11:54 -0700)]
Add missing _EXT suffix to 2D_ARRAY target enums.

17 years agoAdd array texture targets to list that can use compressed formats.
Ian Romanick [Thu, 17 May 2007 18:16:19 +0000 (11:16 -0700)]
Add array texture targets to list that can use compressed formats.

17 years agoRefactor determining whether a texture target can use compressed format
Ian Romanick [Thu, 17 May 2007 18:13:41 +0000 (11:13 -0700)]
Refactor determining whether a texture target can use compressed format

17 years agomake srcPtr param to make_1d_stack_mipmap() const
Brian [Thu, 17 May 2007 14:56:46 +0000 (08:56 -0600)]
make srcPtr param to make_1d_stack_mipmap() const

17 years agoMerge branch 'master' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa
Brian [Thu, 17 May 2007 14:54:08 +0000 (08:54 -0600)]
Merge branch 'master' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa

17 years agor300: Removed the radeon_vertex_buffer structure.
Tommy Schultz Lassen [Thu, 17 May 2007 14:11:23 +0000 (14:11 +0000)]
r300: Removed the radeon_vertex_buffer structure.

17 years agoInitial implementation of MESA_texture_array
Ian Romanick [Wed, 16 May 2007 22:34:22 +0000 (15:34 -0700)]
Initial implementation of MESA_texture_array

Shadow sampling from texture arrays is still not implemented.  Everything
else should be there, though.

17 years agoInitial version of MESA_texture_array spec.
Ian Romanick [Wed, 16 May 2007 22:33:36 +0000 (15:33 -0700)]
Initial version of MESA_texture_array spec.

17 years agoWIP: Replace TTM buffer pool manager with a simplified interface.
Eric Anholt [Wed, 16 May 2007 22:14:20 +0000 (15:14 -0700)]
WIP: Replace TTM buffer pool manager with a simplified interface.

The interface is not solid yet (some simplification to do still, and
adjustment for 0-copy), and the drivers are not converted.  However, the new
interface allows using the same calls to support either a TTM or a classic
static allocation backend, with the static backend allowing a more limited
feature set.

17 years agoAdd simple program to test GL_MESA_texture_array.
Ian Romanick [Wed, 16 May 2007 21:46:13 +0000 (14:46 -0700)]
Add simple program to test GL_MESA_texture_array.

17 years agoAdd enums and functions for GL_{MESA,EXT}_texture_array.
Ian Romanick [Wed, 16 May 2007 21:45:52 +0000 (14:45 -0700)]
Add enums and functions for GL_{MESA,EXT}_texture_array.

17 years agoBring framebuffer_texture's error checking more in-line with the spec.
Ian Romanick [Tue, 15 May 2007 20:42:25 +0000 (13:42 -0700)]
Bring framebuffer_texture's error checking more in-line with the spec.

17 years agoSkeleton file for 7.1 release notes.
Brian [Mon, 14 May 2007 20:40:59 +0000 (14:40 -0600)]
Skeleton file for 7.1 release notes.

17 years agomaster/trunk is now for Mesa 7.1 devel: bump versions
Brian [Mon, 14 May 2007 20:30:36 +0000 (14:30 -0600)]
master/trunk is now for Mesa 7.1 devel: bump versions

17 years agoin __glXGetArrayType() return type, not enabled (bug 10938)
Bruce Merry [Mon, 14 May 2007 15:37:48 +0000 (09:37 -0600)]
in __glXGetArrayType() return type, not enabled (bug 10938)

17 years agocomment about fixing uniform structs
Brian [Fri, 11 May 2007 21:50:33 +0000 (15:50 -0600)]
comment about fixing uniform structs

17 years agor300: Enable the non-user-buffers code to compile.
Oliver McFadden [Sun, 13 May 2007 13:38:38 +0000 (13:38 +0000)]
r300: Enable the non-user-buffers code to compile.

17 years agor300: Use e32(0x0) rather than e32(0); makes greping for hex values easier.
Oliver McFadden [Sun, 13 May 2007 12:59:41 +0000 (12:59 +0000)]
r300: Use e32(0x0) rather than e32(0); makes greping for hex values easier.

17 years agor300: Use the defined values when writing to R300_RS_ROUTE_0.
Oliver McFadden [Sun, 13 May 2007 12:56:59 +0000 (12:56 +0000)]
r300: Use the defined values when writing to R300_RS_ROUTE_0.

17 years agor300: Use the defined values when writing to R300_SE_VTE_CNTL.
Oliver McFadden [Sun, 13 May 2007 12:43:40 +0000 (12:43 +0000)]
r300: Use the defined values when writing to R300_SE_VTE_CNTL.

You can verify this is correct with the following code.

  assert (0x043f ==
  (R300_VTX_W0_FMT | R300_VPORT_X_SCALE_ENA | R300_VPORT_X_OFFSET_ENA
   | R300_VPORT_Y_SCALE_ENA | R300_VPORT_Y_OFFSET_ENA |
   R300_VPORT_Z_SCALE_ENA | R300_VPORT_Z_OFFSET_ENA));

17 years agor300: Added a TODO comment for the R300_VAP_INPUT_ROUTE_[01]_0 values.
Oliver McFadden [Sun, 13 May 2007 12:36:27 +0000 (12:36 +0000)]
r300: Added a TODO comment for the R300_VAP_INPUT_ROUTE_[01]_0 values.

17 years agor300: Changed some more functions to static functions.
Oliver McFadden [Sun, 13 May 2007 09:09:30 +0000 (09:09 +0000)]
r300: Changed some more functions to static functions.

This required reordering some of the functions which is why the diff is a little
larger.

17 years agor300: Changed a couple of functions in r300_state.c to static functions.
Oliver McFadden [Sun, 13 May 2007 08:59:54 +0000 (08:59 +0000)]
r300: Changed a couple of functions in r300_state.c to static functions.

17 years agor300: Removed the unused r300_aos_rec (replaced by r300_dma_region) structure.
Oliver McFadden [Sun, 13 May 2007 08:43:30 +0000 (08:43 +0000)]
r300: Removed the unused r300_aos_rec (replaced by r300_dma_region) structure.

17 years agor300: Use #if 0 for disabled code, rather than commenting it out.
Oliver McFadden [Sun, 13 May 2007 08:28:51 +0000 (08:28 +0000)]
r300: Use #if 0 for disabled code, rather than commenting it out.

17 years agor300: Removed a couple of obsolete/commented out includes.
Oliver McFadden [Sun, 13 May 2007 08:21:50 +0000 (08:21 +0000)]
r300: Removed a couple of obsolete/commented out includes.

17 years agor300: A few very minor indenting corrections.
Oliver McFadden [Sun, 13 May 2007 07:51:41 +0000 (07:51 +0000)]
r300: A few very minor indenting corrections.

17 years agor300: Use the defined values for the interpolater (interp_magic) magic values.
Oliver McFadden [Sun, 13 May 2007 07:44:20 +0000 (07:44 +0000)]
r300: Use the defined values for the interpolater (interp_magic) magic values.

17 years agor300: Use the defined values when writing to R300_VAP_INPUT_CNTL_[01].
Oliver McFadden [Sun, 13 May 2007 06:39:24 +0000 (06:39 +0000)]
r300: Use the defined values when writing to R300_VAP_INPUT_CNTL_[01].

You can verify this is correct with the following code.

  assert (0x00000001 == R300_INPUT_CNTL_0_COLOR);

  assert (0x00000405 ==
  (R300_INPUT_CNTL_POS | R300_INPUT_CNTL_COLOR |
   R300_INPUT_CNTL_TC0));

17 years agoRevert "r300: Perform the locking closer to the DRM texture upload call."
Oliver McFadden [Sat, 12 May 2007 17:16:56 +0000 (17:16 +0000)]
Revert "r300: Perform the locking closer to the DRM texture upload call."

This reverts commit 93881edb46fc95e1cfb4ded4e8a5db92612d3e4d.

17 years agobring over recent radeonMakeCurrent fixes for r300 to radeon/r200
Roland Scheidegger [Sat, 12 May 2007 09:20:24 +0000 (11:20 +0200)]
bring over recent radeonMakeCurrent fixes for r300 to radeon/r200

17 years agor300: Removed the name argument to ALLOC_STATE; do the name via the macro.
Oliver McFadden [Sat, 12 May 2007 01:53:56 +0000 (01:53 +0000)]
r300: Removed the name argument to ALLOC_STATE; do the name via the macro.

17 years agor300: Renamed r300DoEmitState to r300EmitAtoms.
Oliver McFadden [Sat, 12 May 2007 01:13:54 +0000 (01:13 +0000)]
r300: Renamed r300DoEmitState to r300EmitAtoms.

17 years agor300: Perform the locking closer to the DRM texture upload call.
Oliver McFadden [Sat, 12 May 2007 00:14:33 +0000 (00:14 +0000)]
r300: Perform the locking closer to the DRM texture upload call.

This might help if with attaching GDB if the driver gets into a -EAGAIN loop.

17 years agor300: Removed unused FORCE_32BITS_ELTS define.
Oliver McFadden [Fri, 11 May 2007 23:35:37 +0000 (23:35 +0000)]
r300: Removed unused FORCE_32BITS_ELTS define.

17 years agor300: Removed the unused CPT macro.
Oliver McFadden [Fri, 11 May 2007 23:33:47 +0000 (23:33 +0000)]
r300: Removed the unused CPT macro.

17 years agor300: Moved r300PackFloat24 near r300PackFloat32.
Oliver McFadden [Fri, 11 May 2007 23:32:03 +0000 (23:32 +0000)]
r300: Moved r300PackFloat24 near r300PackFloat32.

17 years agor300: Added insert_at_tail to the ALLOC_STATE macro.
Oliver McFadden [Fri, 11 May 2007 23:13:08 +0000 (23:13 +0000)]
r300: Added insert_at_tail to the ALLOC_STATE macro.

17 years agoRevert "r300: Merged radeon_span.c."
Oliver McFadden [Fri, 11 May 2007 23:03:40 +0000 (23:03 +0000)]
Revert "r300: Merged radeon_span.c."

This reverts commit 0aa998b2ab6fdfe139b54de9868e2383440685d0.

17 years agor300: Corrected another error; regexp replaced something it shouldn't have.
Oliver McFadden [Fri, 11 May 2007 22:26:47 +0000 (22:26 +0000)]
r300: Corrected another error; regexp replaced something it shouldn't have.

17 years agor300: Corrected some macro errors from the previous commit.
Oliver McFadden [Fri, 11 May 2007 22:23:31 +0000 (22:23 +0000)]
r300: Corrected some macro errors from the previous commit.

17 years agor300: Reduced the diff on radeon_lock.[ch].
Oliver McFadden [Fri, 11 May 2007 22:21:19 +0000 (22:21 +0000)]
r300: Reduced the diff on radeon_lock.[ch].

17 years agor300: Initial work on merging radeon_lock.[ch].
Oliver McFadden [Fri, 11 May 2007 22:02:52 +0000 (22:02 +0000)]
r300: Initial work on merging radeon_lock.[ch].

17 years agor300: Merged radeon_span.c.
Oliver McFadden [Fri, 11 May 2007 21:56:10 +0000 (21:56 +0000)]
r300: Merged radeon_span.c.

17 years agor300: Cleaned up function names in r300_texstate.c.
Oliver McFadden [Fri, 11 May 2007 21:45:14 +0000 (21:45 +0000)]
r300: Cleaned up function names in r300_texstate.c.

17 years agor300: Enable hardware 3D texture support. Fixes the stex3d demo.
Oliver McFadden [Fri, 11 May 2007 21:40:00 +0000 (21:40 +0000)]
r300: Enable hardware 3D texture support. Fixes the stex3d demo.

17 years agor300: Corrected a small error from 37cbf38c344012f9d6e938937dac3697b73721a8.
Oliver McFadden [Fri, 11 May 2007 21:36:13 +0000 (21:36 +0000)]
r300: Corrected a small error from 37cbf38c344012f9d6e938937dac3697b73721a8.

17 years agor300: Cleaned up the blend factor function.
Oliver McFadden [Fri, 11 May 2007 21:31:22 +0000 (21:31 +0000)]
r300: Cleaned up the blend factor function.

17 years agor300: Removed the r300BindProgram function; mesa default does better checking.
Oliver McFadden [Fri, 11 May 2007 21:22:37 +0000 (21:22 +0000)]
r300: Removed the r300BindProgram function; mesa default does better checking.

17 years agor300: Removed deprecated/disabled VBO code from r300_mem.c
Oliver McFadden [Fri, 11 May 2007 21:08:56 +0000 (21:08 +0000)]
r300: Removed deprecated/disabled VBO code from r300_mem.c

Also removed a couple of unused fields from the r300_memory_manager structure.

17 years agor300: Indented r300_mem.c; I forgot this because it used to be radeon_mm.c.
Oliver McFadden [Fri, 11 May 2007 20:48:35 +0000 (20:48 +0000)]
r300: Indented r300_mem.c; I forgot this because it used to be radeon_mm.c.

17 years agor300: Use __FUNCTION__ not __func__.
Oliver McFadden [Fri, 11 May 2007 20:09:01 +0000 (20:09 +0000)]
r300: Use __FUNCTION__ not __func__.

Just for consistency; most of the code already uses __FUNCTION__.

17 years agor300: Assert if the primitive type is unknown; this can't really happen.
Oliver McFadden [Fri, 11 May 2007 20:06:43 +0000 (20:06 +0000)]
r300: Assert if the primitive type is unknown; this can't really happen.

17 years agor300: Moved some code around in r300_render.c and general clean up.
Oliver McFadden [Fri, 11 May 2007 19:57:07 +0000 (19:57 +0000)]
r300: Moved some code around in r300_render.c and general clean up.

17 years agouser-declared uniform structs not supported yet (see bug 10908)
Brian [Fri, 11 May 2007 21:35:12 +0000 (15:35 -0600)]
user-declared uniform structs not supported yet (see bug 10908)

17 years agodon't ignore return value of _slang_codegen_global_variable()
Brian [Fri, 11 May 2007 21:34:29 +0000 (15:34 -0600)]
don't ignore return value of _slang_codegen_global_variable()

17 years agoremove some unneeded code in init_machine()
Brian [Fri, 11 May 2007 21:12:40 +0000 (15:12 -0600)]
remove some unneeded code in init_machine()

17 years agor300: Removed some checking in r300NumVerts that is not needed.
Oliver McFadden [Fri, 11 May 2007 19:44:35 +0000 (19:44 +0000)]
r300: Removed some checking in r300NumVerts that is not needed.

According to Aapo Tahkola the OpenGL specification defines the behaviour when
there are not enough vertices for the primitive type, thus DRI drivers do not
need to perform verification on the number of vertices per primitive.

17 years agor300: Function naming correction in r300_texmem.c.
Oliver McFadden [Fri, 11 May 2007 19:28:35 +0000 (19:28 +0000)]
r300: Function naming correction in r300_texmem.c.

17 years agor300: Cleaned up function names in r300_state.c.
Oliver McFadden [Fri, 11 May 2007 19:21:08 +0000 (19:21 +0000)]
r300: Cleaned up function names in r300_state.c.

17 years agor300: Cleaned up function naming in r300_emit.c.
Oliver McFadden [Fri, 11 May 2007 17:10:59 +0000 (17:10 +0000)]
r300: Cleaned up function naming in r300_emit.c.

17 years agor300: Renamed r300_maos.c to r300_emit.c; it contains mostly emit code now.
Oliver McFadden [Fri, 11 May 2007 17:07:09 +0000 (17:07 +0000)]
r300: Renamed r300_maos.c to r300_emit.c; it contains mostly emit code now.

17 years agoRemove unused FB_* tokens, re-indent code.
Brian [Fri, 11 May 2007 14:41:34 +0000 (08:41 -0600)]
Remove unused FB_* tokens, re-indent code.

17 years agoWhen feeding back texcoords, don't divide by W. See bug 10913.
Brian [Fri, 11 May 2007 14:39:18 +0000 (08:39 -0600)]
When feeding back texcoords, don't divide by W.  See bug 10913.

17 years agoFix some bugs related to loop counters and conditional branching.
Patrick Baggett [Fri, 11 May 2007 14:19:33 +0000 (08:19 -0600)]
Fix some bugs related to loop counters and conditional branching.

17 years agomore indentation fixes, remove 'register' keywords
Brian [Thu, 10 May 2007 23:33:14 +0000 (17:33 -0600)]
more indentation fixes, remove 'register' keywords

17 years agore-indent some code
Brian [Thu, 10 May 2007 23:30:44 +0000 (17:30 -0600)]
re-indent some code

17 years agodocument exp(), mod() fixes
Brian [Thu, 10 May 2007 22:14:10 +0000 (16:14 -0600)]
document exp(), mod() fixes

17 years agoregenerated
Brian [Thu, 10 May 2007 20:49:06 +0000 (14:49 -0600)]
regenerated

17 years agoImplement exp() in terms of __asm float_power. Fix typo in mod(vec4) function.
Brian [Thu, 10 May 2007 20:48:55 +0000 (14:48 -0600)]
Implement exp() in terms of __asm float_power. Fix typo in mod(vec4) function.

exp() was using __asm float_exp (OPCODE_EXP) but that computes base two, not e.
See bug 10907.

17 years agoFix reversed enable logic in enable_texture
Ian Romanick [Thu, 10 May 2007 22:00:41 +0000 (15:00 -0700)]
Fix reversed enable logic in enable_texture

Fix bug inserted in commit c9e723e5013443df984cb3987ffa3a9ba3384b89.
Discovered by Oliver McFadden (z3ro).

17 years agor300: Added TODO comment regarding texture tiling; I'm not sure about this.
Oliver McFadden [Thu, 10 May 2007 22:01:41 +0000 (22:01 +0000)]
r300: Added TODO comment regarding texture tiling; I'm not sure about this.

17 years agor300: Corrected a compile error introduced by one of the previous commits.
Oliver McFadden [Thu, 10 May 2007 21:40:20 +0000 (21:40 +0000)]
r300: Corrected a compile error introduced by one of the previous commits.

17 years agor300: Removed obsolete start_index16_packet/start_index32_packet.
Oliver McFadden [Thu, 10 May 2007 21:28:04 +0000 (21:28 +0000)]
r300: Removed obsolete start_index16_packet/start_index32_packet.

It's all in r300_render.c now.

17 years agor300: Moved some more emit code into r300_render.c.
Oliver McFadden [Thu, 10 May 2007 17:50:25 +0000 (17:50 +0000)]
r300: Moved some more emit code into r300_render.c.

17 years agor300: Moved some more of the emit code into r300_render.c.
Oliver McFadden [Thu, 10 May 2007 17:45:27 +0000 (17:45 +0000)]
r300: Moved some more of the emit code into r300_render.c.

17 years agodocument tex sampler bug fix, code changes
Brian [Thu, 10 May 2007 16:52:19 +0000 (10:52 -0600)]
document tex sampler bug fix, code changes

17 years agoReplace `pkg-config --cflags libdrm` with LIBDRM_CFLAGS, remove disabled lines, remov...
Brian [Thu, 10 May 2007 16:51:54 +0000 (10:51 -0600)]
Replace `pkg-config --cflags libdrm` with LIBDRM_CFLAGS, remove disabled lines, remove obsolete comments.

17 years agoConvert "bit" parameters to GLbitfield. Fix cut-and-paste bug in _mesa_IsEnabled
Ian Romanick [Thu, 10 May 2007 15:20:04 +0000 (08:20 -0700)]
Convert "bit" parameters to GLbitfield. Fix cut-and-paste bug in _mesa_IsEnabled

These changes are based on patch review comments from Brian Paul, Alan
Hourihane, and vehemens.

17 years agoRefactor the loop in unbind_texobj_from_texunits.
Ian Romanick [Thu, 10 May 2007 04:51:49 +0000 (21:51 -0700)]
Refactor the loop in unbind_texobj_from_texunits.

Common code was pulled out of the per-target if-statment and put at the end
of the for-loop.  The common code is guarded by a new variable, curr, that
is set to point to the unit's current target in each if-statement.

17 years agoRefactor queries of GL_(SOURCE|OPERAND)[012]_(ALPHA|RGB).
Ian Romanick [Thu, 10 May 2007 04:49:35 +0000 (21:49 -0700)]
Refactor queries of GL_(SOURCE|OPERAND)[012]_(ALPHA|RGB).

Most switch-statements that have cases for these enums already use code like:

    const GLuint idx = pname - GL_SOURCE0_RGB;
    ... texUnit->Combine.SourceRGB[idx] ...

This patch just brings the remaining bits up to speed.