--- mesa-7.8.2.orig/autogen.sh +++ mesa-7.8.2/autogen.sh @@ -0,0 +1,18 @@ +#! /bin/sh + +srcdir=`dirname "$0"` +test -z "$srcdir" && srcdir=. + +SRCDIR=`(cd "$srcdir" && pwd)` +ORIGDIR=`pwd` + +if test "x$SRCDIR" != "x$ORIGDIR"; then + echo "Mesa cannot be built when srcdir != builddir" 1>&2 + exit 1 +fi + +MAKEFLAGS="" + +autoreconf -v --install || exit 1 + +"$srcdir"/configure "$@" --- mesa-7.8.2.orig/SConstruct +++ mesa-7.8.2/SConstruct @@ -0,0 +1,238 @@ +####################################################################### +# Top-level SConstruct +# +# For example, invoke scons as +# +# scons debug=1 dri=0 machine=x86 +# +# to set configuration variables. Or you can write those options to a file +# named config.py: +# +# # config.py +# debug=1 +# dri=0 +# machine='x86' +# +# Invoke +# +# scons -h +# +# to get the full list of options. See scons manpage for more info. +# + +import os +import os.path +import sys +import SCons.Util + +import common + +####################################################################### +# Configuration options + +default_statetrackers = 'mesa' + +if common.default_platform in ('linux', 'freebsd', 'darwin'): + default_drivers = 'softpipe,failover,svga,i915,i965,trace,identity,llvmpipe' + default_winsys = 'xlib' +elif common.default_platform in ('winddk',): + default_drivers = 'softpipe,svga,i915,i965,trace,identity' + default_winsys = 'all' +elif common.default_platform in ('embedded',): + default_drivers = 'softpipe,llvmpipe' + default_winsys = 'xlib' +else: + default_drivers = 'all' + default_winsys = 'all' + +opts = Variables('config.py') +common.AddOptions(opts) +opts.Add(ListVariable('statetrackers', 'state trackers to build', default_statetrackers, + ['mesa', 'python', 'xorg'])) +opts.Add(ListVariable('drivers', 'pipe drivers to build', default_drivers, + ['softpipe', 'failover', 'svga', 'i915', 'i965', 'trace', 'r300', 'identity', 'llvmpipe'])) +opts.Add(ListVariable('winsys', 'winsys drivers to build', default_winsys, + ['xlib', 'vmware', 'intel', 'i965', 'gdi', 'radeon'])) + +opts.Add(EnumVariable('MSVS_VERSION', 'MS Visual C++ version', None, allowed_values=('7.1', '8.0', '9.0'))) + +env = Environment( + options = opts, + tools = ['gallium'], + toolpath = ['#scons'], + ENV = os.environ, +) + +if os.environ.has_key('CC'): + env['CC'] = os.environ['CC'] +if os.environ.has_key('CFLAGS'): + env['CCFLAGS'] += SCons.Util.CLVar(os.environ['CFLAGS']) +if os.environ.has_key('CXX'): + env['CXX'] = os.environ['CXX'] +if os.environ.has_key('CXXFLAGS'): + env['CXXFLAGS'] += SCons.Util.CLVar(os.environ['CXXFLAGS']) +if os.environ.has_key('LDFLAGS'): + env['LINKFLAGS'] += SCons.Util.CLVar(os.environ['LDFLAGS']) + +Help(opts.GenerateHelpText(env)) + +# replicate options values in local variables +debug = env['debug'] +dri = env['dri'] +machine = env['machine'] +platform = env['platform'] +drawllvm = 'llvmpipe' in env['drivers'] + +# LLVM support in the Draw module +if drawllvm: + env.Tool('llvm') + if not env.has_key('LLVM_VERSION'): + drawllvm = False + +# derived options +x86 = machine == 'x86' +ppc = machine == 'ppc' +gcc = platform in ('linux', 'freebsd', 'darwin', 'embedded') +msvc = platform in ('windows', 'winddk') + +Export([ + 'debug', + 'x86', + 'ppc', + 'dri', + 'drawllvm', + 'platform', + 'gcc', + 'msvc', +]) + + +####################################################################### +# Environment setup + +# Always build trace driver +if 'trace' not in env['drivers']: + env['drivers'].append('trace') + +# Includes +env.Append(CPPPATH = [ + '#/include', + '#/src/gallium/include', + '#/src/gallium/auxiliary', + '#/src/gallium/drivers', +]) + +if env['msvc']: + env.Append(CPPPATH = ['#include/c99']) + +# Embedded +if platform == 'embedded': + env.Append(CPPDEFINES = [ + '_POSIX_SOURCE', + ('_POSIX_C_SOURCE', '199309L'), + '_SVID_SOURCE', + '_BSD_SOURCE', + '_GNU_SOURCE', + + 'PTHREADS', + ]) + env.Append(LIBS = [ + 'm', + 'pthread', + 'dl', + ]) + +# Posix +if platform in ('posix', 'linux', 'freebsd', 'darwin'): + env.Append(CPPDEFINES = [ + '_POSIX_SOURCE', + ('_POSIX_C_SOURCE', '199309L'), + '_SVID_SOURCE', + '_BSD_SOURCE', + '_GNU_SOURCE', + + 'PTHREADS', + 'HAVE_POSIX_MEMALIGN', + ]) + if platform == 'darwin': + env.Append(CPPDEFINES = ['_DARWIN_C_SOURCE']) + env.Append(CPPPATH = ['/usr/X11R6/include']) + env.Append(LIBPATH = ['/usr/X11R6/lib']) + env.Append(LIBS = [ + 'm', + 'pthread', + 'expat', + 'dl', + ]) + +# DRI +if dri: + env.ParseConfig('pkg-config --cflags --libs libdrm') + env.Append(CPPDEFINES = [ + ('USE_EXTERNAL_DXTN_LIB', '1'), + 'IN_DRI_DRIVER', + 'GLX_DIRECT_RENDERING', + 'GLX_INDIRECT_RENDERING', + ]) + +# LLVM support in the Draw module +if drawllvm: + env.Append(CPPDEFINES = ['DRAW_LLVM']) + +# libGL +if platform in ('linux', 'freebsd', 'darwin'): + env.Append(LIBS = [ + 'X11', + 'Xext', + 'Xxf86vm', + 'Xdamage', + 'Xfixes', + ]) + +# for debugging +#print env.Dump() + +Export('env') + + +####################################################################### +# Invoke SConscripts + +# TODO: Build several variants at the same time? +# http://www.scons.org/wiki/SimultaneousVariantBuilds + +if env['platform'] != common.default_platform: + # GLSL code has to be built twice -- one for the host OS, another for the target OS... + + host_env = Environment( + # options are ignored + # default tool is used + tools = ['default', 'custom'], + toolpath = ['#scons'], + ENV = os.environ, + ) + + host_env['platform'] = common.default_platform + host_env['machine'] = common.default_machine + host_env['debug'] = env['debug'] + + SConscript( + 'src/glsl/SConscript', + variant_dir = os.path.join(env['build'], 'host'), + duplicate = 0, # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html + exports={'env':host_env}, + ) + +SConscript( + 'src/SConscript', + variant_dir = env['build'], + duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html +) + +env.Default('src') + +SConscript( + 'progs/SConscript', + variant_dir = os.path.join('progs', env['build']), + duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html +) --- mesa-7.8.2.orig/common.py +++ mesa-7.8.2/common.py @@ -0,0 +1,66 @@ +####################################################################### +# Common SCons code + +import os +import os.path +import sys +import platform as _platform + + +####################################################################### +# Defaults + +_platform_map = { + 'linux2': 'linux', + 'win32': 'windows', +} + +default_platform = sys.platform +default_platform = _platform_map.get(default_platform, default_platform) + +_machine_map = { + 'x86': 'x86', + 'i386': 'x86', + 'i486': 'x86', + 'i586': 'x86', + 'i686': 'x86', + 'ppc' : 'ppc', + 'x86_64': 'x86_64', +} +if 'PROCESSOR_ARCHITECTURE' in os.environ: + default_machine = os.environ['PROCESSOR_ARCHITECTURE'] +else: + default_machine = _platform.machine() +default_machine = _machine_map.get(default_machine, 'generic') + +if default_platform in ('linux', 'freebsd'): + default_dri = 'yes' +elif default_platform in ('winddk', 'windows', 'wince', 'darwin'): + default_dri = 'no' +else: + default_dri = 'no' + + +####################################################################### +# Common options + +def AddOptions(opts): + try: + from SCons.Variables.BoolVariable import BoolVariable as BoolOption + except ImportError: + from SCons.Options.BoolOption import BoolOption + try: + from SCons.Variables.EnumVariable import EnumVariable as EnumOption + except ImportError: + from SCons.Options.EnumOption import EnumOption + opts.Add(BoolOption('debug', 'debug build', 'no')) + opts.Add(BoolOption('profile', 'profile build', 'no')) + opts.Add(BoolOption('quiet', 'quiet command lines', 'yes')) + opts.Add(EnumOption('machine', 'use machine-specific assembly code', default_machine, + allowed_values=('generic', 'ppc', 'x86', 'x86_64'))) + opts.Add(EnumOption('platform', 'target platform', default_platform, + allowed_values=('linux', 'cell', 'windows', 'winddk', 'wince', 'darwin', 'embedded'))) + opts.Add(EnumOption('toolchain', 'compiler toolchain', 'default', + allowed_values=('default', 'crossmingw', 'winsdk', 'winddk'))) + opts.Add(BoolOption('llvm', 'use LLVM', 'no')) + opts.Add(BoolOption('dri', 'build DRI drivers', default_dri)) --- mesa-7.8.2.orig/Makefile +++ mesa-7.8.2/Makefile @@ -285,9 +285,6 @@ $(DIRECTORY)/src/mesa/x86-64/*.[chS] \ $(DIRECTORY)/src/mesa/x86-64/Makefile \ $(DIRECTORY)/progs/Makefile \ - $(DIRECTORY)/progs/util/README \ - $(DIRECTORY)/progs/util/*.[ch] \ - $(DIRECTORY)/progs/util/sampleMakefile \ $(DIRECTORY)/windows/VC8/ ES_FILES = \ @@ -438,7 +435,10 @@ $(DIRECTORY)/progs/glsl/*.c \ $(DIRECTORY)/progs/glsl/*.frag \ $(DIRECTORY)/progs/glsl/*.vert \ - $(DIRECTORY)/progs/glsl/*.shtest + $(DIRECTORY)/progs/glsl/*.shtest \ + $(DIRECTORY)/progs/util/README \ + $(DIRECTORY)/progs/util/*.[ch] \ + $(DIRECTORY)/progs/util/sampleMakefile GLUT_FILES = \ $(DIRECTORY)/include/GL/glut.h \ --- mesa-7.8.2.orig/configure.ac +++ mesa-7.8.2/configure.ac @@ -398,6 +398,7 @@ dnl has it in libc), or if libdl is needed to get it. AC_CHECK_FUNC([dlopen], [], [AC_CHECK_LIB([dl], [dlopen], [DLOPEN_LIBS="-ldl"])]) +AC_SUBST([DLOPEN_LIBS]) dnl See if posix_memalign is available AC_CHECK_FUNC([posix_memalign], [DEFINES="$DEFINES -DHAVE_POSIX_MEMALIGN"]) @@ -699,7 +700,7 @@ dnl Direct rendering or just indirect rendering AC_ARG_ENABLE([driglx-direct], [AS_HELP_STRING([--disable-driglx-direct], - [enable direct rendering in GLX for DRI @<:@default=enabled@:>@])], + [enable direct rendering in GLX and EGL for DRI @<:@default=enabled@:>@])], [driglx_direct="$enableval"], [driglx_direct="yes"]) dnl Which drivers to build - default is chosen by platform @@ -1102,10 +1103,6 @@ if test "x$enable_glut" = xyes; then SRC_DIRS="$SRC_DIRS glut/glx" - GLUT_CFLAGS="" - if test "x$GCC" = xyes; then - GLUT_CFLAGS="-fexceptions" - fi if test "$x11_pkgconfig" = yes; then PKG_CHECK_MODULES([GLUT],[x11 xmu xi]) GLUT_PC_REQ_PRIV="x11 xmu xi" @@ -1116,6 +1113,9 @@ GLUT_PC_LIB_PRIV="$GLUT_LIB_DEPS" GLUT_PC_CFLAGS="$X11_INCLUDES" fi + if test "x$GCC" = xyes; then + GLUT_CFLAGS="$GLUT_CFLAGS -fexceptions" + fi GLUT_LIB_DEPS="$GLUT_LIB_DEPS -lm" GLUT_PC_LIB_PRIV="$GLUT_PC_LIB_PRIV -lm" @@ -1217,6 +1217,10 @@ if test "x$enable_egl" != xyes; then AC_MSG_ERROR([cannot build egl state tracker without EGL library]) fi + # define GLX_DIRECT_RENDERING even when the driver is not dri + if test "x$mesa_driver" != xdri -a "x$driglx_direct" = xyes; then + DEFINES="$DEFINES -DGLX_DIRECT_RENDERING" + fi ;; xorg) PKG_CHECK_MODULES([LIBDRM_XORG], [libdrm >= $LIBDRM_XORG_REQUIRED]) --- mesa-7.8.2.orig/.emacs-dirvars +++ mesa-7.8.2/.emacs-dirvars @@ -0,0 +1,10 @@ +;; -*- emacs-lisp -*- +;; +;; This file is processed by the dirvars emacs package. Each variable +;; setting below is performed when this dirvars file is loaded. +;; +indent-tabs-mode: nil +tab-width: 8 +c-basic-offset: 3 +kde-emacs-after-parent-string: "" +evaluate: (c-set-offset 'inline-open '0) --- mesa-7.8.2.orig/bin/confdiff.sh +++ mesa-7.8.2/bin/confdiff.sh @@ -0,0 +1,48 @@ +#!/bin/bash -e + +usage() +{ + echo "Usage: $0 " + echo "Highlight differences between Mesa configs" + echo "Example:" + echo " $0 linux linux-x86" +} + +die() +{ + echo "$@" >&2 + return 1 +} + +case "$1" in +-h|--help) usage; exit 0;; +esac + +[ $# -lt 2 ] && die 2 targets needed. See $0 --help +target1=$1 +target2=$2 + +topdir=$(cd "`dirname $0`"/..; pwd) +cd "$topdir" + +[ -f "./configs/$target1" ] || die Missing configs/$target1 +[ -f "./configs/$target2" ] || die Missing configs/$target2 + +trap 'rm -f "$t1" "$t2"' 0 + +t1=$(mktemp) +t2=$(mktemp) + +make -f- -n -p < $t1 +TOP = . +include \$(TOP)/configs/$target1 +default: +EOF + +make -f- -n -p < $t2 +TOP = . +include \$(TOP)/configs/$target2 +default: +EOF + +diff -pu -I'^#' $t1 $t2 --- mesa-7.8.2.orig/bin/installmesa +++ mesa-7.8.2/bin/installmesa @@ -0,0 +1,74 @@ +#!/bin/sh + +# +# Simple shell script for installing Mesa's header and library files. +# If the copy commands below don't work on a particular system (i.e. the +# -f or -d flags), we may need to branch on `uname` to do the right thing. +# + + +TOP=. + +INCLUDE_DIR="/usr/local/include" +LIB_DIR="/usr/local/lib" + +if [ "x$#" = "x0" ] ; then +echo +echo "***** Mesa installation - You may need root privileges to do this *****" +echo +echo "Default directory for header files is:" ${INCLUDE_DIR} +echo "Enter new directory or press to accept this default." + +read INPUT +if [ "x${INPUT}" != "x" ] ; then + INCLUDE_DIR=${INPUT} +fi + +echo +echo "Default directory for library files is:" ${LIB_DIR} +echo "Enter new directory or press to accept this default." + +read INPUT +if [ "x${INPUT}" != "x" ] ; then + LIB_DIR=${INPUT} +fi + +echo +echo "About to install Mesa header files (GL/*.h) in: " ${INCLUDE_DIR}/GL +echo "and Mesa library files (libGL.*, etc) in: " ${LIB_DIR} +echo "Press to continue, or -C to abort." + +read INPUT + +else +INCLUDE_DIR=$1/include +LIB_DIR=$1/lib +fi + +# flags: +# -f = force +# -d = preserve symlinks (does not work on BSD) + +if [ `uname` = "FreeBSD" ] ; then + CP_FLAGS="-f" +elif [ `uname` = "Darwin" ] ; then + CP_FLAGS="-f" +elif [ `uname` = "AIX" ] ; then + CP_FLAGS="-fh" +else + CP_FLAGS="-fd" +fi + + +set -v + +mkdir -p ${INCLUDE_DIR} +mkdir -p ${INCLUDE_DIR}/GL +# NOT YET: mkdir -p ${INCLUDE_DIR}/GLES +mkdir -p ${LIB_DIR} +cp -f ${TOP}/include/GL/*.h ${INCLUDE_DIR}/GL +cp -f ${TOP}/src/glw/*.h ${INCLUDE_DIR}/GL +# NOT YET: cp -f ${TOP}/include/GLES/*.h ${INCLUDE_DIR}/GLES +cp ${CP_FLAGS} ${TOP}/lib*/lib* ${LIB_DIR} + +echo "Done." --- mesa-7.8.2.orig/configs/autoconf.in +++ mesa-7.8.2/configs/autoconf.in @@ -26,6 +26,11 @@ INTEL_CFLAGS = @INTEL_CFLAGS@ X11_LIBS = @X11_LIBS@ X11_CFLAGS = @X11_CFLAGS@ +GLW_CFLAGS = @GLW_CFLAGS@ +GLUT_CFLAGS = @GLUT_CFLAGS@ + +# dlopen +DLOPEN_LIBS = @DLOPEN_LIBS@ # Assembler MESA_ASM_SOURCES = @MESA_ASM_SOURCES@ --- mesa-7.8.2.orig/configs/default +++ mesa-7.8.2/configs/default @@ -121,6 +121,8 @@ APP_LIB_DEPS = -lm X11_LIBS = -lX11 +DLOPEN_LIBS = -ldl + # Installation directories (for make install) INSTALL_DIR = /usr/local INSTALL_LIB_DIR = $(INSTALL_DIR)/$(LIB_DIR) --- mesa-7.8.2.orig/docs/VERSIONS +++ mesa-7.8.2/docs/VERSIONS @@ -0,0 +1,1514 @@ + + +Mesa Version History +==================== + +1.0 beta February 1995 + Initial release + +1.1 beta March 4, 1995 + Changes: + faster point and line drawing (2x faster) + more systems supported, better Makefiles + Renamed lib*.a files to avoid collisions + many small bug fixes + New: + pseudo-GLX functions added + new implementation of evaluators (eval2.c) + GLUT support + +1.1.1 beta March 7, 1995 + Changes: + Reverted from eval2.c to eval.c due to FPE on Linux + more speed improvements + more Makefile changes + +1.1.2 beta March 14, 1995 + New: + implementation of SGI's blending extensions + glXUseXFont implemented + added MESA_DEBUG environment variable support + Changes: + Using eval2.c again + more FPE-prevention checks (0-length normals are OK) + a few small bug fixes + much faster pixel logic ops! + faster transformation arithmetic + +1.1.3 beta March 31, 1995 + New: + gluScaleImage() and gluBuild2DMipMaps() implemented + Mesa widgets for Xt/Motif + blendEXT demos + added environment variables for selecting visuals + Changes: + almost all GLUT demos work correctly now + faster X device driver functions + more bug fixes + +1.1.4 beta April 20, 1995 + Bug fixes: + - missing #define SEEK_SET in src-tk/image.c + - compile glShadeModel into display lists + - fixed pow() domain error in src/light.c + - fixed "flickering bitmaps" in double buffer mode + - fixed tk.h and aux.h for C++ + - state of LIGHT_MODEL_LOCAL_VIEWER was inverted + New features: + - MUCH, MUCH nicer dithering in 8-bit RGB mode + - updated widgets and widget demos + - Implemented GLXPixmap functions + - Added GLU 1.1 and GLX 1.1 functions + - Changed the X/Mesa interface API, more versatile + - Implemented gluPartialDisk() + +1.2 May 22, 1995 + Bug fixes: + - IRIX 4.x makefile problem + - modified tk to share root colormap as needed + - gluLookAt normalization problem + - suppress Expose, NoExpose events in swapbuffers + - glBitmap() and glDrawPixels() clipping + New features: + - GL_BLEND, GL_MODULATE, GL_DECAL, and GL_REPLACE_EXT texture + modes implemented + - texture maps stored more efficiently + - texture maps can be compiled into display lists + - Bogdan Sikorski's GLU polygon tesselation code + - Linas Vepstas's sweep and extrusion library + - glXCreateContext()'s shareList parameter works as it's supposed to. + XMesaCreateContext() updated to accept a shareList parameter too. + - Mesa can be compiled with real OpenGL .h files + - MESA_BACK_BUFFER environment variable + - better GLX error checking + +1.2.1 June 22, 1995 + Bug fixes: + - X/Mesa double buffer window resize crash + - widgets now pass PointerMotion events + - X/Mesa incorrect default clear color and drawing color + - more robust X MIT-SHM support in X/Mesa + - glTexImage( format=GL_LUMINANCE ) didn't work + - GL_LINE mode polygons with line width > 1.0 could cause a crash + - numerous feedback bugs + - glReadPixels() from depth buffer was wrong + - error prone depth and stencil buffer allocation + New features: + - Preliminary Microsoft Windows driver + - Implemented a number of missing functions: glEvalCoord[12][df]v(), + glGet...(), etc. + - Added a few missing symbols to gl.h and glu.h + - Faster rendering of smooth-shaded, RGBA, depth-buffered polygons. + - Faster rendering of lines when width=2.0 + - Stencil-related functions now work in display lists + Changes: + - renamed aux.h as glaux.h (MS-DOS names can't start with aux) + - most filenames are in 8.3 format to accomodate MS-DOS + - use GLubytes to store arrays of colors instead of GLints + +1.2.2 August 2, 1995 + New features: + - texture mapped points and lines + - NURBS! (but not 100% complete) + - viewports may safely extend beyond window boundaries + - MESA_PRIVATE_CMAP environment variable + - Grayscale X display support + - two new demos: demos/gears.c and demos/shadow.c + - MachTen for Macintosh configuration + Bug fixes: + - glGet*(GL_DEPTH_BITS) returned bytes, not bits + - point, line, and bitmap rasterization suffered from roundoff errors + - fixed a division by zero error in line clippping + - occasional wrong default background color really fixed! + - glDepthFunc(GL_ALWAYS) with glDepthMask(GL_FALSE) didn't work + - gluBuild2DMipmaps malloc problem fixed + - view volume clipping of smooth shaded lines resulted in bad colors + Changes: + - new visual selection method in glXChooseVisual() + - improved GLU quadric functions + - call XSync for glFinish and XFlush for glFlush + - glVertex() calls now use a function pointer to avoid conditionals + - removed contrib directory from Mesa tar file (available on ftp site) + - AIX shared library support + - Removed GLUenum type as it's not in OpenGL + +1.2.3 September 26, 1995 + New features: + - Mesa header files now equivalent to SGI OpenGL headers + - Support for HP's Color Recovery dithering displays + - Faster vertex transformation + - Faster raster operations into X windows under certain conditions + - New configurations: HP w/ shared libs, Ultrix w/ GCC, Data General + - 4-bit visuals now supported + Bug fixes: + - glScissor bug fixed + - round-off errors in clipping lines against clip planes fixed + - byte swapping between hosts and display servers implemented + - glGetError() can be called without a current rendering context + - problem with accidentally culled polygons is fixed + - fixed some widget compilation problems + +1.2.4 November 17, 1995 + New features: + - More speed improvements (lighting, fogging, polygon drawing) + - Window system and OS-independent off-screen rendering + - Preliminary Fortran bindings + - glPolygonOffsetEXT implemented + - glColorMask and glIndexMask now fully implemented + - glPixelZoom implemented + - display lists fully implemented + - gamma correction + - dithering in 8-bit TrueColor/DirectColor visuals + Changes: + - Improved device driver interface + - tk.h renamed to gltk.h to avoid conflicts with Tcl's Tk + - Dithering support moved from core into device driver + Bug fixes: + - glEnable/Disable( GL_LIGHTING ) didn't always take effect + - glReadPixels byte swapping was broken + - glMaterial with pname==GL_AMBIENT_AND_DIFFUSE was broken + - duplicate glColor4b() prototype in GL/gl.h removed + - stripes in wave -ci demo fixed + - GL_LINEAR_MIPMAP_NEAREST had wrong value + - bugs in HP Color Recovery support fixed + - fixed bug when blending lines, points, bitmaps outside of window + +1.2.5 November 30, 1995 + New Features: + - updated MS Windows driver + - new implementation of StaticGray/GrayScale visual support + Bug fixes: + - pixelzooming with gamma correction or blending didn't work + - HP color recovery visual wasn't being picked by glXChooseVisual + - glClear didn't always observe glColorMask changes + - olympic and offset demos didn't compile on some Suns + - texcoord clamping wasn't correct + - a polygon optimization introduced an occasional sampling problem + +1.2.6 January 26, 1996 + New Features: + - faster line and polygon rendering under certain conditions. See + Performance Tips 9 and 10 in README + - profiling + - lighting is a bit faster + - better perspective corrected texture mapping + - Amiga AmiWin (X11) support + - preliminary Linux SVGA driver + Changes: + - now using a 16-bit depth buffer, faster, smaller + - GL_NORMALIZE is disabled by default + Bug fixes: + - projective texture mapping + - fixed a memory leak in the context destroy function + - GL_POLYGON with less than 3 vertices caused a crash + - glGet*() returned wrong result for GL_INDEX_MODE + - reading pixels from an unmapped X window caused a BadMatch error + +1.2.7 March 5, 1996 + New: + - faster lighting + - faster 16-bit TrueColor rendering on Linux + - faster 32-bit TrueColor rendering on Linux, HP, IBM + - non-depth-buffered XImage polygons are faster + - vertex array extension + - software alpha planes + - updated Macintosh driver + - new NeXT driver + - GLU quadric functions generate texture coordinates + - reflect.c demo - reflective, textured surface demo + Changes: + - gamma correction code moved into the X driver for better performance + Bug fixes: + - multiple glClipPlane()'s didn't work reliably + - glPolygonMode() didn't always work + - glCullFace( GL_FRONT_AND_BACK ) didn't work + - texture mapping with gamma correction was buggy + - floating point exceptions in texture coordinate interpolation + - XImage byte swapping didn't always work + - polygon edge flags weren't always used correctly + +1.2.8 May 22, 1996 + New: + - overlay planes on X servers with the SERVER_OVERLAY_VISUALS property + - better monochrome output + - more IRIX 6.x configurations + - more robust RGB mode color allocation + - added MESA_XSYNC environment variable + - GLX_MESA_pixmap_colormap and GLX_EXT_visual_info extensions + - GL_MESA_window_pos extension + - faster glReadPixels/glDrawPixels for GL_DEPTH and GL_UNSIGNED_SHORT + and GL_UNSIGNED_INT + - driver for prototype Cirrus Mondello 3-D board + - updated AmigaDOS driver + - a few small speed optimizations in polygon rendering + Changes: + - internal device driver interface modified to simplify device + driver implementations and to support hardware Z buffers + - several changes to the X/Mesa interface (xmesa.h) + Bug fixes: + - fixed pow(0,0) domain error triggered on some systems + - glStencilClear() in a display list caused an infinite loop + - glRasterPos*() was sometimes off by +/-0.5 in X and Y + - color masking and blending were performed in wrong order + - auxSolidCylinder() sometimes drew a wire-frame cylinder + - fixed file writing bug in osdemo.c + - pixel mapping didn't always work + - the GL_GEQUAL stencil func didn't work + - the GL_INVERT stencil op didn't work + - the stencil write mask didn't work + - glPush/PopAttrib() didn't do enough error checking + - glIsList() didn't always work correctly + +2.0 October 10, 1996 + New: + - Implements OpenGL 1.1 API functions + - all texture filtering modes supported (mipmapping) + - faster texture mapping, see Performance Tip 11 in README + - antialiased RGB points + - X support for line and polygon stippling + - glDrawBuffer( GL_FRONT_AND_BACK ) works + - util/ directory of useful stuff + - demos/texobj demo of texture objects + Changes: + - major internal changes for thread-safeness + - new device driver interface + - MESA_ALPHA env variable removed + - triangle rasterizer replaces polygon rasterizer + Bug fixes: + - glPopAttrib() bug + - glDrawBuffer(GL_NONE) works now + +2.1 December 14, 1996 + New: + - VMS support + - MS-DOS driver + - OpenStep support + - updated, combined Windows 95/NT driver + - implemented glGetLighti() and glGetTexGen*() + - GLX does garbage collection of ancillary buffers + Bug fixes: + - removed unused _EXT constants from gl.h + - fixed polygon offset bugs + - Z coordinates of clipped lines were incorrect + - glEdgeFlag() in display lists didn't always work + - glLight*() in display lists didn't work + - fixed X line stipple bugs (Michael Pichler) + - glXUseXfonts XFreeFont/XFreeFontInfo bug fixed + - fixed a feedback bug + - glTexGen*() now transforms GL_EYE_PLANE by inverse modelview matrix + - polygons were sometimes culled instead of clipped + - triangle rasterizer suffered from float/int overflow exceptions + - fixed FP underflow exception in lighting (specular exponent) + - glEnable/glDisable of GL_EXT_vertex_array enums didn't work + - fixed free(NULL) in GLU tesselator code + - using 24-bit color on some X servers resulted in garbage rendering + - 32-bit per pixel mode for XFree86 now works + - glRotate(a,0,0,0) gave unpredictable results + - GL_LINE_STRIP with > 480 vertices had occasional clipping problems + - 8-bit TrueColor GLXPixmap rendering incorrectly required a colormap + - glMaterial() wasn't ignored when GL_COLOR_MATERIAL was enabled + - glEnable(GL_COLOR_MATERIAL) followed by glColor() didn't work right + - accumulation buffer was limited to positive values + - projective textures didn't work + - selection buffer overflows weren't handled correctly + Changes: + - restored the GL_EXT_polygon_offset extension + - slightly faster RGB dithering + - the SVGA driver works again + - Amiga driver now distributed separately + - NeXT driver updated for Mesa 2.x + +2.2 March 14, 1997 + New: + - better color selection when dithering + - added GL_EXT_texture_object extension + - updated MS-DOS driver for DJGPP + - added openbsd make configuration + - faster dithered flat-shaded triangles + - various compilation problems with Motif widgets fixed + - gl.h, glx.h and glu.h name mangling option + - BeOS driver + - 3D texture mapping extension + - GL_MESA_resize_buffers extension + - morph3d, stex3d and spectex demos + - 3Dfx support + Bug fixes: + - glColorMaterial should finally work right in all respects + - linear interpolation of mipmap levels was incorrectly weighted + - readpix.c didn't compile on Macintosh + - GL_INVERT and related logic ops didn't work right + - glTexImage[12]D() didn't check its parameters consistantly + - fixed a memory leak in glTexImage[12]D() + - kludged around a SunOS 5.x/GCC compiler bug in the feedback code + - glReadPixels aborted instead of normally catching some errors + - a few 1.1 constants were missing or misnamed in gl.h + - glBegin(p); glBegin(q); didn't generate an error + - fixed a memory leak in GLX code + - clipping of concave polygons could cause a core dump + - 1-component alpha texture maps didn't work + - fixed a GLU polygon tesselator bug + - polygons with colinear vertices were sometimes culled + - feedback triangle colors were wrong when using smooth shading + - textures with borders didn't work correctly + - colors returned in feedback mode were wrong when using lighting + - spotlights didn't effect ambient lighting correctly + - gluPartialDisk() had a few bugs + Changes: + - device driver interface expanded to support texture mapping + - faster matrix inversion subroutine + - commented out #include "wmesa_extend.h" from src/wmesa.c + - fixed many compiler warnings in the demo programs + +2.3 June 30, 1997 + New: + - Mesa distribution divided into two pieces: library code and demos + - faster vertex transformation, clip testing, lighting + - faster line drawing + - TrueColor visuals how have dithering (for depths < 24 bits) + - added MESA_NO_DITHER environment variable + - new device driver function: NearFar(), RenderVB(), RasterSetup() + - added LynxOS configuration + - added cygnus Win32 configuration + - added texcyl.c GLUT demo + - added XMesaDitherColor() to X/Mesa interface + - new NURBS code from Bogdan Sikorski + - added demos/shape.c (non-rectangular X window!) + Bug fixes: + - glEnable/DisableClientState() were missing from GL/gl.h + - GL_SPHERE_MAP texcoord generation didn't work correctly + - glXGetConfig() returned wrong number of depth, stencil, accum bits + - glDrawPixels feedback/selection didn't examine RasterPos valid bit + - black and white were reversed on some monochrome displays + - fixed potential image memory leak (wasn't setting reference counter) + - glDrawPixels sometimes didn't recognize some GL state changes + - gluProject/UnProject() didn't check for divide by zero + - stex3d demo called random() and srandom(), not portable + - fixed memory leaks in context.c and drawpix.c + - fixed NULL dereferencing problem in gl_update_texture_state() + - glReadPixels between glBegin/glEnd didn't generate an error. + - fixed memory leak in polygon tesselator (Randy Frank) + - fixed seg fault bug drawing flat-shaded, depth-tested lines + - clipped GL_TRIANGLE_STRIPs sometimes had wrong color when flat-shaded + - glBindTexture sometimes didn't work + - fixed a bug deep in glXReleaseBuffersMESA() + - fog was mistakenly applied to alpha + - glPopMatrix didn't set "dirty matrix" flag + - glPolygonStipple pattern was sometimes wrong + - glClear wasn't disabled during feedback and selection + - fixed memory leak in glTexSubImage[123]D + Changes: + - many library source files reorganized + - faster X color allocation, colors also freed when finished with them + - new texture sampling function pointer in texture objects + - incorporated 3Dfx VooDoo driver v0.16 into main source tree + - many 3Dfx driver updates + - cygnus Makefiles now included + - updated DOS driver + - made a few changes to dosmesa.c and wmesa.c (VB->Unclipped) + - internally, colors now stored in GLubytes, not GLfixed + - optimized changing of GL_SHININESS parameter + +2.4 September 18, 1997 + New: + - updated 3Dfx Glide driver + - hacks for 3Dfx rendering into an X window or fullscreen + - added depth buffer access functions to X/Mesa and OS/Mesa interfaces + Bug fixes: + - pixel buffer could overflow with long, wide lines + - fixed FP underflow problems in lighting + - glTexSubImage1D() had an unitialized variable + - incomplete texture objects could cause a segfault + - glDrawPixels with GL_COMPILE_AND_EXECUTE caused infinite loop + - flat-shaded quads in a strip were miscolored if clipped + - mipmapped triangle lod computation now works correctly + - fixed a few under/overflow bugs in triangle rasterizer + - glArrayElement() assigned bad normal if normal array disabled + - changed argument to glXReleaseBuffersMESA() + - fixed small triangle underflow bugs in tritemp.h (hopefully) + - glBindTexture(target, 0) caused a crash + - glTexImage[123]D() with NULL image pointer caused crash + - glPixelStore parameters are now ignored during display list execution + - fixed a two-sided lighting w/ clipping bug (black vertices) + - textures with width!=height were sometimes mis-rendered + - "weird" projection matrices could cause div by 0, other fp errors + Changes: + - changed precompiled header symbol from PCH to PC_HEADER + - split api.c into api1.c and api2.c + - added hash.c source file (but not used yet) + - a few Sun and HP configuration file changes + - MESA_GLX_FX env var replaces MESA_FX_WINDOW and MESA_FX_FULLSCREEN + - fixed a few cygnus build problems (src/Makefile.cygnus, src/wmesa.c) + +2.5 November 20, 1997 + New: + - updated 3Dfx driver (v20) for GLQuake + - added GL_EXT_paletted_texture extension + - added GL_EXT_shared_texture_palette extension + - added GL_EXT_point_parameters extension + - now including Mark Kilgard's GLUT library v3.6 + - new GLUT-based demos in gdemos/ + - added a few more Unix config targets + - added Intel X86 assembly language vertex transformation code + - 3Dfx/Glide driver for Mesa now recognizes SST_SCREENREFRESH env var + - Windows 95 S3 Virge driver + Bug fixes: + - glCopyTexImage?D would crash due to uninitialized variable + - glColor w/ glColorMaterial in a display list caused a bug + - fixed several glDrawPixels() and ReadPixels() bugs in 3Dfx driver + - glVertex4*() vertices weren't always projected correctly + - trying to use mipmapped textured points or lines caused crash + - glColor[34][fd]() values now clamped to [0,1] before int conversion + Changes: + - new device driver functions for texture mapping + - hash tables used for display list and texture object lookup + - fixed GLX visual handling code to avoid saving redundant visuals + - 3Dfx Glide libraries automatically linked to libMesaGL.so + - dropped the Cirrus Logic Mondello code since it's obsolete + - updated Cygnus Makefiles (Stephane Rehel) + - updated Windows MSVC++ Makefiles (Oleg Letsinsky) + - procedure for making library files has changed: scripts now take + a major and minor version arguments. Make-config changed a lot. + - new implementation of glTexSubImage2D() + - updated widgets-mesa directory to create libMesaGLwM.a (Motif widget) + - separate linux-glide and linux-386-glide configurations + +2.6 February 12, 1998 + New: + - Windows WGL functions + - updated VMS, DOS, Windows, Cygnus, BeOS, Amiga compilation support + - v0.22 of 3Dfx Glide driver + - more X86 assembly language optimizations + - faster blending for some modes + - XMesaSetFXmode() to switch between 3Dfx window and full-screen mode + - added preliminary thread support + - added GLX_MESA_copy_sub_buffer extension + - some clipping optimizations + Bug fixes: + - fixed shading/material bug when drawing long primitive strips + - fixed clipping problem in long primitive strips + - fixed clipping bug when using 3Dfx driver + - fixed a problem when trying to use X fonts w/ 3Dfx driver + - fixed a texture filter bug in 3Dfx/Glide driver + - fixed bug in 3Dfx/Glide driver involving depth mask & clearing + - glLoadMatrix to set projection matrix confused the 3Dfx driver + - non-identity texture matrices didn't work with linux-386 configs + - glGenTextures() didn't reserve the returned texture IDs + - NULL proxy image sent to glTexImageXD() caused crash + - added texture state validation optimization (Henk Kok) + - fixed colormap reuse problem when using both RGB and CI windows + - 32bpp True/DirectColor X visuals weren't recognized + - fixed potential problem in evaluators memory allocation + - fixed assorted demo compilation bugs + Changes: + - replaced old Mesa/windows/ directory with Mesa/WIN32/ directory + - converted a few old glaux/gltk demos to GLUT + - renamed directories: demos -> xdemos, gdemos -> demos + + +3.0 September 17, 1998 + New: + - OpenGL 1.2 API + - GL_EXT_abgr pixel format extension + - GL_SGIS_texture_edge_clamp extension + - GL_SGIS_multitexture extension (to be replaced by GL_ARB_multitex) + - GL_EXT_multitexture extension (to be replaced by GL_ARB_multitex) + - GL_EXT_rescale_normal extension and renormal.c demo + - GLX_SGI_video_sync extension (a no-op) + - antialiased lines + - glGetTexImage() now implemented + - glDraw/Copy/ReadPixels() optimizations + - optimized textured triangle code (Marten Stromberg) + - more optimization of dithered TrueColor triangles in X driver + - Linux GGI driver + - updated MGL driver + Bug fixes: + - lots of assorted compilation fixes + - glInitNames didn't write initial hit record + - glBitmap didn't always check for invalid raster position + - switching between GLX and OSMesa contexts caused a crash + - fixed uninitialized variable in Mesa widget code + - fixed typo in texture code which caused book/texgen to crash + - fixed texture sampling bug when filter=GL_LINEAR and wrap=GL_CLAMP + - gluDisk() in POINT or LINE mode sometimes failed + - fixed texture + fog bug + - GL_COMPILE_AND_EXECUTE mode didn't work reliably + - glMultMatrix in projection matrix mode w/ 3Dfx driver could fail + - glDrawPixels(color index pixels) weren't converted to RGBA + - fixed possible getenv() buffer overflow security bug + - glBitmap in feedback mode was offset by xOrig, yOrig params + - device driver's DrawPixels hook was never used + - glDrawPixels with zoomY!=1 and top/bottom clipping didn't work + - glDrawPixels optimized for GL_LUMINANCE, GL_LUMINANCE_ALPHA, GLubyte + - fixed MakeCurrent bug in GLwRedrawObjects() in MesaWorkstation.c + - glCopyTexSubImage2D() didn't work with 3Dfx driver + - lines with width = 2 could cause crash + - glClear with scissor rect sometimes cleared whole buffer + - glTexSubImage2D( .. GL_COLOR_INDEX .. ) didn't work + - glTexImageXD( .. GL_ABGR_EXT .. ) didn't work + - computation of inverse modelview matrix sometimes failed + - fixed GL_CLAMP mode texture sampling bug + - textured line interpolation was somewhat broken + - textured triangle interpolation was also somewhat broken + - glGet(MODELVIEW/PROJECTION/TEXTURE_MATRIX_STACK_DEPTH) off by one + - evaluator state wasn't fully initialized + - texture coordinate clipping was buggy + - evaluator surfaces could be mis-colored + - glAccum(GL_RETURN, s) didn't obey glColorMask() settings + - zero area polygons shouldn't be culled if polygon mode is point/line + - clipped width and height of glReadPixels was sometimes off by one + - blending with alpha = 0 or 1.0 wasn't always exact + - reading of pixels from clipped region was buggy + - minor tweaking of X visual management in GLX emulator + - glPolygonStipple now obeys pixel unpacking parameters + - glGetPolygonStipple now obeys pixel packing parameters + - interleaved vertex array texture coordinates were broken + - query of proxy texture internal format was broken + - alpha channel wasn't reliably cleared + - fixed divide by zero error in gluScaleImage if dest size = 1 x 1 + Conformance bug fixes: + - GL_SELECTION_BUFFER_POINTER and GL_SELECTION_BUFFER_SIZE were missing + - GL_TEXTURE_INTERNAL_FORMAT was missing + - glGet*(GL_POLYGON_STIPPLE) was broken + - glPush/PopAttrib() didn't save/restore all texture state + - glBitmap in feedback mode didn't work + - feedback of texture coords didn't always work + - glDrawPixels w/ format=GL_DEPTH_COMPONENT, type=GLbyte was broke + - glDrawPixels w/ format=GL_DEPTH_COMPONENT, type=GLubyte was broke + - glDrawPixels w/ format=GL_STENCIL_INDEX, type=GL_BITMAP was broke + Changes: + - upgraded GLUT to version 3.7 + - only GL and GLU library code included in MesaLib.tar.gz + - GLUT and all demos now in MesaDemos.tar.gz + - glaux and gltk libraries removed + - IRIX -n32 and -64 libs go in lib32/ and lib64/ directories + + +3.1 beta 1 November 19, 1998 + New: + - GL_EXT_stencil_wrap extension + - GL_INGR_blend_func_separate extension + - GL_ARB_multitexture extension + - GL_NV_texgen_reflection extension + - newly optimized vertex transformation code + - updated GLUT 3.7 code + - better precision when using 32-bit Z buffer + - Allegro DJGPP driver + Bug fixes: + - glCopyPixels between front/back buffers didn't copy alpha correctly + - fixed out-of-bounds memory access in optimized 2-D texture code + - glPixelStorei didn't accept GL_PACK/UNPACK_IMAGE_HEIGHT parameter + - glGet*() didn't accept GL_MAX_3D_TEXTURE_SIZE parameter + - clipping of texture coordinates sometimes had bad R,Q values + - GL_CLAMP_TO_EDGE texture sampling was off by 0.5 texels + - glEdgeFlagPointer() now takes a GLvoid * instead of GLboolean * + - texture was sometimes applied twice with 3Dfx driver + - glPush/PopAttrib() fouled up texture object reference counts + - glDeleteLists(0, n) caused assertion failure + - bilinear texture sampling wasn't accurate enough + - glClear w/ glDepthMask(GL_FALSE) didn't work right on 3Dfx + - color components were reversed on big endian 32 bpp X visuals + Changes: + - removed GL_EXT_multitexture extension + + +3.1 beta 2 May 24, 1999 + New: + - multi-textured points and lines (mjk@nvidia.com) + - optimized 24bpp X rendering (bernd.paysan@gmx.de) + - added allegro support (bernie-t@geocities.com) + - cleaned-up Windows-related stuff (Ted Jump) + - minor stereo changes (KendallB@scitechsoft.com) + - new BeOS driver which implements BGLView class + - new Direct3D driver (see src/D3D) + - more efficient filled gluCylinder() function + - utilities: util/showbuffer.[ch] and util/glstate.[ch] + - fixed some IRIX compiler warnings + - added support for building Mesa in XFree86 with + SGI's GLX (kevin@precisioninsight.com) + Bug fixes: + - a variety of Windows/Mesa bug fixes (mjk@nvidia.com) + - packed pixel images weren't unpacked correctly + - patches some win32 files in GLUT (mjk@nvidia.com) + - glTexImage[123]D() didn't accept internalFormat == GL_COLOR_INDEX + - fixed lighting bug in Keith's new shading code + - fixed texture segfault seen in Lament screensaver + - fixed miscellaneous low-memory bugs + - glClear(GL_COLOR_BUFFER_BIT) with RGBA or CI masking was broken + - GL_LINEAR sampling of 3D textures was broken + - fixed SVR4 'cc' compiler macro problem (dawes@xfree86.org) + - added GL_TEXTURE_PRIORITY fix (keithh@netcomuk.co.uk) + - fixed wide point and wide line conformance bugs (brianp) + Changes: + - some device driver changes (see src/dd.h) + - new copyright on core Mesa code + + +3.1 beta 3 September 17, 1999 + New: + - optimized glAccum function + - optimized 24bpp rendering in XMesa driver + - GLU 1.2 polygon tessellator + Bug Fixes: + - glGetTexLevelParameter wasn't fully implemented + - glXUseXFont now handles multi-byte fonts + - glIsEnabled(GL_TEXTURE_2D / 3D) returned wrong result + - alpha channel of blending points, lines was sometimes incorrect + Changes: + - New library names: "libGL" instead of "libMesaGL" + - New library numbering: libGL.so.1.2.310 + - New subdirectories: docs/ and bin/ + - New Makefile-system (autoconf,automake,libtool) + + +3.1 final December 14, 1999 + New: + - added demos/gloss.c + - added xdemos/glxdpyinfo.c + - added GLX_ARB_get_proc_address extension + - rewritten glTexImage code paths (faster, less memory, bug fixes) + Bug Fixes: + - several vertex array bug fixes + - overlapping glCopyPixels with pixel zooming now works + - glXUseXFont() bitmaps were vertically shifted by one pixel + - glCopyPixels with pixel zooming now works + + +3.2 final April 24, 2000 + Bug fixes: + - fixed memcpy bugs in span.c + - fixed missing glEnd problem in demos/tessdemo.c + - fixed bug when clearing 24bpp Ximages + - fixed clipping problem found in Unreal Tournament + - fixed Loki's "ice bug" and "crazy triangles" seen in Heretic2 + - fixed Loki's 3dfx RGB vs BGR bug + - fixed Loki's 3dfx smooth/flat shading bug in SoF + Changes: + - updated docs/README file + - use bcopy() optimizations on FreeBSD + - re-enabled the optimized persp_textured_triangle() function + + +3.2.1 July 19, 2000 + Bug fixes: + - gluBuild2DMipmaps() didn't accept GL_BGRA + - Fixed compile/makefile problems on IRIX + - fixed segfault in 3dfx driver when using GL selection/feedback + - no longer cull very, very tiny triangles + - blending w/ drawbuffer==GL_FRONT_BACK caused segfault (sw rendering) + - fixed Motif detection code in widgets-mesa/configure.in + - glColorMaterial and glMaterial updates to emissive and ambient + didn't always work right + - Specular highlights weren't always in the right place + - clipped GL_LINE mode polygons had interior lines appear + - blend term GL_ONE_MINUS_CONSTANT_ALPHA was broken + - GL_NICEST fog didn't always work with flat shading + - glRect commands in display lists were sometimes miscolored + - Line Z offset didn't always work + - fixed texgen normal vector problem (gloss's teapot) + - numerous GL conformance bugs fixed + Changes: + - glColorMask(false, false, false, false) handled better/faster + - reverted to old GLU polygon tessellator, GLU 1.1 + - updated Win32 build files + + +3.3 July 21, 2000 + New: + - antialiased triangles now implemented + - GL_EXT_texture_env_add texture mode extension + - GLX 1.3 API + - support for separate draw/read buffers (ie GL_SGI_make_current_read) + - thread-safe API dispath + - improved glxinfo program + - demos/texdown program to measure texture download performance + - glext.h header file + - demos/geartrain program + - GL_EXT_texture_lod_bias extension + - demos/lodbias program + - further optimized glRead/DrawPixels for 16-bit TrueColor X visuals + - GLX_EXT_visual_rating extension (a no-op, however) + - GL_HP_occlusion_test extension (for X and OS/Mesa drivers) + - demos/occlude program + - GL_SGIS_pixel_texture and GL_SGIX_pixel_texture extensions + - demos/pixeltex program + - GL_SGI_color_matrix extension + - GL_SGI_color_table extension + - GL_EXT_histogram extension + - GL_ARB_texture_cube_map extension + - added xdemos/glxheads and xdemos/manywin + - demos/texenv.c demo + - GL_EXT_texture_env_combine extension (by Holger Waechtler) + - Xlib driver is now thread-safe (see xdemos/glthreads) + Bug Fixes: + - various GL conformance failures fixed since 3.2.1 + Changes: + - gl.h now uses #defines instead of C enums for all tokens + - glu.h now uses #defines instead of C enums for all tokens + - moved programs from 3Dfx/demos/ into demos/ directory + + +3.4 November 3, 2000 + New: + - optimized glDrawPixels for glPixelZoom(1,-1) + Bug Fixes: + - widgets-mesa/src/*.c files were missing from 3.3 distro + - include/GL/mesa_wgl.h file was missing from 3.3 distro + - fixed some Win32 compile problems + - texture object priorities weren't getting initialized to 1.0 + - glAreTexturesResident return value was wrong when using hardware + - glXUseXFont segfaulted when using 3dfx driver (via MESA_GLX_FX) + - glReadPixels with GLushort packed types was broken + - fixed a few bugs in the GL_EXT_texture_env_combine texture code + - glPush/PopAttrib(GL_ENABLE_BIT) mishandled multi-texture enables + - fixed some typos/bugs in the VB code + - glDrawPixels(GL_COLOR_INDEX) to RGB window didn't work + - optimized glDrawPixels paths weren't being used + - per-fragment fog calculation didn't work without a Z buffer + - improved blending accuracy, fixes Glean blendFunc test failures + - glPixelStore(GL_PACK/UNPACK_SKIP_IMAGES) wasn't handled correctly + - glXGetProcAddressARB() didn't always return the right address + - gluBuild[12]DMipmaps() didn't grok the GL_BGR pixel format + - texture matrix changes weren't always detected (GLUT projtex demo) + - fixed random color problem in vertex fog code + - fixed Glide-related bug that let Quake get a 24-bit Z buffer + Changes: + - finished internal support for compressed textures for DRI + + +3.4.1 February 14, 2001 + New: + - fixed some Linux build problems + - fixed some Windows build problems + - GL_EXT_texture_env_dot3 extension (Gareth Hughes) + Bug fixes: + - added RENDER_START/RENDER_FINISH macros for glCopyTexImage in DRI + - various state-update code changes needed for DRI bugs + - disabled pixel transfer ops in glColorTable commands, not needed + - fixed bugs in glCopyConvolutionFilter1D/2D, glGetConvolutionFilter + - updated sources and fixed compile problems in widgets-mesa/ + - GLX_PBUFFER enum value was wrong in glx.h + - fixed a glColorMaterial lighting bug + - fixed bad args to Read/WriteStencilSpan in h/w stencil clear function + - glXCopySubBufferMESA() Y position was off by one + - Error checking of glTexSubImage3D() was broken (bug 128775) + - glPopAttrib() didn't restore all derived Mesa state correctly + - Better glReadPixels accuracy for 16bpp color - fixes lots of OpenGL + conformance problems at 16bpp. + - clearing depth buffer with scissoring was broken, would segfault + - OSMesaGetDepthBuffer() returned bad bytesPerValue value + - fixed a line clipping bug (reported by Craig McDaniel) + - fixed RGB color over/underflow bug for very tiny triangles + Known problems: + - NURBS or evaluator surfaces inside display lists don't always work + + +3.4.2 May 17, 2001 + Bug fixes: + - deleting the currently bound texture could cause bad problems + - using fog could result in random vertex alpha values + - AA triangle rendering could touch pixels outside right window bound + - fixed byteswapping problem in clear_32bit_ximage() function + - fixed bugs in wglUseFontBitmapsA(), by Frank Warmerdam + - fixed memory leak in glXUseXFont() + - fragment sampling in AA triangle function was off by 1/2 pixel + - Windows: reading pixels from framebuffer didn't always work + - glConvolutionFilter2D could segfault or cause FP exception + - fixed segfaults in FX and X drivers when using tex unit 1 but not 0 + - GL_NAND logicop didn't work right in RGBA mode + - fixed a memory corruption bug in vertex buffer reset code + - clearing the softwara alpha buffer with scissoring was broken + - fixed a few color index mode fog bugs + - fixed some bad assertions in color index mode + - fixed FX line 'stipple' bug #420091 + - fixed stencil buffer clear width/height typo + - fixed GL error glitches in gl[Client]ActiveTextureARB() + - fixed Windows compilation problem in texutil.c + - fixed 1/8-pixel AA triangle sampling error + Changes: + - optimized writing mono-colored pixel spans to X pixmaps + - increased max viewport size to 2048 x 2048 + + +3.5 June 21, 2001 + New: + - internals of Mesa divided into modular pieces (Keith Whitwell) + - 100% OpenGL 1.2 conformance (passes all conformance tests) + - new AA line algorithm + - GL_EXT_convolution extension + - GL_ARB_imaging subset + - OSMesaCreateContextExt() function + - GL_ARB_texture_env_add extension (same as GL_EXT_texture_env_add) + - GL_MAX_TEXTURE_UNITS_ARB now defaults to eight + - GL_EXT_fog_coord extension (Keith Whitwell) + - GL_EXT_secondary_color extension (Keith Whitwell) + - GL_ARB_texture_env_add extension (same as GL_EXT_texture_env_add) + - GL_SGIX_depth_texture extension + - GL_SGIX_shadow and GL_SGIX_shadow_ambient extensions + - demos/shadowtex.c demo of GL_SGIX_depth_texture and GL_SGIX_shadow + - GL_ARB_texture_env_combine extension + - GL_ARB_texture_env_dot3 extension + - GL_ARB_texture_border_clamp (aka GL_SGIS_texture_border_clamp) + - OSMesaCreateContextExt() function + - libOSMesa.so library, contains the OSMesa driver interface + - GL/glxext.h header file for GLX extensions + - somewhat faster software texturing, fogging, depth testing + - all color-index conformance tests now pass (only 8bpp tested) + - SPARC assembly language TCL optimizations (David Miller) + - GL_SGIS_generate_mipmap extension + Bug Fixes: + - fbiRev and tmuRev were unitialized when using Glide3 + - fixed a few color index mode conformance failures; all pass now + - now appling antialiasing coverage to alpha after texturing + - colors weren't getting clamped to [0,1] before color table lookup + - fixed RISC alignment errors caused by COPY_4UBV macro + - drawing wide, flat-shaded lines could cause a segfault + - vertices now snapped to 1/16 pixel to fix rendering of tiny triangles + Changes: + - SGI's Sample Implementation (SI) 1.3 GLU library replaces Mesa GLU + - new libOSMesa.so library, contains the OSMesa driver interface + + +4.0 October 22, 2001 + New: + - Mesa 4.0 implements the OpenGL 1.3 specification + - GL_IBM_rasterpos_clip extension + - GL_EXT_texture_edge_clamp extension (aka GL_SGIS_texture_edge_clamp) + - GL_ARB_texture_mirrored_repeat extension + - WindML UGL driver (Stephane Raimbault) + - added OSMESA_MAX_WIDTH/HEIGHT queries + - attempted compiliation fixes for Solaris 5, 7 and 8 + - updated glext.h and glxext.h files + - updated Windows driver (Karl Schultz) + Bug fixes: + - added some missing GLX 1.3 tokens to include/GL/glx.h + - GL_COLOR_MATRIX changes weren't recognized by teximage functions + - glCopyPixels with scale and bias was broken + - glRasterPos with lighting could segfault + - glDeleteTextures could leave a dangling pointer + - Proxy textures for cube maps didn't work + - fixed a number of 16-bit color channel bugs + - fixed a few minor memory leaks + - GLX context sharing was broken in 3.5 + - fixed state-update bugs in glPopClientAttrib() + - fixed glDrawRangeElements() bug + - fixed a glPush/PopAttrib() bug related to texture binding + - flat-shaded, textured lines were broken + - fixed a dangling pointer problem in the XMesa code (Chris Burghart) + - lighting didn't always produce the correct alpha value + - fixed 3DNow! code to not read past end of arrays (Andrew Lewycky) + + +4.0.1 December 17, 2001 + New: + - better sub-pixel sample positions for AA triangles (Ray Tice) + - slightly faster blending for (GL_ZERO, GL_ONE) and (GL_ONE, GL_ZERO) + Bug fixes: + - added missing break statements in glGet*() for multisample cases + - fixed uninitialized hash table mutex bug (display lists / texobjs) + - fixed bad teximage error check conditional (bug 476846) + - fixed demos readtex.c compilation problem on Windows (Karl Schultz) + - added missing glGet() query for GL_MAX_TEXTURE_LOD_BIAS_EXT + - silence some compiler warnings (gcc 2.96) + - enable the #define GL_VERSION_1_3 in GL/gl.h + - added GL 1.3 and GLX 1.4 entries to gl_mangle.h and glx_mangle.h + - fixed glu.h typedef problem found with MSDev 6.0 + - build libGL.so with -Bsymbolic (fixes bug found with Chromium) + - added missing 'const' to glXGetContextIDEXT() in glxext.h + - fixed a few glXGetProcAddress() errors (texture compression, etc) + - fixed start index bug in compiled vertex arrays (Keith) + - fixed compilation problems in src/SPARC/glapi_sparc.S + - fixed triangle strip "parity" bug found in VTK medical1 demo (Keith) + - use glXGetProcAddressARB in GLUT to avoid extension linking problems + - provoking vertex of flat-shaded, color-index triangles was wrong + - fixed a few display list bugs (GLUT walker, molecule, etc) (Keith) + - glTexParameter didn't flush the vertex buffer (Ray Tice) + - feedback attributes for glDraw/CopyPixels and glBitmap were wrong + - fixed bug in normal length caching (ParaView lighting bug) + - fixed separate_specular color bug found in Chimera (18 Dec 2001) + + +4.0.2 April 2, 2002 + New: + - New DOS (DJGPP) driver written by Daniel Borca + - New driver interface functions for TCL drivers (such as Radeon DRI) + - GL_RENDERER string returns "Mesa Offscreen16" or "Mesa Offscreen32" + if using deep color channels + - latest GL/glext.h and GL/glxext.h headers from SGI + Bug fixes: + - GL_BLEND with non-black texture env color wasn't always correct + - GL_REPLACE with GL_RGB texture format wasn't always correct (alpha) + - glTexEnviv( pname != GL_TEXTURE_ENV_COLOR ) was broken + - glReadPixels was sometimes mistakenly clipped by the scissor box + - glDraw/ReadPixels didn't catch all the errors that they should have + - Fixed 24bpp rendering problem in Windows driver (Karl Schultz) + - 16-bit GLchan mode fixes (m_trans_tmp.h, s_triangle.c) + - Fixed 1-bit float->int conversion bug in glDrawPixels(GL_DEPTH_COMP) + - glColorMask as sometimes effecting glXSwapBuffers() + - fixed a potential bug in XMesaGarbageCollect() + - N threads rendering into one window didn't work reliably + - glCopyPixels didn't work for deep color channels + - improved 8 -> 16bit/channel texture image conversion (Gerk Huisma) + - glPopAttrib() didn't correctly restore user clip planes + - user clip planes failed for some perspective projections (Chromium) + Known bugs: + - mipmap LOD computation + + +4.0.3 June 25, 2002 + New: + - updated GL/glext.h file (version 15) + - corrected MMX blend code (Jose Fonseca) + - support for software-based alpha planes in Windows driver + - updated GGI driver (Filip Spacek) + Bug fixes: + - glext.h had wrong values for GL_DOT3_RGB[A]_EXT tokens + - OSMesaMakeCurrent() didn't recognize buffer size changes + - assorted conformance fixes for 16-bit/channel rendering + - texcombine alpha subtraction mode was broken + - fixed lighting bug with non-uniform scaling and display lists + - fixed bug when deleting shared display lists + - disabled SPARC cliptest assembly code (Mesa bug 544665) + - fixed a couple Solaris compilation/link problems + - blending clipped glDrawPixels didn't always work + - glGetTexImage() didn't accept packed pixel types + - glPixelMapu[is]v() could explode given too large of pixelmap + - glGetTexParameter[if]v() didn't accept GL_TEXTURE_MAX_ANISOTROPY_EXT + - glXCopyContext() could lead to segfaults + - glCullFace(GL_FRONT_AND_BACK) didn't work (bug 572665) + Changes: + - lots of C++ (g++) code clean-ups + - lots of T&L updates for the Radeon DRI driver + Known bugs: + - mipmap LOD computation (fixed for Mesa 4.1) + + +4.0.4 October 3, 2002 + New: + - GL_NV_texture_rectangle extension + - updated glext.h header (version 17) + - updated DOS driver (Daniel Borca) + - updated BeOS R5 driver (Philippe Houdoin) + - added GL_IBM_texture_mirror_repeat + - glxinfo now takes -l option to print interesting OpenGL limits info + - GL_MESA_ycbcr_texture extension + - GL_APPLE_client_storage extension (for some DRI drivers only) + - GL_MESA_pack_invert extension + Bug fixes: + - fixed GL_LINEAR fog bug by adding clamping + - fixed FP exceptions found using Alpha CPU + - 3dfx MESA_GLX_FX=window (render to window) didn't work + - fixed memory leak in wglCreateContest (Karl Schultz) + - define GLAPIENTRY and GLAPI if undefined in glu.h + - wglGetProcAddress didn't handle all API functions + - when testing for OpenGL 1.2 vs 1.3, check for GL_ARB_texture_cube_map + - removed GL_MAX_CONVOLUTION_WIDTH/HEIGHT from glGetInteger/Float/etc() + - error checking in compressed tex image functions had some glitches + - fixed AIX compile problem in src/config.c + - glGetTexImage was using pixel unpacking instead of packing params + - auto-mipmap generation for cube maps was incorrect + Changes: + - max texture units reduced to six to accomodate texture rectangles + - removed unfinished GL_MESA_sprite_point extension code + + +4.1 October 29, 2002 + New: + - GL_NV_vertex_program extension + - GL_NV_vertex_program1_1 extension + - GL_ARB_window_pos extension + - GL_ARB_depth_texture extension + - GL_ARB_shadow extension + - GL_ARB_shadow_ambient extension + - GL_EXT_shadow_funcs extension + - GL_ARB_point_parameters extension + - GL_ARB_texture_env_crossbar + - GL_NV_point_sprite extension + - GL_NV_texture_rectangle extension + - GL_EXT_multi_draw_arrays extension + - GL_EXT_stencil_two_side extension + - GLX_SGIX_fbconfig and GLX_SGIX_pbuffer extensions + - GL_ATI_texture_mirror_once extension (Ian Romanick) + - massive overhaul/simplification of software rasterizer module, + many contributions from Klaus Niederkrueger + - faster software texturing in some cases (i.e. trilinear filtering) + - new OSMesaGetProcAddress() function + - more blend modes implemented with MMX code (Jose Fonseca) + - added glutGetProcAddress() to GLUT + - added GLUT_FPS env var to compute frames/second in glutSwapBuffers() + - pbinfo and pbdemo PBuffer programs + - glxinfo -v prints transprent pixel info (Gerd Sussner) + Bug fixes: + - better mipmap LOD computation (prevents excessive blurriness) + - OSMesaMakeCurrent() didn't recognize buffer size changes + - assorted conformance fixes for 16-bit/channel rendering + - texcombine alpha subtraction mode was broken + - fixed some blend problems when GLchan==GLfloat (Gerk Huisma) + - clamp colors to [0,inf] in OSMesa if GLchan==GLfloat (Gerk Huisma) + - fixed divide by zero error in NURBS tessellator (Jon Perry) + - fixed GL_LINEAR fog bug by adding clamping + - fixed FP exceptions found using Alpha CPU + - 3dfx/glide driver render-to-window feature was broken + - added missing GLX_TRANSPARENT_RGB token to glx.h + - fixed error checking related to paletted textures + - fixed reference count error in glDeleteTextures (Randy Fayan) + Changes: + - New spec file and Python code to generate some GL dispatch files + - Glide driver defaults to "no" with autoconf/automake + - updated demos/stex3d with new options + + +5.0 November 13, 2002 + New: + - OpenGL 1.4 support (glGetString(GL_VERSION) returns "1.4") + - removed some overlooked debugging code + - glxinfo updated to support GLX_ARB_multisample + - GLUT now support GLX_ARB_multisample + - updated DOS driver (Daniel Borca) + Bug fixes: + - GL_POINT and GL_LINE-mode polygons didn't obey cull state + - fixed potential bug in _mesa_align_malloc/calloc() + - fixed missing triangle bug when running vertex programs + - fixed a few HPUX compilation problems + - FX (Glide) driver didn't compile + - setting GL_TEXTURE_BORDER_COLOR with glTexParameteriv() didn't work + - a few EXT functions, like glGenTexturesEXT, were no-ops + - a few OpenGL 1.4 functions like glFogCoord*, glBlendFuncSeparate, + glMultiDrawArrays and glMultiDrawElements were missing + - glGet*(GL_ACTIVE_STENCIL_FACE_EXT) was broken + - Pentium 4 Mobile was mistakenly identified as having 3DNow! + - fixed one-bit error in point/line fragment Z calculation + - fixed potential segfault in fakeglx code + - fixed color overflow problem in DOT3 texture env mode + + +5.0.1 March 30, 2003 + New: + - DOS driver updates from Daniel Borca + - updated GL/gl_mangle.h file (Bill Hoffman) + Bug fixes: + - auto mipmap generation for cube maps was broken (bug 641363) + - writing/clearing software alpha channels was unreliable + - minor compilation fixes for OS/2 (Evgeny Kotsuba) + - fixed some bad assertions found with shadowtex demo + - fixed error checking bug in glCopyTexSubImage2D (bug 659020) + - glRotate(angle, -x, 0, 0) was incorrect (bug 659677) + - fixed potential segfault in texture object validation (bug 659012) + - fixed some bogus code in _mesa_test_os_sse_exception_support (Linus) + - fix fog stride bug in tnl code for h/w drivers (Michel Danzer) + - fixed glActiveTexture / glMatrixMode(GL_TEXTURE) bug (#669080) + - glGet(GL_CURRENT_SECONDARY_COLOR) should return 4 values, not 3 + - fixed compilation problem on Solaris7/x86 (bug 536406) + - fixed prefetch bug in 3DNow! code (Felix Kuhling) + - fixed NeXT build problem (FABSF macro) + - glDrawPixels Z values when glPixelZoom!=1 were invalid (bug 687811) + - zoomed glDraw/CopyPixels with clipping sometimes failed (bug 689964) + - AA line and triangle Z values are now rounded, not truncated + - fixed color interpolation bug when GLchan==GLfloat (bug 694461) + - glArePrograms/TexturesResident() wasn't 100% correct (Jose Fonseca) + - fixed a minor GL_COLOR_MATERIAL bug + - NV vertex program EXP instruction was broken + - glColorMask misbehaved with X window / pixmap rendering + - fix autoconf/libtool GLU C++ linker problem on Linux (a total hack) + - attempt to fix GGI compilation problem when MesaDemos not present + - NV vertex program ARL-relative fetches didn't work + Changes: + - use glPolygonOffset in gloss demo to avoid z-fighting artifacts + - updated winpos and pointblast demos to use ARB extensions + - disable SPARC normal transformation code (bug 673938) + - GLU fixes for OS/2 (Evgeny Kotsuba) + + +5.0.2 September 5, 2003 + Bug fixes: + - fixed texgen problem causing texcoord's Q to be zero (stex3d) + - default GL_TEXTURE_COMPARE_MODE_ARB was wrong + - GL_CURRENT_MATRIX_NV query was wrong + - GL_CURRENT_MATRIX_STACK_DEPTH_NV query was off by one + - GL_LIST_MODE query wasn't correct + - GL_FOG_COORDINATE_SOURCE_EXT query wasn't supported + - GL_SECONDARY_COLOR_ARRAY_SIZE_EXT query returned wrong value + - blended, wide lines didn't always work correctly (bug 711595) + - glVertexAttrib4svNV w component was always 1 + - fixed bug in GL_IBM_rasterpos_clip (missing return) + - GL_DEPTH_TEXTURE_MODE = GL_ALPHA didn't work correctly + - a few Solaris compilation fixes + - fixed glClear() problem for DRI drivers (non-existant stencil, etc) + - fixed int/REAL mixup in GLU NURBS curve evaluator (Eric Cazeaux) + - fixed delete [] bug in SI GLU (bug 721765) (Diego Santa Cruz) + - glFog() didn't clamp fog colors + - fixed bad float/int conversion for GL_TEXTURE_PRIORITY in the + gl[Get]TexParameteri[v] functions + - fixed invalid memory references in glTexGen functions (bug 781602) + - integer-valued color arrays weren't handled correctly + - glDrawPixels(GL_DEPTH_COMPONENT) with glPixelZoom didn't work + - GL_EXT_texture_lod_bias is part of 1.4, overlooked in 5.0.1 + Changes: + - build GLUT with -fexceptions so C++ apps propogate exceptions + + +5.1 December 17, 2003 + New: + - reorganized directory tree + - GL_ARB_vertex/fragment_program extensions (Michal Krol & Karl Rasche) + - GL_ATI_texture_env_combine3 extension (Ian Romanick) + - GL_SGI_texture_color_table extension (Eric Plante) + - GL_NV_fragment_program extension + - GL_NV_light_max_exponent extension + - GL_EXT_texture_rectangle (identical to GL_NV_texture_rectangle) + - GL_ARB_occlusion_query extension + - GL_ARB_point_sprite extension + - GL_ARB_texture_non_power_of_two extension + - GL_IBM_multimode_draw_arrays extension + - GL_EXT_texture_mirror_clamp extension (Ian Romanick) + - GL_ARB_vertex_buffer_object extension + - new X86 feature detection code (Petr Sebor) + - less memory used for display lists and vertex buffers + - demo of per-pixel lighting with a fragment program (demos/fplight.c) + - new version (18) of glext.h header + - new spriteblast.c demo of GL_ARB_point_sprite + - faster glDrawPixels in X11 driver in some cases (see RELNOTES-5.1) + - faster glCopyPixels in X11 driver in some cases (see RELNOTES-5.1) + Bug fixes: + - really enable OpenGL 1.4 features in DOS driver. + - fixed issues in glDrawPixels and glCopyPixels for very wide images + - glPixelMapf/ui/usv()'s size parameter is GLsizei, not GLint + - fixed some texgen bugs reported by Daniel Borca + - fixed wglMakeCurrent(NULL, NULL) bug (#835861) + - fixed glTexSubImage3D z-offset bug (Cedric Gautier) + - fixed RGBA blend enable bug (Ville Syrjala) + - glAccum is supposed to be a no-op in selection/feedback mode + - fixed texgen bug #597589 (John Popplewell) + Changes: + - dropped API trace feature (src/Trace/) + - documentation overhaul. merged with website content. more html. + - glxgears.c demo updated to use GLX swap rate extensions + - glTexImage1/2/3D now allows width/height/depth = 0 + - disable SPARC asm code on Linux (bug 852204) + + +6.0 January 16, 2004 + New: + - full OpenGL 1.5 support + - updated GL/glext.h file to version 21 + Changes: + - changed max framebuffer size to 4Kx4K (MAX_WIDTH/HEIGHT in config.h) + Bug fixes: + - fixed bug in UNCLAMPED_FLOAT_TO_UBYTE macro; solves a color + clamping issue + - updated suno5-gcc configs + - glColor3 functions sometimes resulted in undefined alpha values + - fixed FP divide by zero error seen on VMS with xlockmore, others + - fixed vertex/fragment program debug problem (bug 873011) + - building on AIX with gcc works now + - glDeleteProgramsARB failed for ARB fragment programs (bug 876160) + - glDrawRangeElements tried to modify potentially read-only storage + - updated files for building on Windows + + +6.0.1 April 2, 2004 + New: + - upgraded glext.h to version 22 + - new build targets (Dan Schikore) + - new linux-x86-opteron build target (Heath Feather) + Bug fixes: + - glBindProgramARB didn't update all necessary state + - fixed build problems on OpenBSD + - omit CVS directories from tarballs + - glGetTexImage(GL_COLOR_INDEX) was broken + - fixed an infinite loop in t&l module + - silenced some valgrind warnings about using unitialized memory + - fixed some compilation/link glitches on IRIX (Mike Stephens) + - glBindProgram wasn't getting compiled into display lists + - GLX_FBCONFIG_ID wasn't recognized in glXChooseFBConfig() (bug 888079) + - two-sided lighting and vertex program didn't work (bug 887330) + - stores to program parameter registers in vertex state programs + didn't work. + - fixed glOrtho bug found with gcc 3.2.2 (RH9) + - glXCreateWindow() wasn't fully implemented (bug 890894) + - generic vertex attribute arrays didn't work in display lists + - vertex buffer objects' default usage and access fields were wrong + - glDrawArrays with start!=0 was broken + - fragment program PK2H, UP2H, UP4B and UP4UB instructions were broken + - linux-osmesa16-static config didn't work + - fixed a few color index rendering problems (bug 910687) + - glInterleavedArrays didn't respect GL_CLIENT_ACTIVE_TEXTURE + - OSMesa RGB and BGR modes were broken + - glProgramStringARB mistakenly required a null-terminated string + - fragment program XPD instruction was incorrect + - glGetMaterial() didn't work reliably + - ARB_fragment_program KIL instruction was incorrect + + +6.1 August 18, 2004 + New: + - Revamped Makefile system + - glXUseRotatedXFont() utility (see xdemos/xuserotfont.c) + - internal driver interface changes related to texture object + allocation, vertex/fragment programs, BlendEquationSeparate, etc. + - option to walk triangle edges with double-precision floats + (Justin Novosad of Discreet) (see config.h file) + - support for AUX buffers in software GLX driver + - updated glext.h to version 24 and glxext.h to version 6 + - new MESA_GLX_FORCE_ALPHA and MESA_GLX_DEPTH_BITS env vars + - updated BeOS support (Philippe Houdoin) + Changes: + - fragment fog interpolation is perspective corrected now + - new glTexImage code, much cleaner, may be a bit faster + Bug fixes: + - glArrayElement in display lists didn't handle generic vertex attribs + - glFogCoord didn't always work properly + - ARB_fragment_program fog options didn't work + - frag prog TEX instruction no longer incorrectly divides s,t,r by q + - ARB frag prog TEX and TEXP instructions now use LOD=0 + - glTexEnviv in display lists didn't work + - glRasterPos didn't do texgen or apply texture matrix + - GL_DOUBLE-valued vertex arrays were broken in some cases + - fixed texture rectangle edge/border sampling bugs + - sampling an incomplete texture in a fragment program would segfault + - glTexImage was missing a few error checks + - fixed some minor glGetTexParameter glitches + - GL_INTENSITY was mistakenly accepted as a to glTexImage + - fragment program writes to RC/HC register were broken + - fixed a few glitches in GL_HP_occlusion_test extension + - glBeginQueryARB and glEndQueryARB didn't work inside display lists + - vertex program state references were broken + - fixed triangle color interpolation bug on AIX (Shane Blackett) + - fixed a number of minor memory leaks (bug #1002030) + + +6.2 October 2, 2004 + New: + - enabled GL_ARB_texture_rectangle (same as GL_NV_texture_rectangle) + - updated Doxygen support (Jose Fonseca) + Changes: + - some GGI driver updates (Christoph Egger, bug 1025977) + Bug fixes: + - Omit GL_ARB_texture_non_power_of_two from list of OpenGL 1.5 features + - fixed a few compilation issues on IRIX + - fixed a matrix classification bug (reported by Wes Bethel) + - we weren't reseting the vertex/fragment program error state + before parsing (Dave Reveman) + - adjust texcoords for sampling texture rectangles (Dave Reveman) + - glGet*(GL_MAX_VERTEX_ATTRIBS_ARB) wasn't implemented + - repeated calls to glDeleteTexture(t) could lead to a crash + - fixed potential ref count bugs in VBOs and vertex/fragment programs + - spriteblast demo didn't handle window size changes correctly + - glTexSubImage didn't handle pixels=NULL correctly for PBOs + - fixed color index mode glDrawPixels bug (Karl Schultz) + + +6.2.1 December 9, 2004 + Bug fixes: + - don't apply regular fog or color sum when using a fragment program + - glProgramEnvParameter4fARB always generated an error on + GL_FRAGMENT_PROGRAM_ARB (fdo bug 1645) + - glVertexAttrib3svNV and glVertexAttrib3svARB were broken + - fixed width/height mix-up in glSeparableFilter2D() + - fixed regression in glCopyPixels + convolution + - glReadPixels from a clipped front color buffer didn't always work + - glTexImage didn't accept GL_RED/GREEN/BLUE as the format + - Attempting queries/accesses of VBO 0 weren't detected as errors + - paletted textures failed if the palette had fewer than 256 entries + Changes: + - fixed a bunch of compiler warnings found with gcc 3.4 + - bug reports should to go bugzilla.freedesktop.org + + +6.3 July 20, 2005 + New: + - GL_EXT_framebuffer_object extension + - GL_ARB_draw_buffers extension + - GL_ARB_pixel_buffer_object extension + - GL_OES_read_format extension (Ian Romanick) + - DirectFB driver (Claudio Ciccani) + - x86_64 vertex transformation code (Mikko T.) + - Updated GL/glext.h to version 29 + Changes: + - added -stereo option for glxgears demo (Jacek Rosik) + - updated the PBuffer demo code in xdemos/ directory + - glDeleteTextures/Programs/Buffers() now makes the object ID + available for immediate re-use + - assorted 64-bit clean-ups fixes (x86_64 and Win64) + - lots of internal changes for GL_EXT_framebuffer_object + Bug fixes: + - some functions didn't support PBO functionality + - glGetTexImage didn't convert color index images to RGBA as required + - fragment program texcoords were sometimes wrong for points and lines + - fixed problem with negative dot product in arbfplight, fplight demos + - fixed bug in perspective correction of antialiased, textured lines + - querying GL_POST_CONVOLUTION_ALPHA_BIAS_EXT returned wrong value + - fixed a couple per-pixel fog bugs (Soju Matsumoto) + - glGetBooleanv(GL_FRAGMENT_PROGRAM_BINDING_NV) was broken + - fixed float parsing bug in ARB frag/vert programs (bug 2520) + - XMesaGetDepthBuffer() returned incorrect value for bytesPerValue + - GL_COLOR_MATERIAL with glColor3 didn't properly set diffuse alpha + - glXChooseFBConfig() crashed if attribList pointer was NULL + - program state.light[n].spot.direction.w was wrong value (bug 3083) + - fragment program fog option required glEnable(GL_FOG) - wrong. + - glColorTable() could produce a Mesa implementation error (bug 3135) + - RasterPos could get corrupted by color index rendering path + - Removed bad XTranslateCoordinates call when rendering to Pixmaps + - glPopAttrib() didn't properly restore GL_TEXTURE_GEN enable state + - fixed a few Darwin compilation problems + + +6.3.1 + This was an intermediate release for X.org which wasn't otherwise released. + + +6.3.2 August 19, 2005 + New: + - The distribution now includes the DRI drivers and GLX code + Changes: + - Made the DRI "new" driver interface standard, remove old code + Bug fixes: + - GL_ARB_vertex/fragment_shader were mistakenly listed in the + extensions string + - negative relative addressing in vertex programs was broken + - update/fix SPARC assembly code for vertex transformation + - fixed memory leak when freeing GLX drawables/renderbuffers + - fixed display list memory leak + - the GL_PIXEL_MAP_I_TO_I table is now floating point, not integer + - wglGetProcAddress() didn't handle wgl-functions + - fixed glxext.h cross-compile issue (Colin Harrison) + - assorted DRI driver fixes + + +6.4 October 24, 2005 + New: + - Added a fast XOR line drawing function in Xlib driver + - Added support for GL_ARB_texture_mirrored_repeat to savage + driver (supported only on Savage4 hardware). + Changes: + - Mesa now packaged in three parts: Library, Demos and GLUT + Bug fixes: + - GLX_X_RENDERABLE token wasn't accepted by glXChooseFBConfig + - Some files were present multiple times in the 6.3.2 tarballs + - r200_vtxtmp_x86.S file was missing from 6.3.2 tarball (bug 4207) + - glxgears_fbconfig demo didn't work (bug 4237) + - fixed bug when bilinear sampling 2d textures with borders + - glXCreatePbuffer() could segfault instead of returning 0 (bug 4235) + - fixed undefined frexp and rand in X.org libGLcore.a (bug 4242) + - fixed a few problems with proxy color tables (bug 4270) + - fixed precision problem in Z clearing (bug 4395) + - glBitmap, glDraw/CopyPixels mistakenly generated selection hits + - fixed potential segfault caused by reading pixels outside + of renderbuffer bounds + - glGetTexLevelParameter didn't accept GL_TEXTURE_DEPTH_SIZE_ARB + - fixed memory corruption bug involving software alpha buffers + - glReadPixels clipped by window bounds was sometimes broken + - glDraw/CopyPixels of stencil data ignored the stencil write mask + - glReadPixels from a texture bound to a framebuffer object didn't work + - glIsRender/FramebufferEXT weren't totally correct + - fixed a number of point size attenuation/fade bugs + - fixed glFogCoord bug 4729 + - GLX encoding for transpose matrix functions was broken + - fixed broken fragment program KIL and SWZ instructions + - fragment programs that wrote result.depth.z didn't work + + +6.4.1 November 30, 2005 + Bug fixes: + - redefining a vertex program string didn't take effect in TNL module + - fixed occasional segfault upon vertex/fragment parsing error + - vertex program LIT instruction didn't handle 0^0=1 correctly + - fragment program fog option didn't work with glDrawPixels, glBitmap + - USE_MGL_NAMESPACE didn't work for x86-64 + - OSMesa demos were missing from previous release tarballs + - fixed problem with float->ushort conversion in glClear (bug 4992) + - popping of GL_EYE_PLANE texgen state was broken (bug 4996) + - popping of GL_SPOT_DIRECTION light state was broken (bug 5005) + - fixed occasional triangle color interpolation problem on VMS + - work around invalid free() call (bug 5131) + - fixed BSD X server compilation problem by including stdint.h + + +6.4.2 February 2, 2006 + New: + - added OSMesaColorClamp() function/feature + - added wglGetExtensionStringARB() function + Bug fixes: + - fixed some problems when building on Windows + - GLw header files weren't installed by installmesa script (bug 5396) + - GL/glfbdev.h file was missing from tarballs + - fixed TNL initialization bug which could lead to crash (bug 5791) + + +6.5 March 31, 2006 + New: + - OpenGL Shading Language support through GL_ARB_shader_objects, + GL_ARB_shading_language_100, GL_ARB_vertex_shader and + GL_ARB_fragment_shader (done by Michal Krol) + - GL_EXT_packed_depth_stencil extension + - GL_EXT_timer_query extension + - GL_EXT_framebuffer_blit extension + - GL_ARB_half_float_pixel + - reflect demo improved to support multiple windows + - singlebuffer demo (shows no/little-flicker single-buffered rendering) + - r200: enable GL_ARB_texture_env_crossbar, separate the texture + sampling unit bits from the texture env combine enable bits + - r200: add support for GL_ATI_fragment_shader + - added fast XOR-mode line drawing optimization + - radeon: add support for all 3 tmus, GL_ARB_texture_cube_map + and GL_EXT_fog_coord + - MESA_GLX_ALPHA_BITS env var for xlib driver + - many DRI driver updates (including screen rotation support + for the Intel DRI driver) + Changes: + - removed GL_HP_occlusion_test (use GL_ARB_occlusion_query instead) + - removed GL_SGIX/SGIS_pixel_texture extensions + Bug fixes: + - fixed glxcontextmodes.c datatype problem (bug 5835) + - fixed aix-gcc build/install bugs (bug 5874) + - fixed some bugs in texture env program generation + - glXCopyContext() didn't handle texture object bindings properly + - glXCopyContext() didn't copy all lighting state + - fixed FreeBSD config (Pedro Giffuni) + - fixed some minor framebuffer object bugs + - replaced dprintf() with _glu_printf() in GLU (bug 6244) + - fixed a number of thread safety bugs/regressions + - fixed a number of GLU tesselator bugs (John Shell, bug 6339) + - paletted texturing was broken w/ floating point palettes (K. Schultz) + - lots of assorted framebuffer object bug fixes + +6.5.1 August 31, 2006 + New: + - Intel i965 DRI driver + - GL_APPLE_vertex_array_object extension (Ian Romanick) + - GL_EXT_texture_sRGB extension + - GL_EXT_gpu_program_parameters (Ian Romanick) + - "engine" demo + - updated fbdev driver and GLUT for fbdev (Sean D'Epagnier) + - many updates to the DRI drivers + Changes: + - The glVertexAttribARB functions no longer alias the conventional + vertex attributes. + - glxinfo program prints more info with -l option + - GL_FRAGMENT_PROGRAM_NV and GL_FRAGMENT_PROGRAM_ARB are now + compatible, in terms of glBindProgramARB() + Bug fixes: + - fixed broken texture border handling for depth textures (bug 6498) + - removed the test for duplicated framebuffer attachments, per + version 117 of the GL_EXT_framebuffer_object specification + - fixed a few render-to-texture bugs, including render to depth texture + - clipping of lines against user-defined clip planes was broken (6512) + - assembly language dispatch for SPARC was broken (bug 6484) + - assorted compilation fixes on various Unix platforms (Dan Schikore) + - glPopAttrib could restore an invalid value for GL_DRAW_BUFFER + - assorted minor fixes for 16 and 32 bit/channel modes + - fixed assorted bugs in texture compression paths + - fixed indirect rendering vertex array crashes (bug 6863) + - glDrawPixels GL_INDEX_OFFSET didn't always work + - fixed convolution memory leak (bug 7077) + - rectangular depth textures didn't work + - invalid mode to glBegin didn't generate an error (bug 7142) + - 'normalized' parameter to glVertexAttribPointerARB didn't work + - disable bogus GLX_SGI_video_sync extension in xlib driver + - fixed R128 driver locking bug (Martijn van Oosterhout) + - using evaluators with vertex programs caused crashes (bug 7564) + - fragment.position wasn't set correctly for point/line primitives + - fixed parser bug for scalar sources for GL_NV_fragment_program + - max fragment program length was incorrectly 128, now 1024 + - writes to result.depth in fragment programs weren't clamped to [0,1] + - fixed potential dangling pointer bug in glBindProgram() + - fixed some memory leaks (and potential crashes) in Xlib driver --- mesa-7.8.2.orig/docs/enums.txt +++ mesa-7.8.2/docs/enums.txt @@ -0,0 +1,57 @@ + +See the OpenGL ARB enum registry at http://www.opengl.org/registry/api/enum.spec + +Blocks allocated to Mesa: + 0x8750-0x875F + 0x8BB0-0x8BBF + + +GL_MESA_packed_depth_stencil + GL_DEPTH_STENCIL_MESA 0x8750 + GL_UNSIGNED_INT_24_8_MESA 0x8751 + GL_UNSIGNED_INT_8_24_REV_MESA 0x8752 + GL_UNSIGNED_SHORT_15_1_MESA 0x8753 + GL_UNSIGNED_SHORT_1_15_REV_MESA 0x8754 + +GL_MESA_trace.spec: + GL_TRACE_ALL_BITS_MESA 0xFFFF + GL_TRACE_OPERATIONS_BIT_MESA 0x0001 + GL_TRACE_PRIMITIVES_BIT_MESA 0x0002 + GL_TRACE_ARRAYS_BIT_MESA 0x0004 + GL_TRACE_TEXTURES_BIT_MESA 0x0008 + GL_TRACE_PIXELS_BIT_MESA 0x0010 + GL_TRACE_ERRORS_BIT_MESA 0x0020 + GL_TRACE_MASK_MESA 0x8755 + GL_TRACE_NAME_MESA 0x8756 + +MESA_ycbcr_texture.spec: + GL_YCBCR_MESA 0x8757 + GL_UNSIGNED_SHORT_8_8_MESA 0x85BA /* same as Apple's */ + GL_UNSIGNED_SHORT_8_8_REV_MESA 0x85BB /* same as Apple's */ + +GL_MESA_pack_invert.spec + GL_PACK_INVERT_MESA 0x8758 + +GL_MESA_shader_debug.spec: (obsolete) + GL_DEBUG_OBJECT_MESA 0x8759 + GL_DEBUG_PRINT_MESA 0x875A + GL_DEBUG_ASSERT_MESA 0x875B + +GL_MESA_program_debug.spec: (obsolete) + GL_FRAGMENT_PROGRAM_CALLBACK_MESA 0x???? + GL_VERTEX_PROGRAM_CALLBACK_MESA 0x???? + GL_FRAGMENT_PROGRAM_POSITION_MESA 0x???? + GL_VERTEX_PROGRAM_POSITION_MESA 0x???? + GL_FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA 0x???? + GL_FRAGMENT_PROGRAM_CALLBACK_DATA_MESA 0x???? + GL_VERTEX_PROGRAM_CALLBACK_FUNC_MESA 0x???? + GL_VERTEX_PROGRAM_CALLBACK_DATA_MESA 0x???? + +GL_MESAX_texture_stack: + GL_TEXTURE_1D_STACK_MESAX 0x8759 + GL_TEXTURE_2D_STACK_MESAX 0x875A + GL_PROXY_TEXTURE_1D_STACK_MESAX 0x875B + GL_PROXY_TEXTURE_2D_STACK_MESAX 0x875C + GL_TEXTURE_1D_STACK_BINDING_MESAX 0x875D + GL_TEXTURE_2D_STACK_BINDING_MESAX 0x875E + --- mesa-7.8.2.orig/docs/libGL.txt +++ mesa-7.8.2/docs/libGL.txt @@ -0,0 +1,197 @@ + + + +Introduction +------------ + +This document describes the implementation of the XFree86 4.0 libGL.so +library defined by the Linux/OpenGL Base specification found at +http://reality.sgi.com/opengl/linux/linuxbase.html. + +The documentation is divided into two sections: + User's Guide + Driver Developer's Guide + +Author: Brian Paul (brian@precisioninsight.com) +Date: February 2000 + + + +User's Guide +------------ + +Using libGL.so + +The libGL.so library defines the gl- and glX-prefixed functions needed to +run OpenGL programs. OpenGL client applications should link with the +-lGL option to use it. + +libGL.so serves two primary functions: GLX protocol generation for indirect +rendering and loading/management of hardware drivers for direct rendering. + +When libGL.so initializes itself it uses the DRI to determine the +appropriate hardware driver for each screen on the local X display. +The hardware drivers are expected to be in the /usr/X11R6/lib/modules/dri/ +directory. Drivers are named with the convention _dri.so where + is a driver such as "tdfx", "i810", "gamma", etc. + +The LIBGL_DRIVERS_DIR environment variable may be used to specify a +different DRI modules directory, overriding /usr/X11R6/lib/modules/dri/. +This environment variable is ignored in setuid programs for security +reasons. + +When libGL.so is unable to locate appropriate hardware drivers it will +fall back to using indirect GLX rendering. + +To aid in solving problems, libGL.so will print diagnostic messages to +stderr if the LIBGL_DEBUG environment variable is defined. + +libGL.so is thread safe. The overhead of thread safety for common, +single-thread clients is negligible. However, the overhead of thread +safety for multi-threaded clients is significant. Each GL API call +requires two calls to pthread_get_specific() which can noticably +impact performance. Warning: libGL.so is thread safe but individual +DRI drivers may not be. Please consult the documentation for a driver +to learn if it is thread safe. + + + +Indirect Rendering + +You can force indirect rendering mode by setting the LIBGL_ALWAYS_INDIRECT +environment variable. Hardware acceleration will not be used. + + + +libGL.so Extensibility + +libGL.so is designed to be extended without upgrading. That is, +drivers may install new OpenGL extension functions into libGL.so +without requiring libGL.so to be replaced. Clients of libGL.so should +use the glXGetProcAddressEXT() function to obtain the address of +functions by name. For more details of GLX_ARB_get_proc_address see +http://oss.sgi.com/projects/ogl-sample/registry/ARB/get_proc_address.spec + +libGL.so is also designed with flexibility such that it may be used +with many generations of hardware drivers to come. + + + + +Driver Developer's Guide +------------------------ + +This section describes the requirements to make an XFree86 4.0 +libGL.so-compatible hardware driver. It is not intended for end +users of libGL.so. + + +XFree86 source files + +libGL.so is built inside XFree86 with sources found in xc/lib/GL/. +Specifically, libGL.so is built from: + + xc/lib/GL/glx/*.c + xc/lib/dri/XF86dri.c + xc/lib/dri/dri_glx.c + xc/lib/GL/mesa/src/glapi.c + xc/lib/GL/mesa/src/glapitemp.h + xc/lib/GL/mesa/src/glapitable.h + xc/lib/GL/mesa/src/glapioffsets.h + xc/lib/GL/mesa/src/glapinoop.c + xc/lib/GL/mesa/src/glheader.h + xc/lib/GL/mesa/src/glthread.c + xc/lib/GL/mesa/src/glthread.h + xc/lib/GL/mesa/src/X86/glapi_x86.S + xc/lib/GL/mesa/src/X86/assyntax.h + +Understand that the mesa/src/gl*.[ch] files are not tied to Mesa. They +have no dependencies on the rest of Mesa and are designed to be reusable +in a number of projects. + +The glapi_x86.X and assyntax.h files implement x86-optimized dispatch +of GL functions. They are not required; C-based dispatch can be used +instead, with a slight performance penalty. + + + +Driver loading and binding + +When libGL.so initializes itself (via the __glXInitialize function) a +call is made to driCreateDisplay(). This function uses DRI facilities +to determine the driver file appropriate for each screen on the local +display. Each screen's driver is then opened with dlopen() and asked +for its __driCreateScreen() function. The pointers to the __driCreateScreen() +functions are kept in an array, indexed by screen number, in the +__DRIdisplayRec struct. + +When a driver's __driCreateScreen() function is called, it must initialize +a __DRIscreenRec struct. This struct acts as the root of a tree of +function pointers which are called to create and destroy contexts and +drawables and perform all the operations needed by the GLX interface. +See the xc/lib/GL/glx/glxclient.h file for details. + + + +Dynamic Extension Function Registration + +In order to provide forward compatibility with future drivers, libGL.so +allows drivers to register new OpenGL extension functions which weren't +known when libGL.so was built. + +The register_extensions() function in xc/lib/GL/dri/dri_glx.c is called +as soon as libGL.so is loaded. This is done with gcc's constructor +attribute. This mechanism will likely have to be changed for other compilers. + +register_extensions() loops over all local displays and screens, determines +the DRI driver for each, and calls the driver's __driRegisterExtensions() +function, if present. + +The __driRegisterExtensions() function can add new entrypoints to libGL +by calling: + + GLboolean _glapi_add_entrypoint(const char *funcName, GLuint offset) + +The parameters are the name of the function (such as "glFoobarEXT") and the +offset of the dispatch slot in the API dispatch table. The return value +indicates success (GL_TRUE) or failure (GL_FALSE). + +_glapi_add_entrypoint() will synthesize entrypoint code in assembly +language. Assembly languages is required since parameter passing +can't be handled correctly using a C-based solution. + +The address of the new entrypoint is obtained by calling the +glXGetProcAddressARB() function. + +The dispatch offset number MUST be a number allocated by SGI in the same +manner in which new GL_* constants are allocated. Using an arbitrary +offset number will result in many problems. + + + +Dispatch Management + +When a GL context is made current, the driver must install its dispatch +table as the current dispatch table. This is done by calling + + void _glapi_set_dispatch(struct _glapi_table *dispatch); + +This will install the named dispatch table for the calling thread. +The current dispatch table for a thread can be obtained by calling + + struct _glapi_table *_glapi_get_dispatch(void); + +For higher performance in the common single-thread case, the global +variable _glapi_Dispatch will point to the current dispatch table. +This variable will be NULL when in multi-thread mode. + + + +Context Management + +libGL.so uses the XFree86 xthreads package to manage a thread-specific +current context pointer. See __glXGet/SetCurrentContext() in glext.c + +Drivers may use the _glapi_set/get_context() functions to maintain +a private thread-specific context pointer. + --- mesa-7.8.2.orig/docs/mesa.css +++ mesa-7.8.2/docs/mesa.css @@ -0,0 +1,33 @@ +/* Mesa CSS */ +body { + background-color: #ffffff; + font: 14px 'Lucida Grande', Geneva, Arial, Verdana, sans-serif; + color: black; + link: #111188; +} + +h1 { + font: 24px 'Lucida Grande', Geneva, Arial, Verdana, sans-serif; + font-weight: bold; + color: black; +} + +h2 { + font: 18px 'Lucida Grande', Geneva, Arial, Verdana, sans-serif, bold; + font-weight: bold; + color: black; +} + +code { + font-family: monospace; + font-size: 10pt; + color: black; +} + + +pre { + /*font-family: monospace;*/ + font-size: 10pt; + /*color: black;*/ +} + --- mesa-7.8.2.orig/docs/GL3.txt +++ mesa-7.8.2/docs/GL3.txt @@ -0,0 +1,69 @@ + +Status of OpenGL 3.x features in Mesa + + +Note: when an item is marked as "DONE" it means all the core Mesa +infrastructure is complete but it may be the case that few (if any) drivers +implement the features. + + +Feature Status +----------------------------------------------------- ------------------------ + +GL 3.0: + +GLSL changes (GL_EXT_gpu_shader4, etc) not started +Conditional rendering (GL_NV_conditional_render) DONE (swrast & softpipe) +Map buffer subranges (GL_APPLE_flush_buffer_range) not started +Float textures, renderbuffers some infrastructure done +Framebuffer objects (GL_EXT_framebuffer_object) DONE +Half-float some infrastructure done +Multisample blit DONE +Non-normalized Integer texture/framebuffer formats not started +1D/2D Texture arrays core Mesa, swrast done +Packed depth/stencil formats DONE +Per-buffer blend and masks (GL_EXT_draw_buffers2) DONE +GL_EXT_texture_compression_rgtc not started +Red and red/green texture formats Ian? +Transform feedback (GL_EXT_transform_feedback) not started +Vertex array objects (GL_APPLE_vertex_array_object) DONE +sRGB framebuffer format (GL_EXT_framebuffer_sRGB) not started +glClearBuffer commands DONE, except for dispatch +glGetStringi command DONE, except for dispatch +glTexParameterI, glGetTexParameterI commands DONE, except for dispatch +glVertexAttribI commands not started +glBindFragDataLocation, glGetFragDataLocation cmds not started +glBindBufferRange, glBindBufferBase commands not started + + +GL 3.1: + +GLSL 1.30 and 1.40 not started +Instanced drawing (GL_ARB_draw_instanced) not started +Buffer copying (GL_ARB_copy_buffer) DONE +Primitive restart (GL_NV_primitive_restart) not started +16 vertex texture image units not started +Texture buffer objs (GL_ARB_textur_buffer_object) not started +Rectangular textures (GL_ARB_texture_rectangle) DONE +Uniform buffer objs (GL_ARB_uniform_buffer_object) not started +Signed normalized texture formats not started + + +GL 3.2: + +Core/compatibility profiles not started +GLSL 1.50 not started +Geometry shaders (GL_ARB_geometry_shader4) partially done (Zack) +BGRA vertex order (GL_ARB_vertex_array_bgra) DONE +Base vertex offset(GL_ARB_draw_elements_base_vertex) DONE +Frag shader coord (GL_ARB_fragment_coord_conventions) not started +Provoking vertex (GL_ARB_provoking_vertex) DONE +Seamless cubemaps (GL_ARB_seamless_cube_map) DONE, mostly? +Multisample textures (GL_ARB_texture_multisample) not started +Frag depth clamp (GL_ARB_depth_clamp) DONE +Fence objects (GL_ARB_sync) DONE + + + +More info about these features and the work involved can be found at +http://dri.freedesktop.org/wiki/MissingFunctionality --- mesa-7.8.2.orig/docs/relnotes-7.8.2.html +++ mesa-7.8.2/docs/relnotes-7.8.2.html @@ -26,7 +26,15 @@

MD5 checksums

-tbd
+c89b63d253605ed40e8ac370d25a833c  MesaLib-7.8.2.tar.gz
+6be2d343a0089bfd395ce02aaf8adb57  MesaLib-7.8.2.tar.bz2
+a04ad3b06ac5ff3969a003fa7bbf7d5b  MesaLib-7.8.2.zip
+7c213f92efeb471f0331670d5079d4c0  MesaDemos-7.8.2.tar.gz
+757d9e2e06f48b1a52848be9b0307ced  MesaDemos-7.8.2.tar.bz2
+8d0e5cfe68b8ebf90265d350ae2c48b1  MesaDemos-7.8.2.zip
+b74482e3f44f35ed395c4aada4fd8240  MesaGLUT-7.8.2.tar.gz
+a471807b65e49c325808ba4551be93ed  MesaGLUT-7.8.2.tar.bz2
+9f190268c42be582ef66e47365ee61e3  MesaGLUT-7.8.2.zip
 
@@ -134,7 +142,5 @@ -

Changes

-

None.

--- mesa-7.8.2.orig/include/c99/stdbool.h +++ mesa-7.8.2/include/c99/stdbool.h @@ -0,0 +1,46 @@ +/************************************************************************** + * + * Copyright 2007-2010 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS, AUTHORS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, + * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE + * USE OR OTHER DEALINGS IN THE SOFTWARE. + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + **************************************************************************/ + +#ifndef _STDBOOL_H_ +#define _STDBOOL_H_ + +#ifndef __cplusplus + +#define false 0 +#define true 1 +#define bool _Bool + +/* For compilers that don't have the builtin _Bool type. */ +#if defined(_MSC_VER) || (__STDC_VERSION__ < 199901L && __GNUC__ < 3) +typedef unsigned char _Bool; +#endif + +#endif /* !__cplusplus */ + +#define __bool_true_false_are_defined 1 + +#endif /* !_STDBOOL_H_ */ --- mesa-7.8.2.orig/include/c99/stdint.h +++ mesa-7.8.2/include/c99/stdint.h @@ -0,0 +1,119 @@ +/************************************************************************** + * + * Copyright 2007-2010 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS, AUTHORS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, + * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE + * USE OR OTHER DEALINGS IN THE SOFTWARE. + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + **************************************************************************/ + +/* + * stdint.h -- + * + * Portable subset of C99's stdint.h. + * + * At the moment it only supports MSVC, given all other mainstream compilers + * already support C99. If this is necessary for other compilers then it + * might be worth to replace this with + * http://www.azillionmonkeys.com/qed/pstdint.h. + */ + +#ifndef _STDINT_H_ +#define _STDINT_H_ + + +#ifndef INT8_MAX +#define INT8_MAX 127 +#endif +#ifndef INT8_MIN +#define INT8_MIN -128 +#endif +#ifndef UINT8_MAX +#define UINT8_MAX 255 +#endif +#ifndef INT16_MAX +#define INT16_MAX 32767 +#endif +#ifndef INT16_MIN +#define INT16_MIN -32768 +#endif +#ifndef UINT16_MAX +#define UINT16_MAX 65535 +#endif +#ifndef INT32_MAX +#define INT32_MAX 2147483647 +#endif +#ifndef INT32_MIN +#define INT32_MIN -2147483648 +#endif +#ifndef UINT32_MAX +#define UINT32_MAX 4294967295U +#endif + +#ifndef INT8_C +#define INT8_C(__val) __val +#endif +#ifndef UINT8_C +#define UINT8_C(__val) __val +#endif +#ifndef INT16_C +#define INT16_C(__val) __val +#endif +#ifndef UINT16_C +#define UINT16_C(__val) __val +#endif +#ifndef INT32_C +#define INT32_C(__val) __val +#endif +#ifndef UINT32_C +#define UINT32_C(__val) __val##U +#endif + + +#if defined(_MSC_VER) + +typedef __int8 int8_t; +typedef unsigned __int8 uint8_t; +typedef __int16 int16_t; +typedef unsigned __int16 uint16_t; +#ifndef __eglplatform_h_ +typedef __int32 int32_t; +#endif +typedef unsigned __int32 uint32_t; +typedef __int64 int64_t; +typedef unsigned __int64 uint64_t; + +#if defined(_WIN64) +typedef __int64 intptr_t; +typedef unsigned __int64 uintptr_t; +#else +typedef __int32 intptr_t; +typedef unsigned __int32 uintptr_t; +#endif + +#define INT64_C(__val) __val##i64 +#define UINT64_C(__val) __val##ui64 + +#else +#error "Unsupported compiler" +#endif + +#endif /* _STDINT_H_ */ --- mesa-7.8.2.orig/src/SConscript +++ mesa-7.8.2/src/SConscript @@ -0,0 +1,13 @@ +Import('*') + +SConscript('glsl/SConscript') +SConscript('gallium/SConscript') + +if 'mesa' in env['statetrackers']: + SConscript('mesa/SConscript') + +SConscript('gallium/winsys/SConscript') + +if platform != 'embedded': + SConscript('glut/glx/SConscript') + SConscript('glew/SConscript') --- mesa-7.8.2.orig/src/egl/docs/EGL_MESA_screen_surface +++ mesa-7.8.2/src/egl/docs/EGL_MESA_screen_surface @@ -0,0 +1,564 @@ +Name + + MESA_screen_surface + +Name Strings + + EGL_MESA_screen_surface + +Contact + + Brian Paul + + To discuss, join the dri-egl@lists.freedesktop.org list. + +Status + + Preliminary - totally subject to change. + +Version + + 11 (27 January 2006) + +Number + + TBD + +Dependencies + + EGL 1.0 or later. + +Overview + + EGL 1.1 supports three types of drawing surfaces: + * Window surfaces + * Pixmap surfaces + * Pbuffer surfaces + This extension defines a fourth type of drawing surface: + * Screen surface + + A screen surface is a surface for which the (front) color buffer can + be directly displayed (i.e. scanned out) on a monitor (such as a flat + panel or CRT). In particular the color buffer memory will be allocated + at a location in VRAM (and in a suitable format) which can be displayed + by the graphics hardware. + + Note that the width and height of the screen surface need not exactly + match the monitor's current resolution. For example, while the monitor + may be configured to to show 1024x768 pixels, the associated screen + surface may be larger, such as 1200x1000. The "screen origin" attribute + will specify which region of the screen surface which is visible on the + monitor. The screen surface can be scrolled by changing this origin. + + This extension also defines functions for controlling the monitor's + display mode (width, height, refresh rate, etc), and specifing which + screen surface is to be displayed on a monitor. + + The new EGLModeMESA type and related functions are very similar to the + EGLConfig type and related functions. The user may get a list of + supported modes for a screen and specify the mode to be used when + displaying a screen surface. + + +Issues + + 1. Should EGL_INTERLACE be a supported mode attribute? + + Arguments against: + + No, this should be provided by another extension which would + also provide the mechanisms needed to play back interlaced video + material correctly on hardware that supports it. + This extension should prefer non-interlaced modes. [M. Danzer] + + Arguments for: + + An interlaced display can be of use without considering video + material. Being able to query whether a screen is operating in + interlaced mode can be used by applications to control their + drawing. For example: avoid drawing 1-pixel-wide horizontal lines + if screen is interlaced. [B. Paul] + + Resolution: Defer for future extension? + + + 2. Should EGL_REFRESH_RATE be a supported mode attribute? + + Arguments for: + + Yes, it's been shown that applications and/or users need to select + modes by this. [M. Danzer] + + Many examples have been given in which it's desirable to let the + user choose from a variety of refresh rates without having to + restart/reconfigure. [B. Paul] + + Arguments against: + + TBD. + + Resolution: Yes. + + + 3. Exactly how should the list of modes returned by eglChooseConfigMESA + be sorted? + + Current method is described in the text below. Subject to change. + + Alternately, leave the sorting order undefined so that each + implementation can return the modes in order of "most desirable" + to "least desirable" which may depend on the display technology + (CRT vs LCD, etc) or other factors. + + + 4. How should screen blanking be supported? Note that a screen can be + disabled or turned off by calling eglShowSurface(dpy, scrn, + EGL_NO_SURFACE, EGL_NO_MODE_MESA). But what about power-save mode? + + I would defer this to other extensions that depend on this one. + I can imagine people wanting different semantics not just in + relation to the power management API being exposed (DPMS or whatever) + but also relating to what events can trigger EGL_CONTEXT_LOST. Also + I'm not sure whether power management commands are properly operations + on the Display or on a screen surface. [A. Jackson] + + + 5. Should the EGL_PHYSICAL_SIZE_EGL query be kept? The size information + isn't always reliable (consider video projectors) but can still be + used to determine the pixel aspect ratio. + + Resolution: Omit. The EGL 1.2 specification includes queries for + the display resolution and pixel aspect ratio. + + + 6. Should detailed mode timing information be exposed by this API? + + Probably not. Instead, offer that information in a layered extension. + + + 7. How should the notion of a screen's "native" mode be expressed? + For example, LCD panels have a native resolution and refresh rate + that looks best but other sub-optimal resolutions may be supported. + + The mode attribute EGL_OPTIMAL_MESA will be set for modes which + best match the screen. [M. Danzer] + + + 8. Should eglQueryModeStringMESA() be included? This function returns + a human-readable string which corresponds to an EGLMode. + + Arguments for: + + A mode name such as "HDTV-720P" might mean more to users than + "1280x720@60Hz" if the later were generated via code. + + Arguments against: + + There's no standard syntax for the strings. May cause more + trouble than it's worth. + + Postpone for future extension. [A. Jackson] + + Latest discussion leaning toward omitting this function. + + + 9. Should we use "Get" or "Query" for functions which return state? + The EGL 1.x specification doesn't seem to be totally consistent + in this regard, but "Query" is used more often. + + Use "Get" for mode-related queries (as for EGLConfigs) but "Query" + for everything else. + + + 10. What should be the default size for screen surfaces? + + For Pbuffer surfaces the default width and height are zero. + We'll do the same for screen surfaces. Since there's no function + to resize surfaces it's useless to have a 0x0 screen, but this isn't + a situation that'll normally be encountered. + + + 11. Should there be a function for resizing a screen surface? + + Suppose one wants to change the screen's size in the EGL application. + Also suppose there's a hardware restriction such that only one screen + surface can exist at a time (either for lack of memory or because of + memory layout restrictions). + + The basic idea is that the currently displayed screen surface must + be deallocated before a new one can be created. Perhaps a resize + function would work better? + + + 12. How should sub-pixel LCD color information be made available? + What about the display's gamma value? + + Perhaps expose as additional read-only mode attributes. + + Perhaps postpone for a layered extension. + + + 13. What happens if the user attempts to delete a screen surface that + is currently being shown? + + Spec currently says that's illegal and that an error (TBD) will be + generated. + + + 14. What if the physical screen size can't be determined? Should + a query of EGL_PHYSICAL_SIZE_MESA return [0,0]? + + Obsolete: EGL_PHYSICAL_SIZE_MESA not used. + + + 15. Suppose the device's number of RAMDACs is different from the + number of output ports. For example, a graphics card with + two RAMDACs but three ports (VGA, DVI, TV). + + Address this in a follow-on extension. [Matthias Hopf] + + + 16. How should we deal with on-the-fly device changes? For example, + the monitor being unplugged and replaced by another with different + characteristics? + + A HAL event could be received via DBUS in the application [J. Smirl, + A. Jackson]. + + Should there be an EGL mechanism for detecting this? Maybe an + EGL_SCREEN_LOST error (similar to EGL_CONTEXT_LOST) can be recorded + when there's a screen change. At least then the application can + poll to detect this situation. + + Maybe leave that to a future extension. + + See also the EGL_SCREEN_COUNT_MESA query. + + + 17. What if pixel-accurate panning is not supported (see + eglScreenPositionMESA)? [M. Danzer] + + Is this a common problem? Can we ignore it for now? + + + 18. Should eglShowSurfaceMESA be renamed to eglShowScreenSurfaceMESA? + + Probably. + + + +New Procedures and Functions + + EGLBoolean eglChooseModeMESA(EGLDisplay dpy, EGLScreenMESA screen, + const EGLint *attrib_list, + EGLModeMESA *modes, EGLint modes_size, + EGLint *num_modes) + + EGLBoolean eglGetModesMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLModeMESA *modes, EGLint modes_size, + EGLint *num_modes) + + EGLBoolean eglGetModeAttribMESA(EGLDisplay dpy, EGLModeMESA mode, + EGLint attrib, EGLint *value) + + + EGLBoolean eglGetScreensMESA(EGLDisplay dpy, EGLScreenMESA *screens, + EGLint screens_size, EGLint *num_screens) + + EGLSurface eglCreateScreenSurfaceMESA(EGLDisplay dpy, EGLConfig config, + const EGLint *attrib_list) + + EGLBoolean eglShowSurfaceMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLSurface surface, EGLModeMESA mode) + + EGLBoolean eglScreenPositionMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLint x, EGLint y) + + + EGLBoolean eglQueryScreenMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLint attrib, EGLint *value); + + EGLBoolean eglQueryScreenSurfaceMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLSurface *surface) + + EGLBoolean eglQueryScreenModeMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLModeMESA *mode) + + const char *eglQueryModeStringMESA(EGLDisplay dpy, EGLMode mode); + + +New Types + + EGLModeMESA + EGLScreenMESA + +New Tokens + + New error codes: + + EGL_BAD_SCREEN_MESA + EGL_BAD_MODE_MESA + + Screen-related tokens: + + EGL_SCREEN_COUNT_MESA + EGL_SCREEN_POSITION_MESA + EGL_SCREEN_BIT_MESA + EGL_SCREEN_POSITION_GRANULARITY_MESA + + Mode-related tokens: + + EGL_MODE_ID_MESA + EGL_REFRESH_RATE_MESA + EGL_INTERLACED_MESA + EGL_OPTIMAL_MESA + EGL_NO_MODE_MESA + + +Additions to Chapter X of the EGL 1.1 Specification + + [XXX this all has to be rewritten to fit into the EGL specification + and match the conventions of an EGL extension. For now, just list + all the functions with brief descriptions.] + + + EGLBoolean eglChooseModeMESA(EGLDisplay dpy, const EGLScreenMESA screen, + EGLint *attrib_list, EGLModeMESA *modes, + EGLint modes_size, EGLint *num_modes) + + Like eglChooseConfig, returns a list of EGLModes which match the given + attribute list. This does not set the screen's current display mode. + The attribute list is a list of token/value pairs terminated with + EGL_NONE. Supported attributes include: + + Name Description + --------------------- --------------------------------------------- + EGL_WIDTH Mode width (resolution) + EGL_HEIGHT Mode height (resolution) + EGL_REFRESH_RATE_MESA The mode's refresh rate, multiplied by 1000 + EGL_INTERLACED_MESA 1 indicates an interlaced mode, 0 otherwise + EGL_OPTIMAL_MESA Set if the most is especially optimal for the + screen (ex. for particular LCD resolutions) + + Any other token will generate the error EGL_BAD_ATTRIBUTE. + + The list of modes returned by eglChooseModeMESA will be sorted + according to the following criteria. See the discussion of table 3.3 + in the EGL specification for more information. + + Selection Sort Sort + Attribute Default Criteria Order Priority + -------------------- -------------- ----------- ------ -------- + EGL_OPTIMAL_MESA EGL_DONT_CARE Exact 1,0 1 + EGL_INTERLACED_MESA EGL_DONT_CARE Exact 0,1 2 + EGL_REFRESH_RATE EGL_DONT_CARE AtLeast Larger 3 + EGL_WIDTH EGL_DONT_CARE AtLeast Larger 4 + EGL_HEIGHT EGL_DONT_CARE AtLeast Larger 5 + EGL_MODE_ID_MESA EGL_DONT_CARE Exact Smaller 6 + + + EGLBoolean eglGetModesMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLModeMESA *modes, EGLint modes_size, + EGLint *num_modes) + + Like eglGetConfigs, returns a list of all modes supported by the + given screen. The returned modes will be sorted in the same manner + as for eglChooseModeMESA(). + + + + EGLBoolean eglGetModeAttribMESA(EGLDisplay dpy, EGLModeMESA mode, + EGLint attrib, EGLint *value) + + Used to query mode attributes. The following attributes are supported: + + Name Return value description + --------------------- ---------------------------------------------- + EGL_OPTIMAL_MESA 1 indicates an optimal mode, 0 otherwise + EGL_INTERLACED_MESA 1 indicates an interlaced mode, 0 otherwise + EGL_REFRESH_RATE_MESA The mode's refresh rate, multiplied by 1000 + EGL_WIDTH Mode width (resolution) + EGL_HEIGHT Mode height (resolution) + EGL_MODE_ID_MESA A unique small integer identifier for the mode + + Any other token will generate the error EGL_BAD_ATTRIBUTE. + + + + EGLBoolean eglGetScreensMESA(EGLDisplay dpy, EGLScreenMESA *screens, + EGLint screens_size, EGLint *num_screens) + + This function returns an array of all available screen handles. + is the maximum number of screens to return in the + array. will return the number of screen handles + placed in the array, even if is NULL. + + The number of screens and the availability of each may change over + time (hot-plugging). Screen handles will not be reused. When a + screen handle becomes invalid, function calls which reference an + invalid handle will generate EGL_BAD_SCREEN_MESA. + + The first screen handle returned will be considered to be the primary + one. + + + + EGLSurface eglCreateScreenSurfaceMESA(EGLDisplay dpy, EGLConfig config, + const EGLint *attrib_list) + + Create a surface that can be displayed on a screen. is + an array of token/value pairs terminated with EGL_NONE. Valid tokens + include: + + Name Description + ---------------- -------------------------------- + EGL_WIDTH desired surface width in pixels + EGL_HEIGHT desired surface height in pixels + + Any other token will generate the error EGL_BAD_ATTRIBUTE. + The default width and height are zero. + + + + EGLBoolean eglShowSurfaceMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLSurface surface, EGLModeMESA mode) + + This function causes a screen to show the given surface (or more + precisely, the surface's front color buffer) with the given mode. + + If the surface is in any way incompatible with the mode, the error + EGL_BAD_MATCH will be generated, EGL_FALSE will be returned, and the + previous screen state will remain in effect. This might occur when + the bandwidth of the video-out subsystem is exceeded, or if the mode + specifies a width or height that's greater than the width or height + of the surface. + + To disable a screen, the values EGL_NO_SURFACE and EGL_NO_MODE_MESA + be passed as the and parameters. + + The values of EGL_SCREEN_POSITION_MESA are clamped to the new valid + range computed from the screen size and surface size. If the new + surface is EGL_NO_SURFACE, EGL_SCREEN_POSITION_MESA is set to [0, 0]. + + + Attempting to delete a screen surface which is currently being + displayed will result in the error EGL_BAD_ACCESS being generated. + + + + EGLBoolean eglScreenPositionMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLint x, EGLint y) + + Specifies the origin of the screen's view into the surface, if the + surface is larger than the screen. Valid values for x and y are + [0, surfaceWidth - screenWidth] and [0, surfaceHeight - screenHeight], + respectively. + + The x and y values are also constrained to be integer multiples of the + EGL_SCREEN_POSITION_GRANULARITY_MESA values. + + + + + EGLBoolean eglQueryScreenMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLint attrib, EGLint *value); + + Used to query screen attributes. may be one of the following: + + Name Return value description + ------------------------ --------------------------------------------- + EGL_SCREEN_POSITION_MESA x, y position of the screen's origin with + respect to the surface. If no surface is + attached to the screen, [0, 0] is returned. + EGL_SCREEN_POSITION_GRANULARITY_MESA + Returns the granularity, in pixels, for + which the screen position is constrained. + + Any other token will generate the error EGL_BAD_ATTRIBUTE. + + + + + EGLBoolean eglQueryScreenSurfaceMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLSurface *surface) + + Returns the surface currently displayed on the given screen. + may be EGL_NO_SURFACE if the screen isn't currently showing any surface. + + + + + EGLBoolean eglQueryScreenModeMESA(EGLDisplay dpy, EGLScreenMESA screen, + EGLModeMESA *mode) + + Returns the given screen's current display mode. The mode may be + EGL_NO_MODE_MESA if the screen is currently disabled. + + + + const char *eglQueryModeStringMESA(EGLDisplay dpy, EGLModeMESA mode); + + Returns a human-readable string for the given mode. The string is a + zero-terminated C string which the user should not attempt to free. + There is no standard syntax for mode strings. Applications should + not directly rely on mode strings. + + + +Version History + + 1. 15 March 2005 - BrianP + Initial version + + 2. 16 March 2005 - BrianP + Removed EGL_DEPTH_MESA + Added EGL_PHYSICAL_WIDTH_MESA, EGL_PHYSICAL_HEIGHT_MESA queries + Added EGL_OPTIMAL_MESA for width/height/refresh rate selection + Added possible eglQueryModeStringMESA() function + More details of the new functions explained. + + 3. 18 March 2005 - BrianP + Added screen_number to eglChooseModeMESA(). + Fix off by one mistake in value range for ORIGIN attributes + Added Issues section + + 4. 21 March 2005 - BrianP + Removed eglScreenAttribsMESA(). + Added eglScreenPositionMESA() to set screen origin. + Replaced EGL_SCREEN_X/Y_OFFSET_MESA with EGL_SCREEN_POSITION_MESA. + Replaced EGL_PHYSICAL_WIDTH/HEIGHT_MESA with EGL_PHYSICAL_SIZE_MESA. + Use EGL_OPTIMAL_MESA as a new mode attribute. (Michel Danzer) + Added a few more issues. + + 5. 6 April 2005 - BrianP + More language for eglGetModeStringMESA(). + Added issues 10, 11, 12, 13, 14. + Updated issue 3 discussion about mode sorting. + + 6. 22 April 2005 - BrianP + Fixed "LDC" typo. + Added issues 15, 16. + Changed dependency on EGL 1.1 to EGL 1.0 + s/EGL_NUM_SCREENS_MESA/EGL_SCREEN_COUNT_MESA/ + Added eglQueryDisplayMESA() to New Functions section. + Clarified language for the EGL_SCREEN_COUNT_MESA query. + + 7. 29 April 2005 - BrianP + Added EGLScreenMESA type and eglGetScreensMESA() function. [J. Smirl]. + Replaced EGLint screen_number parameters with EGLScreenMESA screen. + Added issue 17 (pixel-accurate panning) + + 8. 2 May 2005 - BrianP + Removed eglQueryDisplayMESA. + Fixed a few more EGLint -> EGLScreenMESA changes. + + 9. 20 May 2005 - BrianP + Fixed a few typos. + Updated some open issues text. + + 10. 10 August 2005 - BrianP + Added EGL_SCREEN_POSITION_GRANULARITY_MESA. + + 11. 27 January 2006 - BrianP + EGL_PHYSICAL_SIZE_MESA removed since EGL 1.2 has a similar feature. + --- mesa-7.8.2.orig/src/egl/main/README.txt +++ mesa-7.8.2/src/egl/main/README.txt @@ -0,0 +1,71 @@ + + +Notes about the EGL library: + + +The EGL code here basically consists of two things: + +1. An EGL API dispatcher. This directly routes all the eglFooBar() API + calls into driver-specific functions. + +2. Fallbacks for EGL API functions. A driver _could_ implement all the + EGL API calls from scratch. But in many cases, the fallbacks provided + in libEGL (such as eglChooseConfig()) will do the job. + + + +Bootstrapping: + +When the apps calls eglOpenDisplay() a device driver is selected and loaded +(look for dlsym() or LoadLibrary() in egldriver.c). + +The driver's _eglMain() function is then called. This driver function +allocates, initializes and returns a new _EGLDriver object (usually a +subclass of that type). + +As part of initialization, the dispatch table in _EGLDriver->API must be +populated with all the EGL entrypoints. Typically, _eglInitDriverFallbacks() +can be used to plug in default/fallback functions. Some functions like +driver->API.Initialize and driver->API.Terminate _must_ be implemented +with driver-specific code (no default/fallback function is possible). + + +A bit later, the app will call eglInitialize(). This will get routed +to the driver->API.Initialize() function. Any additional driver +initialization that wasn't done in _eglMain() should be done at this +point. Typically, this will involve setting up visual configs, etc. + + + +Special Functions: + +Certain EGL functions _must_ be implemented by the driver. This includes: + +eglCreateContext +eglCreateWindowSurface +eglCreatePixmapSurface +eglCreatePBufferSurface +eglMakeCurrent +eglSwapBuffers + +Most of the EGLConfig-related functions can be implemented with the +defaults/fallbacks. Same thing for the eglGet/Query functions. + + + + +Teardown: + +When eglTerminate() is called, the driver->API.Terminate() function is +called. The driver should clean up after itself. eglTerminate() will +then close/unload the driver (shared library). + + + + +Subclassing: + +The internal libEGL data structures such as _EGLDisplay, _EGLContext, +_EGLSurface, etc should be considered base classes from which drivers +will derive subclasses. + --- mesa-7.8.2.orig/src/gallium/README.portability +++ mesa-7.8.2/src/gallium/README.portability @@ -0,0 +1,109 @@ + CROSS-PLATFORM PORTABILITY GUIDELINES FOR GALLIUM3D + + += General Considerations = + +The state tracker and winsys driver support a rather limited number of +platforms. However, the pipe drivers are meant to run in a wide number of +platforms. Hence the pipe drivers, the auxiliary modules, and all public +headers in general, should strictly follow these guidelines to ensure + + += Compiler Support = + +* Include the p_compiler.h. + +* Don't use the 'inline' keyword, use the INLINE macro in p_compiler.h instead. + +* Cast explicitly when converting to integer types of smaller sizes. + +* Cast explicitly when converting between float, double and integral types. + +* Don't use named struct initializers. + +* Don't use variable number of macro arguments. Use static inline functions +instead. + +* Don't use C99 features. + += Standard Library = + +* Avoid including standard library headers. Most standard library functions are +not available in Windows Kernel Mode. Use the appropriate p_*.h include. + +== Memory Allocation == + +* Use MALLOC, CALLOC, FREE instead of the malloc, calloc, free functions. + +* Use align_pointer() function defined in u_memory.h for aligning pointers + in a portable way. + +== Debugging == + +* Use the functions/macros in p_debug.h. + +* Don't include assert.h, call abort, printf, etc. + + += Code Style = + +== Inherantice in C == + +The main thing we do is mimic inheritance by structure containment. + +Here's a silly made-up example: + +/* base class */ +struct buffer +{ + int size; + void (*validate)(struct buffer *buf); +}; + +/* sub-class of bufffer */ +struct texture_buffer +{ + struct buffer base; /* the base class, MUST COME FIRST! */ + int format; + int width, height; +}; + + +Then, we'll typically have cast-wrapper functions to convert base-class +pointers to sub-class pointers where needed: + +static inline struct vertex_buffer *vertex_buffer(struct buffer *buf) +{ + return (struct vertex_buffer *) buf; +} + + +To create/init a sub-classed object: + +struct buffer *create_texture_buffer(int w, int h, int format) +{ + struct texture_buffer *t = malloc(sizeof(*t)); + t->format = format; + t->width = w; + t->height = h; + t->base.size = w * h; + t->base.validate = tex_validate; + return &t->base; +} + +Example sub-class method: + +void tex_validate(struct buffer *buf) +{ + struct texture_buffer *tb = texture_buffer(buf); + assert(tb->format); + assert(tb->width); + assert(tb->height); +} + + +Note that we typically do not use typedefs to make "class names"; we use +'struct whatever' everywhere. + +Gallium's pipe_context and the subclassed psb_context, etc are prime examples +of this. There's also many examples in Mesa and the Mesa state tracker. --- mesa-7.8.2.orig/src/gallium/auxiliary/gallivm/lp_bld_init.cpp +++ mesa-7.8.2/src/gallium/auxiliary/gallivm/lp_bld_init.cpp @@ -0,0 +1,69 @@ +/************************************************************************** + * + * Copyright 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + + +#include +#include +#include + +#include "pipe/p_config.h" + +#include "lp_bld_init.h" + + +extern "C" void LLVMLinkInJIT(); + + +extern "C" void +lp_build_init(void) +{ +#if defined(PIPE_OS_WINDOWS) && defined(PIPE_ARCH_X86) + /* + * This is mis-detected on some hardware / software combinations. + */ + llvm::StackAlignment = 4; + llvm::RealignStack = true; +#endif + + /* Same as LLVMInitializeNativeTarget(); */ + llvm::InitializeNativeTarget(); + + LLVMLinkInJIT(); +} + + +/* + * Hack to allow the linking of release LLVM static libraries on a debug build. + * + * See also: + * - http://social.msdn.microsoft.com/Forums/en-US/vclanguage/thread/7234ea2b-0042-42ed-b4e2-5d8644dfb57d + */ +#if defined(_MSC_VER) && defined(_DEBUG) +#include +extern "C" _CRTIMP void __cdecl +_invalid_parameter_noinfo(void) {} +#endif --- mesa-7.8.2.orig/src/gallium/auxiliary/rbug/README +++ mesa-7.8.2/src/gallium/auxiliary/rbug/README @@ -0,0 +1,25 @@ + GALLIUM REMOTE DEBUGGING COMMON CODE + += About = + +This directory contains the common code for the Gallium 3D remote debugging +driver and clients. The code is two parts the connection managment code and +the (de)marsheller. + +The code currently uses tcp and ip4v for connections. + +Information about driver integration can be found in: + +src/gallium/drivers/trace/README + +for information about applications look in: + +progs/rbug/README + +for a GUI see: + + http://cgit.freedesktop.org/mesa/rbug-gui + + +-- +Jakob Bornecrantz --- mesa-7.8.2.orig/src/gallium/auxiliary/tgsi/tgsi-instruction-set.txt +++ mesa-7.8.2/src/gallium/auxiliary/tgsi/tgsi-instruction-set.txt @@ -0,0 +1,1163 @@ +TGSI Instruction Specification +============================== +============================== + + +1 Instruction Set Operations +============================= + + +1.1 GL_NV_vertex_program +------------------------- + + +1.1.1 ARL - Address Register Load + + dst.x = floor(src.x) + dst.y = floor(src.y) + dst.z = floor(src.z) + dst.w = floor(src.w) + + +1.1.2 MOV - Move + + dst.x = src.x + dst.y = src.y + dst.z = src.z + dst.w = src.w + + +1.1.3 LIT - Light Coefficients + + dst.x = 1.0 + dst.y = max(src.x, 0.0) + dst.z = (src.x > 0.0) ? pow(max(src.y, 0.0), clamp(src.w, -128.0, 128.0)) : 0.0 + dst.w = 1.0 + + +1.1.4 RCP - Reciprocal + + dst.x = 1.0 / src.x + dst.y = 1.0 / src.x + dst.z = 1.0 / src.x + dst.w = 1.0 / src.x + + +1.1.5 RSQ - Reciprocal Square Root + + dst.x = 1.0 / sqrt(abs(src.x)) + dst.y = 1.0 / sqrt(abs(src.x)) + dst.z = 1.0 / sqrt(abs(src.x)) + dst.w = 1.0 / sqrt(abs(src.x)) + + +1.1.6 EXP - Approximate Exponential Base 2 + + dst.x = pow(2.0, floor(src.x)) + dst.y = src.x - floor(src.x) + dst.z = pow(2.0, src.x) + dst.w = 1.0 + + +1.1.7 LOG - Approximate Logarithm Base 2 + + dst.x = floor(lg2(abs(src.x))) + dst.y = abs(src.x) / pow(2.0, floor(lg2(abs(src.x)))) + dst.z = lg2(abs(src.x)) + dst.w = 1.0 + + +1.1.8 MUL - Multiply + + dst.x = src0.x * src1.x + dst.y = src0.y * src1.y + dst.z = src0.z * src1.z + dst.w = src0.w * src1.w + + +1.1.9 ADD - Add + + dst.x = src0.x + src1.x + dst.y = src0.y + src1.y + dst.z = src0.z + src1.z + dst.w = src0.w + src1.w + + +1.1.10 DP3 - 3-component Dot Product + + dst.x = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + dst.y = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + dst.z = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + dst.w = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + + +1.1.11 DP4 - 4-component Dot Product + + dst.x = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src0.w * src1.w + dst.y = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src0.w * src1.w + dst.z = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src0.w * src1.w + dst.w = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src0.w * src1.w + + +1.1.12 DST - Distance Vector + + dst.x = 1.0 + dst.y = src0.y * src1.y + dst.z = src0.z + dst.w = src1.w + + +1.1.13 MIN - Minimum + + dst.x = min(src0.x, src1.x) + dst.y = min(src0.y, src1.y) + dst.z = min(src0.z, src1.z) + dst.w = min(src0.w, src1.w) + + +1.1.14 MAX - Maximum + + dst.x = max(src0.x, src1.x) + dst.y = max(src0.y, src1.y) + dst.z = max(src0.z, src1.z) + dst.w = max(src0.w, src1.w) + + +1.1.15 SLT - Set On Less Than + + dst.x = (src0.x < src1.x) ? 1.0 : 0.0 + dst.y = (src0.y < src1.y) ? 1.0 : 0.0 + dst.z = (src0.z < src1.z) ? 1.0 : 0.0 + dst.w = (src0.w < src1.w) ? 1.0 : 0.0 + + +1.1.16 SGE - Set On Greater Equal Than + + dst.x = (src0.x >= src1.x) ? 1.0 : 0.0 + dst.y = (src0.y >= src1.y) ? 1.0 : 0.0 + dst.z = (src0.z >= src1.z) ? 1.0 : 0.0 + dst.w = (src0.w >= src1.w) ? 1.0 : 0.0 + + +1.1.17 MAD - Multiply And Add + + dst.x = src0.x * src1.x + src2.x + dst.y = src0.y * src1.y + src2.y + dst.z = src0.z * src1.z + src2.z + dst.w = src0.w * src1.w + src2.w + + +1.2 GL_ATI_fragment_shader +--------------------------- + + +1.2.1 SUB - Subtract + + dst.x = src0.x - src1.x + dst.y = src0.y - src1.y + dst.z = src0.z - src1.z + dst.w = src0.w - src1.w + + +1.2.2 DOT3 - 3-component Dot Product + + Alias for DP3. + + +1.2.3 DOT4 - 4-component Dot Product + + Alias for DP4. + + +1.2.4 LERP - Linear Interpolate + + dst.x = src0.x * (src1.x - src2.x) + src2.x + dst.y = src0.y * (src1.y - src2.y) + src2.y + dst.z = src0.z * (src1.z - src2.z) + src2.z + dst.w = src0.w * (src1.w - src2.w) + src2.w + + +1.2.5 CND - Condition + + dst.x = (src2.x > 0.5) ? src0.x : src1.x + dst.y = (src2.y > 0.5) ? src0.y : src1.y + dst.z = (src2.z > 0.5) ? src0.z : src1.z + dst.w = (src2.w > 0.5) ? src0.w : src1.w + + +1.2.6 CND0 - Condition Zero + + Removed. Use (CMP src2, src1, src0) instead. + +1.2.7 DOT2ADD - 2-component Dot Product And Add + + dst.x = src0.x * src1.x + src0.y * src1.y + src2.x + dst.y = src0.x * src1.x + src0.y * src1.y + src2.x + dst.z = src0.x * src1.x + src0.y * src1.y + src2.x + dst.w = src0.x * src1.x + src0.y * src1.y + src2.x + + +1.3 GL_EXT_vertex_shader +------------------------- + + +1.3.1 INDEX - Array Lookup + + Considered for removal from language. + + +1.3.2 NEGATE - Negate + + Considered for removal from language. + + +1.3.3 MADD - Multiply And Add + + Alias for MAD. + + +1.3.4 FRAC - Fraction + + dst.x = src.x - floor(src.x) + dst.y = src.y - floor(src.y) + dst.z = src.z - floor(src.z) + dst.w = src.w - floor(src.w) + + +1.3.5 SETGE - Set On Greater Equal + + Alias for SGE. + + +1.3.6 SETLT - Set On Less Than + + Alias for SLT. + + +1.3.7 CLAMP - Clamp + + dst.x = clamp(src0.x, src1.x, src2.x) + dst.y = clamp(src0.y, src1.y, src2.y) + dst.z = clamp(src0.z, src1.z, src2.z) + dst.w = clamp(src0.w, src1.w, src2.w) + + +1.3.8 FLOOR - Floor + + dst.x = floor(src.x) + dst.y = floor(src.y) + dst.z = floor(src.z) + dst.w = floor(src.w) + + +1.3.9 ROUND - Round + + dst.x = round(src.x) + dst.y = round(src.y) + dst.z = round(src.z) + dst.w = round(src.w) + + +1.3.10 EXPBASE2 - Exponential Base 2 + + dst.x = pow(2.0, src.x) + dst.y = pow(2.0, src.x) + dst.z = pow(2.0, src.x) + dst.w = pow(2.0, src.x) + + +1.3.11 LOGBASE2 - Logarithm Base 2 + + dst.x = lg2(src.x) + dst.y = lg2(src.x) + dst.z = lg2(src.x) + dst.w = lg2(src.x) + + +1.3.12 POWER - Power + + dst.x = pow(src0.x, src1.x) + dst.y = pow(src0.x, src1.x) + dst.z = pow(src0.x, src1.x) + dst.w = pow(src0.x, src1.x) + + +1.3.13 RECIP - Reciprocal + + Alias for RCP. + + +1.3.14 RECIPSQRT - Reciprocal Square Root + + Alias for RSQ. + + +1.3.15 CROSSPRODUCT - Cross Product + + dst.x = src0.y * src1.z - src1.y * src0.z + dst.y = src0.z * src1.x - src1.z * src0.x + dst.z = src0.x * src1.y - src1.x * src0.y + dst.w = 1.0 + + +1.3.16 MULTIPLYMATRIX - Multiply Matrix + + Considered for removal from language. + + +1.4 GL_NV_vertex_program1_1 +---------------------------- + + +1.4.1 ABS - Absolute + + dst.x = abs(src.x) + dst.y = abs(src.y) + dst.z = abs(src.z) + dst.w = abs(src.w) + + +1.4.2 RCC - Reciprocal Clamped + + dst.x = (1.0 / src.x) > 0.0 ? clamp(1.0 / src.x, 5.42101e-020, 1.884467e+019) : clamp(1.0 / src.x, -1.884467e+019, -5.42101e-020) + dst.y = (1.0 / src.x) > 0.0 ? clamp(1.0 / src.x, 5.42101e-020, 1.884467e+019) : clamp(1.0 / src.x, -1.884467e+019, -5.42101e-020) + dst.z = (1.0 / src.x) > 0.0 ? clamp(1.0 / src.x, 5.42101e-020, 1.884467e+019) : clamp(1.0 / src.x, -1.884467e+019, -5.42101e-020) + dst.w = (1.0 / src.x) > 0.0 ? clamp(1.0 / src.x, 5.42101e-020, 1.884467e+019) : clamp(1.0 / src.x, -1.884467e+019, -5.42101e-020) + + +1.4.3 DPH - Homogeneous Dot Product + + dst.x = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src1.w + dst.y = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src1.w + dst.z = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src1.w + dst.w = src0.x * src1.x + src0.y * src1.y + src0.z * src1.z + src1.w + + +1.5 GL_NV_fragment_program +--------------------------- + + +1.5.1 COS - Cosine + + dst.x = cos(src.x) + dst.y = cos(src.x) + dst.z = cos(src.x) + dst.w = cos(src.w) + + +1.5.2 DDX - Derivative Relative To X + + dst.x = partialx(src.x) + dst.y = partialx(src.y) + dst.z = partialx(src.z) + dst.w = partialx(src.w) + + +1.5.3 DDY - Derivative Relative To Y + + dst.x = partialy(src.x) + dst.y = partialy(src.y) + dst.z = partialy(src.z) + dst.w = partialy(src.w) + + +1.5.4 EX2 - Exponential Base 2 + + Alias for EXPBASE2. + + +1.5.5 FLR - Floor + + Alias for FLOOR. + + +1.5.6 FRC - Fraction + + Alias for FRAC. + + +1.5.7 KILP - Predicated Discard + + discard + + +1.5.8 LG2 - Logarithm Base 2 + + Alias for LOGBASE2. + + +1.5.9 LRP - Linear Interpolate + + Alias for LERP. + + +1.5.10 PK2H - Pack Two 16-bit Floats + + TBD + + +1.5.11 PK2US - Pack Two Unsigned 16-bit Scalars + + TBD + + +1.5.12 PK4B - Pack Four Signed 8-bit Scalars + + TBD + + +1.5.13 PK4UB - Pack Four Unsigned 8-bit Scalars + + TBD + + +1.5.14 POW - Power + + Alias for POWER. + + +1.5.15 RFL - Reflection Vector + + dst.x = 2.0 * (src0.x * src1.x + src0.y * src1.y + src0.z * src1.z) / (src0.x * src0.x + src0.y * src0.y + src0.z * src0.z) * src0.x - src1.x + dst.y = 2.0 * (src0.x * src1.x + src0.y * src1.y + src0.z * src1.z) / (src0.x * src0.x + src0.y * src0.y + src0.z * src0.z) * src0.y - src1.y + dst.z = 2.0 * (src0.x * src1.x + src0.y * src1.y + src0.z * src1.z) / (src0.x * src0.x + src0.y * src0.y + src0.z * src0.z) * src0.z - src1.z + dst.w = 1.0 + + +1.5.16 SEQ - Set On Equal + + dst.x = (src0.x == src1.x) ? 1.0 : 0.0 + dst.y = (src0.y == src1.y) ? 1.0 : 0.0 + dst.z = (src0.z == src1.z) ? 1.0 : 0.0 + dst.w = (src0.w == src1.w) ? 1.0 : 0.0 + + +1.5.17 SFL - Set On False + + dst.x = 0.0 + dst.y = 0.0 + dst.z = 0.0 + dst.w = 0.0 + + +1.5.18 SGT - Set On Greater Than + + dst.x = (src0.x > src1.x) ? 1.0 : 0.0 + dst.y = (src0.y > src1.y) ? 1.0 : 0.0 + dst.z = (src0.z > src1.z) ? 1.0 : 0.0 + dst.w = (src0.w > src1.w) ? 1.0 : 0.0 + + +1.5.19 SIN - Sine + + dst.x = sin(src.x) + dst.y = sin(src.x) + dst.z = sin(src.x) + dst.w = sin(src.w) + + +1.5.20 SLE - Set On Less Equal Than + + dst.x = (src0.x <= src1.x) ? 1.0 : 0.0 + dst.y = (src0.y <= src1.y) ? 1.0 : 0.0 + dst.z = (src0.z <= src1.z) ? 1.0 : 0.0 + dst.w = (src0.w <= src1.w) ? 1.0 : 0.0 + + +1.5.21 SNE - Set On Not Equal + + dst.x = (src0.x != src1.x) ? 1.0 : 0.0 + dst.y = (src0.y != src1.y) ? 1.0 : 0.0 + dst.z = (src0.z != src1.z) ? 1.0 : 0.0 + dst.w = (src0.w != src1.w) ? 1.0 : 0.0 + + +1.5.22 STR - Set On True + + dst.x = 1.0 + dst.y = 1.0 + dst.z = 1.0 + dst.w = 1.0 + + +1.5.23 TEX - Texture Lookup + + TBD + + +1.5.24 TXD - Texture Lookup with Derivatives + + TBD + + +1.5.25 TXP - Projective Texture Lookup + + TBD + + +1.5.26 UP2H - Unpack Two 16-Bit Floats + + TBD + + +1.5.27 UP2US - Unpack Two Unsigned 16-Bit Scalars + + TBD + + +1.5.28 UP4B - Unpack Four Signed 8-Bit Values + + TBD + + +1.5.29 UP4UB - Unpack Four Unsigned 8-Bit Scalars + + TBD + + +1.5.30 X2D - 2D Coordinate Transformation + + dst.x = src0.x + src1.x * src2.x + src1.y * src2.y + dst.y = src0.y + src1.x * src2.z + src1.y * src2.w + dst.z = src0.x + src1.x * src2.x + src1.y * src2.y + dst.w = src0.y + src1.x * src2.z + src1.y * src2.w + + +1.6 GL_NV_vertex_program2 +-------------------------- + + +1.6.1 ARA - Address Register Add + + TBD + + +1.6.2 ARR - Address Register Load With Round + + dst.x = round(src.x) + dst.y = round(src.y) + dst.z = round(src.z) + dst.w = round(src.w) + + +1.6.3 BRA - Branch + + pc = target + + +1.6.4 CAL - Subroutine Call + + push(pc) + pc = target + + +1.6.5 RET - Subroutine Call Return + + pc = pop() + + +1.6.6 SSG - Set Sign + + dst.x = (src.x > 0.0) ? 1.0 : (src.x < 0.0) ? -1.0 : 0.0 + dst.y = (src.y > 0.0) ? 1.0 : (src.y < 0.0) ? -1.0 : 0.0 + dst.z = (src.z > 0.0) ? 1.0 : (src.z < 0.0) ? -1.0 : 0.0 + dst.w = (src.w > 0.0) ? 1.0 : (src.w < 0.0) ? -1.0 : 0.0 + + +1.7 GL_ARB_vertex_program +-------------------------- + + +1.7.1 SWZ - Extended Swizzle + + dst.x = src.x + dst.y = src.y + dst.z = src.z + dst.w = src.w + + +1.7.2 XPD - Cross Product + + Alias for CROSSPRODUCT. + + +1.8 GL_ARB_fragment_program +---------------------------- + + +1.8.1 CMP - Compare + + dst.x = (src0.x < 0.0) ? src1.x : src2.x + dst.y = (src0.y < 0.0) ? src1.y : src2.y + dst.z = (src0.z < 0.0) ? src1.z : src2.z + dst.w = (src0.w < 0.0) ? src1.w : src2.w + + +1.8.2 KIL - Conditional Discard + + if (src.x < 0.0 || src.y < 0.0 || src.z < 0.0 || src.w < 0.0) + discard + endif + + +1.8.3 SCS - Sine Cosine + + dst.x = cos(src.x) + dst.y = sin(src.x) + dst.z = 0.0 + dst.y = 1.0 + + +1.8.4 TXB - Texture Lookup With Bias + + TBD + + +1.9 GL_NV_fragment_program2 +---------------------------- + + +1.9.1 NRM - 3-component Vector Normalise + + dst.x = src.x / (src.x * src.x + src.y * src.y + src.z * src.z) + dst.y = src.y / (src.x * src.x + src.y * src.y + src.z * src.z) + dst.z = src.z / (src.x * src.x + src.y * src.y + src.z * src.z) + dst.w = 1.0 + + +1.9.2 DIV - Divide + + dst.x = src0.x / src1.x + dst.y = src0.y / src1.y + dst.z = src0.z / src1.z + dst.w = src0.w / src1.w + + +1.9.3 DP2 - 2-component Dot Product + + dst.x = src0.x * src1.x + src0.y * src1.y + dst.y = src0.x * src1.x + src0.y * src1.y + dst.z = src0.x * src1.x + src0.y * src1.y + dst.w = src0.x * src1.x + src0.y * src1.y + + +1.9.4 DP2A - 2-component Dot Product And Add + + Alias for DOT2ADD. + + +1.9.5 TXL - Texture Lookup With LOD + + TBD + + +1.9.6 BRK - Break + + TBD + + +1.9.7 IF - If + + TBD + + +1.9.8 BGNFOR - Begin a For-Loop + + dst.x = floor(src.x) + dst.y = floor(src.y) + dst.z = floor(src.z) + + if (dst.y <= 0) + pc = [matching ENDFOR] + 1 + endif + + Note: The destination must be a loop register. + The source must be a constant register. + + +1.9.9 REP - Repeat + + TBD + + +1.9.10 ELSE - Else + + TBD + + +1.9.11 ENDIF - End If + + TBD + + +1.9.12 ENDFOR - End a For-Loop + + dst.x = dst.x + dst.z + dst.y = dst.y - 1.0 + + if (dst.y > 0) + pc = [matching BGNFOR instruction] + 1 + endif + + Note: The destination must be a loop register. + + +1.9.13 ENDREP - End Repeat + + TBD + + +1.10 GL_NV_vertex_program3 +--------------------------- + + +1.10.1 PUSHA - Push Address Register On Stack + + push(src.x) + push(src.y) + push(src.z) + push(src.w) + + +1.10.2 POPA - Pop Address Register From Stack + + dst.w = pop() + dst.z = pop() + dst.y = pop() + dst.x = pop() + + +1.11 GL_NV_gpu_program4 +------------------------ + + +1.11.1 CEIL - Ceiling + + dst.x = ceil(src.x) + dst.y = ceil(src.y) + dst.z = ceil(src.z) + dst.w = ceil(src.w) + + +1.11.2 I2F - Integer To Float + + dst.x = (float) src.x + dst.y = (float) src.y + dst.z = (float) src.z + dst.w = (float) src.w + + +1.11.3 NOT - Bitwise Not + + dst.x = ~src.x + dst.y = ~src.y + dst.z = ~src.z + dst.w = ~src.w + + +1.11.4 TRUNC - Truncate + + dst.x = trunc(src.x) + dst.y = trunc(src.y) + dst.z = trunc(src.z) + dst.w = trunc(src.w) + + +1.11.5 SHL - Shift Left + + dst.x = src0.x << src1.x + dst.y = src0.y << src1.x + dst.z = src0.z << src1.x + dst.w = src0.w << src1.x + + +1.11.6 SHR - Shift Right + + dst.x = src0.x >> src1.x + dst.y = src0.y >> src1.x + dst.z = src0.z >> src1.x + dst.w = src0.w >> src1.x + + +1.11.7 AND - Bitwise And + + dst.x = src0.x & src1.x + dst.y = src0.y & src1.y + dst.z = src0.z & src1.z + dst.w = src0.w & src1.w + + +1.11.8 OR - Bitwise Or + + dst.x = src0.x | src1.x + dst.y = src0.y | src1.y + dst.z = src0.z | src1.z + dst.w = src0.w | src1.w + + +1.11.9 MOD - Modulus + + dst.x = src0.x % src1.x + dst.y = src0.y % src1.y + dst.z = src0.z % src1.z + dst.w = src0.w % src1.w + + +1.11.10 XOR - Bitwise Xor + + dst.x = src0.x ^ src1.x + dst.y = src0.y ^ src1.y + dst.z = src0.z ^ src1.z + dst.w = src0.w ^ src1.w + + +1.11.11 SAD - Sum Of Absolute Differences + + dst.x = abs(src0.x - src1.x) + src2.x + dst.y = abs(src0.y - src1.y) + src2.y + dst.z = abs(src0.z - src1.z) + src2.z + dst.w = abs(src0.w - src1.w) + src2.w + + +1.11.12 TXF - Texel Fetch + + TBD + + +1.11.13 TXQ - Texture Size Query + + TBD + + +1.11.14 CONT - Continue + + TBD + + +1.12 GL_NV_geometry_program4 +----------------------------- + + +1.12.1 EMIT - Emit + + TBD + + +1.12.2 ENDPRIM - End Primitive + + TBD + + +1.13 GLSL +---------- + + +1.13.1 BGNLOOP - Begin a Loop + + TBD + + +1.13.2 BGNSUB - Begin Subroutine + + TBD + + +1.13.3 ENDLOOP - End a Loop + + TBD + + +1.13.4 ENDSUB - End Subroutine + + TBD + + +1.13.5 INT - Truncate + + Alias for TRUNC. + + +1.13.6 NOISE1 - 1D Noise + + TBD + + +1.13.7 NOISE2 - 2D Noise + + TBD + + +1.13.8 NOISE3 - 3D Noise + + TBD + + +1.13.9 NOISE4 - 4D Noise + + TBD + + +1.13.10 NOP - No Operation + + Do nothing. + + +1.14 ps_1_1 +------------ + + +1.14.1 TEXKILL - Conditional Discard + + Alias for KIL. + + +1.15 ps_1_4 +------------ + + +1.15.1 TEXLD - Texture Lookup + + Alias for TEX. + + +1.16 ps_2_0 +------------ + + +1.16.1 M4X4 - Multiply Matrix + + Alias for MULTIPLYMATRIX. + + +1.16.2 M4X3 - Multiply Matrix + + Considered for removal from language. + + +1.16.3 M3X4 - Multiply Matrix + + Considered for removal from language. + + +1.16.4 M3X3 - Multiply Matrix + + Considered for removal from language. + + +1.16.5 M3X2 - Multiply Matrix + + Considered for removal from language. + + +1.16.6 CRS - Cross Product + + Alias for XPD. + + +1.16.7 NRM4 - 4-component Vector Normalise + + dst.x = src.x / (src.x * src.x + src.y * src.y + src.z * src.z + src.w * src.w) + dst.y = src.y / (src.x * src.x + src.y * src.y + src.z * src.z + src.w * src.w) + dst.z = src.z / (src.x * src.x + src.y * src.y + src.z * src.z + src.w * src.w) + dst.w = src.w / (src.x * src.x + src.y * src.y + src.z * src.z + src.w * src.w) + + +1.16.8 SINCOS - Sine Cosine + + Alias for SCS. + + +1.16.9 TEXLDB - Texture Lookup With Bias + + Alias for TXB. + + +1.16.10 DP2ADD - 2-component Dot Product And Add + + Alias for DP2A. + + +1.17 ps_2_x +------------ + + +1.17.1 CALL - Subroutine Call + + Alias for CAL. + + +1.17.2 CALLNZ - Subroutine Call If Not Zero + + TBD + + +1.17.3 IFC - If + + TBD + + +1.17.4 BREAK - Break + + Alias for BRK. + + +1.17.5 BREAKC - Break Conditional + + TBD + + +1.17.6 DSX - Derivative Relative To X + + Alias for DDX. + + +1.17.7 DSY - Derivative Relative To Y + + Alias for DDY. + + +1.17.8 TEXLDD - Texture Lookup with Derivatives + + Alias for TXD. + + +1.18 vs_1_1 +------------ + + +1.18.1 EXPP - Approximate Exponential Base 2 + + Use EXP. See also 1.19.3. + + +1.18.2 LOGP - Logarithm Base 2 + + Use LOG. See also 1.19.4. + + +1.19 vs_2_0 +------------ + + +1.19.1 SGN - Set Sign + + Alias for SSG. + + +1.19.2 MOVA - Move Address Register + + Alias for ARR. + + +1.19.3 EXPP - Approximate Exponential Base 2 + + Use EX2. + + +1.19.4 LOGP - Logarithm Base 2 + + Use LG2. + + +2 Explanation of symbols used +============================== + + +2.1 Functions +-------------- + + + abs(x) Absolute value of x. + |x| + (x < 0.0) ? -x : x + + ceil(x) Ceiling of x. + + clamp(x,y,z) Clamp x between y and z. + (x < y) ? y : (x > z) ? z : x + + cos(x) Cosine of x. + + floor(x) Floor of x. + + lg2(x) Logarithm base 2 of x. + + max(x,y) Maximum of x and y. + (x > y) ? x : y + + min(x,y) Minimum of x and y. + (x < y) ? x : y + + partialx(x) Derivative of x relative to fragment's X. + + partialy(x) Derivative of x relative to fragment's Y. + + pop() Pop from stack. + + pow(x,y) Raise x to power of y. + + push(x) Push x on stack. + + round(x) Round x. + + sin(x) Sine of x. + + sqrt(x) Square root of x. + + trunc(x) Truncate x. + + +2.2 Keywords +------------- + + + discard Discard fragment. + + dst First destination register. + + dst0 First destination register. + + pc Program counter. + + src First source register. + + src0 First source register. + + src1 Second source register. + + src2 Third source register. + + target Label of target instruction. + + +3 Other tokens +=============== + + +3.1 Declaration Semantic +------------------------- + + + Follows Declaration token if Semantic bit is set. + + Since its purpose is to link a shader with other stages of the pipeline, + it is valid to follow only those Declaration tokens that declare a register + either in INPUT or OUTPUT file. + + SemanticName field contains the semantic name of the register being declared. + There is no default value. + + SemanticIndex is an optional subscript that can be used to distinguish + different register declarations with the same semantic name. The default value + is 0. + + The meanings of the individual semantic names are explained in the following + sections. + + +3.1.1 FACE + + Valid only in a fragment shader INPUT declaration. + + FACE.x is negative when the primitive is back facing. FACE.x is positive + when the primitive is front facing. --- mesa-7.8.2.orig/src/gallium/docs/make.bat +++ mesa-7.8.2/src/gallium/docs/make.bat @@ -0,0 +1,113 @@ +@ECHO OFF + +REM Command file for Sphinx documentation + +set SPHINXBUILD=sphinx-build +set BUILDDIR=build +set ALLSPHINXOPTS=-d %BUILDDIR%/doctrees %SPHINXOPTS% source +if NOT "%PAPER%" == "" ( + set ALLSPHINXOPTS=-D latex_paper_size=%PAPER% %ALLSPHINXOPTS% +) + +if "%1" == "" goto help + +if "%1" == "help" ( + :help + echo.Please use `make ^` where ^ is one of + echo. html to make standalone HTML files + echo. dirhtml to make HTML files named index.html in directories + echo. pickle to make pickle files + echo. json to make JSON files + echo. htmlhelp to make HTML files and a HTML help project + echo. qthelp to make HTML files and a qthelp project + echo. latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter + echo. changes to make an overview over all changed/added/deprecated items + echo. linkcheck to check all external links for integrity + echo. doctest to run all doctests embedded in the documentation if enabled + goto end +) + +if "%1" == "clean" ( + for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i + del /q /s %BUILDDIR%\* + goto end +) + +if "%1" == "html" ( + %SPHINXBUILD% -b html %ALLSPHINXOPTS% %BUILDDIR%/html + echo. + echo.Build finished. The HTML pages are in %BUILDDIR%/html. + goto end +) + +if "%1" == "dirhtml" ( + %SPHINXBUILD% -b dirhtml %ALLSPHINXOPTS% %BUILDDIR%/dirhtml + echo. + echo.Build finished. The HTML pages are in %BUILDDIR%/dirhtml. + goto end +) + +if "%1" == "pickle" ( + %SPHINXBUILD% -b pickle %ALLSPHINXOPTS% %BUILDDIR%/pickle + echo. + echo.Build finished; now you can process the pickle files. + goto end +) + +if "%1" == "json" ( + %SPHINXBUILD% -b json %ALLSPHINXOPTS% %BUILDDIR%/json + echo. + echo.Build finished; now you can process the JSON files. + goto end +) + +if "%1" == "htmlhelp" ( + %SPHINXBUILD% -b htmlhelp %ALLSPHINXOPTS% %BUILDDIR%/htmlhelp + echo. + echo.Build finished; now you can run HTML Help Workshop with the ^ +.hhp project file in %BUILDDIR%/htmlhelp. + goto end +) + +if "%1" == "qthelp" ( + %SPHINXBUILD% -b qthelp %ALLSPHINXOPTS% %BUILDDIR%/qthelp + echo. + echo.Build finished; now you can run "qcollectiongenerator" with the ^ +.qhcp project file in %BUILDDIR%/qthelp, like this: + echo.^> qcollectiongenerator %BUILDDIR%\qthelp\Gallium.qhcp + echo.To view the help file: + echo.^> assistant -collectionFile %BUILDDIR%\qthelp\Gallium.ghc + goto end +) + +if "%1" == "latex" ( + %SPHINXBUILD% -b latex %ALLSPHINXOPTS% %BUILDDIR%/latex + echo. + echo.Build finished; the LaTeX files are in %BUILDDIR%/latex. + goto end +) + +if "%1" == "changes" ( + %SPHINXBUILD% -b changes %ALLSPHINXOPTS% %BUILDDIR%/changes + echo. + echo.The overview file is in %BUILDDIR%/changes. + goto end +) + +if "%1" == "linkcheck" ( + %SPHINXBUILD% -b linkcheck %ALLSPHINXOPTS% %BUILDDIR%/linkcheck + echo. + echo.Link check complete; look for any errors in the above output ^ +or in %BUILDDIR%/linkcheck/output.txt. + goto end +) + +if "%1" == "doctest" ( + %SPHINXBUILD% -b doctest %ALLSPHINXOPTS% %BUILDDIR%/doctest + echo. + echo.Testing of doctests in the sources finished, look at the ^ +results in %BUILDDIR%/doctest/output.txt. + goto end +) + +:end --- mesa-7.8.2.orig/src/gallium/docs/source/cso.rst +++ mesa-7.8.2/src/gallium/docs/source/cso.rst @@ -0,0 +1,14 @@ +CSO +=== + +CSO, Constant State Objects, are a core part of Gallium's API. + +CSO work on the principle of reusable state; they are created by filling +out a state object with the desired properties, then passing that object +to a context. The context returns an opaque context-specific handle which +can be bound at any time for the desired effect. + +.. toctree:: + :glob: + + cso/* --- mesa-7.8.2.orig/src/gallium/docs/source/index.rst +++ mesa-7.8.2/src/gallium/docs/source/index.rst @@ -0,0 +1,28 @@ +.. Gallium documentation master file, created by + sphinx-quickstart on Sun Dec 20 14:09:05 2009. + You can adapt this file completely to your liking, but it should at least + contain the root `toctree` directive. + +Welcome to Gallium's documentation! +=================================== + +Contents: + +.. toctree:: + :maxdepth: 2 + + intro + tgsi + screen + context + cso + distro + glossary + +Indices and tables +================== + +* :ref:`genindex` +* :ref:`modindex` +* :ref:`search` + --- mesa-7.8.2.orig/src/gallium/docs/source/intro.rst +++ mesa-7.8.2/src/gallium/docs/source/intro.rst @@ -0,0 +1,9 @@ +Introduction +============ + +What is Gallium? +---------------- + +Gallium is essentially an API for writing graphics drivers in a largely +device-agnostic fashion. It provides several objects which encapsulate the +core services of graphics hardware in a straightforward manner. --- mesa-7.8.2.orig/src/gallium/docs/source/context.rst +++ mesa-7.8.2/src/gallium/docs/source/context.rst @@ -0,0 +1,232 @@ +Context +======= + +The context object represents the purest, most directly accessible, abilities +of the device's 3D rendering pipeline. + +Methods +------- + +CSO State +^^^^^^^^^ + +All CSO state is created, bound, and destroyed, with triplets of methods that +all follow a specific naming scheme. For example, ``create_blend_state``, +``bind_blend_state``, and ``destroy_blend_state``. + +CSO objects handled by the context object: + +* :ref:`Blend`: ``*_blend_state`` +* :ref:`Sampler`: These are special; they can be bound to either vertex or + fragment samplers, and they are bound in groups. + ``bind_fragment_sampler_states``, ``bind_vertex_sampler_states`` +* :ref:`Rasterizer`: ``*_rasterizer_state`` +* :ref:`Depth, Stencil, & Alpha`: ``*_depth_stencil_alpha_state`` +* :ref:`Shader`: These have two sets of methods. ``*_fs_state`` is for + fragment shaders, and ``*_vs_state`` is for vertex shaders. + + +Resource Binding State +^^^^^^^^^^^^^^^^^^^^^^ + +This state describes how resources in various flavours (textures, +buffers, surfaces) are bound to the driver. + + +* ``set_constant_buffer`` sets a constant buffer to be used for a given shader + type. index is used to indicate which buffer to set (some apis may allow + multiple ones to be set, and binding a specific one later, though drivers + are mostly restricted to the first one right now). + +* ``set_framebuffer_state`` +* ``set_fragment_sampler_textures`` +* ``set_vertex_sampler_textures`` +* ``set_vertex_buffers`` + + +Non-CSO State +^^^^^^^^^^^^^ + +These pieces of state are too small, variable, and/or trivial to have CSO +objects. They all follow simple, one-method binding calls, e.g. +``set_blend_color``. +* ``set_stencil_ref`` sets the stencil front and back reference values + which are used as comparison values in stencil test. +* ``set_blend_color`` +* ``set_clip_state`` +* ``set_polygon_stipple`` +* ``set_scissor_state`` sets the bounds for the scissor test, which culls + pixels before blending to render targets. If the :ref:`Rasterizer` does + not have the scissor test enabled, then the scissor bounds never need to + be set since they will not be used. +* ``set_viewport_state`` +* ``set_vertex_elements`` + + +Clearing +^^^^^^^^ + +``clear`` initializes some or all of the surfaces currently bound to +the framebuffer to particular RGBA, depth, or stencil values. + +Clear is one of the most difficult concepts to nail down to a single +interface and it seems likely that we will want to add additional +clear paths, for instance clearing surfaces not bound to the +framebuffer, or read-modify-write clears such as depth-only or +stencil-only clears of packed depth-stencil buffers. + + +Drawing +^^^^^^^ + +``draw_arrays`` draws a specified primitive. + +This command is equivalent to calling ``draw_arrays_instanced`` +with ``startInstance`` set to 0 and ``instanceCount`` set to 1. + +``draw_elements`` draws a specified primitive using an optional +index buffer. + +This command is equivalent to calling ``draw_elements_instanced`` +with ``startInstance`` set to 0 and ``instanceCount`` set to 1. + +``draw_range_elements`` + +XXX: this is (probably) a temporary entrypoint, as the range +information should be available from the vertex_buffer state. +Using this to quickly evaluate a specialized path in the draw +module. + +``draw_arrays_instanced`` draws multiple instances of the same primitive. + +This command is equivalent to calling ``draw_elements_instanced`` +with ``indexBuffer`` set to NULL and ``indexSize`` set to 0. + +``draw_elements_instanced`` draws multiple instances of the same primitive +using an optional index buffer. + +For instanceID in the range between ``startInstance`` +and ``startInstance``+``instanceCount``-1, inclusive, draw a primitive +specified by ``mode`` and sequential numbers in the range between ``start`` +and ``start``+``count``-1, inclusive. + +If ``indexBuffer`` is not NULL, it specifies an index buffer with index +byte size of ``indexSize``. The sequential numbers are used to lookup +the index buffer and the resulting indices in turn are used to fetch +vertex attributes. + +If ``indexBuffer`` is NULL, the sequential numbers are used directly +as indices to fetch vertex attributes. + +If a given vertex element has ``instance_divisor`` set to 0, it is said +it contains per-vertex data and effective vertex attribute address needs +to be recalculated for every index. + + attribAddr = ``stride`` * index + ``src_offset`` + +If a given vertex element has ``instance_divisor`` set to non-zero, +it is said it contains per-instance data and effective vertex attribute +address needs to recalculated for every ``instance_divisor``-th instance. + + attribAddr = ``stride`` * instanceID / ``instance_divisor`` + ``src_offset`` + +In the above formulas, ``src_offset`` is taken from the given vertex element +and ``stride`` is taken from a vertex buffer associated with the given +vertex element. + +The calculated attribAddr is used as an offset into the vertex buffer to +fetch the attribute data. + +The value of ``instanceID`` can be read in a vertex shader through a system +value register declared with INSTANCEID semantic name. + + +Queries +^^^^^^^ + +Queries gather some statistic from the 3D pipeline over one or more +draws. Queries may be nested, though no state tracker currently +exercises this. + +Queries can be created with ``create_query`` and deleted with +``destroy_query``. To start a query, use ``begin_query``, and when finished, +use ``end_query`` to end the query. + +``get_query_result`` is used to retrieve the results of a query. If +the ``wait`` parameter is TRUE, then the ``get_query_result`` call +will block until the results of the query are ready (and TRUE will be +returned). Otherwise, if the ``wait`` parameter is FALSE, the call +will not block and the return value will be TRUE if the query has +completed or FALSE otherwise. + +A common type of query is the occlusion query which counts the number of +fragments/pixels which are written to the framebuffer (and not culled by +Z/stencil/alpha testing or shader KILL instructions). + + +Conditional Rendering +^^^^^^^^^^^^^^^^^^^^^ + +A drawing command can be skipped depending on the outcome of a query +(typically an occlusion query). The ``render_condition`` function specifies +the query which should be checked prior to rendering anything. + +If ``render_condition`` is called with ``query`` = NULL, conditional +rendering is disabled and drawing takes place normally. + +If ``render_condition`` is called with a non-null ``query`` subsequent +drawing commands will be predicated on the outcome of the query. If +the query result is zero subsequent drawing commands will be skipped. + +If ``mode`` is PIPE_RENDER_COND_WAIT the driver will wait for the +query to complete before deciding whether to render. + +If ``mode`` is PIPE_RENDER_COND_NO_WAIT and the query has not yet +completed, the drawing command will be executed normally. If the query +has completed, drawing will be predicated on the outcome of the query. + +If ``mode`` is PIPE_RENDER_COND_BY_REGION_WAIT or +PIPE_RENDER_COND_BY_REGION_NO_WAIT rendering will be predicated as above +for the non-REGION modes but in the case that an occulusion query returns +a non-zero result, regions which were occluded may be ommitted by subsequent +drawing commands. This can result in better performance with some GPUs. +Normally, if the occlusion query returned a non-zero result subsequent +drawing happens normally so fragments may be generated, shaded and +processed even where they're known to be obscured. + + +Flushing +^^^^^^^^ + +``flush`` + + +Resource Busy Queries +^^^^^^^^^^^^^^^^^^^^^ + +``is_texture_referenced`` + +``is_buffer_referenced`` + + + +Blitting +^^^^^^^^ + +These methods emulate classic blitter controls. They are not guaranteed to be +available; if they are set to NULL, then they are not present. + +These methods operate directly on ``pipe_surface`` objects, and stand +apart from any 3D state in the context. Blitting functionality may be +moved to a separate abstraction at some point in the future. + +``surface_fill`` performs a fill operation on a section of a surface. + +``surface_copy`` blits a region of a surface to a region of another surface, +provided that both surfaces are the same format. The source and destination +may be the same surface, and overlapping blits are permitted. + +The interfaces to these calls are likely to change to make it easier +for a driver to batch multiple blits with the same source and +destination. + --- mesa-7.8.2.orig/src/gallium/docs/source/distro.rst +++ mesa-7.8.2/src/gallium/docs/source/distro.rst @@ -0,0 +1,153 @@ +Distribution +============ + +Along with the interface definitions, the following drivers, state trackers, +and auxiliary modules are shipped in the standard Gallium distribution. + +Drivers +------- + +Cell +^^^^ + +Failover +^^^^^^^^ + +Deprecated. + +Intel i915 +^^^^^^^^^^ + +Intel i965 +^^^^^^^^^^ + +Highly experimental. + +Identity +^^^^^^^^ + +Wrapper driver. + +LLVM Softpipe +^^^^^^^^^^^^^ + +nVidia nv30 +^^^^^^^^^^^ + +nVidia nv40 +^^^^^^^^^^^ + +nVidia nv50 +^^^^^^^^^^^ + +VMWare SVGA +^^^^^^^^^^^ + +ATI r300 +^^^^^^^^ + +Testing-quality. + +Softpipe +^^^^^^^^ + +Reference software rasterizer. + +Trace +^^^^^ + +Wrapper driver. + +State Trackers +-------------- + +Direct Rendering Infrastructure +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +EGL +^^^ + +GLX +^^^ + +MesaGL +^^^^^^ + +Python +^^^^^^ + +OpenVG +^^^^^^ + +WGL +^^^ + +Xorg XFree86 DDX +^^^^^^^^^^^^^^^^ + +Auxiliary +--------- + +OS +^^ + +The OS module contains the abstractions for basic operating system services: + +* memory allocation +* simple message logging +* obtaining run-time configuration option +* threading primitives + +This is the bare minimum required to port Gallium to a new platform. + +The OS module already provides the implementations of these abstractions for +the most common platforms. When targeting an embedded platform no +implementation will be provided -- these must be provided separately. + +CSO Cache +^^^^^^^^^ + +The CSO cache is used to accelerate preparation of state by saving +driver-specific state structures for later use. + +.. _draw: + +Draw +^^^^ + +Draw is a software :term:`TCL` pipeline for hardware that lacks vertex shaders +or other essential parts of pre-rasterization vertex preparation. + +Gallivm +^^^^^^^ + +Indices +^^^^^^^ + +Indices provides tools for translating or generating element indices for +use with element-based rendering. + +Pipe Buffer Managers +^^^^^^^^^^^^^^^^^^^^ + +Each of these managers provides various services to drivers that are not +fully utilizing a memory manager. + +Remote Debugger +^^^^^^^^^^^^^^^ + +Runtime Assembly Emission +^^^^^^^^^^^^^^^^^^^^^^^^^ + +TGSI +^^^^ + +The TGSI auxiliary module provides basic utilities for manipulating TGSI +streams. + +Translate +^^^^^^^^^ + +Util +^^^^ + --- mesa-7.8.2.orig/src/gallium/docs/source/glossary.rst +++ mesa-7.8.2/src/gallium/docs/source/glossary.rst @@ -0,0 +1,23 @@ +Glossary +======== + +.. glossary:: + :sorted: + + MSAA + Multi-Sampled Anti-Aliasing. A basic anti-aliasing technique that takes + multiple samples of the depth buffer, and uses this information to + smooth the edges of polygons. + + TCL + Transform, Clipping, & Lighting. The three stages of preparation in a + rasterizing pipeline prior to the actual rasterization of vertices into + fragments. + + NPOT + Non-power-of-two. Usually applied to textures which have at least one + dimension which is not a power of two. + + LOD + Level of Detail. Also spelled "LoD." The value that determines when the + switches between mipmaps occur during texture sampling. --- mesa-7.8.2.orig/src/gallium/docs/source/screen.rst +++ mesa-7.8.2/src/gallium/docs/source/screen.rst @@ -0,0 +1,281 @@ +Screen +====== + +A screen is an object representing the context-independent part of a device. + +Useful Flags +------------ + +.. _pipe_cap: + +PIPE_CAP +^^^^^^^^ + +Pipe capabilities help expose hardware functionality not explicitly required +by Gallium. For floating-point values, use :ref:`get_paramf`, and for boolean +or integer values, use :ref:`get_param`. + +The integer capabilities: + +* ``MAX_TEXTURE_IMAGE_UNITS``: The maximum number of samplers available. +* ``NPOT_TEXTURES``: Whether :term:`NPOT` textures may have repeat modes, + normalized coordinates, and mipmaps. +* ``TWO_SIDED_STENCIL``: Whether the stencil test can also affect back-facing + polygons. +* ``GLSL``: Deprecated. +* ``DUAL_SOURCE_BLEND``: Whether dual-source blend factors are supported. See + :ref:`Blend` for more information. +* ``ANISOTROPIC_FILTER``: Whether textures can be filtered anisotropically. +* ``POINT_SPRITE``: Whether point sprites are available. +* ``MAX_RENDER_TARGETS``: The maximum number of render targets that may be + bound. +* ``OCCLUSION_QUERY``: Whether occlusion queries are available. +* ``TEXTURE_SHADOW_MAP``: XXX +* ``MAX_TEXTURE_2D_LEVELS``: The maximum number of mipmap levels available + for a 2D texture. +* ``MAX_TEXTURE_3D_LEVELS``: The maximum number of mipmap levels available + for a 3D texture. +* ``MAX_TEXTURE_CUBE_LEVELS``: The maximum number of mipmap levels available + for a cubemap. +* ``TEXTURE_MIRROR_CLAMP``: Whether mirrored texture coordinates with clamp + are supported. +* ``TEXTURE_MIRROR_REPEAT``: Whether mirrored repeating texture coordinates + are supported. +* ``MAX_VERTEX_TEXTURE_UNITS``: The maximum number of samplers addressable + inside the vertex shader. If this is 0, then the vertex shader cannot + sample textures. +* ``TGSI_CONT_SUPPORTED``: Whether the TGSI CONT opcode is supported. +* ``BLEND_EQUATION_SEPARATE``: Whether alpha blend equations may be different + from color blend equations, in :ref:`Blend` state. +* ``SM3``: Whether the vertex shader and fragment shader support equivalent + opcodes to the Shader Model 3 specification. XXX oh god this is horrible +* ``MAX_PREDICATE_REGISTERS``: XXX +* ``MAX_COMBINED_SAMPLERS``: The total number of samplers accessible from + the vertex and fragment shader, inclusive. +* ``MAX_CONST_BUFFERS``: Maximum number of constant buffers that can be bound + to any shader stage using ``set_constant_buffer``. If 0 or 1, the pipe will + only permit binding one constant buffer per shader, and the shaders will + not permit two-dimensional access to constants. +* ``MAX_CONST_BUFFER_SIZE``: Maximum byte size of a single constant buffer. +* ``INDEP_BLEND_ENABLE``: Whether per-rendertarget blend enabling and channel + masks are supported. If 0, then the first rendertarget's blend mask is + replicated across all MRTs. +* ``INDEP_BLEND_FUNC``: Whether per-rendertarget blend functions are + available. If 0, then the first rendertarget's blend functions affect all + MRTs. +* ``PIPE_CAP_TGSI_FS_COORD_ORIGIN_UPPER_LEFT``: Whether the TGSI property + FS_COORD_ORIGIN with value UPPER_LEFT is supported. +* ``PIPE_CAP_TGSI_FS_COORD_ORIGIN_LOWER_LEFT``: Whether the TGSI property + FS_COORD_ORIGIN with value LOWER_LEFT is supported. +* ``PIPE_CAP_TGSI_FS_COORD_PIXEL_CENTER_HALF_INTEGER``: Whether the TGSI + property FS_COORD_PIXEL_CENTER with value HALF_INTEGER is supported. +* ``PIPE_CAP_TGSI_FS_COORD_PIXEL_CENTER_INTEGER``: Whether the TGSI + property FS_COORD_PIXEL_CENTER with value INTEGER is supported. + +The floating-point capabilities: + +* ``MAX_LINE_WIDTH``: The maximum width of a regular line. +* ``MAX_LINE_WIDTH_AA``: The maximum width of a smoothed line. +* ``MAX_POINT_WIDTH``: The maximum width and height of a point. +* ``MAX_POINT_WIDTH_AA``: The maximum width and height of a smoothed point. +* ``MAX_TEXTURE_ANISOTROPY``: The maximum level of anisotropy that can be + applied to anisotropically filtered textures. +* ``MAX_TEXTURE_LOD_BIAS``: The maximum :term:`LOD` bias that may be applied + to filtered textures. +* ``GUARD_BAND_LEFT``, ``GUARD_BAND_TOP``, ``GUARD_BAND_RIGHT``, + ``GUARD_BAND_BOTTOM``: XXX + +XXX Is there a better home for this? vvv + +If 0 is returned, the driver is not aware of multiple constant buffers, +supports binding of only one constant buffer, and does not support +two-dimensional CONST register file access in TGSI shaders. + +If a value greater than 0 is returned, the driver can have multiple +constant buffers bound to shader stages. The CONST register file can +be accessed with two-dimensional indices, like in the example below. + +DCL CONST[0][0..7] # declare first 8 vectors of constbuf 0 +DCL CONST[3][0] # declare first vector of constbuf 3 +MOV OUT[0], CONST[0][3] # copy vector 3 of constbuf 0 + +For backwards compatibility, one-dimensional access to CONST register +file is still supported. In that case, the constbuf index is assumed +to be 0. + +.. _pipe_buffer_usage: + +PIPE_BUFFER_USAGE +^^^^^^^^^^^^^^^^^ + +These flags control buffer creation. Buffers may only have one role, so +care should be taken to not allocate a buffer with the wrong usage. + +* ``PIXEL``: This is the flag to use for all textures. +* ``VERTEX``: A vertex buffer. +* ``INDEX``: An element buffer. +* ``CONSTANT``: A buffer of shader constants. + +Buffers are inevitably abstracting the pipe's underlying memory management, +so many of their usage flags can be used to direct the way the buffer is +handled. + +* ``CPU_READ``, ``CPU_WRITE``: Whether the user will map and, in the case of + the latter, write to, the buffer. The convenience flag ``CPU_READ_WRITE`` is + available to signify a read/write buffer. +* ``GPU_READ``, ``GPU_WRITE``: Whether the driver will internally need to + read from or write to the buffer. The latter will only happen if the buffer + is made into a render target. +* ``DISCARD``: When set on a map, the contents of the map will be discarded + beforehand. Cannot be used with ``CPU_READ``. +* ``DONTBLOCK``: When set on a map, the map will fail if the buffer cannot be + mapped immediately. +* ``UNSYNCHRONIZED``: When set on a map, any outstanding operations on the + buffer will be ignored. The interaction of any writes to the map and any + operations pending with the buffer are undefined. Cannot be used with + ``CPU_READ``. +* ``FLUSH_EXPLICIT``: When set on a map, written ranges of the map require + explicit flushes using :ref:`buffer_flush_mapped_range`. Requires + ``CPU_WRITE``. + +.. _pipe_texture_usage: + +PIPE_TEXTURE_USAGE +^^^^^^^^^^^^^^^^^^ + +These flags determine the possible roles a texture may be used for during its +lifetime. Texture usage flags are cumulative and may be combined to create a +texture that can be used as multiple things. + +* ``RENDER_TARGET``: A color buffer or pixel buffer which will be rendered to. +* ``DISPLAY_TARGET``: A sharable buffer that can be given to another process. +* ``PRIMARY``: A front color buffer or scanout buffer. +* ``DEPTH_STENCIL``: A depth (Z) buffer or stencil buffer. Gallium does + not explicitly provide for stencil-only buffers, so any stencil buffer + validated here is implicitly also a depth buffer. +* ``SAMPLER``: A texture that may be sampled from in a fragment or vertex + shader. +* ``DYNAMIC``: A texture that will be mapped frequently. + + +PIPE_TEXTURE_GEOM +^^^^^^^^^^^^^^^^^ + +These flags are used when querying whether a particular pipe_format is +supported by the driver (with the `is_format_supported` function). +Some formats may only be supported for certain kinds of textures. +For example, a compressed format might only be used for POT textures. + +* ``PIPE_TEXTURE_GEOM_NON_SQUARE``: The texture may not be square +* ``PIPE_TEXTURE_GEOM_NON_POWER_OF_TWO``: The texture dimensions may not be + powers of two. + + +Methods +------- + +XXX moar; got bored + +get_name +^^^^^^^^ + +Returns an identifying name for the screen. + +get_vendor +^^^^^^^^^^ + +Returns the screen vendor. + +.. _get_param: + +get_param +^^^^^^^^^ + +Get an integer/boolean screen parameter. + +**param** is one of the :ref:`PIPE_CAP` names. + +.. _get_paramf: + +get_paramf +^^^^^^^^^^ + +Get a floating-point screen parameter. + +**param** is one of the :ref:`PIPE_CAP` names. + +context_create +^^^^^^^^^^^^^^ + +Create a pipe_context. + +**priv** is private data of the caller, which may be put to various +unspecified uses, typically to do with implementing swapbuffers +and/or front-buffer rendering. + +is_format_supported +^^^^^^^^^^^^^^^^^^^ + +See if a format can be used in a specific manner. + +**usage** is a bitmask of :ref:`PIPE_TEXTURE_USAGE` flags. + +Returns TRUE if all usages can be satisfied. + +.. note:: + + ``PIPE_TEXTURE_USAGE_DYNAMIC`` is not a valid usage. + +.. _texture_create: + +texture_create +^^^^^^^^^^^^^^ + +Given a template of texture setup, create a buffer and texture. + +texture_blanket +^^^^^^^^^^^^^^^ + +Like :ref:`texture_create`, but use a supplied buffer instead of creating a +new one. + +texture_destroy +^^^^^^^^^^^^^^^ + +Destroy a texture. The buffer backing the texture is destroyed if it has no +more references. + +buffer_map +^^^^^^^^^^ + +Map a buffer into memory. + +**usage** is a bitmask of :ref:`PIPE_BUFFER_USAGE` flags. + +Returns a pointer to the map, or NULL if the mapping failed. + +buffer_map_range +^^^^^^^^^^^^^^^^ + +Map a range of a buffer into memory. + +The returned map is always relative to the beginning of the buffer, not the +beginning of the mapped range. + +.. _buffer_flush_mapped_range: + +buffer_flush_mapped_range +^^^^^^^^^^^^^^^^^^^^^^^^^ + +Flush a range of mapped memory into a buffer. + +The buffer must have been mapped with ``PIPE_BUFFER_USAGE_FLUSH_EXPLICIT``. + +**usage** is a bitmask of :ref:`PIPE_BUFFER_USAGE` flags. + +buffer_unmap +^^^^^^^^^^^^ + +Unmap a buffer from memory. + +Any pointers into the map should be considered invalid and discarded. --- mesa-7.8.2.orig/src/gallium/docs/source/tgsi.rst +++ mesa-7.8.2/src/gallium/docs/source/tgsi.rst @@ -0,0 +1,1499 @@ +TGSI +==== + +TGSI, Tungsten Graphics Shader Infrastructure, is an intermediate language +for describing shaders. Since Gallium is inherently shaderful, shaders are +an important part of the API. TGSI is the only intermediate representation +used by all drivers. + +Basics +------ + +All TGSI instructions, known as *opcodes*, operate on arbitrary-precision +floating-point four-component vectors. An opcode may have up to one +destination register, known as *dst*, and between zero and three source +registers, called *src0* through *src2*, or simply *src* if there is only +one. + +Some instructions, like :opcode:`I2F`, permit re-interpretation of vector +components as integers. Other instructions permit using registers as +two-component vectors with double precision; see :ref:`Double Opcodes`. + +When an instruction has a scalar result, the result is usually copied into +each of the components of *dst*. When this happens, the result is said to be +*replicated* to *dst*. :opcode:`RCP` is one such instruction. + +Instruction Set +--------------- + +From GL_NV_vertex_program +^^^^^^^^^^^^^^^^^^^^^^^^^ + + +.. opcode:: ARL - Address Register Load + +.. math:: + + dst.x = \lfloor src.x\rfloor + + dst.y = \lfloor src.y\rfloor + + dst.z = \lfloor src.z\rfloor + + dst.w = \lfloor src.w\rfloor + + +.. opcode:: MOV - Move + +.. math:: + + dst.x = src.x + + dst.y = src.y + + dst.z = src.z + + dst.w = src.w + + +.. opcode:: LIT - Light Coefficients + +.. math:: + + dst.x = 1 + + dst.y = max(src.x, 0) + + dst.z = (src.x > 0) ? max(src.y, 0)^{clamp(src.w, -128, 128))} : 0 + + dst.w = 1 + + +.. opcode:: RCP - Reciprocal + +This instruction replicates its result. + +.. math:: + + dst = \frac{1}{src.x} + + +.. opcode:: RSQ - Reciprocal Square Root + +This instruction replicates its result. + +.. math:: + + dst = \frac{1}{\sqrt{|src.x|}} + + +.. opcode:: EXP - Approximate Exponential Base 2 + +.. math:: + + dst.x = 2^{\lfloor src.x\rfloor} + + dst.y = src.x - \lfloor src.x\rfloor + + dst.z = 2^{src.x} + + dst.w = 1 + + +.. opcode:: LOG - Approximate Logarithm Base 2 + +.. math:: + + dst.x = \lfloor\log_2{|src.x|}\rfloor + + dst.y = \frac{|src.x|}{2^{\lfloor\log_2{|src.x|}\rfloor}} + + dst.z = \log_2{|src.x|} + + dst.w = 1 + + +.. opcode:: MUL - Multiply + +.. math:: + + dst.x = src0.x \times src1.x + + dst.y = src0.y \times src1.y + + dst.z = src0.z \times src1.z + + dst.w = src0.w \times src1.w + + +.. opcode:: ADD - Add + +.. math:: + + dst.x = src0.x + src1.x + + dst.y = src0.y + src1.y + + dst.z = src0.z + src1.z + + dst.w = src0.w + src1.w + + +.. opcode:: DP3 - 3-component Dot Product + +This instruction replicates its result. + +.. math:: + + dst = src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z + + +.. opcode:: DP4 - 4-component Dot Product + +This instruction replicates its result. + +.. math:: + + dst = src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z + src0.w \times src1.w + + +.. opcode:: DST - Distance Vector + +.. math:: + + dst.x = 1 + + dst.y = src0.y \times src1.y + + dst.z = src0.z + + dst.w = src1.w + + +.. opcode:: MIN - Minimum + +.. math:: + + dst.x = min(src0.x, src1.x) + + dst.y = min(src0.y, src1.y) + + dst.z = min(src0.z, src1.z) + + dst.w = min(src0.w, src1.w) + + +.. opcode:: MAX - Maximum + +.. math:: + + dst.x = max(src0.x, src1.x) + + dst.y = max(src0.y, src1.y) + + dst.z = max(src0.z, src1.z) + + dst.w = max(src0.w, src1.w) + + +.. opcode:: SLT - Set On Less Than + +.. math:: + + dst.x = (src0.x < src1.x) ? 1 : 0 + + dst.y = (src0.y < src1.y) ? 1 : 0 + + dst.z = (src0.z < src1.z) ? 1 : 0 + + dst.w = (src0.w < src1.w) ? 1 : 0 + + +.. opcode:: SGE - Set On Greater Equal Than + +.. math:: + + dst.x = (src0.x >= src1.x) ? 1 : 0 + + dst.y = (src0.y >= src1.y) ? 1 : 0 + + dst.z = (src0.z >= src1.z) ? 1 : 0 + + dst.w = (src0.w >= src1.w) ? 1 : 0 + + +.. opcode:: MAD - Multiply And Add + +.. math:: + + dst.x = src0.x \times src1.x + src2.x + + dst.y = src0.y \times src1.y + src2.y + + dst.z = src0.z \times src1.z + src2.z + + dst.w = src0.w \times src1.w + src2.w + + +.. opcode:: SUB - Subtract + +.. math:: + + dst.x = src0.x - src1.x + + dst.y = src0.y - src1.y + + dst.z = src0.z - src1.z + + dst.w = src0.w - src1.w + + +.. opcode:: LRP - Linear Interpolate + +.. math:: + + dst.x = src0.x \times src1.x + (1 - src0.x) \times src2.x + + dst.y = src0.y \times src1.y + (1 - src0.y) \times src2.y + + dst.z = src0.z \times src1.z + (1 - src0.z) \times src2.z + + dst.w = src0.w \times src1.w + (1 - src0.w) \times src2.w + + +.. opcode:: CND - Condition + +.. math:: + + dst.x = (src2.x > 0.5) ? src0.x : src1.x + + dst.y = (src2.y > 0.5) ? src0.y : src1.y + + dst.z = (src2.z > 0.5) ? src0.z : src1.z + + dst.w = (src2.w > 0.5) ? src0.w : src1.w + + +.. opcode:: DP2A - 2-component Dot Product And Add + +.. math:: + + dst.x = src0.x \times src1.x + src0.y \times src1.y + src2.x + + dst.y = src0.x \times src1.x + src0.y \times src1.y + src2.x + + dst.z = src0.x \times src1.x + src0.y \times src1.y + src2.x + + dst.w = src0.x \times src1.x + src0.y \times src1.y + src2.x + + +.. opcode:: FRAC - Fraction + +.. math:: + + dst.x = src.x - \lfloor src.x\rfloor + + dst.y = src.y - \lfloor src.y\rfloor + + dst.z = src.z - \lfloor src.z\rfloor + + dst.w = src.w - \lfloor src.w\rfloor + + +.. opcode:: CLAMP - Clamp + +.. math:: + + dst.x = clamp(src0.x, src1.x, src2.x) + + dst.y = clamp(src0.y, src1.y, src2.y) + + dst.z = clamp(src0.z, src1.z, src2.z) + + dst.w = clamp(src0.w, src1.w, src2.w) + + +.. opcode:: FLR - Floor + +This is identical to :opcode:`ARL`. + +.. math:: + + dst.x = \lfloor src.x\rfloor + + dst.y = \lfloor src.y\rfloor + + dst.z = \lfloor src.z\rfloor + + dst.w = \lfloor src.w\rfloor + + +.. opcode:: ROUND - Round + +.. math:: + + dst.x = round(src.x) + + dst.y = round(src.y) + + dst.z = round(src.z) + + dst.w = round(src.w) + + +.. opcode:: EX2 - Exponential Base 2 + +This instruction replicates its result. + +.. math:: + + dst = 2^{src.x} + + +.. opcode:: LG2 - Logarithm Base 2 + +This instruction replicates its result. + +.. math:: + + dst = \log_2{src.x} + + +.. opcode:: POW - Power + +This instruction replicates its result. + +.. math:: + + dst = src0.x^{src1.x} + +.. opcode:: XPD - Cross Product + +.. math:: + + dst.x = src0.y \times src1.z - src1.y \times src0.z + + dst.y = src0.z \times src1.x - src1.z \times src0.x + + dst.z = src0.x \times src1.y - src1.x \times src0.y + + dst.w = 1 + + +.. opcode:: ABS - Absolute + +.. math:: + + dst.x = |src.x| + + dst.y = |src.y| + + dst.z = |src.z| + + dst.w = |src.w| + + +.. opcode:: RCC - Reciprocal Clamped + +This instruction replicates its result. + +XXX cleanup on aisle three + +.. math:: + + dst = (1 / src.x) > 0 ? clamp(1 / src.x, 5.42101e-020, 1.884467e+019) : clamp(1 / src.x, -1.884467e+019, -5.42101e-020) + + +.. opcode:: DPH - Homogeneous Dot Product + +This instruction replicates its result. + +.. math:: + + dst = src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z + src1.w + + +.. opcode:: COS - Cosine + +This instruction replicates its result. + +.. math:: + + dst = \cos{src.x} + + +.. opcode:: DDX - Derivative Relative To X + +.. math:: + + dst.x = partialx(src.x) + + dst.y = partialx(src.y) + + dst.z = partialx(src.z) + + dst.w = partialx(src.w) + + +.. opcode:: DDY - Derivative Relative To Y + +.. math:: + + dst.x = partialy(src.x) + + dst.y = partialy(src.y) + + dst.z = partialy(src.z) + + dst.w = partialy(src.w) + + +.. opcode:: KILP - Predicated Discard + + discard + + +.. opcode:: PK2H - Pack Two 16-bit Floats + + TBD + + +.. opcode:: PK2US - Pack Two Unsigned 16-bit Scalars + + TBD + + +.. opcode:: PK4B - Pack Four Signed 8-bit Scalars + + TBD + + +.. opcode:: PK4UB - Pack Four Unsigned 8-bit Scalars + + TBD + + +.. opcode:: RFL - Reflection Vector + +.. math:: + + dst.x = 2 \times (src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z) / (src0.x \times src0.x + src0.y \times src0.y + src0.z \times src0.z) \times src0.x - src1.x + + dst.y = 2 \times (src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z) / (src0.x \times src0.x + src0.y \times src0.y + src0.z \times src0.z) \times src0.y - src1.y + + dst.z = 2 \times (src0.x \times src1.x + src0.y \times src1.y + src0.z \times src1.z) / (src0.x \times src0.x + src0.y \times src0.y + src0.z \times src0.z) \times src0.z - src1.z + + dst.w = 1 + +.. note:: + + Considered for removal. + + +.. opcode:: SEQ - Set On Equal + +.. math:: + + dst.x = (src0.x == src1.x) ? 1 : 0 + + dst.y = (src0.y == src1.y) ? 1 : 0 + + dst.z = (src0.z == src1.z) ? 1 : 0 + + dst.w = (src0.w == src1.w) ? 1 : 0 + + +.. opcode:: SFL - Set On False + +This instruction replicates its result. + +.. math:: + + dst = 0 + +.. note:: + + Considered for removal. + + +.. opcode:: SGT - Set On Greater Than + +.. math:: + + dst.x = (src0.x > src1.x) ? 1 : 0 + + dst.y = (src0.y > src1.y) ? 1 : 0 + + dst.z = (src0.z > src1.z) ? 1 : 0 + + dst.w = (src0.w > src1.w) ? 1 : 0 + + +.. opcode:: SIN - Sine + +This instruction replicates its result. + +.. math:: + + dst = \sin{src.x} + + +.. opcode:: SLE - Set On Less Equal Than + +.. math:: + + dst.x = (src0.x <= src1.x) ? 1 : 0 + + dst.y = (src0.y <= src1.y) ? 1 : 0 + + dst.z = (src0.z <= src1.z) ? 1 : 0 + + dst.w = (src0.w <= src1.w) ? 1 : 0 + + +.. opcode:: SNE - Set On Not Equal + +.. math:: + + dst.x = (src0.x != src1.x) ? 1 : 0 + + dst.y = (src0.y != src1.y) ? 1 : 0 + + dst.z = (src0.z != src1.z) ? 1 : 0 + + dst.w = (src0.w != src1.w) ? 1 : 0 + + +.. opcode:: STR - Set On True + +This instruction replicates its result. + +.. math:: + + dst = 1 + + +.. opcode:: TEX - Texture Lookup + + TBD + + +.. opcode:: TXD - Texture Lookup with Derivatives + + TBD + + +.. opcode:: TXP - Projective Texture Lookup + + TBD + + +.. opcode:: UP2H - Unpack Two 16-Bit Floats + + TBD + +.. note:: + + Considered for removal. + +.. opcode:: UP2US - Unpack Two Unsigned 16-Bit Scalars + + TBD + +.. note:: + + Considered for removal. + +.. opcode:: UP4B - Unpack Four Signed 8-Bit Values + + TBD + +.. note:: + + Considered for removal. + +.. opcode:: UP4UB - Unpack Four Unsigned 8-Bit Scalars + + TBD + +.. note:: + + Considered for removal. + +.. opcode:: X2D - 2D Coordinate Transformation + +.. math:: + + dst.x = src0.x + src1.x \times src2.x + src1.y \times src2.y + + dst.y = src0.y + src1.x \times src2.z + src1.y \times src2.w + + dst.z = src0.x + src1.x \times src2.x + src1.y \times src2.y + + dst.w = src0.y + src1.x \times src2.z + src1.y \times src2.w + +.. note:: + + Considered for removal. + + +From GL_NV_vertex_program2 +^^^^^^^^^^^^^^^^^^^^^^^^^^ + + +.. opcode:: ARA - Address Register Add + + TBD + +.. note:: + + Considered for removal. + +.. opcode:: ARR - Address Register Load With Round + +.. math:: + + dst.x = round(src.x) + + dst.y = round(src.y) + + dst.z = round(src.z) + + dst.w = round(src.w) + + +.. opcode:: BRA - Branch + + pc = target + +.. note:: + + Considered for removal. + +.. opcode:: CAL - Subroutine Call + + push(pc) + pc = target + + +.. opcode:: RET - Subroutine Call Return + + pc = pop() + + Potential restrictions: + * Only occurs at end of function. + +.. opcode:: SSG - Set Sign + +.. math:: + + dst.x = (src.x > 0) ? 1 : (src.x < 0) ? -1 : 0 + + dst.y = (src.y > 0) ? 1 : (src.y < 0) ? -1 : 0 + + dst.z = (src.z > 0) ? 1 : (src.z < 0) ? -1 : 0 + + dst.w = (src.w > 0) ? 1 : (src.w < 0) ? -1 : 0 + + +.. opcode:: CMP - Compare + +.. math:: + + dst.x = (src0.x < 0) ? src1.x : src2.x + + dst.y = (src0.y < 0) ? src1.y : src2.y + + dst.z = (src0.z < 0) ? src1.z : src2.z + + dst.w = (src0.w < 0) ? src1.w : src2.w + + +.. opcode:: KIL - Conditional Discard + +.. math:: + + if (src.x < 0 || src.y < 0 || src.z < 0 || src.w < 0) + discard + endif + + +.. opcode:: SCS - Sine Cosine + +.. math:: + + dst.x = \cos{src.x} + + dst.y = \sin{src.x} + + dst.z = 0 + + dst.y = 1 + + +.. opcode:: TXB - Texture Lookup With Bias + + TBD + + +.. opcode:: NRM - 3-component Vector Normalise + +.. math:: + + dst.x = src.x / (src.x \times src.x + src.y \times src.y + src.z \times src.z) + + dst.y = src.y / (src.x \times src.x + src.y \times src.y + src.z \times src.z) + + dst.z = src.z / (src.x \times src.x + src.y \times src.y + src.z \times src.z) + + dst.w = 1 + + +.. opcode:: DIV - Divide + +.. math:: + + dst.x = \frac{src0.x}{src1.x} + + dst.y = \frac{src0.y}{src1.y} + + dst.z = \frac{src0.z}{src1.z} + + dst.w = \frac{src0.w}{src1.w} + + +.. opcode:: DP2 - 2-component Dot Product + +This instruction replicates its result. + +.. math:: + + dst = src0.x \times src1.x + src0.y \times src1.y + + +.. opcode:: TXL - Texture Lookup With LOD + + TBD + + +.. opcode:: BRK - Break + + TBD + + +.. opcode:: IF - If + + TBD + + +.. opcode:: BGNFOR - Begin a For-Loop + + dst.x = floor(src.x) + dst.y = floor(src.y) + dst.z = floor(src.z) + + if (dst.y <= 0) + pc = [matching ENDFOR] + 1 + endif + + Note: The destination must be a loop register. + The source must be a constant register. + +.. note:: + + Considered for cleanup. + +.. note:: + + Considered for removal. + + +.. opcode:: REP - Repeat + + TBD + + +.. opcode:: ELSE - Else + + TBD + + +.. opcode:: ENDIF - End If + + TBD + + +.. opcode:: ENDFOR - End a For-Loop + + dst.x = dst.x + dst.z + dst.y = dst.y - 1.0 + + if (dst.y > 0) + pc = [matching BGNFOR instruction] + 1 + endif + + Note: The destination must be a loop register. + +.. note:: + + Considered for cleanup. + +.. note:: + + Considered for removal. + +.. opcode:: ENDREP - End Repeat + + TBD + + +.. opcode:: PUSHA - Push Address Register On Stack + + push(src.x) + push(src.y) + push(src.z) + push(src.w) + +.. note:: + + Considered for cleanup. + +.. note:: + + Considered for removal. + +.. opcode:: POPA - Pop Address Register From Stack + + dst.w = pop() + dst.z = pop() + dst.y = pop() + dst.x = pop() + +.. note:: + + Considered for cleanup. + +.. note:: + + Considered for removal. + + +From GL_NV_gpu_program4 +^^^^^^^^^^^^^^^^^^^^^^^^ + +Support for these opcodes indicated by a special pipe capability bit (TBD). + +.. opcode:: CEIL - Ceiling + +.. math:: + + dst.x = \lceil src.x\rceil + + dst.y = \lceil src.y\rceil + + dst.z = \lceil src.z\rceil + + dst.w = \lceil src.w\rceil + + +.. opcode:: I2F - Integer To Float + +.. math:: + + dst.x = (float) src.x + + dst.y = (float) src.y + + dst.z = (float) src.z + + dst.w = (float) src.w + + +.. opcode:: NOT - Bitwise Not + +.. math:: + + dst.x = ~src.x + + dst.y = ~src.y + + dst.z = ~src.z + + dst.w = ~src.w + + +.. opcode:: TRUNC - Truncate + +.. math:: + + dst.x = trunc(src.x) + + dst.y = trunc(src.y) + + dst.z = trunc(src.z) + + dst.w = trunc(src.w) + + +.. opcode:: SHL - Shift Left + +.. math:: + + dst.x = src0.x << src1.x + + dst.y = src0.y << src1.x + + dst.z = src0.z << src1.x + + dst.w = src0.w << src1.x + + +.. opcode:: SHR - Shift Right + +.. math:: + + dst.x = src0.x >> src1.x + + dst.y = src0.y >> src1.x + + dst.z = src0.z >> src1.x + + dst.w = src0.w >> src1.x + + +.. opcode:: AND - Bitwise And + +.. math:: + + dst.x = src0.x & src1.x + + dst.y = src0.y & src1.y + + dst.z = src0.z & src1.z + + dst.w = src0.w & src1.w + + +.. opcode:: OR - Bitwise Or + +.. math:: + + dst.x = src0.x | src1.x + + dst.y = src0.y | src1.y + + dst.z = src0.z | src1.z + + dst.w = src0.w | src1.w + + +.. opcode:: MOD - Modulus + +.. math:: + + dst.x = src0.x \bmod src1.x + + dst.y = src0.y \bmod src1.y + + dst.z = src0.z \bmod src1.z + + dst.w = src0.w \bmod src1.w + + +.. opcode:: XOR - Bitwise Xor + +.. math:: + + dst.x = src0.x \oplus src1.x + + dst.y = src0.y \oplus src1.y + + dst.z = src0.z \oplus src1.z + + dst.w = src0.w \oplus src1.w + + +.. opcode:: SAD - Sum Of Absolute Differences + +.. math:: + + dst.x = |src0.x - src1.x| + src2.x + + dst.y = |src0.y - src1.y| + src2.y + + dst.z = |src0.z - src1.z| + src2.z + + dst.w = |src0.w - src1.w| + src2.w + + +.. opcode:: TXF - Texel Fetch + + TBD + + +.. opcode:: TXQ - Texture Size Query + + TBD + + +.. opcode:: CONT - Continue + + TBD + + +From GL_NV_geometry_program4 +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + + +.. opcode:: EMIT - Emit + + TBD + + +.. opcode:: ENDPRIM - End Primitive + + TBD + + +From GLSL +^^^^^^^^^^ + + +.. opcode:: BGNLOOP - Begin a Loop + + TBD + + +.. opcode:: BGNSUB - Begin Subroutine + + TBD + + +.. opcode:: ENDLOOP - End a Loop + + TBD + + +.. opcode:: ENDSUB - End Subroutine + + TBD + + +.. opcode:: NOP - No Operation + + Do nothing. + + +.. opcode:: NRM4 - 4-component Vector Normalise + +This instruction replicates its result. + +.. math:: + + dst = \frac{src.x}{src.x \times src.x + src.y \times src.y + src.z \times src.z + src.w \times src.w} + + +ps_2_x +^^^^^^^^^^^^ + + +.. opcode:: CALLNZ - Subroutine Call If Not Zero + + TBD + + +.. opcode:: IFC - If + + TBD + + +.. opcode:: BREAKC - Break Conditional + + TBD + +.. _doubleopcodes: + +Double Opcodes +^^^^^^^^^^^^^^^ + +.. opcode:: DADD - Add Double + +.. math:: + + dst.xy = src0.xy + src1.xy + + dst.zw = src0.zw + src1.zw + + +.. opcode:: DDIV - Divide Double + +.. math:: + + dst.xy = src0.xy / src1.xy + + dst.zw = src0.zw / src1.zw + +.. opcode:: DSEQ - Set Double on Equal + +.. math:: + + dst.xy = src0.xy == src1.xy ? 1.0F : 0.0F + + dst.zw = src0.zw == src1.zw ? 1.0F : 0.0F + +.. opcode:: DSLT - Set Double on Less than + +.. math:: + + dst.xy = src0.xy < src1.xy ? 1.0F : 0.0F + + dst.zw = src0.zw < src1.zw ? 1.0F : 0.0F + +.. opcode:: DFRAC - Double Fraction + +.. math:: + + dst.xy = src.xy - \lfloor src.xy\rfloor + + dst.zw = src.zw - \lfloor src.zw\rfloor + + +.. opcode:: DFRACEXP - Convert Double Number to Fractional and Integral Components + +.. math:: + + dst0.xy = frexp(src.xy, dst1.xy) + + dst0.zw = frexp(src.zw, dst1.zw) + +.. opcode:: DLDEXP - Multiple Double Number by Integral Power of 2 + +.. math:: + + dst.xy = ldexp(src0.xy, src1.xy) + + dst.zw = ldexp(src0.zw, src1.zw) + +.. opcode:: DMIN - Minimum Double + +.. math:: + + dst.xy = min(src0.xy, src1.xy) + + dst.zw = min(src0.zw, src1.zw) + +.. opcode:: DMAX - Maximum Double + +.. math:: + + dst.xy = max(src0.xy, src1.xy) + + dst.zw = max(src0.zw, src1.zw) + +.. opcode:: DMUL - Multiply Double + +.. math:: + + dst.xy = src0.xy \times src1.xy + + dst.zw = src0.zw \times src1.zw + + +.. opcode:: DMAD - Multiply And Add Doubles + +.. math:: + + dst.xy = src0.xy \times src1.xy + src2.xy + + dst.zw = src0.zw \times src1.zw + src2.zw + + +.. opcode:: DRCP - Reciprocal Double + +.. math:: + + dst.xy = \frac{1}{src.xy} + + dst.zw = \frac{1}{src.zw} + +.. opcode:: DSQRT - Square root double + +.. math:: + + dst.xy = \sqrt{src.xy} + + dst.zw = \sqrt{src.zw} + + +Explanation of symbols used +------------------------------ + + +Functions +^^^^^^^^^^^^^^ + + + :math:`|x|` Absolute value of `x`. + + :math:`\lceil x \rceil` Ceiling of `x`. + + clamp(x,y,z) Clamp x between y and z. + (x < y) ? y : (x > z) ? z : x + + :math:`\lfloor x\rfloor` Floor of `x`. + + :math:`\log_2{x}` Logarithm of `x`, base 2. + + max(x,y) Maximum of x and y. + (x > y) ? x : y + + min(x,y) Minimum of x and y. + (x < y) ? x : y + + partialx(x) Derivative of x relative to fragment's X. + + partialy(x) Derivative of x relative to fragment's Y. + + pop() Pop from stack. + + :math:`x^y` `x` to the power `y`. + + push(x) Push x on stack. + + round(x) Round x. + + trunc(x) Truncate x, i.e. drop the fraction bits. + + +Keywords +^^^^^^^^^^^^^ + + + discard Discard fragment. + + pc Program counter. + + target Label of target instruction. + + +Other tokens +--------------- + + +Declaration +^^^^^^^^^^^ + + +Declares a register that is will be referenced as an operand in Instruction +tokens. + +File field contains register file that is being declared and is one +of TGSI_FILE. + +UsageMask field specifies which of the register components can be accessed +and is one of TGSI_WRITEMASK. + +Interpolate field is only valid for fragment shader INPUT register files. +It specifes the way input is being interpolated by the rasteriser and is one +of TGSI_INTERPOLATE. + +If Dimension flag is set to 1, a Declaration Dimension token follows. + +If Semantic flag is set to 1, a Declaration Semantic token follows. + +CylindricalWrap bitfield is only valid for fragment shader INPUT register +files. It specifies which register components should be subject to cylindrical +wrapping when interpolating by the rasteriser. If TGSI_CYLINDRICAL_WRAP_X +is set to 1, the X component should be interpolated according to cylindrical +wrapping rules. + + +Declaration Semantic +^^^^^^^^^^^^^^^^^^^^^^^^ + + + Follows Declaration token if Semantic bit is set. + + Since its purpose is to link a shader with other stages of the pipeline, + it is valid to follow only those Declaration tokens that declare a register + either in INPUT or OUTPUT file. + + SemanticName field contains the semantic name of the register being declared. + There is no default value. + + SemanticIndex is an optional subscript that can be used to distinguish + different register declarations with the same semantic name. The default value + is 0. + + The meanings of the individual semantic names are explained in the following + sections. + +TGSI_SEMANTIC_POSITION +"""""""""""""""""""""" + +Position, sometimes known as HPOS or WPOS for historical reasons, is the +location of the vertex in space, in ``(x, y, z, w)`` format. ``x``, ``y``, and ``z`` +are the Cartesian coordinates, and ``w`` is the homogenous coordinate and used +for the perspective divide, if enabled. + +As a vertex shader output, position should be scaled to the viewport. When +used in fragment shaders, position will be in window coordinates. The convention +used depends on the FS_COORD_ORIGIN and FS_COORD_PIXEL_CENTER properties. + +XXX additionally, is there a way to configure the perspective divide? it's +accelerated on most chipsets AFAIK... + +Position, if not specified, usually defaults to ``(0, 0, 0, 1)``, and can +be partially specified as ``(x, y, 0, 1)`` or ``(x, y, z, 1)``. + +XXX usually? can we solidify that? + +TGSI_SEMANTIC_COLOR +""""""""""""""""""" + +Colors are used to, well, color the primitives. Colors are always in +``(r, g, b, a)`` format. + +If alpha is not specified, it defaults to 1. + +TGSI_SEMANTIC_BCOLOR +"""""""""""""""""""" + +Back-facing colors are only used for back-facing polygons, and are only valid +in vertex shader outputs. After rasterization, all polygons are front-facing +and COLOR and BCOLOR end up occupying the same slots in the fragment, so +all BCOLORs effectively become regular COLORs in the fragment shader. + +TGSI_SEMANTIC_FOG +""""""""""""""""" + +The fog coordinate historically has been used to replace the depth coordinate +for generation of fog in dedicated fog blocks. Gallium, however, does not use +dedicated fog acceleration, placing it entirely in the fragment shader +instead. + +The fog coordinate should be written in ``(f, 0, 0, 1)`` format. Only the first +component matters when writing from the vertex shader; the driver will ensure +that the coordinate is in this format when used as a fragment shader input. + +TGSI_SEMANTIC_PSIZE +""""""""""""""""""" + +PSIZE, or point size, is used to specify point sizes per-vertex. It should +be in ``(s, 0, 0, 1)`` format, where ``s`` is the (possibly clamped) point size. +Only the first component matters when writing from the vertex shader. + +When using this semantic, be sure to set the appropriate state in the +:ref:`rasterizer` first. + +TGSI_SEMANTIC_GENERIC +""""""""""""""""""""" + +Generic semantics are nearly always used for texture coordinate attributes, +in ``(s, t, r, q)`` format. ``t`` and ``r`` may be unused for certain kinds +of lookups, and ``q`` is the level-of-detail bias for biased sampling. + +These attributes are called "generic" because they may be used for anything +else, including parameters, texture generation information, or anything that +can be stored inside a four-component vector. + +TGSI_SEMANTIC_NORMAL +"""""""""""""""""""" + +Vertex normal; could be used to implement per-pixel lighting for legacy APIs +that allow mixing fixed-function and programmable stages. + +TGSI_SEMANTIC_FACE +"""""""""""""""""" + +FACE is the facing bit, to store the facing information for the fragment +shader. ``(f, 0, 0, 1)`` is the format. The first component will be positive +when the fragment is front-facing, and negative when the component is +back-facing. + +TGSI_SEMANTIC_EDGEFLAG +"""""""""""""""""""""" + +XXX no clue + + +Properties +^^^^^^^^^^^^^^^^^^^^^^^^ + + + Properties are general directives that apply to the whole TGSI program. + +FS_COORD_ORIGIN +""""""""""""""" + +Specifies the fragment shader TGSI_SEMANTIC_POSITION coordinate origin. +The default value is UPPER_LEFT. + +If UPPER_LEFT, the position will be (0,0) at the upper left corner and +increase downward and rightward. +If LOWER_LEFT, the position will be (0,0) at the lower left corner and +increase upward and rightward. + +OpenGL defaults to LOWER_LEFT, and is configurable with the +GL_ARB_fragment_coord_conventions extension. + +DirectX 9/10 use UPPER_LEFT. + +FS_COORD_PIXEL_CENTER +""""""""""""""""""""" + +Specifies the fragment shader TGSI_SEMANTIC_POSITION pixel center convention. +The default value is HALF_INTEGER. + +If HALF_INTEGER, the fractionary part of the position will be 0.5 +If INTEGER, the fractionary part of the position will be 0.0 + +Note that this does not affect the set of fragments generated by +rasterization, which is instead controlled by gl_rasterization_rules in the +rasterizer. + +OpenGL defaults to HALF_INTEGER, and is configurable with the +GL_ARB_fragment_coord_conventions extension. + +DirectX 9 uses INTEGER. +DirectX 10 uses HALF_INTEGER. + + + +Texture Sampling and Texture Formats +------------------------------------ + +This table shows how texture image components are returned as (x,y,z,w) tuples +by TGSI texture instructions, such as :opcode:`TEX`, :opcode:`TXD`, and +:opcode:`TXP`. For reference, OpenGL and Direct3D conventions are shown as +well. + ++--------------------+--------------+--------------------+--------------+ +| Texture Components | Gallium | OpenGL | Direct3D 9 | ++====================+==============+====================+==============+ +| R | XXX TBD | (r, 0, 0, 1) | (r, 1, 1, 1) | ++--------------------+--------------+--------------------+--------------+ +| RG | XXX TBD | (r, g, 0, 1) | (r, g, 1, 1) | ++--------------------+--------------+--------------------+--------------+ +| RGB | (r, g, b, 1) | (r, g, b, 1) | (r, g, b, 1) | ++--------------------+--------------+--------------------+--------------+ +| RGBA | (r, g, b, a) | (r, g, b, a) | (r, g, b, a) | ++--------------------+--------------+--------------------+--------------+ +| A | (0, 0, 0, a) | (0, 0, 0, a) | (0, 0, 0, a) | ++--------------------+--------------+--------------------+--------------+ +| L | (l, l, l, 1) | (l, l, l, 1) | (l, l, l, 1) | ++--------------------+--------------+--------------------+--------------+ +| LA | (l, l, l, a) | (l, l, l, a) | (l, l, l, a) | ++--------------------+--------------+--------------------+--------------+ +| I | (i, i, i, i) | (i, i, i, i) | N/A | ++--------------------+--------------+--------------------+--------------+ +| UV | XXX TBD | (0, 0, 0, 1) | (u, v, 1, 1) | +| | | [#envmap-bumpmap]_ | | ++--------------------+--------------+--------------------+--------------+ +| Z | XXX TBD | (z, z, z, 1) | (0, z, 0, 1) | +| | | [#depth-tex-mode]_ | | ++--------------------+--------------+--------------------+--------------+ + +.. [#envmap-bumpmap] http://www.opengl.org/registry/specs/ATI/envmap_bumpmap.txt +.. [#depth-tex-mode] the default is (z, z, z, 1) but may also be (0, 0, 0, z) + or (z, z, z, z) depending on the value of GL_DEPTH_TEXTURE_MODE. --- mesa-7.8.2.orig/src/gallium/drivers/llvmpipe/README +++ mesa-7.8.2/src/gallium/drivers/llvmpipe/README @@ -0,0 +1,150 @@ +LLVMPIPE -- a fork of softpipe that employs LLVM for code generation. + + +Status +====== + +Done so far is: + + - the whole fragment pipeline is code generated in a single function + + - input interpolation + + - depth testing + + - texture sampling (not all state/formats are supported) + + - fragment shader TGSI translation + - same level of support as the TGSI SSE2 exec machine, with the exception + we don't fallback to TGSI interpretation when an unsupported opcode is + found, but just ignore it + - done in SoA layout + - input interpolation also code generated + + - alpha testing + + - blend (including logic ops) + - both in SoA and AoS layouts, but only the former used for now + + - code is generic + - intermediates can be vectors of floats, ubytes, fixed point, etc, and of + any width and length + - not all operations are implemented for these types yet though + +Most mesa/progs/demos/* work. + +To do (probably by this order): + + - code generate stipple and stencil testing + + - translate the remaining bits of texture sampling state + + - translate TGSI control flow instructions, and all other remaining opcodes + + - integrate with the draw module for VS code generation + + - code generate the triangle setup and rasterization + + +Requirements +============ + + - A x86 or amd64 processor. 64bit mode is preferred. + + Support for sse2 is strongly encouraged. Support for ssse3, and sse4.1 will + yield the most efficient code. The less features the CPU has the more + likely is that you ran into underperforming, buggy, or incomplete code. + + See /proc/cpuinfo to know what your CPU supports. + + - LLVM 2.6. + + For Linux, on a recent Debian based distribution do: + + aptitude install llvm-dev + + For Windows download pre-built MSVC 9.0 or MinGW binaries from + http://people.freedesktop.org/~jrfonseca/llvm/ and set the LLVM environment + variable to the extracted path. + + - scons (optional) + + - udis86, http://udis86.sourceforge.net/ (optional): + + git clone git://udis86.git.sourceforge.net/gitroot/udis86/udis86 + cd udis86 + ./autogen.sh + ./configure --with-pic + make + sudo make install + + +Building +======== + +To build everything on Linux invoke scons as: + + scons debug=yes statetrackers=mesa drivers=llvmpipe winsys=xlib dri=false + +Alternatively, you can build it with GNU make, if you prefer, by invoking it as + + make linux-llvm + +but the rest of these instructions assume that scons is used. + +For windows is everything the except except the winsys: + + scons debug=yes statetrackers=mesa drivers=llvmpipe winsys=gdi dri=false + +Using +===== + +On Linux, building will create a drop-in alternative for libGL.so. To use it +set the environment variables: + + export LD_LIBRARY_PATH=$PWD/build/linux-x86_64-debug/lib:$LD_LIBRARY_PATH + +or + + export LD_LIBRARY_PATH=$PWD/build/linux-x86-debug/lib:$LD_LIBRARY_PATH + +For performance evaluation pass debug=no to scons, and use the corresponding +lib directory without the "-debug" suffix. + +On Windows, building will create a drop-in alternative for opengl32.dll. To use +it put it in the same directory as the application. It can also be used by +replacing the native ICD driver, but it's quite an advanced usage, so if you +need to ask, don't even try it. + + +Unit testing +============ + +Building will also create several unit tests in +build/linux-???-debug/gallium/drivers/llvmpipe: + + - lp_test_blend: blending + - lp_test_conv: SIMD vector conversion + - lp_test_format: pixel unpacking/packing + +Some of this tests can output results and benchmarks to a tab-separated-file +for posterior analysis, e.g.: + + build/linux-x86_64-debug/gallium/drivers/llvmpipe/lp_test_blend -o blend.tsv + + +Development Notes +================= + +- When looking to this code by the first time start in lp_state_fs.c, and + then skim through the lp_bld_* functions called in there, and the comments + at the top of the lp_bld_*.c functions. + +- All lp_bld_*.[ch] are isolated from the rest of the driver, and could/may be + put in a stand-alone Gallium state -> LLVM IR translation module. + +- We use LLVM-C bindings for now. They are not documented, but follow the C++ + interfaces very closely, and appear to be complete enough for code + generation. See + http://npcontemplation.blogspot.com/2008/06/secret-of-llvm-c-bindings.html + for a stand-alone example. --- mesa-7.8.2.orig/src/gallium/drivers/llvmpipe/sp2lp.sh +++ mesa-7.8.2/src/gallium/drivers/llvmpipe/sp2lp.sh @@ -0,0 +1,34 @@ +#!/bin/sh +# +# Port changes from softpipe to llvmpipe. Invoke as +# +# sp2lp.sh +# +# Note that this will only affect llvmpipe -- you still need to actually +# cherry-pick/merge the softpipe changes themselves if they affect directories +# outside src/gallium/drivers/softpipe + +git format-patch \ + --keep-subject \ + --relative=src/gallium/drivers/softpipe \ + --src-prefix=a/src/gallium/drivers/llvmpipe/ \ + --dst-prefix=b/src/gallium/drivers/llvmpipe/ \ + --stdout "$1^1..$1" \ +| sed \ + -e 's/\/llvmpipe/g' \ + -e 's/\/lp/g' \ + -e 's/\/lpt/g' \ + -e 's/\/lps/g' \ + -e 's/\/lpfs/g' \ + -e 's/\/lptex/g' \ + -e 's/\/llvmpipe_\0/g' \ + -e 's/\/llvmpipe_cached_tex_tile/g' \ + -e 's/_get_cached_tile_tex\>/_get_cached_tex_tile/g' \ + -e 's/\/TEX_TILE_SIZE/g' \ + -e 's/\/tex_tile_address/g' \ + -e 's/\data\.color\>/tile->color/g' \ +| patch -p1 --- mesa-7.8.2.orig/src/gallium/drivers/svga/include/README +++ mesa-7.8.2/src/gallium/drivers/svga/include/README @@ -0,0 +1,3 @@ +This directory contains the headers from the VMware SVGA Device Developer Kit: + + https://vmware-svga.svn.sourceforge.net/svnroot/vmware-svga/trunk/lib/vmware/ --- mesa-7.8.2.orig/src/gallium/drivers/trace/trace.xsl +++ mesa-7.8.2/src/gallium/drivers/trace/trace.xsl @@ -0,0 +1,188 @@ + + + + + + + + + + + + + + Gallium Trace + + + +
    + +
+ + +
+ + +
  • + + + + + + :: + + + ( + + ) + +
  • +
    + + + + = + + + , + + + + + = + + + + + + + + + + + + ... + + + + + + " + + + + " + + + + + { + + } + + + + + + , + + + + + + NULL + + + + + + + + + + + + + + + + + + + + +
    + + + +
    + + + +
    +
    + + + + + + + + + + + + + + + + + + + + +
    --- mesa-7.8.2.orig/src/gallium/drivers/trace/README +++ mesa-7.8.2/src/gallium/drivers/trace/README @@ -0,0 +1,77 @@ + TRACE PIPE DRIVER + + += About = + +This directory contains a Gallium3D debugger pipe driver. +It can traces all incoming calls and/or provide remote debugging functionality. + + += Build Instructions = + +To build, invoke scons on the top dir as + + scons dri=no statetrackers=mesa drivers=softpipe,i965simple,trace winsys=xlib + + += Usage = + +To use do + + export LD_LIBRARY_PATH=$PWD/build/linux-x86-debug/lib + +ensure the right libGL.so is being picked by doing + + ldd progs/trivial/tri + +== Tracing == + +For tracing then do + + GALLIUM_TRACE=tri.trace progs/trivial/tri + +which should create a tri.trace file, which is an XML file. You can view copying +trace.xsl to the same directory, and opening with a XSLT capable browser such as +Firefox or Internet Explorer. + +== Remote debugging == + +For remote debugging + + export XMESA_TRACE=y + GALLIUM_RBUG=true progs/trivial/tri + +which should open gallium remote debugging session. While the program is running +you can launch the small remote debugging application from progs/rbug. More +information is in that directory. + += Integrating = + +You can integrate the trace pipe driver either inside the state tracker or the +winsys. The procedure on both cases is the same. Let's assume you have a +pipe_screen and a pipe_context pair obtained by the usual means (variable and +function names are just for illustration purposes): + + real_screen = real_screen_create(...); + + real_context = real_context_create(...); + +The trace screen and pipe_context is then created by doing + + trace_screen = trace_screen_create(real_screen); + + trace_context = trace_context_create(trace_screen, real_context); + +You can then simply use trace_screen and trace_context instead of real_screen +and real_context. + +Do not call trace_winsys_create. Simply pass trace_screen->winsys or +trace_context->winsys in places you would pass winsys. + +You can create as many contexts you wish. Just ensure that you don't mistake +trace_screen with real_screen when creating them. + + +-- +Jose Fonseca +Jakob Bornecrantz --- mesa-7.8.2.orig/src/gallium/state_trackers/README +++ mesa-7.8.2/src/gallium/state_trackers/README @@ -0,0 +1,2 @@ +This directory is a placeholder for incubating state-trackers. Mesa's +state-tracker is in src/mesa. --- mesa-7.8.2.orig/src/gallium/state_trackers/egl/x11/glxinit.c +++ mesa-7.8.2/src/gallium/state_trackers/egl/x11/glxinit.c @@ -16,6 +16,8 @@ #include "glxinit.h" +#ifdef GLX_DIRECT_RENDERING + typedef struct GLXGenericGetString { CARD8 reqType; @@ -680,3 +682,5 @@ return dpyPriv; } + +#endif /* GLX_DIRECT_RENDERING */ --- mesa-7.8.2.orig/src/gallium/state_trackers/egl/x11/native_dri2.c +++ mesa-7.8.2/src/gallium/state_trackers/egl/x11/native_dri2.c @@ -37,6 +37,8 @@ #include "native_x11.h" #include "x11_screen.h" +#ifdef GLX_DIRECT_RENDERING + enum dri2_surface_type { DRI2_SURFACE_TYPE_WINDOW, DRI2_SURFACE_TYPE_PIXMAP, @@ -878,3 +880,15 @@ return &dri2dpy->base; } + +#else /* GLX_DIRECT_RENDERING */ + +struct native_display * +x11_create_dri2_display(EGLNativeDisplayType dpy, + struct native_event_handler *event_handler, + struct drm_api *api) +{ + return NULL; +} + +#endif /* GLX_DIRECT_RENDERING */ --- mesa-7.8.2.orig/src/gallium/state_trackers/egl/x11/native_x11.c +++ mesa-7.8.2/src/gallium/state_trackers/egl/x11/native_x11.c @@ -70,7 +70,9 @@ xscr = x11_screen_create(xdpy, scr); if (xscr) { if (x11_screen_support(xscr, X11_SCREEN_EXTENSION_DRI2)) { +#ifdef GLX_DIRECT_RENDERING driver_name = x11_screen_probe_dri2(xscr, NULL, NULL); +#endif if (driver_name) nprobe->data = strdup(driver_name); } --- mesa-7.8.2.orig/src/gallium/state_trackers/egl/x11/x11_screen.c +++ mesa-7.8.2/src/gallium/state_trackers/egl/x11/x11_screen.c @@ -39,8 +39,10 @@ #include "glxinit.h" struct x11_screen { +#ifdef GLX_DIRECT_RENDERING /* dummy base class */ struct __GLXDRIdisplayRec base; +#endif Display *dpy; int number; @@ -103,15 +105,19 @@ if (xscr->dri_device) Xfree(xscr->dri_device); +#ifdef GLX_DIRECT_RENDERING /* xscr->glx_dpy will be destroyed with the X display */ if (xscr->glx_dpy) xscr->glx_dpy->dri2Display = NULL; +#endif if (xscr->visuals) XFree(xscr->visuals); free(xscr); } +#ifdef GLX_DIRECT_RENDERING + static boolean x11_screen_init_dri2(struct x11_screen *xscr) { @@ -133,6 +139,8 @@ return (xscr->glx_dpy != NULL); } +#endif /* GLX_DIRECT_RENDERING */ + /** * Return true if the screen supports the extension. */ @@ -145,12 +153,14 @@ case X11_SCREEN_EXTENSION_XSHM: supported = XShmQueryExtension(xscr->dpy); break; +#ifdef GLX_DIRECT_RENDERING case X11_SCREEN_EXTENSION_GLX: supported = x11_screen_init_glx(xscr); break; case X11_SCREEN_EXTENSION_DRI2: supported = x11_screen_init_dri2(xscr); break; +#endif default: break; } @@ -234,6 +244,39 @@ } /** + * Return the depth of a drawable. + * + * Unlike other drawable functions, the drawable needs not be a DRI2 drawable. + */ +uint +x11_drawable_get_depth(struct x11_screen *xscr, Drawable drawable) +{ + unsigned int depth; + + if (drawable != xscr->last_drawable) { + Window root; + int x, y; + unsigned int w, h, border; + Status ok; + + ok = XGetGeometry(xscr->dpy, drawable, &root, + &x, &y, &w, &h, &border, &depth); + if (!ok) + depth = 0; + + xscr->last_drawable = drawable; + xscr->last_depth = depth; + } + else { + depth = xscr->last_depth; + } + + return depth; +} + +#ifdef GLX_DIRECT_RENDERING + +/** * Return the GLX fbconfigs. */ const __GLcontextModes * @@ -392,37 +435,6 @@ } /** - * Return the depth of a drawable. - * - * Unlike other drawable functions, the drawable needs not be a DRI2 drawable. - */ -uint -x11_drawable_get_depth(struct x11_screen *xscr, Drawable drawable) -{ - unsigned int depth; - - if (drawable != xscr->last_drawable) { - Window root; - int x, y; - unsigned int w, h, border; - Status ok; - - ok = XGetGeometry(xscr->dpy, drawable, &root, - &x, &y, &w, &h, &border, &depth); - if (!ok) - depth = 0; - - xscr->last_drawable = drawable; - xscr->last_depth = depth; - } - else { - depth = xscr->last_depth; - } - - return depth; -} - -/** * Create a mode list of the given size. */ __GLcontextModes * @@ -489,3 +501,5 @@ xscr->dri_invalidate_buffers(xscr, drawable, xscr->dri_user_data); } + +#endif /* GLX_DIRECT_RENDERING */ --- mesa-7.8.2.orig/src/gallium/state_trackers/egl/x11/x11_screen.h +++ mesa-7.8.2/src/gallium/state_trackers/egl/x11/x11_screen.h @@ -68,20 +68,18 @@ x11_screen_convert_visual(struct x11_screen *xscr, const XVisualInfo *visual, __GLcontextModes *mode); +uint +x11_drawable_get_depth(struct x11_screen *xscr, Drawable drawable); + +#ifdef GLX_DIRECT_RENDERING + +/* GLX */ const __GLcontextModes * x11_screen_get_glx_configs(struct x11_screen *xscr); const __GLcontextModes * x11_screen_get_glx_visuals(struct x11_screen *xscr); -const char * -x11_screen_probe_dri2(struct x11_screen *xscr, int *major, int *minor); - -int -x11_screen_enable_dri2(struct x11_screen *xscr, - x11_drawable_invalidate_buffers invalidate_buffers, - void *user_data); - __GLcontextModes * x11_context_modes_create(unsigned count); @@ -91,6 +89,15 @@ unsigned x11_context_modes_count(const __GLcontextModes *modes); +/* DRI2 */ +const char * +x11_screen_probe_dri2(struct x11_screen *xscr, int *major, int *minor); + +int +x11_screen_enable_dri2(struct x11_screen *xscr, + x11_drawable_invalidate_buffers invalidate_buffers, + void *user_data); + void x11_drawable_enable_dri2(struct x11_screen *xscr, Drawable drawable, boolean on); @@ -105,7 +112,6 @@ int *width, int *height, unsigned int *attachments, boolean with_format, int num_ins, int *num_outs); -uint -x11_drawable_get_depth(struct x11_screen *xscr, Drawable drawable); +#endif /* GLX_DIRECT_RENDERING */ #endif /* _X11_SCREEN_H_ */ --- mesa-7.8.2.orig/src/gallium/state_trackers/python/README +++ mesa-7.8.2/src/gallium/state_trackers/python/README @@ -0,0 +1,43 @@ +This directory contains Python bindings to Gallium3D. It looks like a state +tracker from the pipe driver perspective, and it looks like a pipe driver from +the python script perspective. + + +To build you'll need: +* Python (with development packages) +* SCons +* SWIG, http://www.swig.org/download.html +* Python Imaging Library with TK support, http://www.pythonware.com/products/pil/, + for the samples + +On a debian-based distro you can simply do: + + aptitude install python-dev scons swig python-imaging python-imaging-tk + +On a Windows machine ensure the swig command is in your PATH. + +Invoke scons on the top dir as + + scons debug=yes statetrackers=python drivers=softpipe winsys=none + +To use it set PYTHONPATH appropriately, e.g, in Linux do: + + export PYTHONPATH=$PWD/build/linux-x86-debug/gallium/state_trackers/python + +or (in Windows) + + set PYTHONPATH=%CD%\build\windows-x86-debug\gallium\state_trackers\python + +and then try running + + python progs/gallium/python/samples/tri.py + +which should show a triangle. + + +This is still work in progress: +- errors are not handled properly and almost always result in crash +- state atoms with array members are awkward to set + +-- +Jose Fonseca --- mesa-7.8.2.orig/src/gallium/state_trackers/python/p_compiler.i +++ mesa-7.8.2/src/gallium/state_trackers/python/p_compiler.i @@ -0,0 +1,29 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + + +typedef unsigned char ubyte; --- mesa-7.8.2.orig/src/gallium/state_trackers/python/gallium.i +++ mesa-7.8.2/src/gallium/state_trackers/python/gallium.i @@ -0,0 +1,104 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + +/** + * @file + * SWIG interface definion for Gallium types. + * + * @author Jose Fonseca + */ + +%module gallium; + +%{ + +#include + +#include "pipe/p_screen.h" +#include "pipe/p_context.h" +#include "pipe/p_shader_tokens.h" +#include "os/os_stream.h" +#include "util/u_inlines.h" +#include "util/u_draw_quad.h" +#include "util/u_tile.h" +#include "util/u_math.h" +#include "util/u_format.h" +#include "util/u_dump.h" +#include "util/u_memory.h" +#include "cso_cache/cso_context.h" +#include "tgsi/tgsi_text.h" +#include "tgsi/tgsi_dump.h" + +#include "st_device.h" +#include "st_sample.h" + +%} + +%include "typemaps.i" +%include "exception.i" +%include "cstring.i" + +%include "carrays.i" +%array_class(unsigned char, ByteArray); +%array_class(int, IntArray); +%array_class(unsigned, UnsignedArray); +%array_class(float, FloatArray); + + +%rename(Device) st_device; +%rename(Context) st_context; +%rename(Texture) pipe_texture; +%rename(Surface) st_surface; +%rename(Buffer) pipe_buffer; + +%rename(BlendColor) pipe_blend_color; +%rename(Blend) pipe_blend_state; +%rename(Clip) pipe_clip_state; +%rename(Depth) pipe_depth_state; +%rename(Stencil) pipe_stencil_state; +%rename(Alpha) pipe_alpha_state; +%rename(DepthStencilAlpha) pipe_depth_stencil_alpha_state; +%rename(Framebuffer) pipe_framebuffer_state; +%rename(PolyStipple) pipe_poly_stipple; +%rename(Rasterizer) pipe_rasterizer_state; +%rename(Sampler) pipe_sampler_state; +%rename(Scissor) pipe_scissor_state; +%rename(Shader) pipe_shader_state; +%rename(VertexBuffer) pipe_vertex_buffer; +%rename(VertexElement) pipe_vertex_element; +%rename(Viewport) pipe_viewport_state; + + +%include "p_compiler.i" +%include "p_defines.h"; +%include "p_format.h" + +%include "p_device.i" +%include "p_context.i" +%include "p_texture.i" +%include "p_state.i" + --- mesa-7.8.2.orig/src/gallium/state_trackers/python/p_context.i +++ mesa-7.8.2/src/gallium/state_trackers/python/p_context.i @@ -0,0 +1,354 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + +/** + * @file + * SWIG interface definion for Gallium types. + * + * @author Jose Fonseca + */ + +%nodefaultctor st_context; +%nodefaultdtor st_context; + +struct st_context { +}; + +%extend st_context { + + ~st_context() { + st_context_destroy($self); + } + + /* + * State functions (create/bind/destroy state objects) + */ + + void set_blend( const struct pipe_blend_state *state ) { + cso_set_blend($self->cso, state); + } + + void set_fragment_sampler( unsigned index, const struct pipe_sampler_state *state ) { + cso_single_sampler($self->cso, index, state); + cso_single_sampler_done($self->cso); + } + + void set_vertex_sampler( unsigned index, const struct pipe_sampler_state *state ) { + cso_single_vertex_sampler($self->cso, index, state); + cso_single_vertex_sampler_done($self->cso); + } + + void set_rasterizer( const struct pipe_rasterizer_state *state ) { + cso_set_rasterizer($self->cso, state); + } + + void set_depth_stencil_alpha(const struct pipe_depth_stencil_alpha_state *state) { + cso_set_depth_stencil_alpha($self->cso, state); + } + + void set_fragment_shader( const struct pipe_shader_state *state ) { + void *fs; + + if(!state) { + cso_set_fragment_shader_handle($self->cso, NULL); + return; + } + + fs = $self->pipe->create_fs_state($self->pipe, state); + if(!fs) + return; + + if(cso_set_fragment_shader_handle($self->cso, fs) != PIPE_OK) + return; + + cso_delete_fragment_shader($self->cso, $self->fs); + $self->fs = fs; + } + + void set_vertex_shader( const struct pipe_shader_state *state ) { + void *vs; + + if(!state) { + cso_set_vertex_shader_handle($self->cso, NULL); + return; + } + + vs = $self->pipe->create_vs_state($self->pipe, state); + if(!vs) + return; + + if(cso_set_vertex_shader_handle($self->cso, vs) != PIPE_OK) + return; + + cso_delete_vertex_shader($self->cso, $self->vs); + $self->vs = vs; + } + + void set_geometry_shader( const struct pipe_shader_state *state ) { + void *gs; + + if(!state) { + cso_set_geometry_shader_handle($self->cso, NULL); + return; + } + + gs = $self->pipe->create_gs_state($self->pipe, state); + if(!gs) + return; + + if(cso_set_geometry_shader_handle($self->cso, gs) != PIPE_OK) + return; + + cso_delete_geometry_shader($self->cso, $self->gs); + $self->gs = gs; + } + + /* + * Parameter-like state (or properties) + */ + + void set_blend_color(const struct pipe_blend_color *state ) { + cso_set_blend_color($self->cso, state); + } + + void set_stencil_ref(const struct pipe_stencil_ref *state ) { + cso_set_stencil_ref($self->cso, state); + } + + void set_clip(const struct pipe_clip_state *state ) { + $self->pipe->set_clip_state($self->pipe, state); + } + + void set_constant_buffer(unsigned shader, unsigned index, + struct pipe_buffer *buffer ) + { + $self->pipe->set_constant_buffer($self->pipe, shader, index, buffer); + } + + void set_framebuffer(const struct pipe_framebuffer_state *state ) + { + memcpy(&$self->framebuffer, state, sizeof *state); + cso_set_framebuffer($self->cso, state); + } + + void set_polygon_stipple(const struct pipe_poly_stipple *state ) { + $self->pipe->set_polygon_stipple($self->pipe, state); + } + + void set_scissor(const struct pipe_scissor_state *state ) { + $self->pipe->set_scissor_state($self->pipe, state); + } + + void set_viewport(const struct pipe_viewport_state *state) { + cso_set_viewport($self->cso, state); + } + + void set_fragment_sampler_texture(unsigned index, + struct pipe_texture *texture) { + if(!texture) + texture = $self->default_texture; + pipe_texture_reference(&$self->fragment_sampler_textures[index], texture); + $self->pipe->set_fragment_sampler_textures($self->pipe, + PIPE_MAX_SAMPLERS, + $self->fragment_sampler_textures); + } + + void set_vertex_sampler_texture(unsigned index, + struct pipe_texture *texture) { + if(!texture) + texture = $self->default_texture; + pipe_texture_reference(&$self->vertex_sampler_textures[index], texture); + $self->pipe->set_vertex_sampler_textures($self->pipe, + PIPE_MAX_VERTEX_SAMPLERS, + $self->vertex_sampler_textures); + } + + void set_vertex_buffer(unsigned index, + unsigned stride, + unsigned max_index, + unsigned buffer_offset, + struct pipe_buffer *buffer) + { + unsigned i; + struct pipe_vertex_buffer state; + + memset(&state, 0, sizeof(state)); + state.stride = stride; + state.max_index = max_index; + state.buffer_offset = buffer_offset; + state.buffer = buffer; + + memcpy(&$self->vertex_buffers[index], &state, sizeof(state)); + + for(i = 0; i < PIPE_MAX_ATTRIBS; ++i) + if(self->vertex_buffers[i].buffer) + $self->num_vertex_buffers = i + 1; + + $self->pipe->set_vertex_buffers($self->pipe, + $self->num_vertex_buffers, + $self->vertex_buffers); + } + + void set_vertex_element(unsigned index, + const struct pipe_vertex_element *element) + { + memcpy(&$self->vertex_elements[index], element, sizeof(*element)); + } + + void set_vertex_elements(unsigned num) + { + $self->num_vertex_elements = num; + $self->pipe->set_vertex_elements($self->pipe, + $self->num_vertex_elements, + $self->vertex_elements); + } + + /* + * Draw functions + */ + + void draw_arrays(unsigned mode, unsigned start, unsigned count) { + $self->pipe->draw_arrays($self->pipe, mode, start, count); + } + + void draw_elements( struct pipe_buffer *indexBuffer, + unsigned indexSize, + unsigned mode, unsigned start, unsigned count) + { + $self->pipe->draw_elements($self->pipe, + indexBuffer, + indexSize, + mode, start, count); + } + + void draw_range_elements( struct pipe_buffer *indexBuffer, + unsigned indexSize, unsigned minIndex, unsigned maxIndex, + unsigned mode, unsigned start, unsigned count) + { + $self->pipe->draw_range_elements($self->pipe, + indexBuffer, + indexSize, minIndex, maxIndex, + mode, start, count); + } + + void draw_vertices(unsigned prim, + unsigned num_verts, + unsigned num_attribs, + const float *vertices) + { + struct pipe_context *pipe = $self->pipe; + struct pipe_screen *screen = pipe->screen; + struct pipe_buffer *vbuf; + float *map; + unsigned size; + + size = num_verts * num_attribs * 4 * sizeof(float); + + vbuf = pipe_buffer_create(screen, + 32, + PIPE_BUFFER_USAGE_VERTEX, + size); + if(!vbuf) + goto error1; + + map = pipe_buffer_map(screen, vbuf, PIPE_BUFFER_USAGE_CPU_WRITE); + if (!map) + goto error2; + memcpy(map, vertices, size); + pipe_buffer_unmap(screen, vbuf); + + util_draw_vertex_buffer(pipe, vbuf, 0, prim, num_verts, num_attribs); + +error2: + pipe_buffer_reference(&vbuf, NULL); +error1: + ; + } + + void + flush(unsigned flags = 0) { + struct pipe_fence_handle *fence = NULL; + $self->pipe->flush($self->pipe, flags | PIPE_FLUSH_RENDER_CACHE, &fence); + if(fence) { + /* TODO: allow asynchronous operation */ + $self->pipe->screen->fence_finish( $self->pipe->screen, fence, 0 ); + $self->pipe->screen->fence_reference( $self->pipe->screen, &fence, NULL ); + } + } + + /* + * Surface functions + */ + + void surface_copy(struct st_surface *dst, + unsigned destx, unsigned desty, + struct st_surface *src, + unsigned srcx, unsigned srcy, + unsigned width, unsigned height) + { + struct pipe_surface *_dst = NULL; + struct pipe_surface *_src = NULL; + + _dst = st_pipe_surface(dst, PIPE_BUFFER_USAGE_GPU_WRITE); + if(!_dst) + SWIG_exception(SWIG_ValueError, "couldn't acquire destination surface for writing"); + + _src = st_pipe_surface(src, PIPE_BUFFER_USAGE_GPU_READ); + if(!_src) + SWIG_exception(SWIG_ValueError, "couldn't acquire source surface for reading"); + + $self->pipe->surface_copy($self->pipe, _dst, destx, desty, _src, srcx, srcy, width, height); + + fail: + pipe_surface_reference(&_src, NULL); + pipe_surface_reference(&_dst, NULL); + } + + void surface_fill(struct st_surface *dst, + unsigned x, unsigned y, + unsigned width, unsigned height, + unsigned value) + { + struct pipe_surface *_dst = NULL; + + _dst = st_pipe_surface(dst, PIPE_BUFFER_USAGE_GPU_WRITE); + if(!_dst) + SWIG_exception(SWIG_ValueError, "couldn't acquire destination surface for writing"); + + $self->pipe->surface_fill($self->pipe, _dst, x, y, width, height, value); + + fail: + pipe_surface_reference(&_dst, NULL); + } + + void clear(unsigned buffers, const float *rgba, double depth = 0.0f, + unsigned stencil = 0) + { + $self->pipe->clear($self->pipe, buffers, rgba, depth, stencil); + } + +}; --- mesa-7.8.2.orig/src/gallium/state_trackers/python/p_device.i +++ mesa-7.8.2/src/gallium/state_trackers/python/p_device.i @@ -0,0 +1,139 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + +/** + * @file + * SWIG interface definion for Gallium types. + * + * @author Jose Fonseca + */ + + +%nodefaultctor st_device; +%nodefaultdtor st_device; + + +struct st_device { +}; + +%newobject st_device::texture_create; +%newobject st_device::context_create; +%newobject st_device::buffer_create; + +%extend st_device { + + st_device(int hardware = 1) { + return st_device_create(hardware ? TRUE : FALSE); + } + + ~st_device() { + st_device_destroy($self); + } + + const char * get_name( void ) { + return $self->screen->get_name($self->screen); + } + + const char * get_vendor( void ) { + return $self->screen->get_vendor($self->screen); + } + + /** + * Query an integer-valued capability/parameter/limit + * \param param one of PIPE_CAP_x + */ + int get_param( int param ) { + return $self->screen->get_param($self->screen, param); + } + + /** + * Query a float-valued capability/parameter/limit + * \param param one of PIPE_CAP_x + */ + float get_paramf( int param ) { + return $self->screen->get_paramf($self->screen, param); + } + + /** + * Check if the given pipe_format is supported as a texture or + * drawing surface. + * \param type one of PIPE_TEXTURE, PIPE_SURFACE + */ + int is_format_supported( enum pipe_format format, + enum pipe_texture_target target, + unsigned tex_usage, + unsigned geom_flags ) { + /* We can't really display surfaces with the python statetracker so mask + * out that usage */ + tex_usage &= ~PIPE_TEXTURE_USAGE_DISPLAY_TARGET; + + return $self->screen->is_format_supported( $self->screen, + format, + target, + tex_usage, + geom_flags ); + } + + struct st_context * + context_create(void) { + return st_context_create($self); + } + + struct pipe_texture * + texture_create( + enum pipe_format format, + unsigned width, + unsigned height, + unsigned depth = 1, + unsigned last_level = 0, + enum pipe_texture_target target = PIPE_TEXTURE_2D, + unsigned tex_usage = 0 + ) { + struct pipe_texture templat; + + /* We can't really display surfaces with the python statetracker so mask + * out that usage */ + tex_usage &= ~PIPE_TEXTURE_USAGE_DISPLAY_TARGET; + + memset(&templat, 0, sizeof(templat)); + templat.format = format; + templat.width0 = width; + templat.height0 = height; + templat.depth0 = depth; + templat.last_level = last_level; + templat.target = target; + templat.tex_usage = tex_usage; + + return $self->screen->texture_create($self->screen, &templat); + } + + struct pipe_buffer * + buffer_create(unsigned size, unsigned alignment = 0, unsigned usage = 0) { + return pipe_buffer_create($self->screen, alignment, usage, size); + } + +}; --- mesa-7.8.2.orig/src/gallium/state_trackers/python/p_state.i +++ mesa-7.8.2/src/gallium/state_trackers/python/p_state.i @@ -0,0 +1,184 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + +/** + * @file + * SWIG interface definion for Gallium types. + * + * @author Jose Fonseca + */ + +%module gallium; + +%ignore winsys; +%ignore pipe_vertex_buffer::buffer; + +%include "pipe/p_compiler.h"; +%include "pipe/p_state.h"; + + +%array_class(struct pipe_stencil_state, StencilArray); + + +%extend pipe_rt_blend_state +{ + struct pipe_rt_blend_state * + __getitem__(int index) + { + if(index < 0 || index >= PIPE_MAX_COLOR_BUFS) + SWIG_exception(SWIG_ValueError, "index out of bounds"); + return $self + index; + fail: + return NULL; + }; +}; + + +%extend pipe_blend_state +{ + pipe_blend_state(void) + { + return CALLOC_STRUCT(pipe_blend_state); + } + + %cstring_input_binary(const char *STRING, unsigned LENGTH); + pipe_blend_state(const char *STRING, unsigned LENGTH) + { + struct pipe_blend_state *state; + state = CALLOC_STRUCT(pipe_blend_state); + if (state) { + LENGTH = MIN2(sizeof *state, LENGTH); + memcpy(state, STRING, LENGTH); + } + return state; + } + + %cstring_output_allocate_size(char **STRING, int *LENGTH, os_free(*$1)); + void __str__(char **STRING, int *LENGTH) + { + struct os_stream *stream; + + stream = os_str_stream_create(1); + util_dump_blend_state(stream, $self); + + *STRING = os_str_stream_get_and_close(stream); + *LENGTH = strlen(*STRING); + } +}; + + +%extend pipe_framebuffer_state { + + pipe_framebuffer_state(void) { + return CALLOC_STRUCT(pipe_framebuffer_state); + } + + ~pipe_framebuffer_state() { + unsigned index; + for(index = 0; index < PIPE_MAX_COLOR_BUFS; ++index) + pipe_surface_reference(&$self->cbufs[index], NULL); + pipe_surface_reference(&$self->zsbuf, NULL); + FREE($self); + } + + void + set_cbuf(unsigned index, struct st_surface *surface) + { + struct pipe_surface *_surface = NULL; + + if(index >= PIPE_MAX_COLOR_BUFS) + SWIG_exception(SWIG_ValueError, "index out of bounds"); + + if(surface) { + _surface = st_pipe_surface(surface, PIPE_BUFFER_USAGE_GPU_WRITE); + if(!_surface) + SWIG_exception(SWIG_ValueError, "couldn't acquire surface for writing"); + } + + pipe_surface_reference(&$self->cbufs[index], _surface); + + fail: + return; + } + + void + set_zsbuf(struct st_surface *surface) + { + struct pipe_surface *_surface = NULL; + + if(surface) { + _surface = st_pipe_surface(surface, PIPE_BUFFER_USAGE_GPU_WRITE); + if(!_surface) + SWIG_exception(SWIG_ValueError, "couldn't acquire surface for writing"); + } + + pipe_surface_reference(&$self->zsbuf, _surface); + + fail: + return; + } + +}; + + +%extend pipe_shader_state { + + pipe_shader_state(const char *text, unsigned num_tokens = 1024) { + struct tgsi_token *tokens; + struct pipe_shader_state *shader; + + tokens = MALLOC(num_tokens * sizeof(struct tgsi_token)); + if(!tokens) + goto error1; + + if(tgsi_text_translate(text, tokens, num_tokens ) != TRUE) + goto error2; + + shader = CALLOC_STRUCT(pipe_shader_state); + if(!shader) + goto error3; + + shader->tokens = tokens; + + return shader; + +error3: +error2: + FREE(tokens); +error1: + return NULL; + } + + ~pipe_shader_state() { + FREE((void*)$self->tokens); + FREE($self); + } + + void dump(unsigned flags = 0) { + tgsi_dump($self->tokens, flags); + } +} --- mesa-7.8.2.orig/src/gallium/state_trackers/python/p_texture.i +++ mesa-7.8.2/src/gallium/state_trackers/python/p_texture.i @@ -0,0 +1,428 @@ + /************************************************************************** + * + * Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas. + * 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"), to deal in the Software without restriction, including + * without limitation the rights to use, copy, modify, merge, publish, + * distribute, sub license, and/or sell copies of the Software, and to + * permit persons to whom the Software is furnished to do so, subject to + * the following conditions: + * + * The above copyright notice and this permission notice (including the + * next paragraph) shall be included in all copies or substantial portions + * of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF + * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. + * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR + * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, + * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE + * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + * + **************************************************************************/ + +/** + * @file + * SWIG interface definion for Gallium types. + * + * @author Jose Fonseca + */ + + +%nodefaultctor pipe_texture; +%nodefaultctor st_surface; +%nodefaultctor pipe_buffer; + +%nodefaultdtor pipe_texture; +%nodefaultdtor st_surface; +%nodefaultdtor pipe_buffer; + +%ignore pipe_texture::screen; + +%immutable st_surface::texture; +%immutable st_surface::face; +%immutable st_surface::level; +%immutable st_surface::zslice; + +%newobject pipe_texture::get_surface; + + +%extend pipe_texture { + + ~pipe_texture() { + struct pipe_texture *ptr = $self; + pipe_texture_reference(&ptr, NULL); + } + + unsigned get_width(unsigned level=0) { + return u_minify($self->width0, level); + } + + unsigned get_height(unsigned level=0) { + return u_minify($self->height0, level); + } + + unsigned get_depth(unsigned level=0) { + return u_minify($self->depth0, level); + } + + /** Get a surface which is a "view" into a texture */ + struct st_surface * + get_surface(unsigned face=0, unsigned level=0, unsigned zslice=0) + { + struct st_surface *surface; + + if(face >= ($self->target == PIPE_TEXTURE_CUBE ? 6U : 1U)) + SWIG_exception(SWIG_ValueError, "face out of bounds"); + if(level > $self->last_level) + SWIG_exception(SWIG_ValueError, "level out of bounds"); + if(zslice >= u_minify($self->depth0, level)) + SWIG_exception(SWIG_ValueError, "zslice out of bounds"); + + surface = CALLOC_STRUCT(st_surface); + if(!surface) + return NULL; + + pipe_texture_reference(&surface->texture, $self); + surface->face = face; + surface->level = level; + surface->zslice = zslice; + + return surface; + + fail: + return NULL; + } + +}; + +struct st_surface +{ + %immutable; + + struct pipe_texture *texture; + unsigned face; + unsigned level; + unsigned zslice; + +}; + +%extend st_surface { + + %immutable; + + unsigned format; + unsigned width; + unsigned height; + + ~st_surface() { + pipe_texture_reference(&$self->texture, NULL); + FREE($self); + } + + %cstring_output_allocate_size(char **STRING, int *LENGTH, free(*$1)); + void get_tile_raw(unsigned x, unsigned y, unsigned w, unsigned h, char **STRING, int *LENGTH) + { + struct pipe_texture *texture = $self->texture; + struct pipe_screen *screen = texture->screen; + struct pipe_transfer *transfer; + unsigned stride; + + stride = util_format_get_stride(texture->format, w); + *LENGTH = util_format_get_nblocksy(texture->format, h) * stride; + *STRING = (char *) malloc(*LENGTH); + if(!*STRING) + return; + + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_READ, + x, y, w, h); + if(transfer) { + pipe_get_tile_raw(transfer, 0, 0, w, h, *STRING, stride); + screen->tex_transfer_destroy(transfer); + } + } + + %cstring_input_binary(const char *STRING, unsigned LENGTH); + void put_tile_raw(unsigned x, unsigned y, unsigned w, unsigned h, const char *STRING, unsigned LENGTH, unsigned stride = 0) + { + struct pipe_texture *texture = $self->texture; + struct pipe_screen *screen = texture->screen; + struct pipe_transfer *transfer; + + if(stride == 0) + stride = util_format_get_stride(texture->format, w); + + if(LENGTH < util_format_get_nblocksy(texture->format, h) * stride) + SWIG_exception(SWIG_ValueError, "offset must be smaller than buffer size"); + + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_WRITE, + x, y, w, h); + if(!transfer) + SWIG_exception(SWIG_MemoryError, "couldn't initiate transfer"); + + pipe_put_tile_raw(transfer, 0, 0, w, h, STRING, stride); + screen->tex_transfer_destroy(transfer); + + fail: + return; + } + + void + get_tile_rgba(unsigned x, unsigned y, unsigned w, unsigned h, float *rgba) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_READ, + x, y, w, h); + if(transfer) { + pipe_get_tile_rgba(transfer, 0, 0, w, h, rgba); + screen->tex_transfer_destroy(transfer); + } + } + + void + put_tile_rgba(unsigned x, unsigned y, unsigned w, unsigned h, const float *rgba) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_WRITE, + x, y, w, h); + if(transfer) { + pipe_put_tile_rgba(transfer, 0, 0, w, h, rgba); + screen->tex_transfer_destroy(transfer); + } + } + + %cstring_output_allocate_size(char **STRING, int *LENGTH, free(*$1)); + void + get_tile_rgba8(unsigned x, unsigned y, unsigned w, unsigned h, char **STRING, int *LENGTH) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + float *rgba; + unsigned char *rgba8; + unsigned i, j, k; + + *LENGTH = 0; + *STRING = NULL; + + if (!$self) + return; + + *LENGTH = h*w*4; + *STRING = (char *) malloc(*LENGTH); + if(!*STRING) + return; + + rgba = malloc(h*w*4*sizeof(float)); + if(!rgba) + return; + + rgba8 = (unsigned char *) *STRING; + + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_READ, + x, y, + w, h); + if(transfer) { + pipe_get_tile_rgba(transfer, 0, 0, w, h, rgba); + for(j = 0; j < h; ++j) { + for(i = 0; i < w; ++i) + for(k = 0; k <4; ++k) + rgba8[j*w*4 + i*4 + k] = float_to_ubyte(rgba[j*w*4 + i*4 + k]); + } + screen->tex_transfer_destroy(transfer); + } + + free(rgba); + } + + void + get_tile_z(unsigned x, unsigned y, unsigned w, unsigned h, unsigned *z) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_READ, + x, y, w, h); + if(transfer) { + pipe_get_tile_z(transfer, 0, 0, w, h, z); + screen->tex_transfer_destroy(transfer); + } + } + + void + put_tile_z(unsigned x, unsigned y, unsigned w, unsigned h, const unsigned *z) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_WRITE, + x, y, w, h); + if(transfer) { + pipe_put_tile_z(transfer, 0, 0, w, h, z); + screen->tex_transfer_destroy(transfer); + } + } + + void + sample_rgba(float *rgba) { + st_sample_surface($self, rgba); + } + + unsigned + compare_tile_rgba(unsigned x, unsigned y, unsigned w, unsigned h, const float *rgba, float tol = 0.0) + { + struct pipe_screen *screen = $self->texture->screen; + struct pipe_transfer *transfer; + float *rgba2; + const float *p1; + const float *p2; + unsigned i, j, n; + + rgba2 = MALLOC(h*w*4*sizeof(float)); + if(!rgba2) + return ~0; + + transfer = screen->get_tex_transfer(screen, + $self->texture, + $self->face, + $self->level, + $self->zslice, + PIPE_TRANSFER_READ, + x, y, w, h); + if(!transfer) { + FREE(rgba2); + return ~0; + } + + pipe_get_tile_rgba(transfer, 0, 0, w, h, rgba2); + screen->tex_transfer_destroy(transfer); + + p1 = rgba; + p2 = rgba2; + n = 0; + for(i = h*w; i; --i) { + unsigned differs = 0; + for(j = 4; j; --j) { + float delta = *p2++ - *p1++; + if (delta < -tol || delta > tol) + differs = 1; + } + n += differs; + } + + FREE(rgba2); + + return n; + } + +}; + +%{ + static enum pipe_format + st_surface_format_get(struct st_surface *surface) + { + return surface->texture->format; + } + + static unsigned + st_surface_width_get(struct st_surface *surface) + { + return u_minify(surface->texture->width0, surface->level); + } + + static unsigned + st_surface_height_get(struct st_surface *surface) + { + return u_minify(surface->texture->height0, surface->level); + } +%} + +/* Avoid naming conflict with p_inlines.h's pipe_buffer_read/write */ +%rename(read) read_; +%rename(write) write_; + +%extend pipe_buffer { + + ~pipe_buffer() { + struct pipe_buffer *ptr = $self; + pipe_buffer_reference(&ptr, NULL); + } + + unsigned __len__(void) + { + assert(p_atomic_read(&$self->reference.count) > 0); + return $self->size; + } + + %cstring_output_allocate_size(char **STRING, int *LENGTH, free(*$1)); + void read_(char **STRING, int *LENGTH) + { + struct pipe_screen *screen = $self->screen; + + assert(p_atomic_read(&$self->reference.count) > 0); + + *LENGTH = $self->size; + *STRING = (char *) malloc($self->size); + if(!*STRING) + return; + + pipe_buffer_read(screen, $self, 0, $self->size, *STRING); + } + + %cstring_input_binary(const char *STRING, unsigned LENGTH); + void write_(const char *STRING, unsigned LENGTH, unsigned offset = 0) + { + struct pipe_screen *screen = $self->screen; + + assert(p_atomic_read(&$self->reference.count) > 0); + + if(offset > $self->size) + SWIG_exception(SWIG_ValueError, "offset must be smaller than buffer size"); + + if(offset + LENGTH > $self->size) + SWIG_exception(SWIG_ValueError, "data length must fit inside the buffer"); + + pipe_buffer_write(screen, $self, offset, LENGTH, STRING); + +fail: + return; + } +}; --- mesa-7.8.2.orig/src/gallium/state_trackers/wgl/opengl32.def +++ mesa-7.8.2/src/gallium/state_trackers/wgl/opengl32.def @@ -0,0 +1,389 @@ +EXPORTS +; GlmfBeginGlsBlock +; GlmfCloseMetaFile +; GlmfEndGlsBlock +; GlmfEndPlayback +; GlmfInitPlayback +; GlmfPlayGlsRecord + glAccum + glAlphaFunc + glAreTexturesResident + glArrayElement + glBegin + glBindTexture + glBitmap + glBlendFunc + glCallList + glCallLists + glClear + glClearAccum + glClearColor + glClearDepth + glClearIndex + glClearStencil + glClipPlane + glColor3b + glColor3bv + glColor3d + glColor3dv + glColor3f + glColor3fv + glColor3i + glColor3iv + glColor3s + glColor3sv + glColor3ub + glColor3ubv + glColor3ui + glColor3uiv + glColor3us + glColor3usv + glColor4b + glColor4bv + glColor4d + glColor4dv + glColor4f + glColor4fv + glColor4i + glColor4iv + glColor4s + glColor4sv + glColor4ub + glColor4ubv + glColor4ui + glColor4uiv + glColor4us + glColor4usv + glColorMask + glColorMaterial + glColorPointer + glCopyPixels + glCopyTexImage1D + glCopyTexImage2D + glCopyTexSubImage1D + glCopyTexSubImage2D + glCullFace +; glDebugEntry + glDeleteLists + glDeleteTextures + glDepthFunc + glDepthMask + glDepthRange + glDisable + glDisableClientState + glDrawArrays + glDrawBuffer + glDrawElements + glDrawPixels + glEdgeFlag + glEdgeFlagPointer + glEdgeFlagv + glEnable + glEnableClientState + glEnd + glEndList + glEvalCoord1d + glEvalCoord1dv + glEvalCoord1f + glEvalCoord1fv + glEvalCoord2d + glEvalCoord2dv + glEvalCoord2f + glEvalCoord2fv + glEvalMesh1 + glEvalMesh2 + glEvalPoint1 + glEvalPoint2 + glFeedbackBuffer + glFinish + glFlush + glFogf + glFogfv + glFogi + glFogiv + glFrontFace + glFrustum + glGenLists + glGenTextures + glGetBooleanv + glGetClipPlane + glGetDoublev + glGetError + glGetFloatv + glGetIntegerv + glGetLightfv + glGetLightiv + glGetMapdv + glGetMapfv + glGetMapiv + glGetMaterialfv + glGetMaterialiv + glGetPixelMapfv + glGetPixelMapuiv + glGetPixelMapusv + glGetPointerv + glGetPolygonStipple + glGetString + glGetTexEnvfv + glGetTexEnviv + glGetTexGendv + glGetTexGenfv + glGetTexGeniv + glGetTexImage + glGetTexLevelParameterfv + glGetTexLevelParameteriv + glGetTexParameterfv + glGetTexParameteriv + glHint + glIndexMask + glIndexPointer + glIndexd + glIndexdv + glIndexf + glIndexfv + glIndexi + glIndexiv + glIndexs + glIndexsv + glIndexub + glIndexubv + glInitNames + glInterleavedArrays + glIsEnabled + glIsList + glIsTexture + glLightModelf + glLightModelfv + glLightModeli + glLightModeliv + glLightf + glLightfv + glLighti + glLightiv + glLineStipple + glLineWidth + glListBase + glLoadIdentity + glLoadMatrixd + glLoadMatrixf + glLoadName + glLogicOp + glMap1d + glMap1f + glMap2d + glMap2f + glMapGrid1d + glMapGrid1f + glMapGrid2d + glMapGrid2f + glMaterialf + glMaterialfv + glMateriali + glMaterialiv + glMatrixMode + glMultMatrixd + glMultMatrixf + glNewList + glNormal3b + glNormal3bv + glNormal3d + glNormal3dv + glNormal3f + glNormal3fv + glNormal3i + glNormal3iv + glNormal3s + glNormal3sv + glNormalPointer + glOrtho + glPassThrough + glPixelMapfv + glPixelMapuiv + glPixelMapusv + glPixelStoref + glPixelStorei + glPixelTransferf + glPixelTransferi + glPixelZoom + glPointSize + glPolygonMode + glPolygonOffset + glPolygonStipple + glPopAttrib + glPopClientAttrib + glPopMatrix + glPopName + glPrioritizeTextures + glPushAttrib + glPushClientAttrib + glPushMatrix + glPushName + glRasterPos2d + glRasterPos2dv + glRasterPos2f + glRasterPos2fv + glRasterPos2i + glRasterPos2iv + glRasterPos2s + glRasterPos2sv + glRasterPos3d + glRasterPos3dv + glRasterPos3f + glRasterPos3fv + glRasterPos3i + glRasterPos3iv + glRasterPos3s + glRasterPos3sv + glRasterPos4d + glRasterPos4dv + glRasterPos4f + glRasterPos4fv + glRasterPos4i + glRasterPos4iv + glRasterPos4s + glRasterPos4sv + glReadBuffer + glReadPixels + glRectd + glRectdv + glRectf + glRectfv + glRecti + glRectiv + glRects + glRectsv + glRenderMode + glRotated + glRotatef + glScaled + glScalef + glScissor + glSelectBuffer + glShadeModel + glStencilFunc + glStencilMask + glStencilOp + glTexCoord1d + glTexCoord1dv + glTexCoord1f + glTexCoord1fv + glTexCoord1i + glTexCoord1iv + glTexCoord1s + glTexCoord1sv + glTexCoord2d + glTexCoord2dv + glTexCoord2f + glTexCoord2fv + glTexCoord2i + glTexCoord2iv + glTexCoord2s + glTexCoord2sv + glTexCoord3d + glTexCoord3dv + glTexCoord3f + glTexCoord3fv + glTexCoord3i + glTexCoord3iv + glTexCoord3s + glTexCoord3sv + glTexCoord4d + glTexCoord4dv + glTexCoord4f + glTexCoord4fv + glTexCoord4i + glTexCoord4iv + glTexCoord4s + glTexCoord4sv + glTexCoordPointer + glTexEnvf + glTexEnvfv + glTexEnvi + glTexEnviv + glTexGend + glTexGendv + glTexGenf + glTexGenfv + glTexGeni + glTexGeniv + glTexImage1D + glTexImage2D + glTexParameterf + glTexParameterfv + glTexParameteri + glTexParameteriv + glTexSubImage1D + glTexSubImage2D + glTranslated + glTranslatef + glVertex2d + glVertex2dv + glVertex2f + glVertex2fv + glVertex2i + glVertex2iv + glVertex2s + glVertex2sv + glVertex3d + glVertex3dv + glVertex3f + glVertex3fv + glVertex3i + glVertex3iv + glVertex3s + glVertex3sv + glVertex4d + glVertex4dv + glVertex4f + glVertex4fv + glVertex4i + glVertex4iv + glVertex4s + glVertex4sv + glVertexPointer + glViewport + wglChoosePixelFormat + wglCopyContext + wglCreateContext + wglCreateLayerContext + wglDeleteContext + wglDescribeLayerPlane + wglDescribePixelFormat + wglGetCurrentContext + wglGetCurrentDC +; wglGetDefaultProcAddress + wglGetLayerPaletteEntries + wglGetPixelFormat + wglGetProcAddress + wglMakeCurrent + wglRealizeLayerPalette + wglSetLayerPaletteEntries + wglSetPixelFormat + wglShareLists + wglSwapBuffers + wglSwapLayerBuffers + wglSwapMultipleBuffers + wglUseFontBitmapsA + wglUseFontBitmapsW + wglUseFontOutlinesA + wglUseFontOutlinesW + wglGetExtensionsStringARB + DrvCopyContext + DrvCreateContext + DrvCreateLayerContext + DrvDeleteContext + DrvDescribeLayerPlane + DrvDescribePixelFormat + DrvGetLayerPaletteEntries + DrvGetProcAddress + DrvPresentBuffers + DrvRealizeLayerPalette + DrvReleaseContext + DrvSetCallbackProcs + DrvSetContext + DrvSetLayerPaletteEntries + DrvSetPixelFormat + DrvShareLists + DrvSwapBuffers + DrvSwapLayerBuffers + DrvValidateVersion --- mesa-7.8.2.orig/src/gallium/state_trackers/wgl/opengl32.mingw.def +++ mesa-7.8.2/src/gallium/state_trackers/wgl/opengl32.mingw.def @@ -0,0 +1,388 @@ +EXPORTS +; GlmfBeginGlsBlock = GlmfBeginGlsBlock@4 +; GlmfCloseMetaFile = GlmfCloseMetaFile@4 +; GlmfEndGlsBlock = GlmfEndGlsBlock@4 +; GlmfEndPlayback = GlmfEndPlayback@4 +; GlmfInitPlayback = GlmfInitPlayback@12 +; GlmfPlayGlsRecord = GlmfPlayGlsRecord@16 + glAccum = glAccum@8 + glAlphaFunc = glAlphaFunc@8 + glAreTexturesResident = glAreTexturesResident@12 + glArrayElement = glArrayElement@4 + glBegin = glBegin@4 + glBindTexture = glBindTexture@8 + glBitmap = glBitmap@28 + glBlendFunc = glBlendFunc@8 + glCallList = glCallList@4 + glCallLists = glCallLists@12 + glClear = glClear@4 + glClearAccum = glClearAccum@16 + glClearColor = glClearColor@16 + glClearDepth = glClearDepth@8 + glClearIndex = glClearIndex@4 + glClearStencil = glClearStencil@4 + glClipPlane = glClipPlane@8 + glColor3b = glColor3b@12 + glColor3bv = glColor3bv@4 + glColor3d = glColor3d@24 + glColor3dv = glColor3dv@4 + glColor3f = glColor3f@12 + glColor3fv = glColor3fv@4 + glColor3i = glColor3i@12 + glColor3iv = glColor3iv@4 + glColor3s = glColor3s@12 + glColor3sv = glColor3sv@4 + glColor3ub = glColor3ub@12 + glColor3ubv = glColor3ubv@4 + glColor3ui = glColor3ui@12 + glColor3uiv = glColor3uiv@4 + glColor3us = glColor3us@12 + glColor3usv = glColor3usv@4 + glColor4b = glColor4b@16 + glColor4bv = glColor4bv@4 + glColor4d = glColor4d@32 + glColor4dv = glColor4dv@4 + glColor4f = glColor4f@16 + glColor4fv = glColor4fv@4 + glColor4i = glColor4i@16 + glColor4iv = glColor4iv@4 + glColor4s = glColor4s@16 + glColor4sv = glColor4sv@4 + glColor4ub = glColor4ub@16 + glColor4ubv = glColor4ubv@4 + glColor4ui = glColor4ui@16 + glColor4uiv = glColor4uiv@4 + glColor4us = glColor4us@16 + glColor4usv = glColor4usv@4 + glColorMask = glColorMask@16 + glColorMaterial = glColorMaterial@8 + glColorPointer = glColorPointer@16 + glCopyPixels = glCopyPixels@20 + glCopyTexImage1D = glCopyTexImage1D@28 + glCopyTexImage2D = glCopyTexImage2D@32 + glCopyTexSubImage1D = glCopyTexSubImage1D@24 + glCopyTexSubImage2D = glCopyTexSubImage2D@32 + glCullFace = glCullFace@4 +; glDebugEntry = glDebugEntry@8 + glDeleteLists = glDeleteLists@8 + glDeleteTextures = glDeleteTextures@8 + glDepthFunc = glDepthFunc@4 + glDepthMask = glDepthMask@4 + glDepthRange = glDepthRange@16 + glDisable = glDisable@4 + glDisableClientState = glDisableClientState@4 + glDrawArrays = glDrawArrays@12 + glDrawBuffer = glDrawBuffer@4 + glDrawElements = glDrawElements@16 + glDrawPixels = glDrawPixels@20 + glEdgeFlag = glEdgeFlag@4 + glEdgeFlagPointer = glEdgeFlagPointer@8 + glEdgeFlagv = glEdgeFlagv@4 + glEnable = glEnable@4 + glEnableClientState = glEnableClientState@4 + glEnd = glEnd@0 + glEndList = glEndList@0 + glEvalCoord1d = glEvalCoord1d@8 + glEvalCoord1dv = glEvalCoord1dv@4 + glEvalCoord1f = glEvalCoord1f@4 + glEvalCoord1fv = glEvalCoord1fv@4 + glEvalCoord2d = glEvalCoord2d@16 + glEvalCoord2dv = glEvalCoord2dv@4 + glEvalCoord2f = glEvalCoord2f@8 + glEvalCoord2fv = glEvalCoord2fv@4 + glEvalMesh1 = glEvalMesh1@12 + glEvalMesh2 = glEvalMesh2@20 + glEvalPoint1 = glEvalPoint1@4 + glEvalPoint2 = glEvalPoint2@8 + glFeedbackBuffer = glFeedbackBuffer@12 + glFinish = glFinish@0 + glFlush = glFlush@0 + glFogf = glFogf@8 + glFogfv = glFogfv@8 + glFogi = glFogi@8 + glFogiv = glFogiv@8 + glFrontFace = glFrontFace@4 + glFrustum = glFrustum@48 + glGenLists = glGenLists@4 + glGenTextures = glGenTextures@8 + glGetBooleanv = glGetBooleanv@8 + glGetClipPlane = glGetClipPlane@8 + glGetDoublev = glGetDoublev@8 + glGetError = glGetError@0 + glGetFloatv = glGetFloatv@8 + glGetIntegerv = glGetIntegerv@8 + glGetLightfv = glGetLightfv@12 + glGetLightiv = glGetLightiv@12 + glGetMapdv = glGetMapdv@12 + glGetMapfv = glGetMapfv@12 + glGetMapiv = glGetMapiv@12 + glGetMaterialfv = glGetMaterialfv@12 + glGetMaterialiv = glGetMaterialiv@12 + glGetPixelMapfv = glGetPixelMapfv@8 + glGetPixelMapuiv = glGetPixelMapuiv@8 + glGetPixelMapusv = glGetPixelMapusv@8 + glGetPointerv = glGetPointerv@8 + glGetPolygonStipple = glGetPolygonStipple@4 + glGetString = glGetString@4 + glGetTexEnvfv = glGetTexEnvfv@12 + glGetTexEnviv = glGetTexEnviv@12 + glGetTexGendv = glGetTexGendv@12 + glGetTexGenfv = glGetTexGenfv@12 + glGetTexGeniv = glGetTexGeniv@12 + glGetTexImage = glGetTexImage@20 + glGetTexLevelParameterfv = glGetTexLevelParameterfv@16 + glGetTexLevelParameteriv = glGetTexLevelParameteriv@16 + glGetTexParameterfv = glGetTexParameterfv@12 + glGetTexParameteriv = glGetTexParameteriv@12 + glHint = glHint@8 + glIndexMask = glIndexMask@4 + glIndexPointer = glIndexPointer@12 + glIndexd = glIndexd@8 + glIndexdv = glIndexdv@4 + glIndexf = glIndexf@4 + glIndexfv = glIndexfv@4 + glIndexi = glIndexi@4 + glIndexiv = glIndexiv@4 + glIndexs = glIndexs@4 + glIndexsv = glIndexsv@4 + glIndexub = glIndexub@4 + glIndexubv = glIndexubv@4 + glInitNames = glInitNames@0 + glInterleavedArrays = glInterleavedArrays@12 + glIsEnabled = glIsEnabled@4 + glIsList = glIsList@4 + glIsTexture = glIsTexture@4 + glLightModelf = glLightModelf@8 + glLightModelfv = glLightModelfv@8 + glLightModeli = glLightModeli@8 + glLightModeliv = glLightModeliv@8 + glLightf = glLightf@12 + glLightfv = glLightfv@12 + glLighti = glLighti@12 + glLightiv = glLightiv@12 + glLineStipple = glLineStipple@8 + glLineWidth = glLineWidth@4 + glListBase = glListBase@4 + glLoadIdentity = glLoadIdentity@0 + glLoadMatrixd = glLoadMatrixd@4 + glLoadMatrixf = glLoadMatrixf@4 + glLoadName = glLoadName@4 + glLogicOp = glLogicOp@4 + glMap1d = glMap1d@32 + glMap1f = glMap1f@24 + glMap2d = glMap2d@56 + glMap2f = glMap2f@40 + glMapGrid1d = glMapGrid1d@20 + glMapGrid1f = glMapGrid1f@12 + glMapGrid2d = glMapGrid2d@40 + glMapGrid2f = glMapGrid2f@24 + glMaterialf = glMaterialf@12 + glMaterialfv = glMaterialfv@12 + glMateriali = glMateriali@12 + glMaterialiv = glMaterialiv@12 + glMatrixMode = glMatrixMode@4 + glMultMatrixd = glMultMatrixd@4 + glMultMatrixf = glMultMatrixf@4 + glNewList = glNewList@8 + glNormal3b = glNormal3b@12 + glNormal3bv = glNormal3bv@4 + glNormal3d = glNormal3d@24 + glNormal3dv = glNormal3dv@4 + glNormal3f = glNormal3f@12 + glNormal3fv = glNormal3fv@4 + glNormal3i = glNormal3i@12 + glNormal3iv = glNormal3iv@4 + glNormal3s = glNormal3s@12 + glNormal3sv = glNormal3sv@4 + glNormalPointer = glNormalPointer@12 + glOrtho = glOrtho@48 + glPassThrough = glPassThrough@4 + glPixelMapfv = glPixelMapfv@12 + glPixelMapuiv = glPixelMapuiv@12 + glPixelMapusv = glPixelMapusv@12 + glPixelStoref = glPixelStoref@8 + glPixelStorei = glPixelStorei@8 + glPixelTransferf = glPixelTransferf@8 + glPixelTransferi = glPixelTransferi@8 + glPixelZoom = glPixelZoom@8 + glPointSize = glPointSize@4 + glPolygonMode = glPolygonMode@8 + glPolygonOffset = glPolygonOffset@8 + glPolygonStipple = glPolygonStipple@4 + glPopAttrib = glPopAttrib@0 + glPopClientAttrib = glPopClientAttrib@0 + glPopMatrix = glPopMatrix@0 + glPopName = glPopName@0 + glPrioritizeTextures = glPrioritizeTextures@12 + glPushAttrib = glPushAttrib@4 + glPushClientAttrib = glPushClientAttrib@4 + glPushMatrix = glPushMatrix@0 + glPushName = glPushName@4 + glRasterPos2d = glRasterPos2d@16 + glRasterPos2dv = glRasterPos2dv@4 + glRasterPos2f = glRasterPos2f@8 + glRasterPos2fv = glRasterPos2fv@4 + glRasterPos2i = glRasterPos2i@8 + glRasterPos2iv = glRasterPos2iv@4 + glRasterPos2s = glRasterPos2s@8 + glRasterPos2sv = glRasterPos2sv@4 + glRasterPos3d = glRasterPos3d@24 + glRasterPos3dv = glRasterPos3dv@4 + glRasterPos3f = glRasterPos3f@12 + glRasterPos3fv = glRasterPos3fv@4 + glRasterPos3i = glRasterPos3i@12 + glRasterPos3iv = glRasterPos3iv@4 + glRasterPos3s = glRasterPos3s@12 + glRasterPos3sv = glRasterPos3sv@4 + glRasterPos4d = glRasterPos4d@32 + glRasterPos4dv = glRasterPos4dv@4 + glRasterPos4f = glRasterPos4f@16 + glRasterPos4fv = glRasterPos4fv@4 + glRasterPos4i = glRasterPos4i@16 + glRasterPos4iv = glRasterPos4iv@4 + glRasterPos4s = glRasterPos4s@16 + glRasterPos4sv = glRasterPos4sv@4 + glReadBuffer = glReadBuffer@4 + glReadPixels = glReadPixels@28 + glRectd = glRectd@32 + glRectdv = glRectdv@8 + glRectf = glRectf@16 + glRectfv = glRectfv@8 + glRecti = glRecti@16 + glRectiv = glRectiv@8 + glRects = glRects@16 + glRectsv = glRectsv@8 + glRenderMode = glRenderMode@4 + glRotated = glRotated@32 + glRotatef = glRotatef@16 + glScaled = glScaled@24 + glScalef = glScalef@12 + glScissor = glScissor@16 + glSelectBuffer = glSelectBuffer@8 + glShadeModel = glShadeModel@4 + glStencilFunc = glStencilFunc@12 + glStencilMask = glStencilMask@4 + glStencilOp = glStencilOp@12 + glTexCoord1d = glTexCoord1d@8 + glTexCoord1dv = glTexCoord1dv@4 + glTexCoord1f = glTexCoord1f@4 + glTexCoord1fv = glTexCoord1fv@4 + glTexCoord1i = glTexCoord1i@4 + glTexCoord1iv = glTexCoord1iv@4 + glTexCoord1s = glTexCoord1s@4 + glTexCoord1sv = glTexCoord1sv@4 + glTexCoord2d = glTexCoord2d@16 + glTexCoord2dv = glTexCoord2dv@4 + glTexCoord2f = glTexCoord2f@8 + glTexCoord2fv = glTexCoord2fv@4 + glTexCoord2i = glTexCoord2i@8 + glTexCoord2iv = glTexCoord2iv@4 + glTexCoord2s = glTexCoord2s@8 + glTexCoord2sv = glTexCoord2sv@4 + glTexCoord3d = glTexCoord3d@24 + glTexCoord3dv = glTexCoord3dv@4 + glTexCoord3f = glTexCoord3f@12 + glTexCoord3fv = glTexCoord3fv@4 + glTexCoord3i = glTexCoord3i@12 + glTexCoord3iv = glTexCoord3iv@4 + glTexCoord3s = glTexCoord3s@12 + glTexCoord3sv = glTexCoord3sv@4 + glTexCoord4d = glTexCoord4d@32 + glTexCoord4dv = glTexCoord4dv@4 + glTexCoord4f = glTexCoord4f@16 + glTexCoord4fv = glTexCoord4fv@4 + glTexCoord4i = glTexCoord4i@16 + glTexCoord4iv = glTexCoord4iv@4 + glTexCoord4s = glTexCoord4s@16 + glTexCoord4sv = glTexCoord4sv@4 + glTexCoordPointer = glTexCoordPointer@16 + glTexEnvf = glTexEnvf@12 + glTexEnvfv = glTexEnvfv@12 + glTexEnvi = glTexEnvi@12 + glTexEnviv = glTexEnviv@12 + glTexGend = glTexGend@16 + glTexGendv = glTexGendv@12 + glTexGenf = glTexGenf@12 + glTexGenfv = glTexGenfv@12 + glTexGeni = glTexGeni@12 + glTexGeniv = glTexGeniv@12 + glTexImage1D = glTexImage1D@32 + glTexImage2D = glTexImage2D@36 + glTexParameterf = glTexParameterf@12 + glTexParameterfv = glTexParameterfv@12 + glTexParameteri = glTexParameteri@12 + glTexParameteriv = glTexParameteriv@12 + glTexSubImage1D = glTexSubImage1D@28 + glTexSubImage2D = glTexSubImage2D@36 + glTranslated = glTranslated@24 + glTranslatef = glTranslatef@12 + glVertex2d = glVertex2d@16 + glVertex2dv = glVertex2dv@4 + glVertex2f = glVertex2f@8 + glVertex2fv = glVertex2fv@4 + glVertex2i = glVertex2i@8 + glVertex2iv = glVertex2iv@4 + glVertex2s = glVertex2s@8 + glVertex2sv = glVertex2sv@4 + glVertex3d = glVertex3d@24 + glVertex3dv = glVertex3dv@4 + glVertex3f = glVertex3f@12 + glVertex3fv = glVertex3fv@4 + glVertex3i = glVertex3i@12 + glVertex3iv = glVertex3iv@4 + glVertex3s = glVertex3s@12 + glVertex3sv = glVertex3sv@4 + glVertex4d = glVertex4d@32 + glVertex4dv = glVertex4dv@4 + glVertex4f = glVertex4f@16 + glVertex4fv = glVertex4fv@4 + glVertex4i = glVertex4i@16 + glVertex4iv = glVertex4iv@4 + glVertex4s = glVertex4s@16 + glVertex4sv = glVertex4sv@4 + glVertexPointer = glVertexPointer@16 + glViewport = glViewport@16 + wglChoosePixelFormat = wglChoosePixelFormat@8 + wglCopyContext = wglCopyContext@12 + wglCreateContext = wglCreateContext@4 + wglCreateLayerContext = wglCreateLayerContext@8 + wglDeleteContext = wglDeleteContext@4 + wglDescribeLayerPlane = wglDescribeLayerPlane@20 + wglDescribePixelFormat = wglDescribePixelFormat@16 + wglGetCurrentContext = wglGetCurrentContext@0 + wglGetCurrentDC = wglGetCurrentDC@0 +; wglGetDefaultProcAddress = wglGetDefaultProcAddress@4 + wglGetLayerPaletteEntries = wglGetLayerPaletteEntries@20 + wglGetPixelFormat = wglGetPixelFormat@4 + wglGetProcAddress = wglGetProcAddress@4 + wglMakeCurrent = wglMakeCurrent@8 + wglRealizeLayerPalette = wglRealizeLayerPalette@12 + wglSetLayerPaletteEntries = wglSetLayerPaletteEntries@20 + wglSetPixelFormat = wglSetPixelFormat@12 + wglShareLists = wglShareLists@8 + wglSwapBuffers = wglSwapBuffers@4 + wglSwapLayerBuffers = wglSwapLayerBuffers@8 + wglSwapMultipleBuffers = wglSwapMultipleBuffers@8 + wglUseFontBitmapsA = wglUseFontBitmapsA@16 + wglUseFontBitmapsW = wglUseFontBitmapsW@16 + wglUseFontOutlinesA = wglUseFontOutlinesA@32 + wglUseFontOutlinesW = wglUseFontOutlinesW@32 + DrvCopyContext = DrvCopyContext@12 + DrvCreateContext = DrvCreateContext@4 + DrvCreateLayerContext = DrvCreateLayerContext@8 + DrvDeleteContext = DrvDeleteContext@4 + DrvDescribeLayerPlane = DrvDescribeLayerPlane@20 + DrvDescribePixelFormat = DrvDescribePixelFormat@16 + DrvGetLayerPaletteEntries = DrvGetLayerPaletteEntries@20 + DrvGetProcAddress = DrvGetProcAddress@4 + DrvPresentBuffers = DrvPresentBuffers@8 + DrvRealizeLayerPalette = DrvRealizeLayerPalette@12 + DrvReleaseContext = DrvReleaseContext@4 + DrvSetCallbackProcs = DrvSetCallbackProcs@8 + DrvSetContext = DrvSetContext@12 + DrvSetLayerPaletteEntries = DrvSetLayerPaletteEntries@20 + DrvSetPixelFormat = DrvSetPixelFormat@8 + DrvShareLists = DrvShareLists@8 + DrvSwapBuffers = DrvSwapBuffers@4 + DrvSwapLayerBuffers = DrvSwapLayerBuffers@8 + DrvValidateVersion = DrvValidateVersion@4 --- mesa-7.8.2.orig/src/gallium/winsys/drm/Makefile.egl +++ mesa-7.8.2/src/gallium/winsys/drm/Makefile.egl @@ -11,7 +11,7 @@ EGL_DRIVER_OBJECTS = $(EGL_DRIVER_SOURCES:.c=.o) -common_LIBS = -ldrm -lm -ldl +common_LIBS = -ldrm -lm $(DLOPEN_LIBS) x11_ST = $(TOP)/src/gallium/state_trackers/egl/libeglx11.a x11_LIBS = $(common_LIBS) -lX11 -lXext -lXfixes --- mesa-7.8.2.orig/src/gallium/winsys/drm/i965/dri/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/i965/dri/SConscript @@ -0,0 +1,19 @@ +Import('*') + +env = drienv.Clone() + +env.ParseConfig('pkg-config --cflags --libs libdrm_intel') + +drivers = [ + st_dri, + i965drm, + i965, + trace, +] + +env.LoadableModule( + target ='i965_dri.so', + source = COMMON_GALLIUM_SOURCES, + LIBS = drivers + mesa + gallium + env['LIBS'], + SHLIBPREFIX = '', +) --- mesa-7.8.2.orig/src/gallium/winsys/drm/i965/gem/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/i965/gem/SConscript @@ -0,0 +1,15 @@ +Import('*') + +env = drienv.Clone() + +i965drm_sources = [ + 'i965_drm_api.c', + 'i965_drm_buffer.c', +] + +i965drm = env.ConvenienceLibrary( + target ='i965drm', + source = i965drm_sources, +) + +Export('i965drm') --- mesa-7.8.2.orig/src/gallium/winsys/drm/intel/dri/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/intel/dri/SConscript @@ -0,0 +1,21 @@ +Import('*') + +env = drienv.Clone() + +env.ParseConfig('pkg-config --cflags --libs libdrm_intel') + +env.Prepend(LIBS = [ + st_dri, + inteldrm, + i915, + trace, + mesa, + glsl, + gallium +]) + +env.LoadableModule( + target ='i915_dri.so', + source = COMMON_GALLIUM_SOURCES, + SHLIBPREFIX = '', +) --- mesa-7.8.2.orig/src/gallium/winsys/drm/intel/gem/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/intel/gem/SConscript @@ -0,0 +1,17 @@ +Import('*') + +env = drienv.Clone() + +inteldrm_sources = [ + 'intel_drm_api.c', + 'intel_drm_batchbuffer.c', + 'intel_drm_buffer.c', + 'intel_drm_fence.c', +] + +inteldrm = env.ConvenienceLibrary( + target ='inteldrm', + source = inteldrm_sources, +) + +Export('inteldrm') --- mesa-7.8.2.orig/src/gallium/winsys/drm/radeon/core/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/radeon/core/SConscript @@ -0,0 +1,18 @@ +Import('*') + +env = drienv.Clone() + +radeon_sources = [ + 'radeon_buffer.c', + 'radeon_drm.c', + 'radeon_r300.c', +] + +env.Append(CPPPATH = '#/src/gallium/drivers/r300') + +radeonwinsys = env.ConvenienceLibrary( + target ='radeonwinsys', + source = radeon_sources, +) + +Export('radeonwinsys') --- mesa-7.8.2.orig/src/gallium/winsys/drm/radeon/dri/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/radeon/dri/SConscript @@ -0,0 +1,17 @@ +Import('*') + +env = drienv.Clone() + +env.ParseConfig('pkg-config --cflags --libs libdrm_radeon') + +drivers = [ + trace, + softpipe, + r300 +] + +env.SharedLibrary( + target ='radeon_dri.so', + source = COMMON_GALLIUM_SOURCES, + LIBS = st_dri + radeonwinsys + mesa + drivers + gallium + env['LIBS'], +) --- mesa-7.8.2.orig/src/gallium/winsys/drm/radeon/python/README +++ mesa-7.8.2/src/gallium/winsys/drm/radeon/python/README @@ -0,0 +1,15 @@ +Python bindings for the radeon gallium driver. + + +See gallium/src/gallium/state_trackers/python/README for more information. + + +Build as: + + scons debug=1 statetrackers=python winsys=drm/radeon/python + +Run as: + + export PYTHONPATH=$PWD/build/linux-x86-debug/gallium/winsys/drm/radeon/python:$PWD/build/linux-x86-debug/gallium/state_trackers/python + + python progs/gallium/python/samples/tri.py --- mesa-7.8.2.orig/src/gallium/winsys/drm/radeon/python/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/radeon/python/SConscript @@ -0,0 +1,33 @@ +import os.path + +Import('*') + +if env['platform'] == 'linux': + + env = env.Clone() + + env.Tool('python') + + env.ParseConfig('pkg-config --cflags --libs libdrm') + + env.Prepend(CPPPATH = [ + '#src/gallium/state_trackers/python', + '../core', + ]) + + drivers = [ + softpipe, + radeon, + trace, + ] + + sources = [ + 'radeon_hardpipe_winsys.c', + 'xf86dri.c', + ] + + env.SharedLibrary( + target ='_gallium', + source = sources, + LIBS = [pyst] + drivers + gallium + env['LIBS'], + ) --- mesa-7.8.2.orig/src/gallium/winsys/drm/vmware/core/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/vmware/core/SConscript @@ -0,0 +1,39 @@ +Import('*') + +env = env.Clone() + +if env['gcc']: + env.Append(CCFLAGS = ['-fvisibility=hidden']) + env.Append(CPPDEFINES = [ + 'HAVE_STDINT_H', + 'HAVE_SYS_TYPES_H', + '-D_FILE_OFFSET_BITS=64', + ]) + +env.Prepend(CPPPATH = [ + 'include', + '#/src/gallium/drivers/svga', + '#/src/gallium/drivers/svga/include', +]) + +env.Append(CPPDEFINES = [ +]) + +sources = [ + 'vmw_buffer.c', + 'vmw_context.c', + 'vmw_fence.c', + 'vmw_screen.c', + 'vmw_screen_dri.c', + 'vmw_screen_ioctl.c', + 'vmw_screen_pools.c', + 'vmw_screen_svga.c', + 'vmw_surface.c', +] + +svgadrm = env.ConvenienceLibrary( + target = 'svgadrm', + source = sources, +) + +Export('svgadrm') --- mesa-7.8.2.orig/src/gallium/winsys/drm/vmware/dri/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/vmware/dri/SConscript @@ -0,0 +1,63 @@ +import os +import os.path + +Import('*') + +if env['platform'] == 'linux': + + if env['dri']: + env = env.Clone() + + sources = [ + '#/src/mesa/drivers/dri/common/utils.c', + '#/src/mesa/drivers/dri/common/vblank.c', + '#/src/mesa/drivers/dri/common/dri_util.c', + '#/src/mesa/drivers/dri/common/xmlconfig.c', + ] + + + env.ParseConfig('pkg-config --cflags --libs libdrm') + + env.Prepend(CPPPATH = [ + '#/src/mesa/state_tracker', + '#/src/mesa/drivers/dri/common', + '#/src/mesa/main', + '#/src/mesa/glapi', + '#/src/mesa', + '#/include', + '#/src/gallium/drivers/svga', + '#/src/gallium/drivers/svga/include', + ]) + + env.Append(CPPDEFINES = [ + 'HAVE_STDINT_H', + 'HAVE_SYS_TYPES_H', + ]) + + env.Append(CFLAGS = [ + '-std=gnu99', + '-D_FILE_OFFSET_BITS=64', + ]) + + env.Prepend(LIBPATH = [ + ]) + + env.Prepend(LIBS = [ + trace, + st_dri, + svgadrm, + svga, + mesa, + glsl, + gallium, + ]) + + # TODO: write a wrapper function http://www.scons.org/wiki/WrapperFunctions + env.LoadableModule( + target ='vmwgfx_dri.so', + source = sources, + LIBS = env['LIBS'], + SHLIBPREFIX = '', + ) + + --- mesa-7.8.2.orig/src/gallium/winsys/drm/vmware/xorg/SConscript +++ mesa-7.8.2/src/gallium/winsys/drm/vmware/xorg/SConscript @@ -0,0 +1,57 @@ +import os.path + +Import('*') + +if env['platform'] == 'linux': + + env = env.Clone() + + env.ParseConfig('pkg-config --cflags --libs libdrm xorg-server') + + env.Prepend(CPPPATH = [ + '#/include', + '#/src/gallium', + '#/src/mesa', + '#/src/gallium/drivers/svga', + '#/src/gallium/drivers/svga/include', + ]) + + env.Append(CPPDEFINES = [ + ]) + + if env['gcc']: + env.Append(CPPDEFINES = [ + 'HAVE_STDINT_H', + 'HAVE_SYS_TYPES_H', + ]) + + env.Append(CFLAGS = [ + '-std=gnu99', + '-D_FILE_OFFSET_BITS=64', + ]) + + env.Prepend(LIBPATH = [ + ]) + + env.Prepend(LIBS = [ + trace, + st_xorg, + svgadrm, + svga, + gallium, + ]) + + sources = [ + 'vmw_ioctl.c', + 'vmw_screen.c', + 'vmw_video.c', + 'vmw_xorg.c', + ] + + # TODO: write a wrapper function http://www.scons.org/wiki/WrapperFunctions + env.LoadableModule( + target ='vmwgfx_drv.so', + source = sources, + LIBS = env['LIBS'], + SHLIBPREFIX = '', + ) --- mesa-7.8.2.orig/src/glw/Makefile +++ mesa-7.8.2/src/glw/Makefile @@ -17,7 +17,7 @@ ##### RULES ##### .c.o: - $(CC) -c $(INCDIRS) $(CFLAGS) $< + $(CC) -c $(INCDIRS) $(CFLAGS) $(GLW_CFLAGS) $< --- mesa-7.8.2.orig/src/mesa/SConscript +++ mesa-7.8.2/src/mesa/SConscript @@ -0,0 +1,361 @@ +####################################################################### +# SConscript for Mesa + + +Import('*') + +if env['platform'] != 'winddk': + + env = env.Clone() + + env.Append(CPPPATH = [ + '#/src/mesa', + ]) + + if env['platform'] == 'windows': + env.Append(CPPDEFINES = [ + '_GDI32_', # prevent gl* being declared __declspec(dllimport) in MS headers + 'BUILD_GL32', # declare gl* as __declspec(dllexport) in Mesa headers + 'WIN32_THREADS', # use Win32 thread API + ]) + + # + # Source files + # + + main_sources = [ + 'main/api_arrayelt.c', + 'main/api_exec.c', + 'main/api_loopback.c', + 'main/api_noop.c', + 'main/api_validate.c', + 'main/accum.c', + 'main/attrib.c', + 'main/arrayobj.c', + 'main/blend.c', + 'main/bufferobj.c', + 'main/buffers.c', + 'main/clear.c', + 'main/clip.c', + 'main/colortab.c', + 'main/condrender.c', + 'main/context.c', + 'main/convolve.c', + 'main/cpuinfo.c', + 'main/debug.c', + 'main/depth.c', + 'main/depthstencil.c', + 'main/dlist.c', + 'main/dlopen.c', + 'main/drawpix.c', + 'main/enable.c', + 'main/enums.c', + 'main/eval.c', + 'main/execmem.c', + 'main/extensions.c', + 'main/fbobject.c', + 'main/feedback.c', + 'main/ffvertex_prog.c', + 'main/fog.c', + 'main/formats.c', + 'main/framebuffer.c', + 'main/get.c', + 'main/getstring.c', + 'main/hash.c', + 'main/hint.c', + 'main/histogram.c', + 'main/image.c', + 'main/imports.c', + 'main/light.c', + 'main/lines.c', + 'main/matrix.c', + 'main/mipmap.c', + 'main/mm.c', + 'main/multisample.c', + 'main/pixel.c', + 'main/pixelstore.c', + 'main/points.c', + 'main/polygon.c', + 'main/queryobj.c', + 'main/rastpos.c', + 'main/rbadaptors.c', + 'main/readpix.c', + 'main/remap.c', + 'main/renderbuffer.c', + 'main/scissor.c', + 'main/shaders.c', + 'main/shared.c', + 'main/state.c', + 'main/stencil.c', + 'main/syncobj.c', + 'main/texcompress.c', + 'main/texcompress_s3tc.c', + 'main/texcompress_fxt1.c', + 'main/texenv.c', + 'main/texenvprogram.c', + 'main/texfetch.c', + 'main/texformat.c', + 'main/texgen.c', + 'main/texgetimage.c', + 'main/teximage.c', + 'main/texobj.c', + 'main/texparam.c', + 'main/texrender.c', + 'main/texstate.c', + 'main/texstore.c', + 'main/varray.c', + 'main/version.c', + 'main/viewport.c', + 'main/vtxfmt.c', + ] + + math_sources = [ + 'math/m_debug_clip.c', + 'math/m_debug_norm.c', + 'math/m_debug_xform.c', + 'math/m_eval.c', + 'math/m_matrix.c', + 'math/m_translate.c', + 'math/m_vector.c', + 'math/m_xform.c', + ] + + vbo_sources = [ + 'vbo/vbo_context.c', + 'vbo/vbo_exec.c', + 'vbo/vbo_exec_api.c', + 'vbo/vbo_exec_array.c', + 'vbo/vbo_exec_draw.c', + 'vbo/vbo_exec_eval.c', + 'vbo/vbo_rebase.c', + 'vbo/vbo_split.c', + 'vbo/vbo_split_copy.c', + 'vbo/vbo_split_inplace.c', + 'vbo/vbo_save.c', + 'vbo/vbo_save_api.c', + 'vbo/vbo_save_draw.c', + 'vbo/vbo_save_loopback.c', + ] + + vf_sources = [ + 'vf/vf.c', + 'vf/vf_generic.c', + 'vf/vf_sse.c', + ] + + statetracker_sources = [ + 'state_tracker/st_atom.c', + 'state_tracker/st_atom_blend.c', + 'state_tracker/st_atom_clip.c', + 'state_tracker/st_atom_constbuf.c', + 'state_tracker/st_atom_depth.c', + 'state_tracker/st_atom_framebuffer.c', + 'state_tracker/st_atom_pixeltransfer.c', + 'state_tracker/st_atom_sampler.c', + 'state_tracker/st_atom_scissor.c', + 'state_tracker/st_atom_shader.c', + 'state_tracker/st_atom_rasterizer.c', + 'state_tracker/st_atom_stipple.c', + 'state_tracker/st_atom_texture.c', + 'state_tracker/st_atom_viewport.c', + 'state_tracker/st_cb_accum.c', + 'state_tracker/st_cb_bitmap.c', + 'state_tracker/st_cb_blit.c', + 'state_tracker/st_cb_bufferobjects.c', + 'state_tracker/st_cb_clear.c', + 'state_tracker/st_cb_condrender.c', + 'state_tracker/st_cb_flush.c', + 'state_tracker/st_cb_drawpixels.c', + 'state_tracker/st_cb_fbo.c', + 'state_tracker/st_cb_feedback.c', + 'state_tracker/st_cb_program.c', + 'state_tracker/st_cb_queryobj.c', + 'state_tracker/st_cb_rasterpos.c', + 'state_tracker/st_cb_readpixels.c', + 'state_tracker/st_cb_strings.c', + 'state_tracker/st_cb_texture.c', + 'state_tracker/st_context.c', + 'state_tracker/st_debug.c', + 'state_tracker/st_draw.c', + 'state_tracker/st_draw_feedback.c', + 'state_tracker/st_extensions.c', + 'state_tracker/st_format.c', + 'state_tracker/st_framebuffer.c', + 'state_tracker/st_gen_mipmap.c', + 'state_tracker/st_mesa_to_tgsi.c', + 'state_tracker/st_program.c', + 'state_tracker/st_texture.c', + ] + + shader_sources = [ + 'shader/arbprogparse.c', + 'shader/arbprogram.c', + 'shader/atifragshader.c', + 'shader/hash_table.c', + 'shader/lex.yy.c', + 'shader/nvfragparse.c', + 'shader/nvprogram.c', + 'shader/nvvertparse.c', + 'shader/program.c', + 'shader/program_parse.tab.c', + 'shader/program_parse_extra.c', + 'shader/prog_cache.c', + 'shader/prog_execute.c', + 'shader/prog_instruction.c', + 'shader/prog_noise.c', + 'shader/prog_optimize.c', + 'shader/prog_parameter.c', + 'shader/prog_parameter_layout.c', + 'shader/prog_print.c', + 'shader/prog_statevars.c', + 'shader/prog_uniform.c', + 'shader/programopt.c', + 'shader/symbol_table.c', + 'shader/shader_api.c', + ] + + slang_sources = [ + 'shader/slang/slang_builtin.c', + 'shader/slang/slang_codegen.c', + 'shader/slang/slang_compile.c', + 'shader/slang/slang_compile_function.c', + 'shader/slang/slang_compile_operation.c', + 'shader/slang/slang_compile_struct.c', + 'shader/slang/slang_compile_variable.c', + 'shader/slang/slang_emit.c', + 'shader/slang/slang_ir.c', + 'shader/slang/slang_label.c', + 'shader/slang/slang_link.c', + 'shader/slang/slang_log.c', + 'shader/slang/slang_mem.c', + 'shader/slang/slang_print.c', + 'shader/slang/slang_simplify.c', + 'shader/slang/slang_storage.c', + 'shader/slang/slang_typeinfo.c', + 'shader/slang/slang_vartable.c', + 'shader/slang/slang_utility.c', + ] + + mesa_sources = ( + main_sources + + math_sources + + vbo_sources + + vf_sources + + statetracker_sources + + shader_sources + + slang_sources + ) + + glapi_sources = [ + 'glapi/glapi.c', + 'glapi/glapi_dispatch.c', + 'glapi/glapi_getproc.c', + 'glapi/glapi_nop.c', + 'glapi/glthread.c', + ] + + # + # Assembly sources + # + if gcc and env['machine'] == 'x86': + env.Append(CPPDEFINES = [ + 'USE_X86_ASM', + 'USE_MMX_ASM', + 'USE_3DNOW_ASM', + 'USE_SSE_ASM', + ]) + mesa_sources += [ + 'x86/common_x86.c', + 'x86/x86_xform.c', + 'x86/3dnow.c', + 'x86/sse.c', + 'x86/common_x86_asm.S', + 'x86/x86_xform2.S', + 'x86/x86_xform3.S', + 'x86/x86_xform4.S', + 'x86/x86_cliptest.S', + 'x86/mmx_blend.S', + 'x86/3dnow_xform1.S', + 'x86/3dnow_xform2.S', + 'x86/3dnow_xform3.S', + 'x86/3dnow_xform4.S', + 'x86/3dnow_normal.S', + 'x86/sse_xform1.S', + 'x86/sse_xform2.S', + 'x86/sse_xform3.S', + 'x86/sse_xform4.S', + 'x86/sse_normal.S', + 'x86/read_rgba_span_x86.S', + ] + glapi_sources += [ + 'x86/glapi_x86.S', + ] + elif gcc and env['machine'] == 'x86_64': + env.Append(CPPDEFINES = [ + 'USE_X86_64_ASM', + ]) + mesa_sources += [ + 'x86-64/x86-64.c', + 'x86-64/xform4.S', + ] + glapi_sources += [ + 'x86-64/glapi_x86-64.S' + ] + elif gcc and env['machine'] == 'ppc': + env.Append(CPPDEFINES = [ + 'USE_PPC_ASM', + 'USE_VMX_ASM', + ]) + mesa_sources += [ + 'ppc/common_ppc.c', + ] + glapi_sources += [ + ] + elif gcc and env['machine'] == 'sparc': + mesa_sources += [ + 'sparc/sparc.c', + 'sparc/clip.S', + 'sparc/norm.S', + 'sparc/xform.S', + ] + glapi_sources += [ + 'sparc/glapi_sparc.S' + ] + else: + pass + + # Generate matypes.h + if gcc and env['machine'] in ('x86', 'x86_64'): + # See http://www.scons.org/wiki/UsingCodeGenerators + gen_matypes = env.Program( + target = 'gen_matypes', + source = 'x86/gen_matypes.c', + ) + matypes = env.Command( + 'matypes.h', + gen_matypes, + gen_matypes[0].abspath + ' > $TARGET', + ) + # Add the dir containing the generated header (somewhere inside the + # build dir) to the include path + env.Append(CPPPATH = [matypes[0].dir]) + + SConscript('shader/slang/library/SConscript') + + # + # Libraries + # + + mesa = env.ConvenienceLibrary( + target = 'mesa', + source = mesa_sources, + ) + Export('mesa') + + if not dri: + glapi = env.ConvenienceLibrary( + target = 'glapi', + source = glapi_sources, + ) + Export('glapi') + --- mesa-7.8.2.orig/src/mesa/drivers/dri/common/xmlpool/gen_xmlpool.py +++ mesa-7.8.2/src/mesa/drivers/dri/common/xmlpool/gen_xmlpool.py @@ -0,0 +1,191 @@ +#!/usr/bin/python + +import sys +import gettext +import re + +# List of supported languages +languages = sys.argv[1:] + +# Escape special characters in C strings +def escapeCString (s): + escapeSeqs = {'\a' : '\\a', '\b' : '\\b', '\f' : '\\f', '\n' : '\\n', + '\r' : '\\r', '\t' : '\\t', '\v' : '\\v', '\\' : '\\\\'} + # " -> '' is a hack. Quotes (") aren't possible in XML attributes. + # Better use Unicode characters for typographic quotes in option + # descriptions and translations. + i = 0 + r = '' + while i < len(s): + # Special case: escape double quote with \u201c or \u201d, depending + # on whether it's an open or close quote. This is needed because plain + # double quotes are not possible in XML attributes. + if s[i] == '"': + if i == len(s)-1 or s[i+1].isspace(): + # close quote + q = u'\u201c' + else: + # open quote + q = u'\u201d' + r = r + q + elif escapeSeqs.has_key(s[i]): + r = r + escapeSeqs[s[i]] + else: + r = r + s[i] + i = i + 1 + return r + +# Expand escape sequences in C strings (needed for gettext lookup) +def expandCString (s): + escapeSeqs = {'a' : '\a', 'b' : '\b', 'f' : '\f', 'n' : '\n', + 'r' : '\r', 't' : '\t', 'v' : '\v', + '"' : '"', '\\' : '\\'} + i = 0 + escape = False + hexa = False + octa = False + num = 0 + digits = 0 + r = '' + while i < len(s): + if not escape: + if s[i] == '\\': + escape = True + else: + r = r + s[i] + elif hexa: + if (s[i] >= '0' and s[i] <= '9') or \ + (s[i] >= 'a' and s[i] <= 'f') or \ + (s[i] >= 'A' and s[i] <= 'F'): + num = num * 16 + int(s[i],16) + digits = digits + 1 + else: + digits = 2 + if digits >= 2: + hexa = False + escape = False + r = r + chr(num) + elif octa: + if s[i] >= '0' and s[i] <= '7': + num = num * 8 + int(s[i],8) + digits = digits + 1 + else: + digits = 3 + if digits >= 3: + octa = False + escape = False + r = r + chr(num) + else: + if escapeSeqs.has_key(s[i]): + r = r + escapeSeqs[s[i]] + escape = False + elif s[i] >= '0' and s[i] <= '7': + octa = True + num = int(s[i],8) + if num <= 3: + digits = 1 + else: + digits = 2 + elif s[i] == 'x' or s[i] == 'X': + hexa = True + num = 0 + digits = 0 + else: + r = r + s[i] + escape = False + i = i + 1 + return r + +# Expand matches. The first match is always a DESC or DESC_BEGIN match. +# Subsequent matches are ENUM matches. +# +# DESC, DESC_BEGIN format: \1 \2= \3 \4=gettext(" \5= \6=") \7 +# ENUM format: \1 \2=gettext(" \3= \4=") \5 +def expandMatches (matches, translations, end=None): + assert len(matches) > 0 + nTranslations = len(translations) + i = 0 + # Expand the description+enums for all translations + for lang,trans in translations: + i = i + 1 + # Make sure that all but the last line of a simple description + # are extended with a backslash. + suffix = '' + if len(matches) == 1 and i < len(translations) and \ + not matches[0].expand (r'\7').endswith('\\'): + suffix = ' \\' + # Expand the description line. Need to use ugettext in order to allow + # non-ascii unicode chars in the original English descriptions. + text = escapeCString (trans.ugettext (unicode (expandCString ( + matches[0].expand (r'\5')), "utf-8"))).encode("utf-8") + print matches[0].expand (r'\1' + lang + r'\3"' + text + r'"\7') + suffix + # Expand any subsequent enum lines + for match in matches[1:]: + text = escapeCString (trans.ugettext (unicode (expandCString ( + match.expand (r'\3')), "utf-8"))).encode("utf-8") + print match.expand (r'\1"' + text + r'"\5') + + # Expand description end + if end: + print end, + +# Compile a list of translation classes to all supported languages. +# The first translation is always a NullTranslations. +translations = [("en", gettext.NullTranslations())] +for lang in languages: + try: + trans = gettext.translation ("options", ".", [lang]) + except IOError: + sys.stderr.write ("Warning: language '%s' not found.\n" % lang) + continue + translations.append ((lang, trans)) + +# Regular expressions: +reLibintl_h = re.compile (r'#\s*include\s*') +reDESC = re.compile (r'(\s*DRI_CONF_DESC\s*\(\s*)([a-z]+)(\s*,\s*)(gettext\s*\(\s*")(.*)("\s*\))(\s*\)[ \t]*\\?)$') +reDESC_BEGIN = re.compile (r'(\s*DRI_CONF_DESC_BEGIN\s*\(\s*)([a-z]+)(\s*,\s*)(gettext\s*\(\s*")(.*)("\s*\))(\s*\)[ \t]*\\?)$') +reENUM = re.compile (r'(\s*DRI_CONF_ENUM\s*\([^,]+,\s*)(gettext\s*\(\s*")(.*)("\s*\))(\s*\)[ \t]*\\?)$') +reDESC_END = re.compile (r'\s*DRI_CONF_DESC_END') + +# Print a header +print \ +"/***********************************************************************\n" \ +" *** THIS FILE IS GENERATED AUTOMATICALLY. DON'T EDIT! ***\n" \ +" ***********************************************************************/" + +# Process the options template and generate options.h with all +# translations. +template = file ("t_options.h", "r") +descMatches = [] +for line in template: + if len(descMatches) > 0: + matchENUM = reENUM .match (line) + matchDESC_END = reDESC_END.match (line) + if matchENUM: + descMatches.append (matchENUM) + elif matchDESC_END: + expandMatches (descMatches, translations, line) + descMatches = [] + else: + sys.stderr.write ( + "Warning: unexpected line inside description dropped:\n%s\n" \ + % line) + continue + if reLibintl_h.search (line): + # Ignore (comment out) #include + print "/* %s * commented out by gen_xmlpool.py */" % line + continue + matchDESC = reDESC .match (line) + matchDESC_BEGIN = reDESC_BEGIN.match (line) + if matchDESC: + assert len(descMatches) == 0 + expandMatches ([matchDESC], translations) + elif matchDESC_BEGIN: + assert len(descMatches) == 0 + descMatches = [matchDESC_BEGIN] + else: + print line, + +if len(descMatches) > 0: + sys.stderr.write ("Warning: unterminated description at end of file.\n") + expandMatches (descMatches, translations) --- mesa-7.8.2.orig/src/mesa/drivers/dri/mga/README +++ mesa-7.8.2/src/mesa/drivers/dri/mga/README @@ -0,0 +1,26 @@ +MGA DRI driver ported from XF86DRI to FBDRI +by Denis Oliver Kropp + + +INFO + +This driver has been ported from the head branch of XFree86 to +the embedded-1-branch of Mesa. + + +STATUS + +Already working very well as far as I've tested it (16/32 bit). +glxgears runs at 935 fps (G550 32MB AGP 4x, Athlon 1.33) vs 744 fps with XFree. +Other demos (terrain, fire, etc.) have been successfully tested as well. + + +TODO + +- mgaEngineShutdown +- mgaEngineRestore +- SGRAM detection +- remove some unused bits from server/* +- subset driver support +- mgaWaitForVBlank +- deinitialization (from MGADRICloseScreen) a la radeonDestroyScreen --- mesa-7.8.2.orig/src/mesa/drivers/dri/r300/Lindent +++ mesa-7.8.2/src/mesa/drivers/dri/r300/Lindent @@ -0,0 +1,2 @@ +#!/bin/sh +indent -npro -kr -i8 -ts8 -sob -l80 -ss -ncs "$@" --- mesa-7.8.2.orig/src/mesa/drivers/dri/r300/compiler/SConscript +++ mesa-7.8.2/src/mesa/drivers/dri/r300/compiler/SConscript @@ -0,0 +1,37 @@ +Import('*') + +env = env.Clone() +env.Append(CPPPATH = '#/include') +env.Append(CPPPATH = '#/src/mesa') + +# temporary fix +env['CFLAGS'] = str(env['CFLAGS']).replace('-Werror=declaration-after-statement', '') + +r300compiler = env.ConvenienceLibrary( + target = 'r300compiler', + source = [ + 'radeon_code.c', + 'radeon_compiler.c', + 'radeon_program.c', + 'radeon_program_print.c', + 'radeon_opcodes.c', + 'radeon_program_alu.c', + 'radeon_program_pair.c', + 'radeon_pair_translate.c', + 'radeon_pair_schedule.c', + 'radeon_pair_regalloc.c', + 'radeon_dataflow.c', + 'radeon_dataflow_deadcode.c', + 'radeon_dataflow_swizzles.c', + 'r3xx_fragprog.c', + 'r300_fragprog.c', + 'r300_fragprog_swizzle.c', + 'r300_fragprog_emit.c', + 'r500_fragprog.c', + 'r500_fragprog_emit.c', + 'r3xx_vertprog.c', + 'r3xx_vertprog_dump.c', + 'memory_pool.c', + ]) + +Return('r300compiler') --- mesa-7.8.2.orig/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c +++ mesa-7.8.2/src/mesa/drivers/dri/r300/compiler/radeon_pair_schedule.c @@ -141,12 +141,28 @@ *list = inst; } +static void add_inst_to_list_end(struct schedule_instruction ** list, + struct schedule_instruction * inst) +{ + if(!*list){ + *list = inst; + }else{ + struct schedule_instruction * temp = *list; + while(temp->NextReady){ + temp = temp->NextReady; + } + temp->NextReady = inst; + } +} + static void instruction_ready(struct schedule_state * s, struct schedule_instruction * sinst) { DBG("%i is now ready\n", sinst->Instruction->IP); + /* Adding Ready TEX instructions to the end of the "Ready List" helps + * us emit TEX instructions in blocks without losing our place. */ if (sinst->Instruction->Type == RC_INSTRUCTION_NORMAL) - add_inst_to_list(&s->ReadyTEX, sinst); + add_inst_to_list_end(&s->ReadyTEX, sinst); else if (sinst->Instruction->U.P.Alpha.Opcode == RC_OPCODE_NOP) add_inst_to_list(&s->ReadyRGB, sinst); else if (sinst->Instruction->U.P.RGB.Opcode == RC_OPCODE_NOP) @@ -163,11 +179,14 @@ instruction_ready(s, sinst); } -static void commit_instruction(struct schedule_state * s, struct schedule_instruction * sinst) -{ - DBG("%i: commit\n", sinst->Instruction->IP); - - for(unsigned int i = 0; i < sinst->NumReadValues; ++i) { +/** + * This function decreases the dependencies of the next instruction that + * wants to write to each of sinst's read values. + */ +static void commit_update_reads(struct schedule_state * s, + struct schedule_instruction * sinst){ + unsigned int i; + for(i = 0; i < sinst->NumReadValues; ++i) { struct reg_value * v = sinst->ReadValues[i]; assert(v->NumReaders > 0); v->NumReaders--; @@ -176,8 +195,12 @@ decrease_dependencies(s, v->Next->Writer); } } +} - for(unsigned int i = 0; i < sinst->NumWriteValues; ++i) { +static void commit_update_writes(struct schedule_state * s, + struct schedule_instruction * sinst){ + unsigned int i; + for(i = 0; i < sinst->NumWriteValues; ++i) { struct reg_value * v = sinst->WriteValues[i]; if (v->NumReaders) { for(struct reg_value_reader * r = v->Readers; r; r = r->Next) { @@ -196,6 +219,15 @@ } } +static void commit_alu_instruction(struct schedule_state * s, struct schedule_instruction * sinst) +{ + DBG("%i: commit\n", sinst->Instruction->IP); + + commit_update_reads(s, sinst); + + commit_update_writes(s, sinst); +} + /** * Emit all ready texture instructions in a single block. * @@ -208,21 +240,37 @@ assert(s->ReadyTEX); - /* Don't let the ready list change under us! */ - readytex = s->ReadyTEX; - s->ReadyTEX = 0; - /* Node marker for R300 */ struct rc_instruction * inst_begin = rc_insert_new_instruction(s->C, before->Prev); inst_begin->U.I.Opcode = RC_OPCODE_BEGIN_TEX; /* Link texture instructions back in */ + readytex = s->ReadyTEX; while(readytex) { - struct schedule_instruction * tex = readytex; - readytex = readytex->NextReady; + rc_insert_instruction(before->Prev, readytex->Instruction); + DBG("%i: commit TEX reads\n", readytex->Instruction->IP); - rc_insert_instruction(before->Prev, tex->Instruction); - commit_instruction(s, tex); + /* All of the TEX instructions in the same TEX block have + * their source registers read from before any of the + * instructions in that block write to their destination + * registers. This means that when we commit a TEX + * instruction, any other TEX instruction that wants to write + * to one of the committed instruction's source register can be + * marked as ready and should be emitted in the same TEX + * block. This prevents the following sequence from being + * emitted in two different TEX blocks: + * 0: TEX temp[0].xyz, temp[1].xy__, 2D[0]; + * 1: TEX temp[1].xyz, temp[2].xy__, 2D[0]; + */ + commit_update_reads(s, readytex); + readytex = readytex->NextReady; + } + readytex = s->ReadyTEX; + s->ReadyTEX = 0; + while(readytex){ + DBG("%i: commit TEX writes\n", readytex->Instruction->IP); + commit_update_writes(s, readytex); + readytex = readytex->NextReady; } } @@ -328,7 +376,7 @@ } rc_insert_instruction(before->Prev, sinst->Instruction); - commit_instruction(s, sinst); + commit_alu_instruction(s, sinst); } else { struct schedule_instruction **prgb; struct schedule_instruction **palpha; @@ -346,8 +394,8 @@ *prgb = (*prgb)->NextReady; *palpha = (*palpha)->NextReady; rc_insert_instruction(before->Prev, psirgb->Instruction); - commit_instruction(s, psirgb); - commit_instruction(s, psialpha); + commit_alu_instruction(s, psirgb); + commit_alu_instruction(s, psialpha); goto success; } } @@ -357,7 +405,7 @@ s->ReadyRGB = s->ReadyRGB->NextReady; rc_insert_instruction(before->Prev, sinst->Instruction); - commit_instruction(s, sinst); + commit_alu_instruction(s, sinst); success: ; } } --- mesa-7.8.2.orig/src/mesa/drivers/dri/r600/Lindent +++ mesa-7.8.2/src/mesa/drivers/dri/r600/Lindent @@ -0,0 +1,2 @@ +#!/bin/sh +indent -npro -kr -i8 -ts8 -sob -l80 -ss -ncs "$@" --- mesa-7.8.2.orig/src/mesa/drivers/dri/tdfx/BUGS +++ mesa-7.8.2/src/mesa/drivers/dri/tdfx/BUGS @@ -0,0 +1,64 @@ +REMOVE THIS FILE BEFORE MERGING WITH TRUNK +------------------------------------------ + +OUTSTANDING BUGS + +demos/reflect - reading back Z on Voodoo3, image offset to right + Fixed in latest Glide. + +Q3 - some polygons drawn as vertical strips, similar to bug that was + seen in demos/fire. Voodoo3 only. May be related to glDepthMask + or glColorMask. + +book/fog - not fogging + Fog in orthograph mode still not implemented. Checking with + 3dfx engineers for ideas. + +Q3 demo crashes after changing display settings + but the full Q3 game version seems OK. + + + +MORE OUTSTANDING BUGS + +private context was NULL! causing immediate failure of any glx prog. cant +reproduce after restarting the X server. putting it down as halluc. + +texture object image was NULL, causing segmentation failure. happens with +prboom. ive put a check in tdfx_texstate.c but this isn't a fix. + +prboom, wall textures near first chainsaw aren't bound properly. sideways +movements causes the wall textures to move with you. prboom busted? + +16bpp mode, quake3, windowed, q3dm1, floor under rocketlauncher bands. it +looks like multitexturing gone wrong. i'll disable a tmu and test. + +sof, polygons appear at wrong x,y,z positions, intermittent, have not yet +found reliable way of reproducing. culling? sometimes polys disappear. + +descent3 is all black in 16bpp mode - FIXED (palette problems) + +smeared pixels in quake3 - FIXED (texture memory overlapped FB) + + + +PERFORMANCE COMPARISON (Brian / Alan) + + V3/16 is Voodoo3 in 16bpp on a P3/500 + V5/16 is Voodoo5 in 16bpp on a P3/600 + V5/32 is Voodoo5 in 32bpp on a P3/600 + V5A/16 is Voodoo5 in 16bpp on an Alpha AXP/600 + V5A/32 is Voodoo5 in 32bpp on an Alpha AXP/600 + + tdfx-2-1-branch tdfx-3-0-0-branch +demo V3/16 V5/16 V5/32 V3/16 V5/16 V5/32 V5A/16 V5A/32 +------------------------------------------------------------------------ +gloss 257 183 174 320 308 177 313 167 +fire 42 39 52 41 +fire (no help) 98 80 50 106 113 73 124 80 +tunnel 61 50 70 58 +tunnel (no help) 167 142 57 138 152 113 171 122 +gears 663 554 540 881 1232 776 1484 830 +teapot 20 21 37 36 +teapot (no help) 22 14 14 24 30 30 43 42 + --- mesa-7.8.2.orig/src/mesa/drivers/windows/fx/fx.rc +++ mesa-7.8.2/src/mesa/drivers/windows/fx/fx.rc @@ -0,0 +1,39 @@ +#include + +#define PRODNAME "Mesa 6.x" +#define CONTACTSTR "http://www.mesa3d.org" +#define HWSTR "3dfx Voodoo Graphics, Voodoo Rush, Voodoo^2, Voodoo Banshee, Velocity 100/200, Voodoo3, Voodoo4, Voodoo5" +#define COPYRIGHTSTR "Copyright \251 Brian E. Paul" + +#define VERSIONSTR "6.3.0.1" +#define MANVERSION 6 +#define MANREVISION 3 +#define BUILD_NUMBER 1 + +VS_VERSION_INFO VERSIONINFO + FILEVERSION MANVERSION, MANREVISION, 0, BUILD_NUMBER + PRODUCTVERSION MANVERSION, MANREVISION, 0, BUILD_NUMBER + FILEFLAGSMASK 0x0030003FL + + FILEOS VOS_DOS_WINDOWS32 + FILETYPE VFT_DRV + FILESUBTYPE VFT2_DRV_INSTALLABLE +BEGIN + BLOCK "StringFileInfo" + BEGIN + BLOCK "040904E4" + BEGIN + VALUE "FileDescription", PRODNAME + VALUE "FileVersion", VERSIONSTR + VALUE "LegalCopyright", COPYRIGHTSTR + VALUE "ProductName", PRODNAME + VALUE "Graphics Subsystem", HWSTR + VALUE "Contact", CONTACTSTR + END + END + BLOCK "VarFileInfo" + BEGIN + /* the following line should be extended for localized versions */ + VALUE "Translation", 0x409, 1252 + END +END --- mesa-7.8.2.orig/src/mesa/drivers/windows/gdi/InitCritSections.cpp +++ mesa-7.8.2/src/mesa/drivers/windows/gdi/InitCritSections.cpp @@ -0,0 +1,32 @@ +#include "glapi.h" +#include "glThread.h" + +#ifdef WIN32_THREADS +extern "C" _glthread_Mutex OneTimeLock; +extern "C" _glthread_Mutex GenTexturesLock; + +extern "C" void FreeAllTSD(void); + +class _CriticalSectionInit +{ +public: + static _CriticalSectionInit m_inst; + + _CriticalSectionInit() + { + _glthread_INIT_MUTEX(OneTimeLock); + _glthread_INIT_MUTEX(GenTexturesLock); + } + + ~_CriticalSectionInit() + { + _glthread_DESTROY_MUTEX(OneTimeLock); + _glthread_DESTROY_MUTEX(GenTexturesLock); + FreeAllTSD(); + } +}; + +_CriticalSectionInit _CriticalSectionInit::m_inst; + + +#endif --- mesa-7.8.2.orig/src/mesa/drivers/windows/gldirect/gldirect.rc +++ mesa-7.8.2/src/mesa/drivers/windows/gldirect/gldirect.rc @@ -0,0 +1,43 @@ +/**************************************************************************** +* +* Mesa 3-D graphics library +* Direct3D Driver Interface +* +* ======================================================================== +* +* Copyright (C) 1991-2004 SciTech Software, 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"), +* to deal in the Software without restriction, including without limitation +* the rights to use, copy, modify, merge, publish, distribute, sublicense, +* and/or sell copies of the Software, and to permit persons to whom the +* Software is furnished to do so, subject to the following conditions: +* +* The above copyright notice and this permission notice shall be included +* in all copies or substantial portions of the Software. +* +* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +* SCITECH SOFTWARE INC BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF +* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +* SOFTWARE. +* +* ====================================================================== +* +* Language: Windows Resource Compiler +* Environment: Windows 95 +* +****************************************************************************/ + +#ifndef WORKSHOP_INVOKED + #include +#endif + +#define FILE_DESCRIPTION "SciTech GLDirect" +#define ORIG_FILENAME "opengl32.dll" +#define FILE_TYPE VFT_DLL + +#include "gldirect/gldver.ver" --- mesa-7.8.2.orig/src/mesa/drivers/windows/gldirect/opengl32.ref +++ mesa-7.8.2/src/mesa/drivers/windows/gldirect/opengl32.ref @@ -0,0 +1,495 @@ +;**************************************************************************** +;* +;* Mesa 3-D graphics library +;* Direct3D Driver Interface +;* +;* ======================================================================== +;* +;* Copyright (C) 1991-2004 SciTech Software, 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"), +;* to deal in the Software without restriction, including without limitation +;* the rights to use, copy, modify, merge, publish, distribute, sublicense, +;* and/or sell copies of the Software, and to permit persons to whom the +;* Software is furnished to do so, subject to the following conditions: +;* +;* The above copyright notice and this permission notice shall be included +;* in all copies or substantial portions of the Software. +;* +;* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +;* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +;* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +;* SCITECH SOFTWARE INC BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +;* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF +;* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +;* SOFTWARE. +;* +;* ====================================================================== +;* +;* Language: ANSI C +;* Environment: Windows 9x/2000/XP/XBox (Win32) +;* +;* Description: DLL Module definition file +;* +;****************************************************************************/ + +DESCRIPTION 'GLDirect' + +VERSION 3.0 + +EXPORTS + glAccum + glAlphaFunc + glAreTexturesResident + glArrayElement + glBegin + glBindTexture + glBitmap + glBlendFunc + glCallList + glCallLists + glClear + glClearAccum + glClearIndex + glClearColor + glClearDepth + glClearStencil + glClipPlane + glColor3b + glColor3d + glColor3f + glColor3i + glColor3s + glColor3ub + glColor3ui + glColor3us + glColor4b + glColor4d + glColor4f + glColor4i + glColor4s + glColor4ub + glColor4ui + glColor4us + glColor3bv + glColor3dv + glColor3fv + glColor3iv + glColor3sv + glColor3ubv + glColor3uiv + glColor3usv + glColor4bv + glColor4dv + glColor4fv + glColor4iv + glColor4sv + glColor4ubv + glColor4uiv + glColor4usv + glColorMask + glColorMaterial + glColorPointer + glColorTableEXT + glColorSubTableEXT + glCopyPixels + glCopyTexImage1D + glCopyTexImage2D + glCopyTexSubImage1D + glCopyTexSubImage2D + glCullFace + glDepthFunc + glDepthMask + glDepthRange + glDeleteLists + glDeleteTextures + glDisable + glDisableClientState + glDrawArrays + glDrawBuffer + glDrawElements + glDrawPixels + glEnable + glEnableClientState + glEnd + glEndList + glEvalCoord1d + glEvalCoord1f + glEvalCoord1dv + glEvalCoord1fv + glEvalCoord2d + glEvalCoord2f + glEvalCoord2dv + glEvalCoord2fv + glEvalPoint1 + glEvalPoint2 + glEvalMesh1 + glEdgeFlag + glEdgeFlagv + glEdgeFlagPointer + glEvalMesh2 + glFeedbackBuffer + glFinish + glFlush + glFogf + glFogi + glFogfv + glFogiv + glFrontFace + glFrustum + glGenLists + glGenTextures + glGetBooleanv + glGetClipPlane + glGetColorTableEXT + glGetColorTableParameterivEXT + glGetColorTableParameterfvEXT + glGetDoublev + glGetError + glGetFloatv + glGetIntegerv + glGetLightfv + glGetLightiv + glGetMapdv + glGetMapfv + glGetMapiv + glGetMaterialfv + glGetMaterialiv + glGetPixelMapfv + glGetPixelMapuiv + glGetPixelMapusv + glGetPointerv + glGetPolygonStipple + glGetString + glGetTexEnvfv + glGetTexEnviv + glGetTexGeniv + glGetTexGendv + glGetTexGenfv + glGetTexImage + glGetTexLevelParameterfv + glGetTexLevelParameteriv + glGetTexParameterfv + glGetTexParameteriv + glHint + glIndexd + glIndexf + glIndexi + glIndexs + glIndexub + glIndexdv + glIndexfv + glIndexiv + glIndexsv + glIndexubv + glIndexMask + glIndexPointer + glInterleavedArrays + glInitNames + glIsList + glIsTexture + glLightf + glLighti + glLightfv + glLightiv + glLightModelf + glLightModeli + glLightModelfv + glLightModeliv + glLineWidth + glLineStipple + glListBase + glLoadIdentity + glLoadMatrixd + glLoadMatrixf + glLoadName + glLogicOp + glMap1d + glMap1f + glMap2d + glMap2f + glMapGrid1d + glMapGrid1f + glMapGrid2d + glMapGrid2f + glMaterialf + glMateriali + glMaterialfv + glMaterialiv + glMatrixMode + glMultMatrixd + glMultMatrixf + glNewList + glNormal3b + glNormal3d + glNormal3f + glNormal3i + glNormal3s + glNormal3bv + glNormal3dv + glNormal3fv + glNormal3iv + glNormal3sv + glNormalPointer + glOrtho + glPassThrough + glPixelMapfv + glPixelMapuiv + glPixelMapusv + glPixelStoref + glPixelStorei + glPixelTransferf + glPixelTransferi + glPixelZoom + glPointSize + glPolygonMode + glPolygonOffset + glPolygonOffsetEXT + glPolygonStipple + glPopAttrib + glPopClientAttrib + glPopMatrix + glPopName + glPrioritizeTextures + glPushMatrix + glRasterPos2d + glRasterPos2f + glRasterPos2i + glRasterPos2s + glRasterPos3d + glRasterPos3f + glRasterPos3i + glRasterPos3s + glRasterPos4d + glRasterPos4f + glRasterPos4i + glRasterPos4s + glRasterPos2dv + glRasterPos2fv + glRasterPos2iv + glRasterPos2sv + glRasterPos3dv + glRasterPos3fv + glRasterPos3iv + glRasterPos3sv + glRasterPos4dv + glRasterPos4fv + glRasterPos4iv + glRasterPos4sv + glReadBuffer + glReadPixels + glRectd + glRectf + glRecti + glRects + glRectdv + glRectfv + glRectiv + glRectsv + glScissor + glIsEnabled + glPushAttrib + glPushClientAttrib + glPushName + glRenderMode + glRotated + glRotatef + glSelectBuffer + glScaled + glScalef + glShadeModel + glStencilFunc + glStencilMask + glStencilOp + glTexCoord1d + glTexCoord1f + glTexCoord1i + glTexCoord1s + glTexCoord2d + glTexCoord2f + glTexCoord2i + glTexCoord2s + glTexCoord3d + glTexCoord3f + glTexCoord3i + glTexCoord3s + glTexCoord4d + glTexCoord4f + glTexCoord4i + glTexCoord4s + glTexCoord1dv + glTexCoord1fv + glTexCoord1iv + glTexCoord1sv + glTexCoord2dv + glTexCoord2fv + glTexCoord2iv + glTexCoord2sv + glTexCoord3dv + glTexCoord3fv + glTexCoord3iv + glTexCoord3sv + glTexCoord4dv + glTexCoord4fv + glTexCoord4iv + glTexCoord4sv + glTexCoordPointer + glTexGend + glTexGenf + glTexGeni + glTexGendv + glTexGeniv + glTexGenfv + glTexEnvf + glTexEnvi + glTexEnvfv + glTexEnviv + glTexImage1D + glTexImage2D + glTexParameterf + glTexParameteri + glTexParameterfv + glTexParameteriv + glTexSubImage1D + glTexSubImage2D + glTranslated + glTranslatef + glVertex2d + glVertex2f + glVertex2i + glVertex2s + glVertex3d + glVertex3f + glVertex3i + glVertex3s + glVertex4d + glVertex4f + glVertex4i + glVertex4s + glVertex2dv + glVertex2fv + glVertex2iv + glVertex2sv + glVertex3dv + glVertex3fv + glVertex3iv + glVertex3sv + glVertex4dv + glVertex4fv + glVertex4iv + glVertex4sv + glVertexPointer + glViewport + + glBlendEquationEXT + glBlendColorEXT + glVertexPointerEXT + glNormalPointerEXT + glColorPointerEXT + glIndexPointerEXT + glTexCoordPointerEXT + glEdgeFlagPointerEXT + glGetPointervEXT + glArrayElementEXT + glDrawArraysEXT + glBindTextureEXT + glDeleteTexturesEXT + glGenTexturesEXT + glPrioritizeTexturesEXT + glCopyTexSubImage3DEXT + glTexImage3DEXT + glTexSubImage3DEXT + + glWindowPos4fMESA + glWindowPos2iMESA + glWindowPos2sMESA + glWindowPos2fMESA + glWindowPos2dMESA + glWindowPos2ivMESA + glWindowPos2svMESA + glWindowPos2fvMESA + glWindowPos2dvMESA + glWindowPos3iMESA + glWindowPos3sMESA + glWindowPos3fMESA + glWindowPos3dMESA + glWindowPos3ivMESA + glWindowPos3svMESA + glWindowPos3fvMESA + glWindowPos3dvMESA + glWindowPos4iMESA + glWindowPos4sMESA + glWindowPos4dMESA + glWindowPos4ivMESA + glWindowPos4svMESA + glWindowPos4fvMESA + glWindowPos4dvMESA + glResizeBuffersMESA + + wglCopyContext + wglCreateContext + wglCreateLayerContext + wglDeleteContext + wglDescribeLayerPlane + wglGetCurrentContext + wglGetCurrentDC + wglGetLayerPaletteEntries + wglGetProcAddress + wglMakeCurrent + wglRealizeLayerPalette + wglSetLayerPaletteEntries + wglShareLists + wglSwapLayerBuffers + wglUseFontBitmapsA + wglUseFontBitmapsW + wglUseFontOutlinesA + wglUseFontOutlinesW + +;These functions are identical and therefore share the same addresses + ChoosePixelFormat = wglChoosePixelFormat + DescribePixelFormat = wglDescribePixelFormat + GetPixelFormat = wglGetPixelFormat + SetPixelFormat = wglSetPixelFormat + SwapBuffers = wglSwapBuffers + + wglChoosePixelFormat + wglDescribePixelFormat + wglGetPixelFormat + wglSetPixelFormat + wglSwapBuffers + + glActiveTextureARB + glClientActiveTextureARB + glMultiTexCoord1dARB + glMultiTexCoord1dvARB + glMultiTexCoord1fARB + glMultiTexCoord1fvARB + glMultiTexCoord1iARB + glMultiTexCoord1ivARB + glMultiTexCoord1sARB + glMultiTexCoord1svARB + glMultiTexCoord2dARB + glMultiTexCoord2dvARB + glMultiTexCoord2fARB + glMultiTexCoord2fvARB + glMultiTexCoord2iARB + glMultiTexCoord2ivARB + glMultiTexCoord2sARB + glMultiTexCoord2svARB + glMultiTexCoord3dARB + glMultiTexCoord3dvARB + glMultiTexCoord3fARB + glMultiTexCoord3fvARB + glMultiTexCoord3iARB + glMultiTexCoord3ivARB + glMultiTexCoord3sARB + glMultiTexCoord3svARB + glMultiTexCoord4dARB + glMultiTexCoord4dvARB + glMultiTexCoord4fARB + glMultiTexCoord4fvARB + glMultiTexCoord4iARB + glMultiTexCoord4ivARB + glMultiTexCoord4sARB + glMultiTexCoord4svARB --- mesa-7.8.2.orig/src/mesa/drivers/windows/gldirect/mesasw/colors.h +++ mesa-7.8.2/src/mesa/drivers/windows/gldirect/mesasw/colors.h @@ -0,0 +1,520 @@ +/* File name : colors.h + * Version : 2.3 + * + * Header file for display driver for Mesa 2.3 under + * Windows95 and WindowsNT + * This file defines macros and global variables needed + * for converting color format + * + * Copyright (C) 1996- Li Wei + * Address : Institute of Artificial Intelligence + * : & Robotics + * : Xi'an Jiaotong University + * Email : liwei@aiar.xjtu.edu.cn + * Web page : http://sun.aiar.xjtu.edu.cn + * + * This file and its associations are partially based on the + * Windows NT driver for Mesa, written by Mark Leaming + * (mark@rsinc.com). + */ + +/* + * Macros for pixel format defined + */ + +/* + * Revision 1.1 2004/04/20 11:13:11 alanh + * add SciTech's GLDirect driver for Windows. + * + * This code is donated to Mesa which allows the usage of + * a Direct3D layer (DX7, DX8, DX9 or complete software fallback). + * + * No build system exists for this code yet, that will come..... + * + * Revision 1.1.1.1 1999/08/19 00:55:42 jtg + * Imported sources + * + * Revision 1.2 1999/01/03 03:08:57 brianp + * Ted Jump's changes + * + * Revision 1.1 1999/01/03 03:08:12 brianp + * Initial revision + * + * Revision 2.0.2 1997/4/30 15:58:00 CST by Li Wei(liwei@aiar.xjtu.edu.cn) + * Add LUTs need for dithering + */ + +/* + * Revision 1.1 2004/04/20 11:13:11 alanh + * add SciTech's GLDirect driver for Windows. + * + * This code is donated to Mesa which allows the usage of + * a Direct3D layer (DX7, DX8, DX9 or complete software fallback). + * + * No build system exists for this code yet, that will come..... + * + * Revision 1.1.1.1 1999/08/19 00:55:42 jtg + * Imported sources + * + * Revision 1.2 1999/01/03 03:08:57 brianp + * Ted Jump's changes + * + * Revision 1.1 1999/01/03 03:08:12 brianp + * Initial revision + * + * Revision 2.0.1 1997/4/29 15:52:00 CST by Li Wei(liwei@aiar.xjtu.edu.cn) + * Add BGR8 Macro + */ + +/* + * Revision 1.1 2004/04/20 11:13:11 alanh + * add SciTech's GLDirect driver for Windows. + * + * This code is donated to Mesa which allows the usage of + * a Direct3D layer (DX7, DX8, DX9 or complete software fallback). + * + * No build system exists for this code yet, that will come..... + * + * Revision 1.1.1.1 1999/08/19 00:55:42 jtg + * Imported sources + * + * Revision 1.2 1999/01/03 03:08:57 brianp + * Ted Jump's changes + * + * Revision 1.1 1999/01/03 03:08:12 brianp + * Initial revision + * + * Revision 2.0 1996/11/15 10:55:00 CST by Li Wei(liwei@aiar.xjtu.edu.cn) + * Initial revision + */ +/* Values for wmesa->pixelformat: */ + +#define PF_8A8B8G8R 3 /* 32-bit TrueColor: 8-A, 8-B, 8-G, 8-R */ +#define PF_8R8G8B 4 /* 32-bit TrueColor: 8-R, 8-G, 8-B */ +#define PF_5R6G5B 5 /* 16-bit TrueColor: 5-R, 6-G, 5-B bits */ +#define PF_DITHER8 6 /* Dithered RGB using a lookup table */ +#define PF_LOOKUP 7 /* Undithered RGB using a lookup table */ +#define PF_GRAYSCALE 10 /* Grayscale or StaticGray */ +#define PF_BADFORMAT 11 +#define PF_INDEX8 12 + +char ColorMap16[] = { +0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, +0x01,0x01,0x01,0x01,0x01,0x01,0x01,0x01, +0x02,0x02,0x02,0x02,0x02,0x02,0x02,0x02, +0x03,0x03,0x03,0x03,0x03,0x03,0x03,0x03, +0x04,0x04,0x04,0x04,0x04,0x04,0x04,0x04, +0x05,0x05,0x05,0x05,0x05,0x05,0x05,0x05, +0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x06, +0x07,0x07,0x07,0x07,0x07,0x07,0x07,0x07, +0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08, +0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09, +0x0A,0x0A,0x0A,0x0A,0x0A,0x0A,0x0A,0x0A, +0x0B,0x0B,0x0B,0x0B,0x0B,0x0B,0x0B,0x0B, +0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C,0x0C, +0x0D,0x0D,0x0D,0x0D,0x0D,0x0D,0x0D,0x0D, +0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E, +0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F,0x0F, +0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10, +0x11,0x11,0x11,0x11,0x11,0x11,0x11,0x11, +0x12,0x12,0x12,0x12,0x12,0x12,0x12,0x12, +0x13,0x13,0x13,0x13,0x13,0x13,0x13,0x13, +0x14,0x14,0x14,0x14,0x14,0x14,0x14,0x14, +0x15,0x15,0x15,0x15,0x15,0x15,0x15,0x15, +0x16,0x16,0x16,0x16,0x16,0x16,0x16,0x16, +0x17,0x17,0x17,0x17,0x17,0x17,0x17,0x17, +0x18,0x18,0x18,0x18,0x18,0x18,0x18,0x18, +0x19,0x19,0x19,0x19,0x19,0x19,0x19,0x19, +0x1A,0x1A,0x1A,0x1A,0x1A,0x1A,0x1A,0x1A, +0x1B,0x1B,0x1B,0x1B,0x1B,0x1B,0x1B,0x1B, +0x1C,0x1C,0x1C,0x1C,0x1C,0x1C,0x1C,0x1C, +0x1D,0x1D,0x1D,0x1D,0x1D,0x1D,0x1D,0x1D, +0x1E,0x1E,0x1E,0x1E,0x1E,0x1E,0x1E,0x1E, +0x1F,0x1F,0x1F,0x1F,0x1F,0x1F,0x1F,0x1F}; + +#define BGR8(r,g,b) (unsigned)(((BYTE)(b & 0xc0 | (g & 0xe0)>>2 | (r & 0xe0)>>5))) +#ifdef DDRAW +#define BGR16(r,g,b) ((WORD)(((BYTE)(ColorMap16[b]) | ((BYTE)(g&0xfc) << 3)) | (((WORD)(BYTE)(ColorMap16[r])) << 11))) +#else +#define BGR16(r,g,b) ((WORD)(((BYTE)(ColorMap16[b]) | ((BYTE)(ColorMap16[g]) << 5)) | (((WORD)(BYTE)(ColorMap16[r])) << 10))) +#endif +#define BGR24(r,g,b) (unsigned long)(((DWORD)(((BYTE)(b)|((WORD)((BYTE)(g))<<8))|(((DWORD)(BYTE)(r))<<16))) << 8) +#define BGR32(r,g,b) (unsigned long)((DWORD)(((BYTE)(b)|((WORD)((BYTE)(g))<<8))|(((DWORD)(BYTE)(r))<<16))) + + + +/* + * If pixelformat==PF_8A8B8G8R: + */ +#define PACK_8A8B8G8R( R, G, B, A ) \ + ( ((A) << 24) | ((B) << 16) | ((G) << 8) | (R) ) + + +/* + * If pixelformat==PF_8R8G8B: + */ +#define PACK_8R8G8B( R, G, B) ( ((R) << 16) | ((G) << 8) | (B) ) + + +/* + * If pixelformat==PF_5R6G5B: + */ + + +#ifdef DDRAW +#define PACK_5R6G5B( R, G, B) ((WORD)(((BYTE)(ColorMap16[B]) | ((BYTE)(G&0xfc) << 3)) | (((WORD)(BYTE)(ColorMap16[R])) << 11))) +#else +#define PACK_5R6G5B( R, G, B) ((WORD)(((BYTE)(ColorMap16[B]) | ((BYTE)(ColorMap16[G]) << 5)) | (((WORD)(BYTE)(ColorMap16[R])) << 10))) +#endif +/*---------------------------------------------------------------------------- + +Division lookup tables. These tables compute 0-255 divided by 51 and +modulo 51. These tables could approximate gamma correction. + +*/ + +char unsigned const aDividedBy51Rounded[256] = +{ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, + 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, +}; + +char unsigned const aDividedBy51[256] = +{ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, +}; + +char unsigned const aModulo51[256] = +{ + 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, + 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, + 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 0, 1, 2, 3, 4, 5, 6, + 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, + 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, + 44, 45, 46, 47, 48, 49, 50, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, + 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, + 49, 50, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, + 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, + 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 0, 1, 2, 3, + 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, + 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 0, +}; + +/*---------------------------------------------------------------------------- + +Multiplication LUTs. These compute 0-5 times 6 and 36. + +*/ + +char unsigned const aTimes6[6] = +{ + 0, 6, 12, 18, 24, 30 +}; + +char unsigned const aTimes36[6] = +{ + 0, 36, 72, 108, 144, 180 +}; + + +/*---------------------------------------------------------------------------- + +Dither matrices for 8 bit to 2.6 bit halftones. + +*/ + +char unsigned const aHalftone16x16[256] = +{ + 0, 44, 9, 41, 3, 46, 12, 43, 1, 44, 10, 41, 3, 46, 12, 43, + 34, 16, 25, 19, 37, 18, 28, 21, 35, 16, 26, 19, 37, 18, 28, 21, + 38, 6, 47, 3, 40, 9, 50, 6, 38, 7, 47, 4, 40, 9, 49, 6, + 22, 28, 13, 31, 25, 31, 15, 34, 22, 29, 13, 32, 24, 31, 15, 34, + 2, 46, 12, 43, 1, 45, 10, 42, 2, 45, 11, 42, 1, 45, 11, 42, + 37, 18, 27, 21, 35, 17, 26, 20, 36, 17, 27, 20, 36, 17, 26, 20, + 40, 8, 49, 5, 38, 7, 48, 4, 39, 8, 48, 5, 39, 7, 48, 4, + 24, 30, 15, 33, 23, 29, 13, 32, 23, 30, 14, 33, 23, 29, 14, 32, + 2, 46, 12, 43, 0, 44, 10, 41, 3, 47, 12, 44, 0, 44, 10, 41, + 37, 18, 27, 21, 35, 16, 25, 19, 37, 19, 28, 22, 35, 16, 25, 19, + 40, 9, 49, 5, 38, 7, 47, 4, 40, 9, 50, 6, 38, 6, 47, 3, + 24, 30, 15, 34, 22, 29, 13, 32, 25, 31, 15, 34, 22, 28, 13, 31, + 1, 45, 11, 42, 2, 46, 11, 42, 1, 45, 10, 41, 2, 46, 11, 43, + 36, 17, 26, 20, 36, 17, 27, 21, 35, 16, 26, 20, 36, 18, 27, 21, + 39, 8, 48, 4, 39, 8, 49, 5, 38, 7, 48, 4, 39, 8, 49, 5, + 23, 29, 14, 33, 24, 30, 14, 33, 23, 29, 13, 32, 24, 30, 14, 33, +}; + +char unsigned const aHalftone8x8[64] = +{ + 0, 38, 9, 47, 2, 40, 11, 50, + 25, 12, 35, 22, 27, 15, 37, 24, + 6, 44, 3, 41, 8, 47, 5, 43, + 31, 19, 28, 15, 34, 21, 31, 18, + 1, 39, 11, 49, 0, 39, 10, 48, + 27, 14, 36, 23, 26, 13, 35, 23, + 7, 46, 4, 43, 7, 45, 3, 42, + 33, 20, 30, 17, 32, 19, 29, 16, +}; + +char unsigned const aHalftone4x4_1[16] = +{ + 0, 25, 6, 31, + 38, 12, 44, 19, + 9, 35, 3, 28, + 47, 22, 41, 15 +}; + +char unsigned const aHalftone4x4_2[16] = +{ + 41, 3, 9, 28, + 35, 15, 22, 47, + 6, 25, 38, 0, + 19, 44, 31, 12 +}; + +/*************************************************************************** + aWinGHalftoneTranslation + + Translates a 2.6 bit-per-pixel halftoned representation into the + slightly rearranged WinG Halftone Palette. +*/ + +char unsigned const aWinGHalftoneTranslation[216] = +{ + 0, + 29, + 30, + 31, + 32, + 249, + 33, + 34, + 35, + 36, + 37, + 38, + 39, + 40, + 41, + 42, + 43, + 44, + 45, + 46, + 47, + 48, + 49, + 50, + 51, + 52, + 53, + 54, + 55, + 56, + 250, + 250, + 57, + 58, + 59, + 251, + 60, + 61, + 62, + 63, + 64, + 65, + 66, + 67, + 68, + 69, + 70, + 71, + 72, + 73, + 74, + 75, + 76, + 77, + 78, + 79, + 80, + 81, + 82, + 83, + 84, + 85, + 86, + 87, + 88, + 89, + 250, + 90, + 91, + 92, + 93, + 94, + 95, + 96, + 97, + 98, + 99, + 100, + 101, + 102, + 103, + 104, + 105, + 106, + 107, + 108, + 109, + 110, + 111, + 227, + 112, + 113, + 114, + 115, + 116, + 117, + 118, + 119, + 151, + 120, + 121, + 122, + 123, + 124, + 228, + 125, + 126, + 229, + 133, + 162, + 135, + 131, + 132, + 137, + 166, + 134, + 140, + 130, + 136, + 143, + 138, + 139, + 174, + 141, + 142, + 177, + 129, + 144, + 145, + 146, + 147, + 148, + 149, + 150, + 157, + 152, + 153, + 154, + 155, + 156, + 192, + 158, + 159, + 160, + 161, + 196, + 163, + 164, + 165, + 127, + 199, + 167, + 168, + 169, + 170, + 171, + 172, + 173, + 207, + 175, + 176, + 210, + 178, + 179, + 180, + 181, + 182, + 183, + 184, + 185, + 186, + 187, + 188, + 189, + 190, + 191, + 224, + 193, + 194, + 195, + 252, + 252, + 197, + 198, + 128, + 253, + 252, + 200, + 201, + 202, + 203, + 204, + 205, + 206, + 230, + 208, + 209, + 231, + 211, + 212, + 213, + 214, + 215, + 216, + 217, + 218, + 219, + 220, + 221, + 222, + 254, + 223, + 232, + 225, + 226, + 255, +}; --- mesa-7.8.2.orig/src/mesa/drivers/windows/gldirect/mesasw/gld_wgl_mesasw.c +++ mesa-7.8.2/src/mesa/drivers/windows/gldirect/mesasw/gld_wgl_mesasw.c @@ -0,0 +1,1682 @@ +/**************************************************************************** +* +* Mesa 3-D graphics library +* Direct3D Driver Interface +* +* ======================================================================== +* +* Copyright (C) 1991-2004 SciTech Software, 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"), +* to deal in the Software without restriction, including without limitation +* the rights to use, copy, modify, merge, publish, distribute, sublicense, +* and/or sell copies of the Software, and to permit persons to whom the +* Software is furnished to do so, subject to the following conditions: +* +* The above copyright notice and this permission notice shall be included +* in all copies or substantial portions of the Software. +* +* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +* SCITECH SOFTWARE INC BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF +* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +* SOFTWARE. +* +* ====================================================================== +* +* Language: ANSI C +* Environment: Windows 9x/2000/XP/XBox (Win32) +* +* Description: Mesa Software WGL (WindowsGL) +* +****************************************************************************/ + +#include +#define GL_GLEXT_PROTOTYPES +#include +#include + +#include "glheader.h" +#include "colors.h" +#include "context.h" +#include "colormac.h" +#include "dd.h" +#include "depth.h" +#include "extensions.h" +#include "macros.h" +#include "matrix.h" +// #include "mem.h" +//#include "mmath.h" +#include "mtypes.h" +#include "texformat.h" +#include "texstore.h" +#include "teximage.h" +#include "vbo/vbo.h" +#include "swrast/swrast.h" +#include "swrast_setup/swrast_setup.h" +#include "swrast/s_context.h" +#include "swrast/s_depth.h" +#include "swrast/s_lines.h" +#include "swrast/s_triangle.h" +#include "swrast/s_trispan.h" +#include "tnl/tnl.h" +#include "tnl/t_context.h" +#include "tnl/t_pipeline.h" + +#include "dglcontext.h" +#include "gld_driver.h" + +//--------------------------------------------------------------------------- +//--------------------------------------------------------------------------- + +DGL_pixelFormat pfTemplateMesaSW = +{ + { + sizeof(PIXELFORMATDESCRIPTOR), // Size of the data structure + 1, // Structure version - should be 1 + // Flags: + PFD_DRAW_TO_WINDOW | // The buffer can draw to a window or device surface. + PFD_DRAW_TO_BITMAP | // The buffer can draw to a bitmap. (DaveM) + PFD_SUPPORT_GDI | // The buffer supports GDI drawing. (DaveM) + PFD_SUPPORT_OPENGL | // The buffer supports OpenGL drawing. + PFD_DOUBLEBUFFER | // The buffer is double-buffered. + 0, // Placeholder for easy commenting of above flags + PFD_TYPE_RGBA, // Pixel type RGBA. + 32, // Total colour bitplanes (excluding alpha bitplanes) + 8, 0, // Red bits, shift + 8, 8, // Green bits, shift + 8, 16, // Blue bits, shift + 8, 24, // Alpha bits, shift (destination alpha) + 64, // Accumulator bits (total) + 16, 16, 16, 16, // Accumulator bits: Red, Green, Blue, Alpha + 16, // Depth bits + 8, // Stencil bits + 0, // Number of auxiliary buffers + 0, // Layer type + 0, // Specifies the number of overlay and underlay planes. + 0, // Layer mask + 0, // Specifies the transparent color or index of an underlay plane. + 0 // Damage mask + }, + 0, // Unused +}; + +//--------------------------------------------------------------------------- +// Extensions +//--------------------------------------------------------------------------- + +typedef struct { + PROC proc; + char *name; +} GLD_extension; + +static GLD_extension GLD_extList[] = { +#ifdef GL_EXT_polygon_offset + { (PROC)glPolygonOffsetEXT, "glPolygonOffsetEXT" }, +#endif + { (PROC)glBlendEquationEXT, "glBlendEquationEXT" }, + { (PROC)glBlendColorEXT, "glBlendColorExt" }, + { (PROC)glVertexPointerEXT, "glVertexPointerEXT" }, + { (PROC)glNormalPointerEXT, "glNormalPointerEXT" }, + { (PROC)glColorPointerEXT, "glColorPointerEXT" }, + { (PROC)glIndexPointerEXT, "glIndexPointerEXT" }, + { (PROC)glTexCoordPointerEXT, "glTexCoordPointer" }, + { (PROC)glEdgeFlagPointerEXT, "glEdgeFlagPointerEXT" }, + { (PROC)glGetPointervEXT, "glGetPointervEXT" }, + { (PROC)glArrayElementEXT, "glArrayElementEXT" }, + { (PROC)glDrawArraysEXT, "glDrawArrayEXT" }, + { (PROC)glAreTexturesResidentEXT, "glAreTexturesResidentEXT" }, + { (PROC)glBindTextureEXT, "glBindTextureEXT" }, + { (PROC)glDeleteTexturesEXT, "glDeleteTexturesEXT" }, + { (PROC)glGenTexturesEXT, "glGenTexturesEXT" }, + { (PROC)glIsTextureEXT, "glIsTextureEXT" }, + { (PROC)glPrioritizeTexturesEXT, "glPrioritizeTexturesEXT" }, + { (PROC)glCopyTexSubImage3DEXT, "glCopyTexSubImage3DEXT" }, + { (PROC)glTexImage3DEXT, "glTexImage3DEXT" }, + { (PROC)glTexSubImage3DEXT, "glTexSubImage3DEXT" }, + { (PROC)glPointParameterfEXT, "glPointParameterfEXT" }, + { (PROC)glPointParameterfvEXT, "glPointParameterfvEXT" }, + { (PROC)glLockArraysEXT, "glLockArraysEXT" }, + { (PROC)glUnlockArraysEXT, "glUnlockArraysEXT" }, + { NULL, "\0" } +}; + +//--------------------------------------------------------------------------- +// WMesa Internal Functions +//--------------------------------------------------------------------------- + +#define PAGE_FILE 0xffffffff + +#define REDBITS 0x03 +#define REDSHIFT 0x00 +#define GREENBITS 0x03 +#define GREENSHIFT 0x03 +#define BLUEBITS 0x02 +#define BLUESHIFT 0x06 + +typedef struct _dibSection { + HDC hDC; + HANDLE hFileMap; + BOOL fFlushed; + LPVOID base; +} WMDIBSECTION, *PWMDIBSECTION; + +typedef struct wmesa_context { + HWND Window; + HDC hDC; + HPALETTE hPalette; + HPALETTE hOldPalette; + HPEN hPen; + HPEN hOldPen; + HCURSOR hOldCursor; + COLORREF crColor; + // 3D projection stuff + RECT drawRect; + UINT uiDIBoffset; + // OpenGL stuff + HPALETTE hGLPalette; + GLuint width; + GLuint height; + GLuint ScanWidth; + GLboolean db_flag; //* double buffered? + GLboolean rgb_flag; //* RGB mode? + GLboolean dither_flag; //* use dither when 256 color mode for RGB? + GLuint depth; //* bits per pixel (1, 8, 24, etc) + ULONG pixel; // current color index or RGBA pixel value + ULONG clearpixel; //* pixel for clearing the color buffers + PBYTE ScreenMem; // WinG memory + BITMAPINFO *IndexFormat; + HPALETTE hPal; // Current Palette + HPALETTE hPalHalfTone; + + + WMDIBSECTION dib; + BITMAPINFO bmi; + HBITMAP hbmDIB; + HBITMAP hOldBitmap; + HBITMAP Old_Compat_BM; + HBITMAP Compat_BM; // Bitmap for double buffering + PBYTE pbPixels; + int nColors; + BYTE cColorBits; + int pixelformat; + + RECT rectOffScreen; + RECT rectSurface; +// HWND hwnd; + DWORD pitch; + PBYTE addrOffScreen; + + // We always double-buffer, for performance reasons, but + // we need to know which of SwapBuffers() or glFlush() to + // handle. If we're emulating, then we update on Flush(), + // otherwise we update on SwapBufers(). KeithH + BOOL bEmulateSingleBuffer; +} WMesaContext, *PWMC; + +#define GLD_GET_WMESA_DRIVER(c) (WMesaContext*)(c)->glPriv + +// TODO: +GLint stereo_flag = 0 ; + +/* If we are double-buffering, we want to get the DC for the + * off-screen DIB, otherwise the DC for the window. + */ +#define DD_GETDC ((Current->db_flag) ? Current->dib.hDC : Current->hDC ) +#define DD_RELEASEDC + +#define FLIP(Y) (Current->height-(Y)-1) + +struct DISPLAY_OPTIONS { + int stereo; + int fullScreen; + int mode; + int bpp; +}; + +struct DISPLAY_OPTIONS displayOptions; + +//--------------------------------------------------------------------------- + +static unsigned char threeto8[8] = { + 0, 0111>>1, 0222>>1, 0333>>1, 0444>>1, 0555>>1, 0666>>1, 0377 +}; + +static unsigned char twoto8[4] = { + 0, 0x55, 0xaa, 0xff +}; + +static unsigned char oneto8[2] = { + 0, 255 +}; + +//--------------------------------------------------------------------------- + +BYTE DITHER_RGB_2_8BIT( int red, int green, int blue, int pixel, int scanline) +{ + char unsigned redtemp, greentemp, bluetemp, paletteindex; + + //*** now, look up each value in the halftone matrix + //*** using an 8x8 ordered dither. + redtemp = aDividedBy51[red] + + (aModulo51[red] > aHalftone8x8[(pixel%8)*8 + + scanline%8]); + greentemp = aDividedBy51[(char unsigned)green] + + (aModulo51[green] > aHalftone8x8[ + (pixel%8)*8 + scanline%8]); + bluetemp = aDividedBy51[(char unsigned)blue] + + (aModulo51[blue] > aHalftone8x8[ + (pixel%8)*8 +scanline%8]); + + //*** recombine the halftoned rgb values into a palette index + paletteindex = + redtemp + aTimes6[greentemp] + aTimes36[bluetemp]; + + //*** and translate through the wing halftone palette + //*** translation vector to give the correct value. + return aWinGHalftoneTranslation[paletteindex]; +} + +//--------------------------------------------------------------------------- + +static unsigned char componentFromIndex(UCHAR i, UINT nbits, UINT shift) +{ + unsigned char val; + + val = i >> shift; + switch (nbits) { + + case 1: + val &= 0x1; + return oneto8[val]; + + case 2: + val &= 0x3; + return twoto8[val]; + + case 3: + val &= 0x7; + return threeto8[val]; + + default: + return 0; + } +} + +//--------------------------------------------------------------------------- + + +void wmSetPixel(PWMC pwc, int iScanLine, int iPixel, BYTE r, BYTE g, BYTE b) +{ + WMesaContext *Current = pwc; + + // Test for invalid scanline parameter. KeithH + if ((iScanLine < 0) || (iScanLine >= pwc->height)) + return; + + if (Current->db_flag) { + LPBYTE lpb = pwc->pbPixels; + UINT nBypp = pwc->cColorBits >> 3; + UINT nOffset = iPixel % nBypp; + + lpb += pwc->ScanWidth * iScanLine; + lpb += iPixel * nBypp; + + if(nBypp == 1){ + if(pwc->dither_flag) + *lpb = DITHER_RGB_2_8BIT(r,g,b,iScanLine,iPixel); + else + *lpb = BGR8(r,g,b); + } + else if(nBypp == 2) + *((LPWORD)lpb) = BGR16(r,g,b); + else if (nBypp == 3) + *((LPDWORD)lpb) = BGR24(r,g,b); + else if (nBypp == 4) + *((LPDWORD)lpb) = BGR32(r,g,b); + } + else{ + SetPixel(Current->hDC, iPixel, iScanLine, RGB(r,g,b)); + } +} + +//--------------------------------------------------------------------------- + +void wmCreateDIBSection( + HDC hDC, + PWMC pwc, // handle of device context + CONST BITMAPINFO *pbmi, // bitmap size, format, and color data + UINT iUsage // color data type indicator: RGB values or palette indices + ) +{ + DWORD dwSize = 0; + DWORD dwScanWidth; + UINT nBypp = pwc->cColorBits / 8; + HDC hic; + + dwScanWidth = (((pwc->ScanWidth * nBypp)+ 3) & ~3); + + pwc->ScanWidth =pwc->pitch = dwScanWidth; + + if (stereo_flag) + pwc->ScanWidth = 2* pwc->pitch; + + dwSize = sizeof(BITMAPINFO) + (dwScanWidth * pwc->height); + + pwc->dib.hFileMap = CreateFileMapping((HANDLE)PAGE_FILE, + NULL, + PAGE_READWRITE | SEC_COMMIT, + 0, + dwSize, + NULL); + + if (!pwc->dib.hFileMap) + return; + + pwc->dib.base = MapViewOfFile(pwc->dib.hFileMap, + FILE_MAP_ALL_ACCESS, + 0, + 0, + 0); + + if(!pwc->dib.base){ + CloseHandle(pwc->dib.hFileMap); + return; + } + + + CopyMemory(pwc->dib.base, pbmi, sizeof(BITMAPINFO)); + + hic = CreateIC("display", NULL, NULL, NULL); + pwc->dib.hDC = CreateCompatibleDC(hic); + + + pwc->hbmDIB = CreateDIBSection(hic, + &(pwc->bmi), + (iUsage ? DIB_PAL_COLORS : DIB_RGB_COLORS), + &(pwc->pbPixels), + pwc->dib.hFileMap, + 0); + pwc->ScreenMem = pwc->addrOffScreen = pwc->pbPixels; + pwc->hOldBitmap = SelectObject(pwc->dib.hDC, pwc->hbmDIB); + + DeleteDC(hic); + + return; + +} + +//--------------------------------------------------------------------------- + +void wmCreatePalette( PWMC pwdc ) +{ + /* Create a compressed and re-expanded 3:3:2 palette */ + int i; + LOGPALETTE *pPal; + BYTE rb, rs, gb, gs, bb, bs; + + pwdc->nColors = 0x100; + + pPal = (PLOGPALETTE)malloc(sizeof(LOGPALETTE) + + pwdc->nColors * sizeof(PALETTEENTRY)); + memset( pPal, 0, sizeof(LOGPALETTE) + pwdc->nColors * sizeof(PALETTEENTRY) ); + + pPal->palVersion = 0x300; + + rb = REDBITS; + rs = REDSHIFT; + gb = GREENBITS; + gs = GREENSHIFT; + bb = BLUEBITS; + bs = BLUESHIFT; + + if (pwdc->db_flag) { + + /* Need to make two palettes: one for the screen DC and one for the DIB. */ + pPal->palNumEntries = pwdc->nColors; + for (i = 0; i < pwdc->nColors; i++) { + pPal->palPalEntry[i].peRed = componentFromIndex( i, rb, rs ); + pPal->palPalEntry[i].peGreen = componentFromIndex( i, gb, gs ); + pPal->palPalEntry[i].peBlue = componentFromIndex( i, bb, bs ); + pPal->palPalEntry[i].peFlags = 0; + } + pwdc->hGLPalette = CreatePalette( pPal ); + pwdc->hPalette = CreatePalette( pPal ); + } + + else { + pPal->palNumEntries = pwdc->nColors; + for (i = 0; i < pwdc->nColors; i++) { + pPal->palPalEntry[i].peRed = componentFromIndex( i, rb, rs ); + pPal->palPalEntry[i].peGreen = componentFromIndex( i, gb, gs ); + pPal->palPalEntry[i].peBlue = componentFromIndex( i, bb, bs ); + pPal->palPalEntry[i].peFlags = 0; + } + pwdc->hGLPalette = CreatePalette( pPal ); + } + + free(pPal); + +} + +//--------------------------------------------------------------------------- + +/* This function sets the color table of a DIB section + * to match that of the destination DC + */ +BOOL wmSetDibColors(PWMC pwc) +{ + RGBQUAD *pColTab, *pRGB; + PALETTEENTRY *pPal, *pPE; + int i, nColors; + BOOL bRet=TRUE; + DWORD dwErr=0; + + /* Build a color table in the DIB that maps to the + * selected palette in the DC. + */ + nColors = 1 << pwc->cColorBits; + pPal = (PALETTEENTRY *)malloc( nColors * sizeof(PALETTEENTRY)); + memset( pPal, 0, nColors * sizeof(PALETTEENTRY) ); + GetPaletteEntries( pwc->hGLPalette, 0, nColors, pPal ); + pColTab = (RGBQUAD *)malloc( nColors * sizeof(RGBQUAD)); + for (i = 0, pRGB = pColTab, pPE = pPal; i < nColors; i++, pRGB++, pPE++) { + pRGB->rgbRed = pPE->peRed; + pRGB->rgbGreen = pPE->peGreen; + pRGB->rgbBlue = pPE->peBlue; + } + if(pwc->db_flag) + bRet = SetDIBColorTable(pwc->dib.hDC, 0, nColors, pColTab ); + + if(!bRet) + dwErr = GetLastError(); + + free( pColTab ); + free( pPal ); + + return bRet; +} + +//--------------------------------------------------------------------------- + +static void wmSetPixelFormat( PWMC wc, HDC hDC) +{ + if(wc->rgb_flag) + wc->cColorBits = GetDeviceCaps(hDC, BITSPIXEL); + else + wc->cColorBits = 8; + switch(wc->cColorBits){ + case 8: + if(wc->dither_flag != GL_TRUE) + wc->pixelformat = PF_INDEX8; + else + wc->pixelformat = PF_DITHER8; + break; + case 16: + wc->pixelformat = PF_5R6G5B; + break; + case 32: + wc->pixelformat = PF_8R8G8B; + break; + default: + wc->pixelformat = PF_BADFORMAT; + } +} + +//--------------------------------------------------------------------------- + +/* + * This function creates the DIB section that is used for combined + * GL and GDI calls + */ +BOOL wmCreateBackingStore(PWMC pwc, long lxSize, long lySize) +{ + HDC hdc = pwc->hDC; + LPBITMAPINFO pbmi = &(pwc->bmi); + int iUsage; + + pbmi->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); + pbmi->bmiHeader.biWidth = lxSize; + pbmi->bmiHeader.biHeight= -lySize; + pbmi->bmiHeader.biPlanes = 1; + if(pwc->rgb_flag) + pbmi->bmiHeader.biBitCount = GetDeviceCaps(pwc->hDC, BITSPIXEL); + else + pbmi->bmiHeader.biBitCount = 8; + pbmi->bmiHeader.biCompression = BI_RGB; + pbmi->bmiHeader.biSizeImage = 0; + pbmi->bmiHeader.biXPelsPerMeter = 0; + pbmi->bmiHeader.biYPelsPerMeter = 0; + pbmi->bmiHeader.biClrUsed = 0; + pbmi->bmiHeader.biClrImportant = 0; + + iUsage = (pbmi->bmiHeader.biBitCount <= 8) ? DIB_PAL_COLORS : DIB_RGB_COLORS; + + pwc->cColorBits = pbmi->bmiHeader.biBitCount; + pwc->ScanWidth = pwc->pitch = lxSize; + pwc->width = lxSize; + pwc->height = lySize; + + wmCreateDIBSection(hdc, pwc, pbmi, iUsage); + + if ((iUsage == DIB_PAL_COLORS) && !(pwc->hGLPalette)) { + wmCreatePalette( pwc ); + wmSetDibColors( pwc ); + } + wmSetPixelFormat(pwc, pwc->hDC); + return TRUE; +} + +//--------------------------------------------------------------------------- + +/* + * Free up the dib section that was created + */ +BOOL wmDeleteBackingStore(PWMC pwc) +{ + SelectObject(pwc->dib.hDC, pwc->hOldBitmap); + DeleteDC(pwc->dib.hDC); + DeleteObject(pwc->hbmDIB); + UnmapViewOfFile(pwc->dib.base); + CloseHandle(pwc->dib.hFileMap); + return TRUE; +} + +//--------------------------------------------------------------------------- + +/* + * Blit memory DC to screen DC + */ +BOOL wmFlush(PWMC pwc, HDC hDC) +{ + BOOL bRet = 0; + DWORD dwErr = 0; + +// Now using bEmulateSingleBuffer in the calling function. KeithH + +// if(pwc->db_flag){ + bRet = BitBlt(hDC, 0, 0, pwc->width, pwc->height, + pwc->dib.hDC, 0, 0, SRCCOPY); +// } + + return bRet; + +} + +//--------------------------------------------------------------------------- +// Support Functions +//--------------------------------------------------------------------------- + +static void flush(GLcontext* ctx) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); +/* + if((Current->rgb_flag &&!(Current->db_flag)) + ||(!Current->rgb_flag)) + { + wmFlush(Current, Current->hDC); + } +*/ + // Only flush if we're not in double-buffer mode. KeithH + // The demo fractal.c calls glutSwapBuffers() then glFlush()! + if (Current->bEmulateSingleBuffer) { + wmFlush(Current, Current->hDC); + } +} + + +//--------------------------------------------------------------------------- + +/* + * Set the color used to clear the color buffer. + */ +//static void clear_color( GLcontext* ctx, const GLchan color[4] ) +// Changed for Mesa 5.x. KeithH +static void clear_color( + GLcontext* ctx, + const GLfloat color[4]) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + GLubyte col[4]; + CLAMPED_FLOAT_TO_UBYTE(col[0], color[0]); + CLAMPED_FLOAT_TO_UBYTE(col[1], color[1]); + CLAMPED_FLOAT_TO_UBYTE(col[2], color[2]); + Current->clearpixel = RGB(col[0], col[1], col[2]); +} + + +//--------------------------------------------------------------------------- + + +/* + * Clear the specified region of the color buffer using the clear color + * or index as specified by one of the two functions above. + * + * This procedure clears either the front and/or the back COLOR buffers. + * Only the "left" buffer is cleared since we are not stereo. + * Clearing of the other non-color buffers is left to the swrast. + * We also only clear the color buffers if the color masks are all 1's. + * Otherwise, we let swrast do it. + */ + +static clear(GLcontext* ctx, GLbitfield mask, + GLboolean all, GLint x, GLint y, GLint width, GLint height) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + DWORD dwColor; + WORD wColor; + BYTE bColor; + LPDWORD lpdw = (LPDWORD)Current->pbPixels; + LPWORD lpw = (LPWORD)Current->pbPixels; + LPBYTE lpb = Current->pbPixels; + int lines; + const GLuint *colorMask = (GLuint *) &ctx->Color.ColorMask; + + if (all){ + x=y=0; + width=Current->width; + height=Current->height; + } + + + /* sanity check - can't have right(stereo) buffers */ + assert((mask & (DD_FRONT_RIGHT_BIT | DD_BACK_RIGHT_BIT)) == 0); + + /* clear alpha */ + if ((mask & (DD_FRONT_LEFT_BIT | DD_BACK_RIGHT_BIT)) && + ctx->DrawBuffer->UseSoftwareAlphaBuffers && + ctx->Color.ColorMask[ACOMP]) { + _swrast_clear_alpha_buffers( ctx ); + } + + if (*colorMask == 0xffffffff && ctx->Color.IndexMask == 0xffffffff) { + if (mask & DD_BACK_LEFT_BIT) { + /* Double-buffering - clear back buffer */ + UINT nBypp = Current->cColorBits / 8; + int i = 0; + int iSize = 0; + + assert(Current->db_flag==GL_TRUE); /* we'd better be double buffer */ + if(nBypp ==1 ){ + iSize = Current->width/4; + bColor = BGR8(GetRValue(Current->clearpixel), + GetGValue(Current->clearpixel), + GetBValue(Current->clearpixel)); + wColor = MAKEWORD(bColor,bColor); + dwColor = MAKELONG(wColor, wColor); + } + if(nBypp == 2){ + iSize = Current->width / 2; + wColor = BGR16(GetRValue(Current->clearpixel), + GetGValue(Current->clearpixel), + GetBValue(Current->clearpixel)); + dwColor = MAKELONG(wColor, wColor); + } + else if(nBypp == 4){ + iSize = Current->width; + dwColor = BGR32(GetRValue(Current->clearpixel), + GetGValue(Current->clearpixel), + GetBValue(Current->clearpixel)); + } + + /* clear a line */ + while(i < iSize){ + *lpdw = dwColor; + lpdw++; + i++; + } + + /* This is the 24bit case */ + if (nBypp == 3) { + iSize = Current->width *3/4; + dwColor = BGR24(GetRValue(Current->clearpixel), + GetGValue(Current->clearpixel), + GetBValue(Current->clearpixel)); + while(i < iSize){ + *lpdw = dwColor; + lpb += nBypp; + lpdw = (LPDWORD)lpb; + i++; + } + } + + i = 0; + if (stereo_flag) + lines = height /2; + else + lines = height; + /* copy cleared line to other lines in buffer */ + do { + memcpy(lpb, Current->pbPixels, iSize*4); + lpb += Current->ScanWidth; + i++; + } + while (iclearpixel); + HBRUSH Brush=CreateSolidBrush(Current->clearpixel); + HPEN Old_Pen=SelectObject(DC,Pen); + HBRUSH Old_Brush=SelectObject(DC,Brush); + Rectangle(DC,x,y,x+width,y+height); + SelectObject(DC,Old_Pen); + SelectObject(DC,Old_Brush); + DeleteObject(Pen); + DeleteObject(Brush); + DD_RELEASEDC; + mask &= ~DD_FRONT_LEFT_BIT; + } /* single-buffer */ + } /* if masks are all 1's */ + + /* Call swrast if there is anything left to clear (like DEPTH) */ + if (mask) + _swrast_Clear( ctx, mask, all, x, y, width, height ); +} + + +//--------------------------------------------------------------------------- + + +static void enable( GLcontext* ctx, GLenum pname, GLboolean enable ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + + if (!Current) + return; + + if (pname == GL_DITHER) { + if(enable == GL_FALSE){ + Current->dither_flag = GL_FALSE; + if(Current->cColorBits == 8) + Current->pixelformat = PF_INDEX8; + } + else{ + if (Current->rgb_flag && Current->cColorBits == 8){ + Current->pixelformat = PF_DITHER8; + Current->dither_flag = GL_TRUE; + } + else + Current->dither_flag = GL_FALSE; + } + } +} + +//--------------------------------------------------------------------------- + +static GLboolean set_draw_buffer( GLcontext* ctx, GLenum mode ) +{ + /* TODO: this could be better */ + if (mode==GL_FRONT_LEFT || mode==GL_BACK_LEFT) { + return GL_TRUE; + } + else { + return GL_FALSE; + } +} + +//--------------------------------------------------------------------------- + + +static void set_read_buffer(GLcontext *ctx, GLframebuffer *colorBuffer, + GLenum buffer ) +{ + /* XXX todo */ + return; +} + + +//--------------------------------------------------------------------------- + + +/* Return characteristics of the output buffer. */ +//static void buffer_size( GLcontext* ctx, GLuint *width, GLuint *height ) +// Altered for Mesa 5.x. KeithH +static void buffer_size( + GLframebuffer *buffer, + GLuint *width, + GLuint *height) +{ + // For some reason the context is not passed into this function. + // Therefore we have to explicitly retrieve it. + GET_CURRENT_CONTEXT(ctx); + + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + int New_Size; + RECT CR; + + GetClientRect(Current->Window,&CR); + + *width=CR.right; + *height=CR.bottom; + + New_Size=((*width)!=Current->width) || ((*height)!=Current->height); + + if (New_Size){ + Current->width=*width; + Current->height=*height; + Current->ScanWidth=Current->width; + if ((Current->ScanWidth%sizeof(long))!=0) + Current->ScanWidth+=(sizeof(long)-(Current->ScanWidth%sizeof(long))); + + if (Current->db_flag){ + if (Current->rgb_flag==GL_TRUE && Current->dither_flag!=GL_TRUE){ + wmDeleteBackingStore(Current); + wmCreateBackingStore(Current, Current->width, Current->height); + } + } + + } +} + + + +/**********************************************************************/ +/***** Accelerated point, line, polygon rendering *****/ +/**********************************************************************/ + +/* Accelerated routines are not implemented in 4.0. See OSMesa for ideas. */ + +static void fast_rgb_points( GLcontext* ctx, GLuint first, GLuint last ) +{ +} + +//--------------------------------------------------------------------------- + +/* Return pointer to accelerated points function */ +extern tnl_points_func choose_points_function( GLcontext* ctx ) +{ + return NULL; +} + +//--------------------------------------------------------------------------- + +static void fast_flat_rgb_line( GLcontext* ctx, GLuint v0, + GLuint v1, GLuint pv ) +{ +} + +//--------------------------------------------------------------------------- + +static tnl_line_func choose_line_function( GLcontext* ctx ) +{ +} + + +/**********************************************************************/ +/***** Span-based pixel drawing *****/ +/**********************************************************************/ + + +/* Write a horizontal span of 32-bit color-index pixels with a boolean mask. */ +static void write_ci32_span( const GLcontext* ctx, + GLuint n, GLint x, GLint y, + const GLuint index[], + const GLubyte mask[] ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + GLuint i; + PBYTE Mem=Current->ScreenMem+FLIP(y)*Current->ScanWidth+x; + assert(Current->rgb_flag==GL_FALSE); + for (i=0; iScreenMem+FLIP(y)*Current->ScanWidth+x; + assert(Current->rgb_flag==GL_FALSE); + for (i=0; iScreenMem+FLIP(y)*Current->ScanWidth+x; + assert(Current->rgb_flag==GL_FALSE); + for (i=0; irgb_flag==GL_TRUE) + { + GLuint i; + HDC DC=DD_GETDC; + y=FLIP(y); + if (mask) { + for (i=0; iScreenMem+y*Current->ScanWidth+x; + y = FLIP(y); + if (mask) { + for (i=0; ihPal, + RGB(rgba[i][RCOMP], + rgba[i][GCOMP], + rgba[i][BCOMP])); + } + else { + for (i=0; ihPal, + RGB(rgba[i][RCOMP], + rgba[i][GCOMP], + rgba[i][BCOMP])); + } + } +} + +//--------------------------------------------------------------------------- + +/* Write a horizontal span of RGB color pixels with a boolean mask. */ +static void write_rgb_span( const GLcontext* ctx, + GLuint n, GLint x, GLint y, + const GLubyte rgb[][3], const GLubyte mask[] ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + PWMC pwc = Current; + + if (pwc->rgb_flag==GL_TRUE) + { + GLuint i; + HDC DC=DD_GETDC; + y=FLIP(y); + if (mask) { + for (i=0; iScreenMem+y*Current->ScanWidth+x; + y = FLIP(y); + if (mask) { + for (i=0; ihPal, + RGB(rgb[i][RCOMP], + rgb[i][GCOMP], + rgb[i][BCOMP])); + } + else { + for (i=0; ihPal, + RGB(rgb[i][RCOMP], + rgb[i][GCOMP], + rgb[i][BCOMP])); + } + } +} + +//--------------------------------------------------------------------------- + +/* + * Write a horizontal span of pixels with a boolean mask. The current color + * is used for all pixels. + */ +static void write_mono_rgba_span( const GLcontext* ctx, + GLuint n, GLint x, GLint y, + const GLchan color[4], const GLubyte mask[]) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + ULONG pixel = RGB( color[RCOMP], color[GCOMP], color[BCOMP] ); + GLuint i; + HDC DC=DD_GETDC; + PWMC pwc = Current; + assert(Current->rgb_flag==GL_TRUE); + y=FLIP(y); + if(Current->rgb_flag==GL_TRUE){ + for (i=0; irgb_flag==GL_FALSE); + for (i=0; iScreenMem+FLIP(y[i])*Current->ScanWidth+x[i]; + *Mem = index[i]; + } + } +} + + +//--------------------------------------------------------------------------- + + +/* + * Write an array of pixels with a boolean mask. The current color + * index is used for all pixels. + */ +static void write_mono_ci_pixels( const GLcontext* ctx, + GLuint n, + const GLint x[], const GLint y[], + GLuint colorIndex, const GLubyte mask[] ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + GLuint i; + assert(Current->rgb_flag==GL_FALSE); + for (i=0; iScreenMem+FLIP(y[i])*Current->ScanWidth+x[i]; + *Mem = colorIndex; + } + } +} + + +//--------------------------------------------------------------------------- + + +/* Write an array of RGBA pixels with a boolean mask. */ +static void write_rgba_pixels( const GLcontext* ctx, + GLuint n, const GLint x[], const GLint y[], + const GLubyte rgba[][4], const GLubyte mask[] ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + GLuint i; + PWMC pwc = Current; + HDC DC=DD_GETDC; + assert(Current->rgb_flag==GL_TRUE); + for (i=0; irgb_flag==GL_TRUE); + for (i=0; iScreenMem+FLIP(y)*Current->ScanWidth+x; + assert(Current->rgb_flag==GL_FALSE); + for (i=0; irgb_flag==GL_FALSE); + for (i=0; iScreenMem+FLIP(y[i])*Current->ScanWidth+x[i]); + } + } +} + +//--------------------------------------------------------------------------- + +/* Read a horizontal span of color pixels. */ +static void read_rgba_span( const GLcontext* ctx, + GLuint n, GLint x, GLint y, + GLubyte rgba[][4] ) +{ + GLD_context *gldCtx = GLD_GET_CONTEXT(ctx); + WMesaContext *Current = GLD_GET_WMESA_DRIVER(gldCtx); + UINT i; + COLORREF Color; + HDC DC=DD_GETDC; + assert(Current->rgb_flag==GL_TRUE); + y = Current->height - y - 1; + for (i=0; irgb_flag==GL_TRUE); + for (i=0; iheight - y[i] - 1; + Color=GetPixel(DC,x[i],y2); + rgba[i][RCOMP] = GetRValue(Color); + rgba[i][GCOMP] = GetGValue(Color); + rgba[i][BCOMP] = GetBValue(Color); + rgba[i][ACOMP] = 255; + } + } + DD_RELEASEDC; +} + +//--------------------------------------------------------------------------- + +static void wmesa_update_state( + GLcontext *ctx, + GLuint new_state) +{ + _swrast_InvalidateState( ctx, new_state ); + _swsetup_InvalidateState( ctx, new_state ); + _vbo_InvalidateState( ctx, new_state ); + _tnl_InvalidateState( ctx, new_state ); +} + +//--------------------------------------------------------------------------- + +static void wmesa_viewport( + GLcontext *ctx, + GLint x, + GLint y, + GLsizei w, + GLsizei h) +{ +// ctx->Driver.ResizeBuffersMESA(ctx); +} + +//--------------------------------------------------------------------------- + +static void wmesa_update_state_first_time( + GLcontext *ctx, + GLuint new_state) +{ + struct swrast_device_driver *swdd = _swrast_GetDeviceDriverReference( ctx ); + TNLcontext *tnl = TNL_CONTEXT(ctx); + + _mesa_init_driver_functions(&ctx->Driver); + + /* + * XXX these function pointers could be initialized just once during + * context creation since they don't depend on any state changes. + * kws - This is true - this function gets called a lot and it + * would be good to minimize setting all this when not needed. + */ + // Good idea, so I'll do it. KeithH. :-) + + ctx->Driver.GetString = _gldGetStringGeneric; + ctx->Driver.UpdateState = wmesa_update_state; + ctx->Driver.DrawBuffer = set_draw_buffer; + ctx->Driver.ResizeBuffers = _swrast_alloc_buffers; + ctx->Driver.GetBufferSize = buffer_size; + + ctx->Driver.Viewport = wmesa_viewport; + + ctx->Driver.Clear = clear; + + ctx->Driver.Flush = flush; + ctx->Driver.ClearColor = clear_color; + ctx->Driver.Enable = enable; + + + // Does not apply for Mesa 5.x + //ctx->Driver.BaseCompressedTexFormat = _mesa_base_compressed_texformat; + //ctx->Driver.CompressedTextureSize = _mesa_compressed_texture_size; + //ctx->Driver.GetCompressedTexImage = _mesa_get_compressed_teximage; + + swdd->SetBuffer = set_read_buffer; + + + /* Pixel/span writing functions: */ + swdd->WriteRGBASpan = write_rgba_span; + swdd->WriteRGBSpan = write_rgb_span; + swdd->WriteMonoRGBASpan = write_mono_rgba_span; + swdd->WriteRGBAPixels = write_rgba_pixels; + swdd->WriteMonoRGBAPixels = write_mono_rgba_pixels; + swdd->WriteCI32Span = write_ci32_span; + swdd->WriteCI8Span = write_ci8_span; + swdd->WriteMonoCISpan = write_mono_ci_span; + swdd->WriteCI32Pixels = write_ci32_pixels; + swdd->WriteMonoCIPixels = write_mono_ci_pixels; + + swdd->ReadCI32Span = read_ci32_span; + swdd->ReadRGBASpan = read_rgba_span; + swdd->ReadCI32Pixels = read_ci32_pixels; + swdd->ReadRGBAPixels = read_rgba_pixels; + + + tnl->Driver.RunPipeline = _tnl_run_pipeline; + + wmesa_update_state(ctx, new_state); +} + +//--------------------------------------------------------------------------- +// Driver interface functions +//--------------------------------------------------------------------------- + +BOOL gldCreateDrawable_MesaSW( + DGL_ctx *pCtx, + BOOL bPersistantInterface, + BOOL bPersistantBuffers) +{ + WMesaContext *c; + GLboolean true_color_flag; + GLboolean rgb_flag = GL_TRUE; + GLboolean db_flag = GL_TRUE; + + if (pCtx == NULL) + return FALSE; + + c = (struct wmesa_context * ) calloc(1,sizeof(struct wmesa_context)); + if (!c) + return FALSE; + + pCtx->glPriv = c; + + c->hDC = pCtx->hDC; + c->Window = pCtx->hWnd; + + true_color_flag = GetDeviceCaps(pCtx->hDC, BITSPIXEL) > 8; + + +#ifdef DITHER + if ((true_color_flag==GL_FALSE) && (rgb_flag == GL_TRUE)){ + c->dither_flag = GL_TRUE; + c->hPalHalfTone = WinGCreateHalftonePalette(); + } + else + c->dither_flag = GL_FALSE; +#else + c->dither_flag = GL_FALSE; +#endif + + + if (rgb_flag==GL_FALSE) + { + c->rgb_flag = GL_FALSE; +#if 0 + /* Old WinG stuff???? */ + c->db_flag = db_flag =GL_TRUE; /* WinG requires double buffering */ + printf("Single buffer is not supported in color index mode, ", + "setting to double buffer.\n"); +#endif + } + else + { + c->rgb_flag = GL_TRUE; + } + +// db_flag = pCtx->lpPF->pfd.dwFlags & PFD_DOUBLEBUFFER ? GL_TRUE : GL_FALSE; + db_flag = GL_TRUE; // Force double-buffer + if (db_flag) { + c->db_flag = 1; + /* Double buffered */ + { + wmCreateBackingStore(c, pCtx->dwWidth, pCtx->dwHeight); + + } + } else { + /* Single Buffered */ + if (c->rgb_flag) + c->db_flag = 0; + } + + c->bEmulateSingleBuffer = (pCtx->lpPF->pfd.dwFlags & PFD_DOUBLEBUFFER) + ? FALSE : TRUE; + + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldResizeDrawable_MesaSW( + DGL_ctx *ctx, + BOOL bDefaultDriver, + BOOL bPersistantInterface, + BOOL bPersistantBuffers) +{ + WMesaContext *c; + + if (ctx == NULL) + return FALSE; + + c = ctx->glPriv; + if (c == NULL) + return FALSE; + + c->hDC = ctx->hDC; + c->Window = ctx->hWnd; +// c->width = ctx->dwWidth; +// c->height = ctx->dwHeight; + + if (c->db_flag) { + wmDeleteBackingStore(c); + wmCreateBackingStore(c, ctx->dwWidth, ctx->dwHeight); + } + + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldDestroyDrawable_MesaSW( + DGL_ctx *ctx) +{ + WMesaContext *c; + + if (ctx == NULL) + return FALSE; + + c = ctx->glPriv; + if (c == NULL) + return FALSE; + + if (c->hPalHalfTone != NULL) + DeleteObject(c->hPalHalfTone); + + if (c->db_flag) + wmDeleteBackingStore(c); + + free(c); + + ctx->glPriv = NULL; + + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldCreatePrivateGlobals_MesaSW(void) +{ + // Mesa Software driver needs no private globals + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldDestroyPrivateGlobals_MesaSW(void) +{ + // Mesa Software driver needs no private globals + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldBuildPixelformatList_MesaSW(void) +{ + // Release any existing pixelformat list + if (glb.lpPF) { + free(glb.lpPF); + } + + glb.nPixelFormatCount = 0; + glb.lpPF = NULL; + + glb.lpPF = (DGL_pixelFormat *)calloc(2, sizeof(DGL_pixelFormat)); + if (glb.lpPF == NULL) + return FALSE; + // Single-buffered + memcpy(&glb.lpPF[0], &pfTemplateMesaSW, sizeof(DGL_pixelFormat)); + glb.lpPF[0].pfd.dwFlags &= ~PFD_DOUBLEBUFFER; // Remove doublebuffer flag + // Double-buffered + memcpy(&glb.lpPF[1], &pfTemplateMesaSW, sizeof(DGL_pixelFormat)); + glb.nPixelFormatCount = 2; + + // Mark list as 'current' + glb.bPixelformatsDirty = FALSE; + + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldInitialiseMesa_MesaSW( + DGL_ctx *gld) +{ + GLcontext *ctx; + + if (gld == NULL) + return FALSE; + + ctx = gld->glCtx; + + // Set max texture size to 256 + ctx->Const.MaxTextureLevels = 8; + + // Multitexture enable/disable + ctx->Const.MaxTextureUnits = (glb.bMultitexture) ? MAX_TEXTURE_UNITS : 1; + + /* Initialize the software rasterizer and helper modules.*/ + + // Added this to force max texture diminsion to 256. KeithH + ctx->Const.MaxTextureLevels = 8; + ctx->Const.MaxDrawBuffers = 1; + + _mesa_enable_sw_extensions(ctx); + _mesa_enable_imaging_extensions(ctx); + _mesa_enable_1_3_extensions(ctx); + +// _swrast_CreateContext( ctx ); +// _vbo_CreateContext( ctx ); +// _tnl_CreateContext( ctx ); +// _swsetup_CreateContext( ctx ); + + _swsetup_Wakeup( ctx ); + + wmesa_update_state_first_time(ctx, ~0); + + return TRUE; +} + +//--------------------------------------------------------------------------- + +BOOL gldSwapBuffers_MesaSW( + DGL_ctx *ctx, + HDC hDC, + HWND hWnd) +{ + WMesaContext *c; + + if (ctx == NULL) + return FALSE; + + c = ctx->glPriv; + if (c == NULL) + return FALSE; + + /* If we're swapping the buffer associated with the current context + * we have to flush any pending rendering commands first. + */ + + // Altered to respect bEmulateSingleBuffer. KeithH +// if (c->db_flag) + if (!c->bEmulateSingleBuffer) + wmFlush(c, hDC); + + return TRUE; +} + +//--------------------------------------------------------------------------- + +PROC gldGetProcAddress_MesaSW( + LPCSTR a) +{ + int i; + PROC proc = NULL; + + for (i=0; GLD_extList[i].proc; i++) { + if (!strcmp(a, GLD_extList[i].name)) { + proc = GLD_extList[i].proc; + break; + } + } + + gldLogPrintf(GLDLOG_INFO, "GetProcAddress: %s (%s)", a, proc ? "OK" : "Failed"); + + return proc; +} + +//--------------------------------------------------------------------------- + +BOOL gldGetDisplayMode_MesaSW( + DGL_ctx *ctx, + GLD_displayMode *glddm) +{ + HDC hdcDesktop; + + if (glddm == NULL) + return FALSE; + + // + // A bit hacky... KeithH + // + + hdcDesktop = GetDC(NULL); + glddm->Width = GetDeviceCaps(hdcDesktop, HORZRES); + glddm->Height = GetDeviceCaps(hdcDesktop, VERTRES); + glddm->BPP = GetDeviceCaps(hdcDesktop, BITSPIXEL); + glddm->Refresh = 0; + ReleaseDC(0, hdcDesktop); + + return TRUE; +} + +//--------------------------------------------------------------------------- + --- mesa-7.8.2.orig/src/mesa/main/get_gen.py +++ mesa-7.8.2/src/mesa/main/get_gen.py @@ -0,0 +1,1333 @@ +#!/usr/bin/env python + +# Mesa 3-D graphics library +# +# Copyright (C) 1999-2006 Brian Paul 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"), +# to deal in the Software without restriction, including without limitation +# the rights to use, copy, modify, merge, publish, distribute, sublicense, +# and/or sell copies of the Software, and to permit persons to whom the +# Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included +# in all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL +# BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN +# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + +# This script is used to generate the get.c file: +# python get_gen.py > get.c + + +import string +import sys + + +GLint = 1 +GLenum = 2 +GLfloat = 3 +GLdouble = 4 +GLboolean = 5 +GLfloatN = 6 # A normalized value, such as a color or depth range +GLint64 = 7 + + +TypeStrings = { + GLint : "GLint", + GLenum : "GLenum", + GLfloat : "GLfloat", + GLdouble : "GLdouble", + GLboolean : "GLboolean", + GLint64 : "GLint64" +} + + +# Each entry is a tuple of: +# - the GL state name, such as GL_CURRENT_COLOR +# - the state datatype, one of GLint, GLfloat, GLboolean or GLenum +# - list of code fragments to get the state, such as ["ctx->Foo.Bar"] +# - optional extra code or empty string. If present, "CONVERSION" will be +# replaced by ENUM_TO_FLOAT, INT_TO_FLOAT, etc. +# - optional extensions to check, or None +# +StateVars = [ + ( "GL_ACCUM_RED_BITS", GLint, ["ctx->DrawBuffer->Visual.accumRedBits"], + "", None ), + ( "GL_ACCUM_GREEN_BITS", GLint, ["ctx->DrawBuffer->Visual.accumGreenBits"], + "", None ), + ( "GL_ACCUM_BLUE_BITS", GLint, ["ctx->DrawBuffer->Visual.accumBlueBits"], + "", None ), + ( "GL_ACCUM_ALPHA_BITS", GLint, ["ctx->DrawBuffer->Visual.accumAlphaBits"], + "", None ), + ( "GL_ACCUM_CLEAR_VALUE", GLfloatN, + [ "ctx->Accum.ClearColor[0]", + "ctx->Accum.ClearColor[1]", + "ctx->Accum.ClearColor[2]", + "ctx->Accum.ClearColor[3]" ], + "", None ), + ( "GL_ALPHA_BIAS", GLfloat, ["ctx->Pixel.AlphaBias"], "", None ), + ( "GL_ALPHA_BITS", GLint, ["ctx->DrawBuffer->Visual.alphaBits"], + "", None ), + ( "GL_ALPHA_SCALE", GLfloat, ["ctx->Pixel.AlphaScale"], "", None ), + ( "GL_ALPHA_TEST", GLboolean, ["ctx->Color.AlphaEnabled"], "", None ), + ( "GL_ALPHA_TEST_FUNC", GLenum, ["ctx->Color.AlphaFunc"], "", None ), + ( "GL_ALPHA_TEST_REF", GLfloatN, ["ctx->Color.AlphaRef"], "", None ), + ( "GL_ATTRIB_STACK_DEPTH", GLint, ["ctx->AttribStackDepth"], "", None ), + ( "GL_AUTO_NORMAL", GLboolean, ["ctx->Eval.AutoNormal"], "", None ), + ( "GL_AUX_BUFFERS", GLint, ["ctx->DrawBuffer->Visual.numAuxBuffers"], + "", None ), + ( "GL_BLEND", GLboolean, ["(ctx->Color.BlendEnabled & 1)"], "", None ), + ( "GL_BLEND_DST", GLenum, ["ctx->Color.BlendDstRGB"], "", None ), + ( "GL_BLEND_SRC", GLenum, ["ctx->Color.BlendSrcRGB"], "", None ), + ( "GL_BLEND_SRC_RGB_EXT", GLenum, ["ctx->Color.BlendSrcRGB"], "", None ), + ( "GL_BLEND_DST_RGB_EXT", GLenum, ["ctx->Color.BlendDstRGB"], "", None ), + ( "GL_BLEND_SRC_ALPHA_EXT", GLenum, ["ctx->Color.BlendSrcA"], "", None ), + ( "GL_BLEND_DST_ALPHA_EXT", GLenum, ["ctx->Color.BlendDstA"], "", None ), + ( "GL_BLEND_EQUATION", GLenum, ["ctx->Color.BlendEquationRGB "], "", None), + ( "GL_BLEND_EQUATION_ALPHA_EXT", GLenum, ["ctx->Color.BlendEquationA "], + "", None ), + ( "GL_BLEND_COLOR_EXT", GLfloatN, + [ "ctx->Color.BlendColor[0]", + "ctx->Color.BlendColor[1]", + "ctx->Color.BlendColor[2]", + "ctx->Color.BlendColor[3]"], "", None ), + ( "GL_BLUE_BIAS", GLfloat, ["ctx->Pixel.BlueBias"], "", None ), + ( "GL_BLUE_BITS", GLint, ["ctx->DrawBuffer->Visual.blueBits"], "", None ), + ( "GL_BLUE_SCALE", GLfloat, ["ctx->Pixel.BlueScale"], "", None ), + ( "GL_CLIENT_ATTRIB_STACK_DEPTH", GLint, + ["ctx->ClientAttribStackDepth"], "", None ), + ( "GL_CLIP_PLANE0", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 0) & 1" ], "", None ), + ( "GL_CLIP_PLANE1", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 1) & 1" ], "", None ), + ( "GL_CLIP_PLANE2", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 2) & 1" ], "", None ), + ( "GL_CLIP_PLANE3", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 3) & 1" ], "", None ), + ( "GL_CLIP_PLANE4", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 4) & 1" ], "", None ), + ( "GL_CLIP_PLANE5", GLboolean, + [ "(ctx->Transform.ClipPlanesEnabled >> 5) & 1" ], "", None ), + ( "GL_COLOR_CLEAR_VALUE", GLfloatN, + [ "ctx->Color.ClearColor[0]", + "ctx->Color.ClearColor[1]", + "ctx->Color.ClearColor[2]", + "ctx->Color.ClearColor[3]" ], "", None ), + ( "GL_COLOR_MATERIAL", GLboolean, + ["ctx->Light.ColorMaterialEnabled"], "", None ), + ( "GL_COLOR_MATERIAL_FACE", GLenum, + ["ctx->Light.ColorMaterialFace"], "", None ), + ( "GL_COLOR_MATERIAL_PARAMETER", GLenum, + ["ctx->Light.ColorMaterialMode"], "", None ), + ( "GL_COLOR_WRITEMASK", GLint, + [ "ctx->Color.ColorMask[0][RCOMP] ? 1 : 0", + "ctx->Color.ColorMask[0][GCOMP] ? 1 : 0", + "ctx->Color.ColorMask[0][BCOMP] ? 1 : 0", + "ctx->Color.ColorMask[0][ACOMP] ? 1 : 0" ], "", None ), + ( "GL_CULL_FACE", GLboolean, ["ctx->Polygon.CullFlag"], "", None ), + ( "GL_CULL_FACE_MODE", GLenum, ["ctx->Polygon.CullFaceMode"], "", None ), + ( "GL_CURRENT_COLOR", GLfloatN, + [ "ctx->Current.Attrib[VERT_ATTRIB_COLOR0][0]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR0][1]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR0][2]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR0][3]" ], + "FLUSH_CURRENT(ctx, 0);", None ), + ( "GL_CURRENT_INDEX", GLfloat, + [ "ctx->Current.Attrib[VERT_ATTRIB_COLOR_INDEX][0]" ], + "FLUSH_CURRENT(ctx, 0);", None ), + ( "GL_CURRENT_NORMAL", GLfloatN, + [ "ctx->Current.Attrib[VERT_ATTRIB_NORMAL][0]", + "ctx->Current.Attrib[VERT_ATTRIB_NORMAL][1]", + "ctx->Current.Attrib[VERT_ATTRIB_NORMAL][2]"], + "FLUSH_CURRENT(ctx, 0);", None ), + ( "GL_CURRENT_RASTER_COLOR", GLfloatN, + ["ctx->Current.RasterColor[0]", + "ctx->Current.RasterColor[1]", + "ctx->Current.RasterColor[2]", + "ctx->Current.RasterColor[3]"], "", None ), + ( "GL_CURRENT_RASTER_DISTANCE", GLfloat, + ["ctx->Current.RasterDistance"], "", None ), + ( "GL_CURRENT_RASTER_INDEX", GLfloat, + ["1.0"], "", None ), + ( "GL_CURRENT_RASTER_POSITION", GLfloat, + ["ctx->Current.RasterPos[0]", + "ctx->Current.RasterPos[1]", + "ctx->Current.RasterPos[2]", + "ctx->Current.RasterPos[3]"], "", None ), + ( "GL_CURRENT_RASTER_SECONDARY_COLOR", GLfloatN, + ["ctx->Current.RasterSecondaryColor[0]", + "ctx->Current.RasterSecondaryColor[1]", + "ctx->Current.RasterSecondaryColor[2]", + "ctx->Current.RasterSecondaryColor[3]"], "", None ), + ( "GL_CURRENT_RASTER_TEXTURE_COORDS", GLfloat, + ["ctx->Current.RasterTexCoords[unit][0]", + "ctx->Current.RasterTexCoords[unit][1]", + "ctx->Current.RasterTexCoords[unit][2]", + "ctx->Current.RasterTexCoords[unit][3]"], + """const GLuint unit = ctx->Texture.CurrentUnit; + if (unit >= ctx->Const.MaxTextureCoordUnits) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "glGet(raster tex coords, unit %u)", unit); + return; + }""", + None ), + ( "GL_CURRENT_RASTER_POSITION_VALID", GLboolean, + ["ctx->Current.RasterPosValid"], "", None ), + ( "GL_CURRENT_TEXTURE_COORDS", GLfloat, + ["ctx->Current.Attrib[VERT_ATTRIB_TEX0 + unit][0]", + "ctx->Current.Attrib[VERT_ATTRIB_TEX0 + unit][1]", + "ctx->Current.Attrib[VERT_ATTRIB_TEX0 + unit][2]", + "ctx->Current.Attrib[VERT_ATTRIB_TEX0 + unit][3]"], + """const GLuint unit = ctx->Texture.CurrentUnit; + if (unit >= ctx->Const.MaxTextureCoordUnits) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "glGet(current tex coords, unit %u)", unit); + return; + } + FLUSH_CURRENT(ctx, 0);""", + None ), + ( "GL_DEPTH_BIAS", GLfloat, ["ctx->Pixel.DepthBias"], "", None ), + ( "GL_DEPTH_BITS", GLint, ["ctx->DrawBuffer->Visual.depthBits"], + "", None ), + ( "GL_DEPTH_CLEAR_VALUE", GLfloatN, ["((GLfloat) ctx->Depth.Clear)"], "", None ), + ( "GL_DEPTH_FUNC", GLenum, ["ctx->Depth.Func"], "", None ), + ( "GL_DEPTH_RANGE", GLfloatN, + [ "ctx->Viewport.Near", "ctx->Viewport.Far" ], "", None ), + ( "GL_DEPTH_SCALE", GLfloat, ["ctx->Pixel.DepthScale"], "", None ), + ( "GL_DEPTH_TEST", GLboolean, ["ctx->Depth.Test"], "", None ), + ( "GL_DEPTH_WRITEMASK", GLboolean, ["ctx->Depth.Mask"], "", None ), + ( "GL_DITHER", GLboolean, ["ctx->Color.DitherFlag"], "", None ), + ( "GL_DOUBLEBUFFER", GLboolean, + ["ctx->DrawBuffer->Visual.doubleBufferMode"], "", None ), + ( "GL_DRAW_BUFFER", GLenum, ["ctx->DrawBuffer->ColorDrawBuffer[0]"], "", None ), + ( "GL_EDGE_FLAG", GLboolean, ["(ctx->Current.Attrib[VERT_ATTRIB_EDGEFLAG][0] == 1.0)"], + "FLUSH_CURRENT(ctx, 0);", None ), + ( "GL_FEEDBACK_BUFFER_SIZE", GLint, ["ctx->Feedback.BufferSize"], "", None ), + ( "GL_FEEDBACK_BUFFER_TYPE", GLenum, ["ctx->Feedback.Type"], "", None ), + ( "GL_FOG", GLboolean, ["ctx->Fog.Enabled"], "", None ), + ( "GL_FOG_COLOR", GLfloatN, + [ "ctx->Fog.Color[0]", + "ctx->Fog.Color[1]", + "ctx->Fog.Color[2]", + "ctx->Fog.Color[3]" ], "", None ), + ( "GL_FOG_DENSITY", GLfloat, ["ctx->Fog.Density"], "", None ), + ( "GL_FOG_END", GLfloat, ["ctx->Fog.End"], "", None ), + ( "GL_FOG_HINT", GLenum, ["ctx->Hint.Fog"], "", None ), + ( "GL_FOG_INDEX", GLfloat, ["ctx->Fog.Index"], "", None ), + ( "GL_FOG_MODE", GLenum, ["ctx->Fog.Mode"], "", None ), + ( "GL_FOG_START", GLfloat, ["ctx->Fog.Start"], "", None ), + ( "GL_FRONT_FACE", GLenum, ["ctx->Polygon.FrontFace"], "", None ), + ( "GL_GREEN_BIAS", GLfloat, ["ctx->Pixel.GreenBias"], "", None ), + ( "GL_GREEN_BITS", GLint, ["ctx->DrawBuffer->Visual.greenBits"], + "", None ), + ( "GL_GREEN_SCALE", GLfloat, ["ctx->Pixel.GreenScale"], "", None ), + ( "GL_INDEX_BITS", GLint, ["ctx->DrawBuffer->Visual.indexBits"], + "", None ), + ( "GL_INDEX_CLEAR_VALUE", GLint, ["ctx->Color.ClearIndex"], "", None ), + ( "GL_INDEX_MODE", GLboolean, ["GL_FALSE"], + "", None ), + ( "GL_INDEX_OFFSET", GLint, ["ctx->Pixel.IndexOffset"], "", None ), + ( "GL_INDEX_SHIFT", GLint, ["ctx->Pixel.IndexShift"], "", None ), + ( "GL_INDEX_WRITEMASK", GLint, ["ctx->Color.IndexMask"], "", None ), + ( "GL_LIGHT0", GLboolean, ["ctx->Light.Light[0].Enabled"], "", None ), + ( "GL_LIGHT1", GLboolean, ["ctx->Light.Light[1].Enabled"], "", None ), + ( "GL_LIGHT2", GLboolean, ["ctx->Light.Light[2].Enabled"], "", None ), + ( "GL_LIGHT3", GLboolean, ["ctx->Light.Light[3].Enabled"], "", None ), + ( "GL_LIGHT4", GLboolean, ["ctx->Light.Light[4].Enabled"], "", None ), + ( "GL_LIGHT5", GLboolean, ["ctx->Light.Light[5].Enabled"], "", None ), + ( "GL_LIGHT6", GLboolean, ["ctx->Light.Light[6].Enabled"], "", None ), + ( "GL_LIGHT7", GLboolean, ["ctx->Light.Light[7].Enabled"], "", None ), + ( "GL_LIGHTING", GLboolean, ["ctx->Light.Enabled"], "", None ), + ( "GL_LIGHT_MODEL_AMBIENT", GLfloatN, + ["ctx->Light.Model.Ambient[0]", + "ctx->Light.Model.Ambient[1]", + "ctx->Light.Model.Ambient[2]", + "ctx->Light.Model.Ambient[3]"], "", None ), + ( "GL_LIGHT_MODEL_COLOR_CONTROL", GLenum, + ["ctx->Light.Model.ColorControl"], "", None ), + ( "GL_LIGHT_MODEL_LOCAL_VIEWER", GLboolean, + ["ctx->Light.Model.LocalViewer"], "", None ), + ( "GL_LIGHT_MODEL_TWO_SIDE", GLboolean, ["ctx->Light.Model.TwoSide"], "", None ), + ( "GL_LINE_SMOOTH", GLboolean, ["ctx->Line.SmoothFlag"], "", None ), + ( "GL_LINE_SMOOTH_HINT", GLenum, ["ctx->Hint.LineSmooth"], "", None ), + ( "GL_LINE_STIPPLE", GLboolean, ["ctx->Line.StippleFlag"], "", None ), + ( "GL_LINE_STIPPLE_PATTERN", GLint, ["ctx->Line.StipplePattern"], "", None ), + ( "GL_LINE_STIPPLE_REPEAT", GLint, ["ctx->Line.StippleFactor"], "", None ), + ( "GL_LINE_WIDTH", GLfloat, ["ctx->Line.Width"], "", None ), + ( "GL_LINE_WIDTH_GRANULARITY", GLfloat, + ["ctx->Const.LineWidthGranularity"], "", None ), + ( "GL_LINE_WIDTH_RANGE", GLfloat, + ["ctx->Const.MinLineWidthAA", + "ctx->Const.MaxLineWidthAA"], "", None ), + ( "GL_ALIASED_LINE_WIDTH_RANGE", GLfloat, + ["ctx->Const.MinLineWidth", + "ctx->Const.MaxLineWidth"], "", None ), + ( "GL_LIST_BASE", GLint, ["ctx->List.ListBase"], "", None ), + ( "GL_LIST_INDEX", GLint, ["(ctx->ListState.CurrentList ? ctx->ListState.CurrentList->Name : 0)"], "", None ), + ( "GL_LIST_MODE", GLenum, ["mode"], + """GLenum mode; + if (!ctx->CompileFlag) + mode = 0; + else if (ctx->ExecuteFlag) + mode = GL_COMPILE_AND_EXECUTE; + else + mode = GL_COMPILE;""", None ), + ( "GL_INDEX_LOGIC_OP", GLboolean, ["ctx->Color.IndexLogicOpEnabled"], "", None ), + ( "GL_COLOR_LOGIC_OP", GLboolean, ["ctx->Color.ColorLogicOpEnabled"], "", None ), + ( "GL_LOGIC_OP_MODE", GLenum, ["ctx->Color.LogicOp"], "", None ), + ( "GL_MAP1_COLOR_4", GLboolean, ["ctx->Eval.Map1Color4"], "", None ), + ( "GL_MAP1_GRID_DOMAIN", GLfloat, + ["ctx->Eval.MapGrid1u1", + "ctx->Eval.MapGrid1u2"], "", None ), + ( "GL_MAP1_GRID_SEGMENTS", GLint, ["ctx->Eval.MapGrid1un"], "", None ), + ( "GL_MAP1_INDEX", GLboolean, ["ctx->Eval.Map1Index"], "", None ), + ( "GL_MAP1_NORMAL", GLboolean, ["ctx->Eval.Map1Normal"], "", None ), + ( "GL_MAP1_TEXTURE_COORD_1", GLboolean, ["ctx->Eval.Map1TextureCoord1"], "", None ), + ( "GL_MAP1_TEXTURE_COORD_2", GLboolean, ["ctx->Eval.Map1TextureCoord2"], "", None ), + ( "GL_MAP1_TEXTURE_COORD_3", GLboolean, ["ctx->Eval.Map1TextureCoord3"], "", None ), + ( "GL_MAP1_TEXTURE_COORD_4", GLboolean, ["ctx->Eval.Map1TextureCoord4"], "", None ), + ( "GL_MAP1_VERTEX_3", GLboolean, ["ctx->Eval.Map1Vertex3"], "", None ), + ( "GL_MAP1_VERTEX_4", GLboolean, ["ctx->Eval.Map1Vertex4"], "", None ), + ( "GL_MAP2_COLOR_4", GLboolean, ["ctx->Eval.Map2Color4"], "", None ), + ( "GL_MAP2_GRID_DOMAIN", GLfloat, + ["ctx->Eval.MapGrid2u1", + "ctx->Eval.MapGrid2u2", + "ctx->Eval.MapGrid2v1", + "ctx->Eval.MapGrid2v2"], "", None ), + ( "GL_MAP2_GRID_SEGMENTS", GLint, + ["ctx->Eval.MapGrid2un", + "ctx->Eval.MapGrid2vn"], "", None ), + ( "GL_MAP2_INDEX", GLboolean, ["ctx->Eval.Map2Index"], "", None ), + ( "GL_MAP2_NORMAL", GLboolean, ["ctx->Eval.Map2Normal"], "", None ), + ( "GL_MAP2_TEXTURE_COORD_1", GLboolean, ["ctx->Eval.Map2TextureCoord1"], "", None ), + ( "GL_MAP2_TEXTURE_COORD_2", GLboolean, ["ctx->Eval.Map2TextureCoord2"], "", None ), + ( "GL_MAP2_TEXTURE_COORD_3", GLboolean, ["ctx->Eval.Map2TextureCoord3"], "", None ), + ( "GL_MAP2_TEXTURE_COORD_4", GLboolean, ["ctx->Eval.Map2TextureCoord4"], "", None ), + ( "GL_MAP2_VERTEX_3", GLboolean, ["ctx->Eval.Map2Vertex3"], "", None ), + ( "GL_MAP2_VERTEX_4", GLboolean, ["ctx->Eval.Map2Vertex4"], "", None ), + ( "GL_MAP_COLOR", GLboolean, ["ctx->Pixel.MapColorFlag"], "", None ), + ( "GL_MAP_STENCIL", GLboolean, ["ctx->Pixel.MapStencilFlag"], "", None ), + ( "GL_MATRIX_MODE", GLenum, ["ctx->Transform.MatrixMode"], "", None ), + + ( "GL_MAX_ATTRIB_STACK_DEPTH", GLint, ["MAX_ATTRIB_STACK_DEPTH"], "", None ), + ( "GL_MAX_CLIENT_ATTRIB_STACK_DEPTH", GLint, ["MAX_CLIENT_ATTRIB_STACK_DEPTH"], "", None ), + ( "GL_MAX_CLIP_PLANES", GLint, ["ctx->Const.MaxClipPlanes"], "", None ), + ( "GL_MAX_ELEMENTS_VERTICES", GLint, ["ctx->Const.MaxArrayLockSize"], "", None ), + ( "GL_MAX_ELEMENTS_INDICES", GLint, ["ctx->Const.MaxArrayLockSize"], "", None ), + ( "GL_MAX_EVAL_ORDER", GLint, ["MAX_EVAL_ORDER"], "", None ), + ( "GL_MAX_LIGHTS", GLint, ["ctx->Const.MaxLights"], "", None ), + ( "GL_MAX_LIST_NESTING", GLint, ["MAX_LIST_NESTING"], "", None ), + ( "GL_MAX_MODELVIEW_STACK_DEPTH", GLint, ["MAX_MODELVIEW_STACK_DEPTH"], "", None ), + ( "GL_MAX_NAME_STACK_DEPTH", GLint, ["MAX_NAME_STACK_DEPTH"], "", None ), + ( "GL_MAX_PIXEL_MAP_TABLE", GLint, ["MAX_PIXEL_MAP_TABLE"], "", None ), + ( "GL_MAX_PROJECTION_STACK_DEPTH", GLint, ["MAX_PROJECTION_STACK_DEPTH"], "", None ), + ( "GL_MAX_TEXTURE_SIZE", GLint, ["1 << (ctx->Const.MaxTextureLevels - 1)"], "", None ), + ( "GL_MAX_3D_TEXTURE_SIZE", GLint, ["1 << (ctx->Const.Max3DTextureLevels - 1)"], "", None ), + ( "GL_MAX_TEXTURE_STACK_DEPTH", GLint, ["MAX_TEXTURE_STACK_DEPTH"], "", None ), + ( "GL_MAX_VIEWPORT_DIMS", GLint, + ["ctx->Const.MaxViewportWidth", "ctx->Const.MaxViewportHeight"], + "", None ), + ( "GL_MODELVIEW_MATRIX", GLfloat, + [ "matrix[0]", "matrix[1]", "matrix[2]", "matrix[3]", + "matrix[4]", "matrix[5]", "matrix[6]", "matrix[7]", + "matrix[8]", "matrix[9]", "matrix[10]", "matrix[11]", + "matrix[12]", "matrix[13]", "matrix[14]", "matrix[15]" ], + "const GLfloat *matrix = ctx->ModelviewMatrixStack.Top->m;", None ), + ( "GL_MODELVIEW_STACK_DEPTH", GLint, ["ctx->ModelviewMatrixStack.Depth + 1"], "", None ), + ( "GL_NAME_STACK_DEPTH", GLint, ["ctx->Select.NameStackDepth"], "", None ), + ( "GL_NORMALIZE", GLboolean, ["ctx->Transform.Normalize"], "", None ), + ( "GL_PACK_ALIGNMENT", GLint, ["ctx->Pack.Alignment"], "", None ), + ( "GL_PACK_LSB_FIRST", GLboolean, ["ctx->Pack.LsbFirst"], "", None ), + ( "GL_PACK_ROW_LENGTH", GLint, ["ctx->Pack.RowLength"], "", None ), + ( "GL_PACK_SKIP_PIXELS", GLint, ["ctx->Pack.SkipPixels"], "", None ), + ( "GL_PACK_SKIP_ROWS", GLint, ["ctx->Pack.SkipRows"], "", None ), + ( "GL_PACK_SWAP_BYTES", GLboolean, ["ctx->Pack.SwapBytes"], "", None ), + ( "GL_PACK_SKIP_IMAGES_EXT", GLint, ["ctx->Pack.SkipImages"], "", None ), + ( "GL_PACK_IMAGE_HEIGHT_EXT", GLint, ["ctx->Pack.ImageHeight"], "", None ), + ( "GL_PACK_INVERT_MESA", GLboolean, ["ctx->Pack.Invert"], "", None ), + ( "GL_PERSPECTIVE_CORRECTION_HINT", GLenum, + ["ctx->Hint.PerspectiveCorrection"], "", None ), + ( "GL_PIXEL_MAP_A_TO_A_SIZE", GLint, ["ctx->PixelMaps.AtoA.Size"], "", None ), + ( "GL_PIXEL_MAP_B_TO_B_SIZE", GLint, ["ctx->PixelMaps.BtoB.Size"], "", None ), + ( "GL_PIXEL_MAP_G_TO_G_SIZE", GLint, ["ctx->PixelMaps.GtoG.Size"], "", None ), + ( "GL_PIXEL_MAP_I_TO_A_SIZE", GLint, ["ctx->PixelMaps.ItoA.Size"], "", None ), + ( "GL_PIXEL_MAP_I_TO_B_SIZE", GLint, ["ctx->PixelMaps.ItoB.Size"], "", None ), + ( "GL_PIXEL_MAP_I_TO_G_SIZE", GLint, ["ctx->PixelMaps.ItoG.Size"], "", None ), + ( "GL_PIXEL_MAP_I_TO_I_SIZE", GLint, ["ctx->PixelMaps.ItoI.Size"], "", None ), + ( "GL_PIXEL_MAP_I_TO_R_SIZE", GLint, ["ctx->PixelMaps.ItoR.Size"], "", None ), + ( "GL_PIXEL_MAP_R_TO_R_SIZE", GLint, ["ctx->PixelMaps.RtoR.Size"], "", None ), + ( "GL_PIXEL_MAP_S_TO_S_SIZE", GLint, ["ctx->PixelMaps.StoS.Size"], "", None ), + ( "GL_POINT_SIZE", GLfloat, ["ctx->Point.Size"], "", None ), + ( "GL_POINT_SIZE_GRANULARITY", GLfloat, + ["ctx->Const.PointSizeGranularity"], "", None ), + ( "GL_POINT_SIZE_RANGE", GLfloat, + ["ctx->Const.MinPointSizeAA", + "ctx->Const.MaxPointSizeAA"], "", None ), + ( "GL_ALIASED_POINT_SIZE_RANGE", GLfloat, + ["ctx->Const.MinPointSize", + "ctx->Const.MaxPointSize"], "", None ), + ( "GL_POINT_SMOOTH", GLboolean, ["ctx->Point.SmoothFlag"], "", None ), + ( "GL_POINT_SMOOTH_HINT", GLenum, ["ctx->Hint.PointSmooth"], "", None ), + ( "GL_POINT_SIZE_MIN_EXT", GLfloat, ["ctx->Point.MinSize"], "", None ), + ( "GL_POINT_SIZE_MAX_EXT", GLfloat, ["ctx->Point.MaxSize"], "", None ), + ( "GL_POINT_FADE_THRESHOLD_SIZE_EXT", GLfloat, + ["ctx->Point.Threshold"], "", None ), + ( "GL_DISTANCE_ATTENUATION_EXT", GLfloat, + ["ctx->Point.Params[0]", + "ctx->Point.Params[1]", + "ctx->Point.Params[2]"], "", None ), + ( "GL_POLYGON_MODE", GLenum, + ["ctx->Polygon.FrontMode", + "ctx->Polygon.BackMode"], "", None ), + ( "GL_POLYGON_OFFSET_BIAS_EXT", GLfloat, ["ctx->Polygon.OffsetUnits"], "", None ), + ( "GL_POLYGON_OFFSET_FACTOR", GLfloat, ["ctx->Polygon.OffsetFactor "], "", None ), + ( "GL_POLYGON_OFFSET_UNITS", GLfloat, ["ctx->Polygon.OffsetUnits "], "", None ), + ( "GL_POLYGON_OFFSET_POINT", GLboolean, ["ctx->Polygon.OffsetPoint"], "", None ), + ( "GL_POLYGON_OFFSET_LINE", GLboolean, ["ctx->Polygon.OffsetLine"], "", None ), + ( "GL_POLYGON_OFFSET_FILL", GLboolean, ["ctx->Polygon.OffsetFill"], "", None ), + ( "GL_POLYGON_SMOOTH", GLboolean, ["ctx->Polygon.SmoothFlag"], "", None ), + ( "GL_POLYGON_SMOOTH_HINT", GLenum, ["ctx->Hint.PolygonSmooth"], "", None ), + ( "GL_POLYGON_STIPPLE", GLboolean, ["ctx->Polygon.StippleFlag"], "", None ), + ( "GL_PROJECTION_MATRIX", GLfloat, + [ "matrix[0]", "matrix[1]", "matrix[2]", "matrix[3]", + "matrix[4]", "matrix[5]", "matrix[6]", "matrix[7]", + "matrix[8]", "matrix[9]", "matrix[10]", "matrix[11]", + "matrix[12]", "matrix[13]", "matrix[14]", "matrix[15]" ], + "const GLfloat *matrix = ctx->ProjectionMatrixStack.Top->m;", None ), + ( "GL_PROJECTION_STACK_DEPTH", GLint, + ["ctx->ProjectionMatrixStack.Depth + 1"], "", None ), + ( "GL_READ_BUFFER", GLenum, ["ctx->ReadBuffer->ColorReadBuffer"], "", None ), + ( "GL_RED_BIAS", GLfloat, ["ctx->Pixel.RedBias"], "", None ), + ( "GL_RED_BITS", GLint, ["ctx->DrawBuffer->Visual.redBits"], "", None ), + ( "GL_RED_SCALE", GLfloat, ["ctx->Pixel.RedScale"], "", None ), + ( "GL_RENDER_MODE", GLenum, ["ctx->RenderMode"], "", None ), + ( "GL_RESCALE_NORMAL", GLboolean, + ["ctx->Transform.RescaleNormals"], "", None ), + ( "GL_RGBA_MODE", GLboolean, ["GL_TRUE"], + "", None ), + ( "GL_SCISSOR_BOX", GLint, + ["ctx->Scissor.X", + "ctx->Scissor.Y", + "ctx->Scissor.Width", + "ctx->Scissor.Height"], "", None ), + ( "GL_SCISSOR_TEST", GLboolean, ["ctx->Scissor.Enabled"], "", None ), + ( "GL_SELECTION_BUFFER_SIZE", GLint, ["ctx->Select.BufferSize"], "", None ), + ( "GL_SHADE_MODEL", GLenum, ["ctx->Light.ShadeModel"], "", None ), + ( "GL_SHARED_TEXTURE_PALETTE_EXT", GLboolean, + ["ctx->Texture.SharedPalette"], "", None ), + ( "GL_STENCIL_BITS", GLint, ["ctx->DrawBuffer->Visual.stencilBits"], "", None ), + ( "GL_STENCIL_CLEAR_VALUE", GLint, ["ctx->Stencil.Clear"], "", None ), + ( "GL_STENCIL_FAIL", GLenum, + ["ctx->Stencil.FailFunc[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_FUNC", GLenum, + ["ctx->Stencil.Function[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_PASS_DEPTH_FAIL", GLenum, + ["ctx->Stencil.ZFailFunc[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_PASS_DEPTH_PASS", GLenum, + ["ctx->Stencil.ZPassFunc[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_REF", GLint, + ["ctx->Stencil.Ref[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_TEST", GLboolean, ["ctx->Stencil.Enabled"], "", None ), + ( "GL_STENCIL_VALUE_MASK", GLint, + ["ctx->Stencil.ValueMask[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STENCIL_WRITEMASK", GLint, + ["ctx->Stencil.WriteMask[ctx->Stencil.ActiveFace]"], "", None ), + ( "GL_STEREO", GLboolean, ["ctx->DrawBuffer->Visual.stereoMode"], + "", None ), + ( "GL_SUBPIXEL_BITS", GLint, ["ctx->Const.SubPixelBits"], "", None ), + ( "GL_TEXTURE_1D", GLboolean, ["_mesa_IsEnabled(GL_TEXTURE_1D)"], "", None ), + ( "GL_TEXTURE_2D", GLboolean, ["_mesa_IsEnabled(GL_TEXTURE_2D)"], "", None ), + ( "GL_TEXTURE_3D", GLboolean, ["_mesa_IsEnabled(GL_TEXTURE_3D)"], "", None ), + ( "GL_TEXTURE_1D_ARRAY_EXT", GLboolean, ["_mesa_IsEnabled(GL_TEXTURE_1D_ARRAY_EXT)"], "", ["MESA_texture_array"] ), + ( "GL_TEXTURE_2D_ARRAY_EXT", GLboolean, ["_mesa_IsEnabled(GL_TEXTURE_2D_ARRAY_EXT)"], "", ["MESA_texture_array"] ), + ( "GL_TEXTURE_BINDING_1D", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_1D_INDEX]->Name"], "", None ), + ( "GL_TEXTURE_BINDING_2D", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_2D_INDEX]->Name"], "", None ), + ( "GL_TEXTURE_BINDING_3D", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_3D_INDEX]->Name"], "", None ), + ( "GL_TEXTURE_BINDING_1D_ARRAY_EXT", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_1D_ARRAY_INDEX]->Name"], "", ["MESA_texture_array"] ), + ( "GL_TEXTURE_BINDING_2D_ARRAY_EXT", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_2D_ARRAY_INDEX]->Name"], "", ["MESA_texture_array"] ), + ( "GL_TEXTURE_GEN_S", GLboolean, + ["((ctx->Texture.Unit[ctx->Texture.CurrentUnit].TexGenEnabled & S_BIT) ? 1 : 0)"], "", None ), + ( "GL_TEXTURE_GEN_T", GLboolean, + ["((ctx->Texture.Unit[ctx->Texture.CurrentUnit].TexGenEnabled & T_BIT) ? 1 : 0)"], "", None ), + ( "GL_TEXTURE_GEN_R", GLboolean, + ["((ctx->Texture.Unit[ctx->Texture.CurrentUnit].TexGenEnabled & R_BIT) ? 1 : 0)"], "", None ), + ( "GL_TEXTURE_GEN_Q", GLboolean, + ["((ctx->Texture.Unit[ctx->Texture.CurrentUnit].TexGenEnabled & Q_BIT) ? 1 : 0)"], "", None ), + ( "GL_TEXTURE_MATRIX", GLfloat, + ["matrix[0]", "matrix[1]", "matrix[2]", "matrix[3]", + "matrix[4]", "matrix[5]", "matrix[6]", "matrix[7]", + "matrix[8]", "matrix[9]", "matrix[10]", "matrix[11]", + "matrix[12]", "matrix[13]", "matrix[14]", "matrix[15]" ], + """const GLfloat *matrix; + const GLuint unit = ctx->Texture.CurrentUnit; + if (unit >= ctx->Const.MaxTextureCoordUnits) { + _mesa_error(ctx, GL_INVALID_OPERATION, "glGet(texture matrix %u)", + unit); + return; + } + matrix = ctx->TextureMatrixStack[unit].Top->m;""", + None ), + ( "GL_TEXTURE_STACK_DEPTH", GLint, + ["ctx->TextureMatrixStack[unit].Depth + 1"], + """const GLuint unit = ctx->Texture.CurrentUnit; + if (unit >= ctx->Const.MaxTextureCoordUnits) { + _mesa_error(ctx, GL_INVALID_OPERATION, + "glGet(texture stack depth, unit %u)", unit); + return; + }""", + None ), + ( "GL_UNPACK_ALIGNMENT", GLint, ["ctx->Unpack.Alignment"], "", None ), + ( "GL_UNPACK_LSB_FIRST", GLboolean, ["ctx->Unpack.LsbFirst"], "", None ), + ( "GL_UNPACK_ROW_LENGTH", GLint, ["ctx->Unpack.RowLength"], "", None ), + ( "GL_UNPACK_SKIP_PIXELS", GLint, ["ctx->Unpack.SkipPixels"], "", None ), + ( "GL_UNPACK_SKIP_ROWS", GLint, ["ctx->Unpack.SkipRows"], "", None ), + ( "GL_UNPACK_SWAP_BYTES", GLboolean, ["ctx->Unpack.SwapBytes"], "", None ), + ( "GL_UNPACK_SKIP_IMAGES_EXT", GLint, ["ctx->Unpack.SkipImages"], "", None ), + ( "GL_UNPACK_IMAGE_HEIGHT_EXT", GLint, ["ctx->Unpack.ImageHeight"], "", None ), + ( "GL_UNPACK_CLIENT_STORAGE_APPLE", GLboolean, ["ctx->Unpack.ClientStorage"], "", None ), + ( "GL_VIEWPORT", GLint, [ "ctx->Viewport.X", "ctx->Viewport.Y", + "ctx->Viewport.Width", "ctx->Viewport.Height" ], "", None ), + ( "GL_ZOOM_X", GLfloat, ["ctx->Pixel.ZoomX"], "", None ), + ( "GL_ZOOM_Y", GLfloat, ["ctx->Pixel.ZoomY"], "", None ), + + # Vertex arrays + ( "GL_VERTEX_ARRAY", GLboolean, ["ctx->Array.ArrayObj->Vertex.Enabled"], "", None ), + ( "GL_VERTEX_ARRAY_SIZE", GLint, ["ctx->Array.ArrayObj->Vertex.Size"], "", None ), + ( "GL_VERTEX_ARRAY_TYPE", GLenum, ["ctx->Array.ArrayObj->Vertex.Type"], "", None ), + ( "GL_VERTEX_ARRAY_STRIDE", GLint, ["ctx->Array.ArrayObj->Vertex.Stride"], "", None ), + ( "GL_VERTEX_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + ( "GL_NORMAL_ARRAY", GLenum, ["ctx->Array.ArrayObj->Normal.Enabled"], "", None ), + ( "GL_NORMAL_ARRAY_TYPE", GLenum, ["ctx->Array.ArrayObj->Normal.Type"], "", None ), + ( "GL_NORMAL_ARRAY_STRIDE", GLint, ["ctx->Array.ArrayObj->Normal.Stride"], "", None ), + ( "GL_NORMAL_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + ( "GL_COLOR_ARRAY", GLboolean, ["ctx->Array.ArrayObj->Color.Enabled"], "", None ), + ( "GL_COLOR_ARRAY_SIZE", GLint, ["ctx->Array.ArrayObj->Color.Size"], "", None ), + ( "GL_COLOR_ARRAY_TYPE", GLenum, ["ctx->Array.ArrayObj->Color.Type"], "", None ), + ( "GL_COLOR_ARRAY_STRIDE", GLint, ["ctx->Array.ArrayObj->Color.Stride"], "", None ), + ( "GL_COLOR_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + ( "GL_INDEX_ARRAY", GLboolean, ["ctx->Array.ArrayObj->Index.Enabled"], "", None ), + ( "GL_INDEX_ARRAY_TYPE", GLenum, ["ctx->Array.ArrayObj->Index.Type"], "", None ), + ( "GL_INDEX_ARRAY_STRIDE", GLint, ["ctx->Array.ArrayObj->Index.Stride"], "", None ), + ( "GL_INDEX_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY", GLboolean, + ["ctx->Array.ArrayObj->TexCoord[ctx->Array.ActiveTexture].Enabled"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY_SIZE", GLint, + ["ctx->Array.ArrayObj->TexCoord[ctx->Array.ActiveTexture].Size"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY_TYPE", GLenum, + ["ctx->Array.ArrayObj->TexCoord[ctx->Array.ActiveTexture].Type"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY_STRIDE", GLint, + ["ctx->Array.ArrayObj->TexCoord[ctx->Array.ActiveTexture].Stride"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + ( "GL_EDGE_FLAG_ARRAY", GLboolean, ["ctx->Array.ArrayObj->EdgeFlag.Enabled"], "", None ), + ( "GL_EDGE_FLAG_ARRAY_STRIDE", GLint, ["ctx->Array.ArrayObj->EdgeFlag.Stride"], "", None ), + ( "GL_EDGE_FLAG_ARRAY_COUNT_EXT", GLint, ["0"], "", None ), + + # GL_ARB_multitexture + ( "GL_MAX_TEXTURE_UNITS_ARB", GLint, + ["ctx->Const.MaxTextureUnits"], "", ["ARB_multitexture"] ), + ( "GL_ACTIVE_TEXTURE_ARB", GLint, + [ "GL_TEXTURE0_ARB + ctx->Texture.CurrentUnit"], "", ["ARB_multitexture"] ), + ( "GL_CLIENT_ACTIVE_TEXTURE_ARB", GLint, + ["GL_TEXTURE0_ARB + ctx->Array.ActiveTexture"], "", ["ARB_multitexture"] ), + + # GL_ARB_texture_cube_map + ( "GL_TEXTURE_CUBE_MAP_ARB", GLboolean, + ["_mesa_IsEnabled(GL_TEXTURE_CUBE_MAP_ARB)"], "", ["ARB_texture_cube_map"] ), + ( "GL_TEXTURE_BINDING_CUBE_MAP_ARB", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_CUBE_INDEX]->Name"], + "", ["ARB_texture_cube_map"] ), + ( "GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB", GLint, + ["(1 << (ctx->Const.MaxCubeTextureLevels - 1))"], + "", ["ARB_texture_cube_map"]), + + # GL_ARB_texture_compression */ + ( "GL_TEXTURE_COMPRESSION_HINT_ARB", GLint, + ["ctx->Hint.TextureCompression"], "", None ), + ( "GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB", GLint, + ["_mesa_get_compressed_formats(ctx, NULL, GL_FALSE)"], + "", None ), + ( "GL_COMPRESSED_TEXTURE_FORMATS_ARB", GLenum, + [], + """GLint formats[100]; + GLuint i, n = _mesa_get_compressed_formats(ctx, formats, GL_FALSE); + ASSERT(n <= 100); + for (i = 0; i < n; i++) + params[i] = CONVERSION(formats[i]);""", + None ), + + # GL_EXT_compiled_vertex_array + ( "GL_ARRAY_ELEMENT_LOCK_FIRST_EXT", GLint, ["ctx->Array.LockFirst"], + "", ["EXT_compiled_vertex_array"] ), + ( "GL_ARRAY_ELEMENT_LOCK_COUNT_EXT", GLint, ["ctx->Array.LockCount"], + "", ["EXT_compiled_vertex_array"] ), + + # GL_ARB_transpose_matrix + ( "GL_TRANSPOSE_COLOR_MATRIX_ARB", GLfloat, + ["matrix[0]", "matrix[4]", "matrix[8]", "matrix[12]", + "matrix[1]", "matrix[5]", "matrix[9]", "matrix[13]", + "matrix[2]", "matrix[6]", "matrix[10]", "matrix[14]", + "matrix[3]", "matrix[7]", "matrix[11]", "matrix[15]"], + "const GLfloat *matrix = ctx->ColorMatrixStack.Top->m;", None ), + ( "GL_TRANSPOSE_MODELVIEW_MATRIX_ARB", GLfloat, + ["matrix[0]", "matrix[4]", "matrix[8]", "matrix[12]", + "matrix[1]", "matrix[5]", "matrix[9]", "matrix[13]", + "matrix[2]", "matrix[6]", "matrix[10]", "matrix[14]", + "matrix[3]", "matrix[7]", "matrix[11]", "matrix[15]"], + "const GLfloat *matrix = ctx->ModelviewMatrixStack.Top->m;", None ), + ( "GL_TRANSPOSE_PROJECTION_MATRIX_ARB", GLfloat, + ["matrix[0]", "matrix[4]", "matrix[8]", "matrix[12]", + "matrix[1]", "matrix[5]", "matrix[9]", "matrix[13]", + "matrix[2]", "matrix[6]", "matrix[10]", "matrix[14]", + "matrix[3]", "matrix[7]", "matrix[11]", "matrix[15]"], + "const GLfloat *matrix = ctx->ProjectionMatrixStack.Top->m;", None ), + ( "GL_TRANSPOSE_TEXTURE_MATRIX_ARB", GLfloat, + ["matrix[0]", "matrix[4]", "matrix[8]", "matrix[12]", + "matrix[1]", "matrix[5]", "matrix[9]", "matrix[13]", + "matrix[2]", "matrix[6]", "matrix[10]", "matrix[14]", + "matrix[3]", "matrix[7]", "matrix[11]", "matrix[15]"], + "const GLfloat *matrix = ctx->TextureMatrixStack[ctx->Texture.CurrentUnit].Top->m;", None ), + + # GL_SGI_color_matrix (also in 1.2 imaging) + ( "GL_COLOR_MATRIX_SGI", GLfloat, + ["matrix[0]", "matrix[1]", "matrix[2]", "matrix[3]", + "matrix[4]", "matrix[5]", "matrix[6]", "matrix[7]", + "matrix[8]", "matrix[9]", "matrix[10]", "matrix[11]", + "matrix[12]", "matrix[13]", "matrix[14]", "matrix[15]" ], + "const GLfloat *matrix = ctx->ColorMatrixStack.Top->m;", None ), + ( "GL_COLOR_MATRIX_STACK_DEPTH_SGI", GLint, + ["ctx->ColorMatrixStack.Depth + 1"], "", None ), + ( "GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI", GLint, + ["MAX_COLOR_STACK_DEPTH"], "", None ), + ( "GL_POST_COLOR_MATRIX_RED_SCALE_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixScale[0]"], "", None ), + ( "GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixScale[1]"], "", None ), + ( "GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixScale[2]"], "", None ), + ( "GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixScale[3]"], "", None ), + ( "GL_POST_COLOR_MATRIX_RED_BIAS_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixBias[0]"], "", None ), + ( "GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixBias[1]"], "", None ), + ( "GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixBias[2]"], "", None ), + ( "GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI", GLfloat, + ["ctx->Pixel.PostColorMatrixBias[3]"], "", None ), + + # GL_EXT_convolution (also in 1.2 imaging) + ( "GL_CONVOLUTION_1D_EXT", GLboolean, + ["ctx->Pixel.Convolution1DEnabled"], "", ["EXT_convolution"] ), + ( "GL_CONVOLUTION_2D_EXT", GLboolean, + ["ctx->Pixel.Convolution2DEnabled"], "", ["EXT_convolution"] ), + ( "GL_SEPARABLE_2D_EXT", GLboolean, + ["ctx->Pixel.Separable2DEnabled"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_RED_SCALE_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionScale[0]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_GREEN_SCALE_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionScale[1]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_BLUE_SCALE_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionScale[2]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_ALPHA_SCALE_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionScale[3]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_RED_BIAS_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionBias[0]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_GREEN_BIAS_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionBias[1]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_BLUE_BIAS_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionBias[2]"], "", ["EXT_convolution"] ), + ( "GL_POST_CONVOLUTION_ALPHA_BIAS_EXT", GLfloat, + ["ctx->Pixel.PostConvolutionBias[3]"], "", ["EXT_convolution"] ), + + # GL_EXT_histogram / GL_ARB_imaging + ( "GL_HISTOGRAM", GLboolean, + [ "ctx->Pixel.HistogramEnabled" ], "", ["EXT_histogram"] ), + ( "GL_MINMAX", GLboolean, + [ "ctx->Pixel.MinMaxEnabled" ], "", ["EXT_histogram"] ), + + # GL_SGI_color_table / GL_ARB_imaging + ( "GL_COLOR_TABLE_SGI", GLboolean, + ["ctx->Pixel.ColorTableEnabled[COLORTABLE_PRECONVOLUTION]"], "", ["SGI_color_table"] ), + ( "GL_POST_CONVOLUTION_COLOR_TABLE_SGI", GLboolean, + ["ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCONVOLUTION]"], "", ["SGI_color_table"] ), + ( "GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI", GLboolean, + ["ctx->Pixel.ColorTableEnabled[COLORTABLE_POSTCOLORMATRIX]"], "", ["SGI_color_table"] ), + + # GL_SGI_texture_color_table + ( "GL_TEXTURE_COLOR_TABLE_SGI", GLboolean, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].ColorTableEnabled"], + "", ["SGI_texture_color_table"] ), + + # GL_EXT_secondary_color + ( "GL_COLOR_SUM_EXT", GLboolean, + ["ctx->Fog.ColorSumEnabled"], "", + ["EXT_secondary_color", "ARB_vertex_program"] ), + ( "GL_CURRENT_SECONDARY_COLOR_EXT", GLfloatN, + ["ctx->Current.Attrib[VERT_ATTRIB_COLOR1][0]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR1][1]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR1][2]", + "ctx->Current.Attrib[VERT_ATTRIB_COLOR1][3]"], + "FLUSH_CURRENT(ctx, 0);", ["EXT_secondary_color"] ), + ( "GL_SECONDARY_COLOR_ARRAY_EXT", GLboolean, + ["ctx->Array.ArrayObj->SecondaryColor.Enabled"], "", ["EXT_secondary_color"] ), + ( "GL_SECONDARY_COLOR_ARRAY_TYPE_EXT", GLenum, + ["ctx->Array.ArrayObj->SecondaryColor.Type"], "", ["EXT_secondary_color"] ), + ( "GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT", GLint, + ["ctx->Array.ArrayObj->SecondaryColor.Stride"], "", ["EXT_secondary_color"] ), + ( "GL_SECONDARY_COLOR_ARRAY_SIZE_EXT", GLint, + ["ctx->Array.ArrayObj->SecondaryColor.Size"], "", ["EXT_secondary_color"] ), + + # GL_EXT_fog_coord + ( "GL_CURRENT_FOG_COORDINATE_EXT", GLfloat, + ["ctx->Current.Attrib[VERT_ATTRIB_FOG][0]"], + "FLUSH_CURRENT(ctx, 0);", ["EXT_fog_coord"] ), + ( "GL_FOG_COORDINATE_ARRAY_EXT", GLboolean, ["ctx->Array.ArrayObj->FogCoord.Enabled"], + "", ["EXT_fog_coord"] ), + ( "GL_FOG_COORDINATE_ARRAY_TYPE_EXT", GLenum, ["ctx->Array.ArrayObj->FogCoord.Type"], + "", ["EXT_fog_coord"] ), + ( "GL_FOG_COORDINATE_ARRAY_STRIDE_EXT", GLint, ["ctx->Array.ArrayObj->FogCoord.Stride"], + "", ["EXT_fog_coord"] ), + ( "GL_FOG_COORDINATE_SOURCE_EXT", GLenum, ["ctx->Fog.FogCoordinateSource"], + "", ["EXT_fog_coord"] ), + + # GL_EXT_texture_lod_bias + ( "GL_MAX_TEXTURE_LOD_BIAS_EXT", GLfloat, + ["ctx->Const.MaxTextureLodBias"], "", ["EXT_texture_lod_bias"]), + + # GL_EXT_texture_filter_anisotropic + ( "GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT", GLfloat, + ["ctx->Const.MaxTextureMaxAnisotropy"], "", ["EXT_texture_filter_anisotropic"]), + + # GL_ARB_multisample + ( "GL_MULTISAMPLE_ARB", GLboolean, + ["ctx->Multisample.Enabled"], "", None ), + ( "GL_SAMPLE_ALPHA_TO_COVERAGE_ARB", GLboolean, + ["ctx->Multisample.SampleAlphaToCoverage"], "", None ), + ( "GL_SAMPLE_ALPHA_TO_ONE_ARB", GLboolean, + ["ctx->Multisample.SampleAlphaToOne"], "", None ), + ( "GL_SAMPLE_COVERAGE_ARB", GLboolean, + ["ctx->Multisample.SampleCoverage"], "", None ), + ( "GL_SAMPLE_COVERAGE_VALUE_ARB", GLfloat, + ["ctx->Multisample.SampleCoverageValue"], "", None ), + ( "GL_SAMPLE_COVERAGE_INVERT_ARB", GLboolean, + ["ctx->Multisample.SampleCoverageInvert"], "", None ), + ( "GL_SAMPLE_BUFFERS_ARB", GLint, + ["ctx->DrawBuffer->Visual.sampleBuffers"], "", None ), + ( "GL_SAMPLES_ARB", GLint, + ["ctx->DrawBuffer->Visual.samples"], "", None ), + + # GL_IBM_rasterpos_clip + ( "GL_RASTER_POSITION_UNCLIPPED_IBM", GLboolean, + ["ctx->Transform.RasterPositionUnclipped"], "", ["IBM_rasterpos_clip"] ), + + # GL_NV_point_sprite + ( "GL_POINT_SPRITE_NV", GLboolean, ["ctx->Point.PointSprite"], # == GL_POINT_SPRITE_ARB + "", ["NV_point_sprite", "ARB_point_sprite"] ), + ( "GL_POINT_SPRITE_R_MODE_NV", GLenum, ["ctx->Point.SpriteRMode"], + "", ["NV_point_sprite"] ), + ( "GL_POINT_SPRITE_COORD_ORIGIN", GLenum, ["ctx->Point.SpriteOrigin"], + "", ["NV_point_sprite", "ARB_point_sprite"] ), + + # GL_SGIS_generate_mipmap + ( "GL_GENERATE_MIPMAP_HINT_SGIS", GLenum, ["ctx->Hint.GenerateMipmap"], + "", ["SGIS_generate_mipmap"] ), + + # GL_NV_vertex_program + ( "GL_VERTEX_PROGRAM_BINDING_NV", GLint, + ["(ctx->VertexProgram.Current ? ctx->VertexProgram.Current->Base.Id : 0)"], + "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY0_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[0].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY1_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[1].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY2_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[2].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY3_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[3].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY4_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[4].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY5_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[5].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY6_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[6].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY7_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[7].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY8_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[8].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY9_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[9].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY10_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[10].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY11_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[11].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY12_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[12].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY13_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[13].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY14_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[14].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_VERTEX_ATTRIB_ARRAY15_NV", GLboolean, + ["ctx->Array.ArrayObj->VertexAttrib[15].Enabled"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB0_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[0]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB1_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[1]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB2_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[2]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB3_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[3]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB4_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[4]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB5_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[5]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB6_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[6]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB7_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[7]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB8_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[8]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB9_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[9]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB10_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[10]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB11_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[11]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB12_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[12]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB13_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[13]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB14_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[14]"], "", ["NV_vertex_program"] ), + ( "GL_MAP1_VERTEX_ATTRIB15_4_NV", GLboolean, + ["ctx->Eval.Map1Attrib[15]"], "", ["NV_vertex_program"] ), + + # GL_NV_fragment_program + ( "GL_FRAGMENT_PROGRAM_NV", GLboolean, + ["ctx->FragmentProgram.Enabled"], "", ["NV_fragment_program"] ), + ( "GL_FRAGMENT_PROGRAM_BINDING_NV", GLint, + ["ctx->FragmentProgram.Current ? ctx->FragmentProgram.Current->Base.Id : 0"], + "", ["NV_fragment_program"] ), + ( "GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV", GLint, + ["MAX_NV_FRAGMENT_PROGRAM_PARAMS"], "", ["NV_fragment_program"] ), + + # GL_NV_texture_rectangle + ( "GL_TEXTURE_RECTANGLE_NV", GLboolean, + ["_mesa_IsEnabled(GL_TEXTURE_RECTANGLE_NV)"], "", ["NV_texture_rectangle"] ), + ( "GL_TEXTURE_BINDING_RECTANGLE_NV", GLint, + ["ctx->Texture.Unit[ctx->Texture.CurrentUnit].CurrentTex[TEXTURE_RECT_INDEX]->Name"], + "", ["NV_texture_rectangle"] ), + ( "GL_MAX_RECTANGLE_TEXTURE_SIZE_NV", GLint, + ["ctx->Const.MaxTextureRectSize"], "", ["NV_texture_rectangle"] ), + + # GL_EXT_stencil_two_side + ( "GL_STENCIL_TEST_TWO_SIDE_EXT", GLboolean, + ["ctx->Stencil.TestTwoSide"], "", ["EXT_stencil_two_side"] ), + ( "GL_ACTIVE_STENCIL_FACE_EXT", GLenum, + ["ctx->Stencil.ActiveFace ? GL_BACK : GL_FRONT"], + "", ["EXT_stencil_two_side"] ), + + # GL_NV_light_max_exponent + ( "GL_MAX_SHININESS_NV", GLfloat, + ["ctx->Const.MaxShininess"], "", ["NV_light_max_exponent"] ), + ( "GL_MAX_SPOT_EXPONENT_NV", GLfloat, + ["ctx->Const.MaxSpotExponent"], "", ["NV_light_max_exponent"] ), + + # GL_ARB_vertex_buffer_object + ( "GL_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayBufferObj->Name"], "", None ), + ( "GL_VERTEX_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->Vertex.BufferObj->Name"], "", None ), + ( "GL_NORMAL_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->Normal.BufferObj->Name"], "", None ), + ( "GL_COLOR_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->Color.BufferObj->Name"], "", None ), + ( "GL_INDEX_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->Index.BufferObj->Name"], "", None ), + ( "GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->TexCoord[ctx->Array.ActiveTexture].BufferObj->Name"], + "", None ), + ( "GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->EdgeFlag.BufferObj->Name"], "", None ), + ( "GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->SecondaryColor.BufferObj->Name"], + "", None ), + ( "GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ArrayObj->FogCoord.BufferObj->Name"], + "", None ), + # GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB - not supported + ( "GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB", GLint, + ["ctx->Array.ElementArrayBufferObj->Name"], + "", None ), + + # GL_EXT_pixel_buffer_object + ( "GL_PIXEL_PACK_BUFFER_BINDING_EXT", GLint, + ["ctx->Pack.BufferObj->Name"], "", ["EXT_pixel_buffer_object"] ), + ( "GL_PIXEL_UNPACK_BUFFER_BINDING_EXT", GLint, + ["ctx->Unpack.BufferObj->Name"], "", ["EXT_pixel_buffer_object"] ), + + # GL_ARB_vertex_program + ( "GL_VERTEX_PROGRAM_ARB", GLboolean, # == GL_VERTEX_PROGRAM_NV + ["ctx->VertexProgram.Enabled"], "", + ["ARB_vertex_program", "NV_vertex_program"] ), + ( "GL_VERTEX_PROGRAM_POINT_SIZE_ARB", GLboolean, # == GL_VERTEX_PROGRAM_POINT_SIZE_NV + ["ctx->VertexProgram.PointSizeEnabled"], "", + ["ARB_vertex_program", "NV_vertex_program"] ), + ( "GL_VERTEX_PROGRAM_TWO_SIDE_ARB", GLboolean, # == GL_VERTEX_PROGRAM_TWO_SIDE_NV + ["ctx->VertexProgram.TwoSideEnabled"], "", + ["ARB_vertex_program", "NV_vertex_program"] ), + ( "GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB", GLint, # == GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV + ["ctx->Const.MaxProgramMatrixStackDepth"], "", + ["ARB_vertex_program", "ARB_fragment_program", "NV_vertex_program"] ), + ( "GL_MAX_PROGRAM_MATRICES_ARB", GLint, # == GL_MAX_TRACK_MATRICES_NV + ["ctx->Const.MaxProgramMatrices"], "", + ["ARB_vertex_program", "ARB_fragment_program", "NV_vertex_program"] ), + ( "GL_CURRENT_MATRIX_STACK_DEPTH_ARB", GLboolean, # == GL_CURRENT_MATRIX_STACK_DEPTH_NV + ["ctx->CurrentStack->Depth + 1"], "", + ["ARB_vertex_program", "ARB_fragment_program", "NV_vertex_program"] ), + ( "GL_CURRENT_MATRIX_ARB", GLfloat, # == GL_CURRENT_MATRIX_NV + ["matrix[0]", "matrix[1]", "matrix[2]", "matrix[3]", + "matrix[4]", "matrix[5]", "matrix[6]", "matrix[7]", + "matrix[8]", "matrix[9]", "matrix[10]", "matrix[11]", + "matrix[12]", "matrix[13]", "matrix[14]", "matrix[15]" ], + "const GLfloat *matrix = ctx->CurrentStack->Top->m;", + ["ARB_vertex_program", "ARB_fragment_program", "NV_fragment_program"] ), + ( "GL_TRANSPOSE_CURRENT_MATRIX_ARB", GLfloat, + ["matrix[0]", "matrix[4]", "matrix[8]", "matrix[12]", + "matrix[1]", "matrix[5]", "matrix[9]", "matrix[13]", + "matrix[2]", "matrix[6]", "matrix[10]", "matrix[14]", + "matrix[3]", "matrix[7]", "matrix[11]", "matrix[15]"], + "const GLfloat *matrix = ctx->CurrentStack->Top->m;", + ["ARB_vertex_program", "ARB_fragment_program"] ), + ( "GL_MAX_VERTEX_ATTRIBS_ARB", GLint, + ["ctx->Const.VertexProgram.MaxAttribs"], "", ["ARB_vertex_program"] ), + ( "GL_PROGRAM_ERROR_POSITION_ARB", GLint, # == GL_PROGRAM_ERROR_POSITION_NV + ["ctx->Program.ErrorPos"], "", ["NV_vertex_program", + "ARB_vertex_program", "NV_fragment_program", "ARB_fragment_program"] ), + + # GL_ARB_fragment_program + ( "GL_FRAGMENT_PROGRAM_ARB", GLboolean, + ["ctx->FragmentProgram.Enabled"], "", ["ARB_fragment_program"] ), + ( "GL_MAX_TEXTURE_COORDS_ARB", GLint, # == GL_MAX_TEXTURE_COORDS_NV + ["ctx->Const.MaxTextureCoordUnits"], "", + ["ARB_fragment_program", "NV_fragment_program"] ), + ( "GL_MAX_TEXTURE_IMAGE_UNITS_ARB", GLint, # == GL_MAX_TEXTURE_IMAGE_UNITS_NV + ["ctx->Const.MaxTextureImageUnits"], "", + ["ARB_fragment_program", "NV_fragment_program"] ), + + # GL_EXT_depth_bounds_test + ( "GL_DEPTH_BOUNDS_TEST_EXT", GLboolean, + ["ctx->Depth.BoundsTest"], "", ["EXT_depth_bounds_test"] ), + ( "GL_DEPTH_BOUNDS_EXT", GLfloat, + ["ctx->Depth.BoundsMin", "ctx->Depth.BoundsMax"], + "", ["EXT_depth_bounds_test"] ), + + # GL_ARB_depth_clamp + ( "GL_DEPTH_CLAMP", GLboolean, ["ctx->Transform.DepthClamp"], "", + ["ARB_depth_clamp"] ), + + # GL_ARB_draw_buffers + ( "GL_MAX_DRAW_BUFFERS_ARB", GLint, + ["ctx->Const.MaxDrawBuffers"], "", None ), + ( "GL_DRAW_BUFFER0_ARB", GLenum, + ["ctx->DrawBuffer->ColorDrawBuffer[0]"], "", None ), + ( "GL_DRAW_BUFFER1_ARB", GLenum, + ["buffer"], + """GLenum buffer; + if (pname - GL_DRAW_BUFFER0_ARB >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_ENUM, "glGet(GL_DRAW_BUFFERx_ARB)"); + return; + } + buffer = ctx->DrawBuffer->ColorDrawBuffer[1];""", None ), + ( "GL_DRAW_BUFFER2_ARB", GLenum, + ["buffer"], + """GLenum buffer; + if (pname - GL_DRAW_BUFFER0_ARB >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_ENUM, "glGet(GL_DRAW_BUFFERx_ARB)"); + return; + } + buffer = ctx->DrawBuffer->ColorDrawBuffer[2];""", None ), + ( "GL_DRAW_BUFFER3_ARB", GLenum, + ["buffer"], + """GLenum buffer; + if (pname - GL_DRAW_BUFFER0_ARB >= ctx->Const.MaxDrawBuffers) { + _mesa_error(ctx, GL_INVALID_ENUM, "glGet(GL_DRAW_BUFFERx_ARB)"); + return; + } + buffer = ctx->DrawBuffer->ColorDrawBuffer[3];""", None ), + # XXX Add more GL_DRAW_BUFFERn_ARB entries as needed in the future + + # GL_OES_read_format + ( "GL_IMPLEMENTATION_COLOR_READ_TYPE_OES", GLint, + ["_mesa_get_color_read_type(ctx)"], "", ["OES_read_format"] ), + ( "GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES", GLint, + ["_mesa_get_color_read_format(ctx)"], "", ["OES_read_format"] ), + + # GL_ATI_fragment_shader + ( "GL_NUM_FRAGMENT_REGISTERS_ATI", GLint, ["6"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_FRAGMENT_CONSTANTS_ATI", GLint, ["8"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_PASSES_ATI", GLint, ["2"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_INSTRUCTIONS_PER_PASS_ATI", GLint, ["8"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_INSTRUCTIONS_TOTAL_ATI", GLint, ["16"], "", ["ATI_fragment_shader"] ), + ( "GL_COLOR_ALPHA_PAIRING_ATI", GLboolean, ["GL_TRUE"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_LOOPBACK_COMPONENTS_ATI", GLint, ["3"], "", ["ATI_fragment_shader"] ), + ( "GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI", GLint, ["3"], "", ["ATI_fragment_shader"] ), + + # OpenGL 2.0 + ( "GL_STENCIL_BACK_FUNC", GLenum, ["ctx->Stencil.Function[1]"], "", None ), + ( "GL_STENCIL_BACK_VALUE_MASK", GLint, ["ctx->Stencil.ValueMask[1]"], "", None ), + ( "GL_STENCIL_BACK_WRITEMASK", GLint, ["ctx->Stencil.WriteMask[1]"], "", None ), + ( "GL_STENCIL_BACK_REF", GLint, ["ctx->Stencil.Ref[1]"], "", None ), + ( "GL_STENCIL_BACK_FAIL", GLenum, ["ctx->Stencil.FailFunc[1]"], "", None ), + ( "GL_STENCIL_BACK_PASS_DEPTH_FAIL", GLenum, ["ctx->Stencil.ZFailFunc[1]"], "", None ), + ( "GL_STENCIL_BACK_PASS_DEPTH_PASS", GLenum, ["ctx->Stencil.ZPassFunc[1]"], "", None ), + + # GL_EXT_framebuffer_object + ( "GL_FRAMEBUFFER_BINDING_EXT", GLint, ["ctx->DrawBuffer->Name"], "", + ["EXT_framebuffer_object"] ), + ( "GL_RENDERBUFFER_BINDING_EXT", GLint, + ["ctx->CurrentRenderbuffer ? ctx->CurrentRenderbuffer->Name : 0"], "", + ["EXT_framebuffer_object"] ), + ( "GL_MAX_COLOR_ATTACHMENTS_EXT", GLint, + ["ctx->Const.MaxColorAttachments"], "", + ["EXT_framebuffer_object"] ), + ( "GL_MAX_RENDERBUFFER_SIZE_EXT", GLint, + ["ctx->Const.MaxRenderbufferSize"], "", + ["EXT_framebuffer_object"] ), + + # GL_EXT_framebuffer_blit + # NOTE: GL_DRAW_FRAMEBUFFER_BINDING_EXT == GL_FRAMEBUFFER_BINDING_EXT + ( "GL_READ_FRAMEBUFFER_BINDING_EXT", GLint, ["ctx->ReadBuffer->Name"], "", + ["EXT_framebuffer_blit"] ), + + # GL_EXT_provoking_vertex + ( "GL_PROVOKING_VERTEX_EXT", GLboolean, + ["ctx->Light.ProvokingVertex"], "", ["EXT_provoking_vertex"] ), + ( "GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT", GLboolean, + ["ctx->Const.QuadsFollowProvokingVertexConvention"], "", + ["EXT_provoking_vertex"] ), + + # GL_ARB_fragment_shader + ( "GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB", GLint, + ["ctx->Const.FragmentProgram.MaxUniformComponents"], "", + ["ARB_fragment_shader"] ), + ( "GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB", GLenum, + ["ctx->Hint.FragmentShaderDerivative"], "", ["ARB_fragment_shader"] ), + + # GL_ARB_vertex_shader + ( "GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB", GLint, + ["ctx->Const.VertexProgram.MaxUniformComponents"], "", + ["ARB_vertex_shader"] ), + ( "GL_MAX_VARYING_FLOATS_ARB", GLint, + ["ctx->Const.MaxVarying * 4"], "", ["ARB_vertex_shader"] ), + ( "GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB", GLint, + ["ctx->Const.MaxVertexTextureImageUnits"], "", ["ARB_vertex_shader"] ), + ( "GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB", GLint, + ["ctx->Const.MaxCombinedTextureImageUnits"], "", ["ARB_vertex_shader"] ), + + # GL_ARB_shader_objects + # Actually, this token isn't part of GL_ARB_shader_objects, but is + # close enough for now. + ( "GL_CURRENT_PROGRAM", GLint, + ["ctx->Shader.CurrentProgram ? ctx->Shader.CurrentProgram->Name : 0"], + "", ["ARB_shader_objects"] ), + + # GL_ARB_framebuffer_object + ( "GL_MAX_SAMPLES", GLint, ["ctx->Const.MaxSamples"], "", + ["ARB_framebuffer_object"] ), + + # GL_APPLE_vertex_array_object + ( "GL_VERTEX_ARRAY_BINDING_APPLE", GLint, ["ctx->Array.ArrayObj->Name"], "", + ["APPLE_vertex_array_object"] ), + + # GL_ARB_seamless_cube_map + ( "GL_TEXTURE_CUBE_MAP_SEAMLESS", GLboolean, ["ctx->Texture.CubeMapSeamless"], "", + ["ARB_seamless_cube_map"] ), + + # GL_ARB_sync + ( "GL_MAX_SERVER_WAIT_TIMEOUT", GLint64, ["ctx->Const.MaxServerWaitTimeout"], "", + ["ARB_sync"] ), + + # GL3 + ( "GL_NUM_EXTENSIONS", GLint, ["_mesa_get_extension_count(ctx)"], "", None ), + ( "GL_MAJOR_VERSION", GLint, ["ctx->VersionMajor"], "", None ), + ( "GL_MINOR_VERSION", GLint, ["ctx->VersionMinor"], "", None ) +] + + +# These are queried via glGetIntegetIndexdvEXT() or glGetIntegeri_v() +IndexedStateVars = [ + ( "GL_BLEND", GLint, ["((ctx->Color.BlendEnabled >> index) & 1)"], + "ctx->Const.MaxDrawBuffers", ["EXT_draw_buffers2"] ), + ( "GL_COLOR_WRITEMASK", GLint, + [ "ctx->Color.ColorMask[index][RCOMP] ? 1 : 0", + "ctx->Color.ColorMask[index][GCOMP] ? 1 : 0", + "ctx->Color.ColorMask[index][BCOMP] ? 1 : 0", + "ctx->Color.ColorMask[index][ACOMP] ? 1 : 0" ], + "ctx->Const.MaxDrawBuffers", ["EXT_draw_buffers2"] ), + # XXX more to come... +] + + + +def ConversionFunc(fromType, toType): + """Return the name of the macro to convert between two data types.""" + if fromType == toType: + return "" + elif fromType == GLfloat and toType == GLint: + return "IROUND" + elif fromType == GLfloat and toType == GLint64: + return "IROUND64" + elif fromType == GLfloatN and toType == GLfloat: + return "" + elif fromType == GLint and toType == GLfloat: # but not GLfloatN! + return "(GLfloat)" + elif fromType == GLint and toType == GLint64: + return "(GLint64)" + elif fromType == GLint64 and toType == GLfloat: # but not GLfloatN! + return "(GLfloat)" + else: + if fromType == GLfloatN: + fromType = GLfloat + fromStr = TypeStrings[fromType] + fromStr = string.upper(fromStr[2:]) + toStr = TypeStrings[toType] + toStr = string.upper(toStr[2:]) + return fromStr + "_TO_" + toStr + + +def EmitGetFunction(stateVars, returnType, indexed): + """Emit the code to implement glGetBooleanv, glGetIntegerv or glGetFloatv.""" + assert (returnType == GLboolean or + returnType == GLint or + returnType == GLint64 or + returnType == GLfloat) + + strType = TypeStrings[returnType] + # Capitalize first letter of return type + if indexed: + if returnType == GLint: + function = "GetIntegerIndexedv" + elif returnType == GLboolean: + function = "GetBooleanIndexedv" + elif returnType == GLint64: + function = "GetInteger64Indexedv" + else: + function = "Foo" + else: + if returnType == GLint: + function = "GetIntegerv" + elif returnType == GLboolean: + function = "GetBooleanv" + elif returnType == GLfloat: + function = "GetFloatv" + elif returnType == GLint64: + function = "GetInteger64v" + else: + sys.exit(1) + + if returnType == GLint64: + print "#if FEATURE_ARB_sync" + + print "void GLAPIENTRY" + if indexed: + print "_mesa_%s( GLenum pname, GLuint index, %s *params )" % (function, strType) + else: + print "_mesa_%s( GLenum pname, %s *params )" % (function, strType) + print "{" + print " GET_CURRENT_CONTEXT(ctx);" + print " ASSERT_OUTSIDE_BEGIN_END(ctx);" + print "" + print " if (!params)" + print " return;" + print "" + print " if (ctx->NewState)" + print " _mesa_update_state(ctx);" + print "" + if indexed == 0: + print " if (ctx->Driver.%s &&" % function + print " ctx->Driver.%s(ctx, pname, params))" % function + print " return;" + print "" + print " switch (pname) {" + + for state in stateVars: + if indexed: + (name, varType, state, indexMax, extensions) = state + optionalCode = 0 + else: + (name, varType, state, optionalCode, extensions) = state + indexMax = 0 + print " case " + name + ":" + if extensions: + if len(extensions) == 1: + print (' CHECK_EXT1(%s, "%s");' % + (extensions[0], function)) + elif len(extensions) == 2: + print (' CHECK_EXT2(%s, %s, "%s");' % + (extensions[0], extensions[1], function)) + elif len(extensions) == 3: + print (' CHECK_EXT3(%s, %s, %s, "%s");' % + (extensions[0], extensions[1], extensions[2], function)) + else: + assert len(extensions) == 4 + print (' CHECK_EXT4(%s, %s, %s, %s, "%s");' % + (extensions[0], extensions[1], extensions[2], extensions[3], function)) + if indexMax: + print (' if (index >= %s) {' % indexMax) + print (' _mesa_error(ctx, GL_INVALID_VALUE, "gl%s(index=%%u), index", pname);' % function) + print (' }') + + conversion = ConversionFunc(varType, returnType) + if optionalCode: + optionalCode = string.replace(optionalCode, "CONVERSION", conversion); + print " {" + print " " + optionalCode + n = len(state) + for i in range(n): + if conversion: + print " params[%d] = %s(%s);" % (i, conversion, state[i]) + else: + print " params[%d] = %s;" % (i, state[i]) + if optionalCode: + print " }" + print " break;" + + print " default:" + print ' _mesa_error(ctx, GL_INVALID_ENUM, "gl%s(pname=0x%%x)", pname);' % function + print " }" + print "}" + if returnType == GLint64: + print "#endif /* FEATURE_ARB_sync */" + print "" + return + + + +def EmitHeader(): + """Print the get.c file header.""" + print """ +/*** + *** NOTE!!! DO NOT EDIT THIS FILE!!! IT IS GENERATED BY get_gen.py + ***/ + +#include "glheader.h" +#include "context.h" +#include "enable.h" +#include "extensions.h" +#include "get.h" +#include "macros.h" +#include "mtypes.h" +#include "state.h" +#include "texcompress.h" +#include "framebuffer.h" + + +#define FLOAT_TO_BOOLEAN(X) ( (X) ? GL_TRUE : GL_FALSE ) + +#define INT_TO_BOOLEAN(I) ( (I) ? GL_TRUE : GL_FALSE ) + +#define INT64_TO_BOOLEAN(I) ( (I) ? GL_TRUE : GL_FALSE ) +#define INT64_TO_INT(I) ( (GLint)((I > INT_MAX) ? INT_MAX : ((I < INT_MIN) ? INT_MIN : (I))) ) + +#define BOOLEAN_TO_INT(B) ( (GLint) (B) ) +#define BOOLEAN_TO_INT64(B) ( (GLint64) (B) ) +#define BOOLEAN_TO_FLOAT(B) ( (B) ? 1.0F : 0.0F ) + +#define ENUM_TO_INT64(E) ( (GLint64) (E) ) + + +/* + * Check if named extension is enabled, if not generate error and return. + */ +#define CHECK_EXT1(EXT1, FUNC) \\ + if (!ctx->Extensions.EXT1) { \\ + _mesa_error(ctx, GL_INVALID_ENUM, FUNC "(0x%x)", (int) pname); \\ + return; \\ + } + +/* + * Check if either of two extensions is enabled. + */ +#define CHECK_EXT2(EXT1, EXT2, FUNC) \\ + if (!ctx->Extensions.EXT1 && !ctx->Extensions.EXT2) { \\ + _mesa_error(ctx, GL_INVALID_ENUM, FUNC "(0x%x)", (int) pname); \\ + return; \\ + } + +/* + * Check if either of three extensions is enabled. + */ +#define CHECK_EXT3(EXT1, EXT2, EXT3, FUNC) \\ + if (!ctx->Extensions.EXT1 && !ctx->Extensions.EXT2 && \\ + !ctx->Extensions.EXT3) { \\ + _mesa_error(ctx, GL_INVALID_ENUM, FUNC "(0x%x)", (int) pname); \\ + return; \\ + } + +/* + * Check if either of four extensions is enabled. + */ +#define CHECK_EXT4(EXT1, EXT2, EXT3, EXT4, FUNC) \\ + if (!ctx->Extensions.EXT1 && !ctx->Extensions.EXT2 && \\ + !ctx->Extensions.EXT3 && !ctx->Extensions.EXT4) { \\ + _mesa_error(ctx, GL_INVALID_ENUM, FUNC "(0x%x)", (int) pname); \\ + return; \\ + } + +""" + return + + + +def EmitGetDoublev(): + print """ +void GLAPIENTRY +_mesa_GetDoublev( GLenum pname, GLdouble *params ) +{ + const GLfloat magic = -1234.5F; + GLfloat values[16]; + GLuint i; + + if (!params) + return; + + /* Init temp array to magic numbers so we can figure out how many values + * are returned by the GetFloatv() call. + */ + for (i = 0; i < 16; i++) + values[i] = magic; + + _mesa_GetFloatv(pname, values); + + for (i = 0; i < 16 && values[i] != magic; i++) + params[i] = (GLdouble) values[i]; +} +""" + + + + +EmitHeader() +# XXX Maybe sort the StateVars list +EmitGetFunction(StateVars, GLboolean, 0) +EmitGetFunction(StateVars, GLfloat, 0) +EmitGetFunction(StateVars, GLint, 0) +EmitGetFunction(StateVars, GLint64, 0) +EmitGetDoublev() + +EmitGetFunction(IndexedStateVars, GLboolean, 1) +EmitGetFunction(IndexedStateVars, GLint, 1) +EmitGetFunction(IndexedStateVars, GLint64, 1) + --- mesa-7.8.2.orig/src/mesa/state_tracker/Makefile +++ mesa-7.8.2/src/mesa/state_tracker/Makefile @@ -0,0 +1,2 @@ +default: + cd ../.. ; make \ No newline at end of file --- mesa-7.8.2.orig/src/mesa/swrast/NOTES +++ mesa-7.8.2/src/mesa/swrast/NOTES @@ -0,0 +1,55 @@ +INTRODUCTION + +Mesa's native software rasterizer. This module provides the fallback +paths for rasterization operations and states that aren't accelerated +in hardware drivers, and as the full rasterization engine in software +drivers. + +The swrast module 'stands alone', relying only on interfaces to core +mesa and it's own driver interface. It knows nothing about the tnl or +other modules, allowing it to be used for fallback paths in future tnl +schemes without modification. + +As well as providing triangle/line/point rasterization functionality, +the module provides implementations of the pixel operations +(ReadPixels, etc), and texture operations (CopyTexSubImage) which may +be plugged in to the core Mesa driver interface where accelerated +versions of these operations are unavailable. + + +STATE + +To create and destroy the module: + + GLboolean _swrast_CreateContext( GLcontext *ctx ); + void _swrast_DestroyContext( GLcontext *ctx ); + +This module tracks state changes internally and maintains derived +values based on the current state. For this to work, the driver +ensure the following funciton is called whenever the state changes and +the swsetup module is 'awake': + + void _swrast_InvalidateState( GLcontext *ctx, GLuint new_state ); + +There is no explicit call to put the swrast module to sleep. + + +CUSTOMIZATION + + void (*choose_point)( GLcontext * ); + void (*choose_line)( GLcontext * ); + void (*choose_triangle)( GLcontext * ); + +Drivers may add additional triangle/line/point functions to swrast by +overriding these functions. It is necessary for the driver to be very +careful that it doesn't return an inappropriate function, eg a +rasterization function in feedback mode. See the X11 driver for +examples. + +DRIVER INTERFACE + +The swrast device driver provides swrast primarily with span- and +pixel- level interfaces to a framebuffer, with a few additional hooks +for locking and setting the read buffer. + +See the definition of struct swrast_device_driver in swrast.h. \ No newline at end of file --- mesa-7.8.2.orig/src/mesa/swrast_setup/NOTES +++ mesa-7.8.2/src/mesa/swrast_setup/NOTES @@ -0,0 +1,65 @@ +INTRODUCTION + +A helper module which provides glue to bind the software rasterizer to +the software t&l module. The main task of this module is to build +swrast vertices from the t&l vertex_buffer structs, and to use them to +perform triangle setup functions not implemented in the software +rasterizer. + +The module implements a full set of functions to plug into the +t_vb_render.c driver interface (tnl->Driver.Render.*). + +There are strong advantages to decoupling the software rasterizer from +the t&l module, primarily allowing hardware drivers better control +over fallbacks, the removal of implicit knowledge about the software +rasterizer in the t&l module, allowing the two modules to evolve +independently and allowing either to be substituted with equivalent +functionality from another codebase. + +This module implements triangle/quad setup for offset, unfilled and +twoside-lit triangles. The software rasterizer doesn't handle these +primitives directly. + +Hardware rasterization drivers typically use this module in situations +where no hardware rasterization is possible, ie during total +fallbacks. + +STATE + +To create and destroy the module: + + GLboolean _swsetup_CreateContext( GLcontext *ctx ); + void _swsetup_DestroyContext( GLcontext *ctx ); + +The module is not active by default, and must be installed by calling +_swrast_Wakeup(). This function installs internal swrast_setup +functions into all the tnl->Driver.Render driver hooks, thus taking +over the task of rasterization entirely: + + void _swrast_Wakeup( GLcontext *ctx ); + + +This module tracks state changes internally and maintains derived +values based on the current state. For this to work, the driver +ensure the following funciton is called whenever the state changes and +the swsetup module is 'awake': + + void _swsetup_InvalidateState( GLcontext *ctx, GLuint new_state ); + +There is no explicit call to put the swsetup module to sleep. Simply +install other function pointers into all the tnl->Driver.Render.* +hooks, and (optionally) cease calling _swsetup_InvalidateState(). + +DRIVER INTERFACE + +The module offers a minimal driver interface: + + void (*Start)( GLcontext *ctx ); + void (*Finish)( GLcontext *ctx ); + +These are called before and after the completion of all swrast drawing +activity. As swrast doesn't call callbacks during triangle, line or +point rasterization, these are necessary to provide locking hooks for +some drivers. They may otherwise be left null. + + --- mesa-7.8.2.orig/src/mesa/tnl/NOTES +++ mesa-7.8.2/src/mesa/tnl/NOTES @@ -0,0 +1,102 @@ +INTRODUCTION + +A generic, configurable software implementation of GL transformation & +lighting. + +This module provides an implementation of the routines required by the +'vtxfmt' mechanism of core mesa for tnl functionality in all +combinations of compile and execute modes. + +Most current drivers use the tnl module exclusively to provide this +functionality, though there is an experimental alternate +implementation provided by the tnl_dd/t_dd_imm_* files which can +handle a small subset of GL states in execute mode only. + + +STATE + +To create and destroy the module: + + GLboolean _tnl_CreateContext( GLcontext *ctx ); + void _tnl_DestroyContext( GLcontext *ctx ); + +The module is not active by default, and must be installed by calling +_tnl_Wakeup(). This function installs internal tnl functions into all +the vtxfmt dispatch hooks, thus taking over the task of transformation +and lighting entirely: + + void _tnl_wakeup_exec( GLcontext *ctx ); + void _tnl_wakeup_save_exec( GLcontext *ctx ); + + +This module tracks state changes internally and maintains derived +values based on the current state. For this to work, the driver +ensure the following funciton is called whenever the state changes and +the swsetup module is 'awake': + + void _tnl_InvalidateState( GLcontext *ctx, GLuint new_state ); + +There is no explicit call to put the tnl module to sleep. Simply +install other function pointers into all the vtxfmt dispatch slots, +and (optionally) cease calling _tnl_InvalidateState(). + +CUSTOMIZATION + +The module provides customizability through several mechanisms. The +most important is by allowing drivers to specify the pipeline through +which vertex data is passed, including its eventual transfer to +rasterization hardware (or software). + +The default pipeline is specified in t_pipeline.c, and is usually a +starting point for driver pipelines. Some drivers will remove a stage +where hardware provides support for the implemented operation (for +instance fog where per-pixel hardware fog is available, as in the dri +tdfx driver), or add stages to shortcircuit latter operations (for +example taking advantage of hardware support for strips and other +higher-level primitives (for example the radeon driver). + +In addition, the following functions provide further tweaks: + +extern void +_tnl_need_projected_coords( GLcontext *ctx, GLboolean flag ); + + - Direct the default vertex transformation stage to + produce/not produce projected clip coordinates. + +extern void +_tnl_need_dlist_loopback( GLcontext *ctx, GLboolean flag ); + + - Direct the display list component of the tnl module to + replay display lists as 'glVertex' type calls, rather than + passing the display list data directly into the tnl pipeline + mechanism. + + This allows display lists to be replayed by the tnl module + even when the module is not strictly active. + + +extern void +_tnl_need_dlist_norm_lengths( GLcontext *ctx, GLboolean flag ); + + - Direct the display list component to enable/disable caching + 1/length values for display list normals. Doing so is + ususally helpful when lighting is performed in software, but + wasteful otherwise. + + +DRIVER INTERFACE + +The module itself offers a minimal driver interface: + + void (*RunPipeline)( GLcontext *ctx ); + +Normally this is set to _tnl_RunPipeline(), however the driver can use +this hook to wrap checks or other code around this call. + +In addition, the driver interface for the default render pipeline +stage is housed in the tnl context struct (this could be cleaner). + + +RENDER DRIVER INTERFACE + +See t_context.h for the definition and explanation of this. \ No newline at end of file --- mesa-7.8.2.orig/src/mesa/x86-64/calling_convention.txt +++ mesa-7.8.2/src/mesa/x86-64/calling_convention.txt @@ -0,0 +1,50 @@ +Register Usage +rax temporary register; with variable arguments passes information + about the number of SSE registers used; 1st return register + +rbx* callee-saved register; optionally used as base pointer + +rcx used to pass 4th integer argument to functions + +rdx used to pass 3rd argument to functions 2nd return register + +rsp* stack pointer + +rbp* callee-saved register; optionally used as frame pointer + +rsi used to pass 2nd argument to functions + +rdi used to pass 1st argument to functions + +r8 used to pass 5th argument to functions + +r9 used to pass 6th argument to functions + +r10 temporary register, used for passing a function's static chain pointer + +r11 temporary register + +r12-15* callee-saved registers + +xmm01 used to pass and return floating point arguments + +xmm27 used to pass floating point arguments + +xmm815 temporary registers + +mmx07 temporary registers + +st0 temporary register; used to return long double arguments + +st1 temporary registers; used to return long double arguments + +st27 temporary registers + +fs Reserved for system use (as thread specific data register) + + + +*) must be preserved across function calls + +Integer arguments from list: rdi,rsi,rdx,rcx,r8,r9,stack +Floating point arguments from list: xmm0-xmm7 \ No newline at end of file --- mesa-7.8.2.orig/src/mesa/shader/slang/library/SConscript +++ mesa-7.8.2/src/mesa/shader/slang/library/SConscript @@ -0,0 +1,52 @@ +####################################################################### +# SConscript for GLSL builtin library + +Import('*') + +env = env.Clone() + +# See also http://www.scons.org/wiki/UsingCodeGenerators + +def glsl_compile_emitter(target, source, env): + env.Depends(target, glsl_compile) + return (target, source) + +bld_frag = Builder( + action = Action(glsl_compile[0].abspath + ' fragment $SOURCE $TARGET', '$CODEGENCODESTR'), + emitter = glsl_compile_emitter, + suffix = '.gc', + src_suffix = '_gc.h') + +bld_vert = Builder( + action = Action(glsl_compile[0].abspath + ' vertex $SOURCE $TARGET', '$CODEGENCODESTR'), + emitter = glsl_compile_emitter, + suffix = '.gc', + src_suffix = '_gc.h') + +env['BUILDERS']['bld_frag'] = bld_frag +env['BUILDERS']['bld_vert'] = bld_vert + +# Generate GLSL builtin library binaries +env.bld_frag( + '#src/mesa/shader/slang/library/slang_core_gc.h', + '#src/mesa/shader/slang/library/slang_core.gc') +env.bld_frag( + '#src/mesa/shader/slang/library/slang_common_builtin_gc.h', + '#src/mesa/shader/slang/library/slang_common_builtin.gc') +env.bld_frag( + '#src/mesa/shader/slang/library/slang_fragment_builtin_gc.h', + '#src/mesa/shader/slang/library/slang_fragment_builtin.gc') +env.bld_vert( + '#src/mesa/shader/slang/library/slang_vertex_builtin_gc.h', + '#src/mesa/shader/slang/library/slang_vertex_builtin.gc') + +# Generate GLSL 1.20 builtin library binaries +env.bld_frag( + '#src/mesa/shader/slang/library/slang_120_core_gc.h', + '#src/mesa/shader/slang/library/slang_120_core.gc') +env.bld_frag( + '#src/mesa/shader/slang/library/slang_builtin_120_common_gc.h', + '#src/mesa/shader/slang/library/slang_builtin_120_common.gc') +env.bld_frag( + '#src/mesa/shader/slang/library/slang_builtin_120_fragment_gc.h', + '#src/mesa/shader/slang/library/slang_builtin_120_fragment.gc') --- mesa-7.8.2.orig/src/mesa/glapi/gen/Makefile +++ mesa-7.8.2/src/mesa/glapi/gen/Makefile @@ -0,0 +1,203 @@ +# This file isn't used during a normal compilation since we don't want to +# require Python in order to compile Mesa. +# Instead, when the Mesa developers update/change the API interface it's +# up to him/her to re-run this makefile and check in the newly generated files. + + +TOP = ../../../.. +include $(TOP)/configs/current + +MESA_DIR = $(TOP)/src/mesa +MESA_GLAPI_DIR = $(TOP)/src/mesa/glapi +MESA_GLX_DIR = $(TOP)/src/glx + +MESA_GLAPI_OUTPUTS = \ + $(MESA_GLAPI_DIR)/glprocs.h \ + $(MESA_GLAPI_DIR)/glapitemp.h \ + $(MESA_GLAPI_DIR)/glapioffsets.h \ + $(MESA_GLAPI_DIR)/glapitable.h \ + $(MESA_GLAPI_DIR)/glapidispatch.h + +MESA_GLAPI_ASM_OUTPUTS = \ + $(MESA_DIR)/x86/glapi_x86.S \ + $(MESA_DIR)/x86-64/glapi_x86-64.S \ + $(MESA_DIR)/sparc/glapi_sparc.S + +MESA_OUTPUTS = \ + $(MESA_GLAPI_OUTPUTS) \ + $(MESA_GLAPI_ASM_OUTPUTS) \ + $(MESA_DIR)/main/enums.c \ + $(MESA_DIR)/main/remap_helper.h \ + $(MESA_GLX_DIR)/indirect.c \ + $(MESA_GLX_DIR)/indirect.h \ + $(MESA_GLX_DIR)/indirect_init.c \ + $(MESA_GLX_DIR)/indirect_size.h \ + $(MESA_GLX_DIR)/indirect_size.c + +###################################################################### + +XORG_GLX_DIR = $(XORG_BASE)/glx +XORG_GLAPI_DIR = $(XORG_BASE)/glx/glapi + +XORG_GLAPI_FILES = \ + $(XORG_GLAPI_DIR)/glapi.h \ + $(XORG_GLAPI_DIR)/glapi.c \ + $(XORG_GLAPI_DIR)/glapi_getproc.c \ + $(XORG_GLAPI_DIR)/glapi_nop.c \ + $(XORG_GLAPI_DIR)/glthread.c \ + $(XORG_GLAPI_DIR)/glthread.h + +XORG_GLAPI_OUTPUTS = \ + $(XORG_GLAPI_DIR)/glprocs.h \ + $(XORG_GLAPI_DIR)/glapitemp.h \ + $(XORG_GLAPI_DIR)/glapioffsets.h \ + $(XORG_GLAPI_DIR)/glapitable.h \ + $(XORG_GLAPI_DIR)/glapidispatch.h + +XORG_OUTPUTS = \ + $(XORG_GLAPI_FILES) \ + $(XORG_GLAPI_OUTPUTS) \ + $(XORG_GLX_DIR)/indirect_dispatch.c \ + $(XORG_GLX_DIR)/indirect_dispatch_swap.c \ + $(XORG_GLX_DIR)/indirect_dispatch.h \ + $(XORG_GLX_DIR)/indirect_reqsize.c \ + $(XORG_GLX_DIR)/indirect_reqsize.h \ + $(XORG_GLX_DIR)/indirect_size.h \ + $(XORG_GLX_DIR)/indirect_size_get.c \ + $(XORG_GLX_DIR)/indirect_size_get.h \ + $(XORG_GLX_DIR)/indirect_table.c + +###################################################################### + +API_XML = \ + gl_API.xml \ + ARB_copy_buffer.xml \ + ARB_depth_clamp.xml \ + ARB_draw_elements_base_vertex.xml \ + ARB_framebuffer_object.xml \ + ARB_map_buffer_range.xml \ + ARB_seamless_cube_map.xml \ + ARB_sync.xml \ + ARB_vertex_array_object.xml \ + APPLE_object_purgeable.xml \ + APPLE_vertex_array_object.xml \ + EXT_draw_buffers2.xml \ + EXT_framebuffer_object.xml \ + EXT_packed_depth_stencil.xml \ + EXT_provoking_vertex.xml \ + EXT_texture_array.xml \ + NV_conditional_render.xml \ + OES_EGL_image.xml + +COMMON = $(API_XML) gl_XML.py glX_XML.py license.py typeexpr.py + +COMMON_GLX = $(COMMON) glX_API.xml glX_XML.py glX_proto_common.py + +###################################################################### + +all: mesa xorg + +mesa: $(MESA_OUTPUTS) + +xorg: check-xorg-source $(XORG_OUTPUTS) + +check-xorg-source: + @if ! test -d $(XORG_GLX_DIR); then \ + echo "ERROR: Must specify path to xserver checkout; set XORG_BASE."; \ + exit 1; \ + fi + +clean: + -rm -f *~ *.pyo + -rm -f $(MESA_OUTPUTS) + +###################################################################### + +$(XORG_GLAPI_DIR)/%.c: $(MESA_GLAPI_DIR)/%.c + cp $< $@ + +$(XORG_GLAPI_DIR)/%.h: $(MESA_GLAPI_DIR)/%.h + cp $< $@ + +###################################################################### + +$(MESA_GLAPI_DIR)/glprocs.h: gl_procs.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapitemp.h: gl_apitemp.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapioffsets.h: gl_offsets.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapitable.h: gl_table.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_GLAPI_DIR)/glapidispatch.h: gl_table.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< -m remap_table > $@ + +###################################################################### + +$(MESA_DIR)/x86/glapi_x86.S: gl_x86_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_DIR)/x86-64/glapi_x86-64.S: gl_x86-64_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_DIR)/sparc/glapi_sparc.S: gl_SPARC_asm.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +###################################################################### + +$(MESA_DIR)/main/enums.c: gl_enums.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +$(MESA_DIR)/main/remap_helper.h: remap_helper.py $(COMMON) + $(PYTHON2) $(PYTHON_FLAGS) $< > $@ + +###################################################################### + +$(MESA_GLX_DIR)/indirect.c: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m proto | $(INDENT) $(INDENT_FLAGS) > $@ + +$(MESA_GLX_DIR)/indirect.h: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m init_h > $@ + +$(MESA_GLX_DIR)/indirect_init.c: glX_proto_send.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m init_c > $@ + +$(MESA_GLX_DIR)/indirect_size.h $(XORG_GLX_DIR)/indirect_size.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_h --only-set -h _INDIRECT_SIZE_H_ \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +$(MESA_GLX_DIR)/indirect_size.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_c --only-set \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +###################################################################### + +$(XORG_GLX_DIR)/indirect_dispatch.c: glX_proto_recv.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_c > $@ + +$(XORG_GLX_DIR)/indirect_dispatch_swap.c: glX_proto_recv.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_c -s > $@ + +$(XORG_GLX_DIR)/indirect_dispatch.h: glX_proto_recv.py gl_and_glX_API.xml $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m dispatch_h -f gl_and_glX_API.xml -s > $@ + +$(XORG_GLX_DIR)/indirect_size_get.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_h --only-get -h '_INDIRECT_SIZE_GET_H_' \ + | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_size_get.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m size_c | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_reqsize.h: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m reqsize_h --only-get -h '_INDIRECT_SIZE_GET_H_' \ + | $(INDENT) $(INDENT_FLAGS) -l200 > $@ + +$(XORG_GLX_DIR)/indirect_reqsize.c: glX_proto_size.py $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -m reqsize_c | $(INDENT) $(INDENT_FLAGS) > $@ + +$(XORG_GLX_DIR)/indirect_table.c: glX_server_table.py gl_and_glX_API.xml $(COMMON_GLX) + $(PYTHON2) $(PYTHON_FLAGS) $< -f gl_and_glX_API.xml > $@ --- mesa-7.8.2.orig/src/mesa/glapi/gen/next_available_offset.sh +++ mesa-7.8.2/src/mesa/glapi/gen/next_available_offset.sh @@ -0,0 +1,39 @@ +#!/usr/bin/env bash +# +# (C) Copyright IBM Corporation 2004 +# 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"), +# to deal in the Software without restriction, including without limitation +# on the rights to use, copy, modify, merge, publish, distribute, sub +# license, and/or sell copies of the Software, and to permit persons to whom +# the Software is furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice (including the next +# paragraph) shall be included in all copies or substantial portions of the +# Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL +# IBM AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS +# IN THE SOFTWARE. +# +# Authors: +# Ian Romanick + +# Trivial shell script to search the API definition file and print out the +# next numerically available API entry-point offset. This could probably +# be made smarter, but it would be better to use the existin Python +# framework to do that. This is just a quick-and-dirty hack. + +num=$(grep 'offset="' gl_API.xml |\ + sed 's/.\+ offset="//g;s/".*$//g' |\ + grep -v '?' |\ + sort -rn |\ + head -1) + +echo $((num + 1)) --- mesa-7.8.2.orig/debian/README.source +++ mesa-7.8.2/debian/README.source @@ -0,0 +1,39 @@ +------------------------------------------------------ +Quick Guide To Patching This Package For The Impatient +------------------------------------------------------ + +1. Make sure you have quilt installed +2. Unpack the package as usual with "dpkg-source -x" +3. Run the "patch" target in debian/rules +4. Create a new patch with "quilt new" (see quilt(1)) +5. Edit all the files you want to include in the patch with "quilt edit" + (see quilt(1)). +6. Write the patch with "quilt refresh" (see quilt(1)) +7. Run the "clean" target in debian/rules + +Alternatively, instead of using quilt directly, you can drop the patch in to +debian/patches and add the name of the patch to debian/patches/series. + + +The X Strike Force team maintains X packages in git repositories on +git.debian.org in the pkg-xorg subdirectory. Most upstream packages +are actually maintained in git repositories as well, so they often +just need to be pulled into git.debian.org in a "upstream-*" branch. + +The .orig.tar.gz upstream source file could be generated this +"upstream-*" branch in the Debian git repository but it is actually +generated from upstream tarballs directly. +Upstream ships Mesa as 3 different tarballs (MesaLib, MesaGLUT and +MesaDemos) which are re-bundled together into a single .orig.tar.gz. + +The Debian packaging is added by creating the "debian-*" git branch +which contains the aforementioned "upstream-*" branch plus the debian/ +repository files. +When a patch has to be applied to the Debian package, two solutions +are involved: +* If the patch is available in one of the upstream branches, it + may be git'cherry-picked into the Debian repository. In this + case, it appears directly in the .diff.gz. +* Otherwise, the patch is added to debian/patches/ which is managed + with quilt as documented in /usr/share/doc/quilt/README.source. + Thus, the patching system requires a build dependency on quilt. --- mesa-7.8.2.orig/debian/compat +++ mesa-7.8.2/debian/compat @@ -0,0 +1 @@ +7 --- mesa-7.8.2.orig/debian/egl.pc +++ mesa-7.8.2/debian/egl.pc @@ -0,0 +1,12 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: egl +Description: Mesa EGL library +Requires.private: libdrm >= 2.4.15 dri2proto >= 2.1 glproto >= 1.4.11 x11 xext xxf86vm xdamage xfixes +Version: 7.8.1 +Libs: -L${libdir} -lEGL +Libs.private: -lm -lpthread -ldl +Cflags: -I${includedir} --- mesa-7.8.2.orig/debian/glesv1_cm.pc +++ mesa-7.8.2/debian/glesv1_cm.pc @@ -0,0 +1,12 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv1_cm +Description: Mesa OpenGL ES 1.1 CM library +Requires.private: +Version: 7.8.1 +Libs: -L${libdir} -lGLESv1_CM +Libs.private: -lm -lpthread -ldl +Cflags: -I${includedir} --- mesa-7.8.2.orig/debian/glesv2.pc +++ mesa-7.8.2/debian/glesv2.pc @@ -0,0 +1,12 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: glesv2 +Description: Mesa OpenGL ES 2.0 library +Requires.private: +Version: 7.8.1 +Libs: -L${libdir} -lGLESv2 +Libs.private: -lm -lpthread -ldl +Cflags: -I${includedir} --- mesa-7.8.2.orig/debian/glxdemo.1 +++ mesa-7.8.2/debian/glxdemo.1 @@ -0,0 +1,15 @@ +.TH glxdemo 1 "2006-11-29" +.SH NAME +glxdemo \- a demonstration of the GLX functions +.SH SYNOPSIS +.B glxdemo +.SH DESCRIPTION +The \fIglxdemo\fP program shows how to use the GLX functions in order to +create an OpenGL program running on top of an X server. This program is most +useful when studied in its source code form. +.SH AUTHOR +glxdemo was written by Brian Paul . +.PP +This manual page was written by Thierry Reding , for the +Debian project (but may be used by others). + --- mesa-7.8.2.orig/debian/glxgears.1 +++ mesa-7.8.2/debian/glxgears.1 @@ -0,0 +1,29 @@ +.TH glxgears 1 "2006-11-29" +.SH NAME +glxgears \- ``gears'' demo for GLX +.SH SYNOPSIS +.B glxgears +.RI [ options ] +.SH DESCRIPTION +The \fIglxgears\fP program is a port of the ``gears'' demo to GLX. It displays +a set of rotating gears and prints out the frame rate at regular intervals. It +has become quite popular as basic benchmarking tool. +.SH OPTIONS +.TP 8 +.B \-display \fIdisplay\fP +Specify which X display to run on. +.TP 8 +.B \-info +Display OpenGL renderer information. +.TP 8 +.B \-stereo +Use a stereo enabled GLX visual. +.TP 8 +.B \-fullscreen +Run in fullscreen mode. +.SH AUTHOR +glxgears was written by Brian Paul . +.PP +This manual page was written by Thierry Reding , for the +Debian project (but may be used by others). + --- mesa-7.8.2.orig/debian/glxheads.1 +++ mesa-7.8.2/debian/glxheads.1 @@ -0,0 +1,30 @@ +.TH glxheads 1 "2006-11-29" +.SH NAME +glxheads \- exercise multiple GLX connections +.SH SYNOPSIS +.B glxheads +[\fIdisplay\fP ...] +.SH DESCRIPTION +The \fIglxheads\fP program will try to open GLX connections on multiple X +displays as specified on the command-line. If a connection can be made it will +try to create a direct GLX context (and fallback to using indirect contexts if +that fails) and open a window displaying a spinning green triangle. +.PP +If no display names are specified, \fIglxheads\fP will default to opening a +single local connection on display 0. +.SH EXAMPLE +To open a local connection on display 0 and two remote connections to the +hosts \fImars\fP (display 0) and \fIvenus\fP (display 1), run glxheads with +the following command-line: +.PP +.RS 3n +.nf +$ glxheads :0 mars:0 venus:1 +.fi +.RE +.SH AUTHOR +glxheads was written by Brian Paul . +.PP +This manual page was written by Thierry Reding for the +Debian project (but may be used by others). + --- mesa-7.8.2.orig/debian/glxinfo.1 +++ mesa-7.8.2/debian/glxinfo.1 @@ -0,0 +1,41 @@ +.TH glxinfo 1 "2006-11-29" +.SH NAME +glxinfo \- show information about the GLX implementation +.SH SYNOPSIS +.B glxinfo +.RI [ options ] +.SH DESCRIPTION +The \fIglxinfo\fP program shows information about the OpenGL and GLX +implementations running on a given X display. +.PP +The information includes details about the server- and client-side GLX +implementation, the OpenGL and GLU implementations as well as a list +of available GLX visuals. +.SH OPTIONS +.TP 8 +.B \-v +Print visuals info in verbose form. +.TP 8 +.B \-t +Print verbose table. +.TP 8 +.B \-display \fIdisplay\fP +Specify the X display to interrogate. +.TP 8 +.B \-h +Print usage information. +.TP 8 +.B \-i +Force an indirect rendering context. +.TP 8 +.B \-b +Find the "best" visual and print its number. +.TP 8 +.B \-l +Print interesting OpenGL limits. +.SH AUTHOR +glxinfo was written by Brian Paul . +.PP +This manual page was written by Thierry Reding , for the +Debian project (but may be used by others). + --- mesa-7.8.2.orig/debian/libegl1-mesa-dev.install +++ mesa-7.8.2/debian/libegl1-mesa-dev.install @@ -0,0 +1,4 @@ +dri/usr/lib/libEGL.so usr/lib +dri/usr/include/EGL usr/include +dri/usr/include/KHR usr/include +debian/egl.pc usr/lib/pkgconfig --- mesa-7.8.2.orig/debian/libegl1-mesa-drivers-kms.install +++ mesa-7.8.2/debian/libegl1-mesa-drivers-kms.install @@ -0,0 +1 @@ +dri/usr/lib/egl/egl_kms_*.so usr/lib/egl --- mesa-7.8.2.orig/debian/libegl1-mesa-drivers-x11.install +++ mesa-7.8.2/debian/libegl1-mesa-drivers-x11.install @@ -0,0 +1 @@ +dri/usr/lib/egl/egl_x11_*.so usr/lib/egl --- mesa-7.8.2.orig/debian/libegl1-mesa.install +++ mesa-7.8.2/debian/libegl1-mesa.install @@ -0,0 +1,3 @@ +dri/usr/lib/libEGL.so.1* usr/lib +dri/usr/lib/egl/egl_dri2.so usr/lib/egl +dri/usr/lib/egl/egl_glx.so usr/lib/egl --- mesa-7.8.2.orig/debian/libegl1-mesa.lintian-overrides +++ mesa-7.8.2/debian/libegl1-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libEGL1 --- mesa-7.8.2.orig/debian/libegl1-mesa.symbols +++ mesa-7.8.2/debian/libegl1-mesa.symbols @@ -0,0 +1,79 @@ +libEGL.so.1 libegl1-mesa #MINVER# + _eglAddConfig@Base 7.8.1 + _eglAddNewMode@Base 7.8.1 + _eglAddScreen@Base 7.8.1 + _eglBindContext@Base 7.8.1 + _eglCheckResource@Base 7.8.1 + _eglCleanupDisplay@Base 7.8.1 + _eglCompareConfigs@Base 7.8.1 + _eglConfigFromContextModesRec@Base 7.8.1 + _eglConfigToContextModesRec@Base 7.8.1 + _eglDestroyScreen@Base 7.8.1 + _eglError@Base 7.8.1 + _eglGetAPIContext@Base 7.8.1 + _eglGetCurrentContext@Base 7.8.1 + _eglGetCurrentThread@Base 7.8.1 + _eglGetProbeCache@Base 7.8.1 + _eglInitConfig@Base 7.8.1 + _eglInitContext@Base 7.8.1 + _eglInitDriverFallbacks@Base 7.8.1 + _eglInitImage@Base 7.8.1 + _eglInitScreen@Base 7.8.1 + _eglInitSurface@Base 7.8.1 + _eglLog@Base 7.8.1 + _eglMatchConfig@Base 7.8.1 + _eglParseConfigAttribList@Base 7.8.1 + _eglReleaseDisplayResources@Base 7.8.1 + _eglSetLogLevel@Base 7.8.1 + _eglSetLogProc@Base 7.8.1 + _eglSetProbeCache@Base 7.8.1 + _eglSortConfigs@Base 7.8.1 + _eglValidateConfig@Base 7.8.1 + eglBindAPI@Base 7.8.1 + eglBindTexImage@Base 7.8.1 + eglChooseConfig@Base 7.8.1 + eglChooseModeMESA@Base 7.8.1 + eglCopyBuffers@Base 7.8.1 + eglCopyContextMESA@Base 7.8.1 + eglCreateContext@Base 7.8.1 + eglCreateImageKHR@Base 7.8.1 + eglCreatePbufferFromClientBuffer@Base 7.8.1 + eglCreatePbufferSurface@Base 7.8.1 + eglCreatePixmapSurface@Base 7.8.1 + eglCreateScreenSurfaceMESA@Base 7.8.1 + eglCreateWindowSurface@Base 7.8.1 + eglDestroyContext@Base 7.8.1 + eglDestroyImageKHR@Base 7.8.1 + eglDestroySurface@Base 7.8.1 + eglGetConfigAttrib@Base 7.8.1 + eglGetConfigs@Base 7.8.1 + eglGetCurrentContext@Base 7.8.1 + eglGetCurrentDisplay@Base 7.8.1 + eglGetCurrentSurface@Base 7.8.1 + eglGetDisplay@Base 7.8.1 + eglGetError@Base 7.8.1 + eglGetModeAttribMESA@Base 7.8.1 + eglGetModesMESA@Base 7.8.1 + eglGetProcAddress@Base 7.8.1 + eglGetScreensMESA@Base 7.8.1 + eglInitialize@Base 7.8.1 + eglMakeCurrent@Base 7.8.1 + eglQueryAPI@Base 7.8.1 + eglQueryContext@Base 7.8.1 + eglQueryModeStringMESA@Base 7.8.1 + eglQueryScreenMESA@Base 7.8.1 + eglQueryScreenModeMESA@Base 7.8.1 + eglQueryScreenSurfaceMESA@Base 7.8.1 + eglQueryString@Base 7.8.1 + eglQuerySurface@Base 7.8.1 + eglReleaseTexImage@Base 7.8.1 + eglReleaseThread@Base 7.8.1 + eglScreenPositionMESA@Base 7.8.1 + eglShowScreenSurfaceMESA@Base 7.8.1 + eglSurfaceAttrib@Base 7.8.1 + eglSwapBuffers@Base 7.8.1 + eglSwapInterval@Base 7.8.1 + eglTerminate@Base 7.8.1 + eglWaitClient@Base 7.8.1 + eglWaitGL@Base 7.8.1 + eglWaitNative@Base 7.8.1 --- mesa-7.8.2.orig/debian/libgl1-mesa-dri-experimental.install +++ mesa-7.8.2/debian/libgl1-mesa-dri-experimental.install @@ -0,0 +1 @@ +build/dri/lib/gallium/nouveau_dri.so usr/lib/dri --- mesa-7.8.2.orig/debian/libgl1-mesa-dri-i686.install +++ mesa-7.8.2/debian/libgl1-mesa-dri-i686.install @@ -0,0 +1 @@ +dri/usr/lib/dri/i686/cmov/*.so --- mesa-7.8.2.orig/debian/libgl1-mesa-dri.install +++ mesa-7.8.2/debian/libgl1-mesa-dri.install @@ -0,0 +1 @@ +build/dri/lib/*_dri.so usr/lib/dri/ --- mesa-7.8.2.orig/debian/libgl1-mesa-glx-i686.install +++ mesa-7.8.2/debian/libgl1-mesa-glx-i686.install @@ -0,0 +1 @@ +dri/usr/lib/i686/cmov/libGL.so.* usr/lib/i686/cmov --- mesa-7.8.2.orig/debian/libgl1-mesa-glx.lintian-overrides +++ mesa-7.8.2/debian/libgl1-mesa-glx.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGL1 --- mesa-7.8.2.orig/debian/libgl1-mesa-glx.shlibs +++ mesa-7.8.2/debian/libgl1-mesa-glx.shlibs @@ -0,0 +1 @@ +libGL 1 libgl1-mesa-glx | libgl1 --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11-i686.install +++ mesa-7.8.2/debian/libgl1-mesa-swx11-i686.install @@ -0,0 +1 @@ +usr/lib/i686/cmov/libGL.so.* --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11-i686.shlibs +++ mesa-7.8.2/debian/libgl1-mesa-swx11-i686.shlibs @@ -0,0 +1 @@ +libGL 1 libgl1-mesa-glx | libgl1 --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11.lintian-overrides +++ mesa-7.8.2/debian/libgl1-mesa-swx11.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGL1 --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11.shlibs +++ mesa-7.8.2/debian/libgl1-mesa-swx11.shlibs @@ -0,0 +1 @@ +libGL 1 libgl1-mesa-glx | libgl1 --- mesa-7.8.2.orig/debian/libgles1-mesa-dev.install +++ mesa-7.8.2/debian/libgles1-mesa-dev.install @@ -0,0 +1,3 @@ +dri/usr/lib/libGLESv1_CM.so usr/lib +dri/usr/include/GLES usr/include +debian/glesv1_cm.pc usr/lib/pkgconfig --- mesa-7.8.2.orig/debian/libgles1-mesa.install +++ mesa-7.8.2/debian/libgles1-mesa.install @@ -0,0 +1 @@ +dri/usr/lib/libGLESv1_CM.so.1* usr/lib --- mesa-7.8.2.orig/debian/libgles1-mesa.lintian-overrides +++ mesa-7.8.2/debian/libgles1-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGLESv1-CM1 --- mesa-7.8.2.orig/debian/libgles1-mesa.symbols +++ mesa-7.8.2/debian/libgles1-mesa.symbols @@ -0,0 +1,265 @@ +libGLESv1_CM.so.1 libgles1-mesa #MINVER# +# _glapi_* are internal GL dispatch symbols. They should probably be hidden + (regex)"^_glapi_.*@Base$" 7.8.1 +# These are optimised assembly versions of functions, accessed through a +# dispatch table. They're arch-specific, and should probably be hidden. + (regex|optional=mesa internal ASM optimized functions)"^_mesa_.*@Base$" 7.8.1 + _glthread_GetID@Base 7.8.1 + glActiveTexture@Base 7.8.1 + glAlphaFunc@Base 7.8.1 + glAlphaFuncx@Base 7.8.1 + glAlphaFuncxOES@Base 7.8.1 + glBindBuffer@Base 7.8.1 + glBindFramebufferOES@Base 7.8.1 + glBindRenderbufferOES@Base 7.8.1 + glBindTexture@Base 7.8.1 + glBlendEquationOES@Base 7.8.1 + glBlendEquationSeparateOES@Base 7.8.1 + glBlendFunc@Base 7.8.1 + glBlendFuncSeparateOES@Base 7.8.1 + glBufferData@Base 7.8.1 + glBufferSubData@Base 7.8.1 + glCheckFramebufferStatusOES@Base 7.8.1 + glClear@Base 7.8.1 + glClearColor@Base 7.8.1 + glClearColorx@Base 7.8.1 + glClearColorxOES@Base 7.8.1 + glClearDepthf@Base 7.8.1 + glClearDepthfOES@Base 7.8.1 + glClearDepthx@Base 7.8.1 + glClearDepthxOES@Base 7.8.1 + glClearStencil@Base 7.8.1 + glClientActiveTexture@Base 7.8.1 + glClipPlanef@Base 7.8.1 + glClipPlanefOES@Base 7.8.1 + glClipPlanex@Base 7.8.1 + glClipPlanexOES@Base 7.8.1 + glColor4f@Base 7.8.1 + glColor4ub@Base 7.8.1 + glColor4x@Base 7.8.1 + glColor4xOES@Base 7.8.1 + glColorMask@Base 7.8.1 + glColorPointer@Base 7.8.1 + glCompressedTexImage2D@Base 7.8.1 + glCompressedTexSubImage2D@Base 7.8.1 + glCopyTexImage2D@Base 7.8.1 + glCopyTexSubImage2D@Base 7.8.1 + glCullFace@Base 7.8.1 + glDeleteBuffers@Base 7.8.1 + glDeleteFramebuffersOES@Base 7.8.1 + glDeleteRenderbuffersOES@Base 7.8.1 + glDeleteTextures@Base 7.8.1 + glDepthFunc@Base 7.8.1 + glDepthMask@Base 7.8.1 + glDepthRangef@Base 7.8.1 + glDepthRangefOES@Base 7.8.1 + glDepthRangex@Base 7.8.1 + glDepthRangexOES@Base 7.8.1 + glDisable@Base 7.8.1 + glDisableClientState@Base 7.8.1 + glDrawArrays@Base 7.8.1 + glDrawElements@Base 7.8.1 + glDrawTexfOES@Base 7.8.1 + glDrawTexfvOES@Base 7.8.1 + glDrawTexiOES@Base 7.8.1 + glDrawTexivOES@Base 7.8.1 + glDrawTexsOES@Base 7.8.1 + glDrawTexsvOES@Base 7.8.1 + glDrawTexxOES@Base 7.8.1 + glDrawTexxvOES@Base 7.8.1 + glEGLImageTargetRenderbufferStorageOES@Base 7.8.1 + glEGLImageTargetTexture2DOES@Base 7.8.1 + glEnable@Base 7.8.1 + glEnableClientState@Base 7.8.1 + glFinish@Base 7.8.1 + glFlush@Base 7.8.1 + glFogf@Base 7.8.1 + glFogfv@Base 7.8.1 + glFogx@Base 7.8.1 + glFogxOES@Base 7.8.1 + glFogxv@Base 7.8.1 + glFogxvOES@Base 7.8.1 + glFramebufferRenderbufferOES@Base 7.8.1 + glFramebufferTexture2DOES@Base 7.8.1 + glFrontFace@Base 7.8.1 + glFrustumf@Base 7.8.1 + glFrustumfOES@Base 7.8.1 + glFrustumx@Base 7.8.1 + glFrustumxOES@Base 7.8.1 + glGenBuffers@Base 7.8.1 + glGenFramebuffersOES@Base 7.8.1 + glGenRenderbuffersOES@Base 7.8.1 + glGenTextures@Base 7.8.1 + glGenerateMipmapOES@Base 7.8.1 + glGetBooleanv@Base 7.8.1 + glGetBufferParameteriv@Base 7.8.1 + glGetBufferPointervOES@Base 7.8.1 + glGetClipPlanef@Base 7.8.1 + glGetClipPlanefOES@Base 7.8.1 + glGetClipPlanex@Base 7.8.1 + glGetClipPlanexOES@Base 7.8.1 + glGetError@Base 7.8.1 + glGetFixedv@Base 7.8.1 + glGetFixedvOES@Base 7.8.1 + glGetFloatv@Base 7.8.1 + glGetFramebufferAttachmentParameterivOES@Base 7.8.1 + glGetIntegerv@Base 7.8.1 + glGetLightfv@Base 7.8.1 + glGetLightxv@Base 7.8.1 + glGetLightxvOES@Base 7.8.1 + glGetMaterialfv@Base 7.8.1 + glGetMaterialxv@Base 7.8.1 + glGetMaterialxvOES@Base 7.8.1 + glGetPointerv@Base 7.8.1 + glGetRenderbufferParameterivOES@Base 7.8.1 + glGetString@Base 7.8.1 + glGetTexEnvfv@Base 7.8.1 + glGetTexEnviv@Base 7.8.1 + glGetTexEnvxv@Base 7.8.1 + glGetTexEnvxvOES@Base 7.8.1 + glGetTexGenfvOES@Base 7.8.1 + glGetTexGenivOES@Base 7.8.1 + glGetTexGenxvOES@Base 7.8.1 + glGetTexParameterfv@Base 7.8.1 + glGetTexParameteriv@Base 7.8.1 + glGetTexParameterxv@Base 7.8.1 + glGetTexParameterxvOES@Base 7.8.1 + glHint@Base 7.8.1 + glIsBuffer@Base 7.8.1 + glIsEnabled@Base 7.8.1 + glIsFramebufferOES@Base 7.8.1 + glIsRenderbufferOES@Base 7.8.1 + glIsTexture@Base 7.8.1 + glLightModelf@Base 7.8.1 + glLightModelfv@Base 7.8.1 + glLightModelx@Base 7.8.1 + glLightModelxOES@Base 7.8.1 + glLightModelxv@Base 7.8.1 + glLightModelxvOES@Base 7.8.1 + glLightf@Base 7.8.1 + glLightfv@Base 7.8.1 + glLightx@Base 7.8.1 + glLightxOES@Base 7.8.1 + glLightxv@Base 7.8.1 + glLightxvOES@Base 7.8.1 + glLineWidth@Base 7.8.1 + glLineWidthx@Base 7.8.1 + glLineWidthxOES@Base 7.8.1 + glLoadIdentity@Base 7.8.1 + glLoadMatrixf@Base 7.8.1 + glLoadMatrixx@Base 7.8.1 + glLoadMatrixxOES@Base 7.8.1 + glLogicOp@Base 7.8.1 + glMapBufferOES@Base 7.8.1 + glMaterialf@Base 7.8.1 + glMaterialfv@Base 7.8.1 + glMaterialx@Base 7.8.1 + glMaterialxOES@Base 7.8.1 + glMaterialxv@Base 7.8.1 + glMaterialxvOES@Base 7.8.1 + glMatrixMode@Base 7.8.1 + glMultMatrixf@Base 7.8.1 + glMultMatrixx@Base 7.8.1 + glMultMatrixxOES@Base 7.8.1 + glMultiDrawArraysEXT@Base 7.8.1 + glMultiDrawElementsEXT@Base 7.8.1 + glMultiTexCoord4f@Base 7.8.1 + glMultiTexCoord4x@Base 7.8.1 + glMultiTexCoord4xOES@Base 7.8.1 + glNormal3f@Base 7.8.1 + glNormal3x@Base 7.8.1 + glNormal3xOES@Base 7.8.1 + glNormalPointer@Base 7.8.1 + glOrthof@Base 7.8.1 + glOrthofOES@Base 7.8.1 + glOrthox@Base 7.8.1 + glOrthoxOES@Base 7.8.1 + glPixelStorei@Base 7.8.1 + glPointParameterf@Base 7.8.1 + glPointParameterfv@Base 7.8.1 + glPointParameterx@Base 7.8.1 + glPointParameterxOES@Base 7.8.1 + glPointParameterxv@Base 7.8.1 + glPointParameterxvOES@Base 7.8.1 + glPointSize@Base 7.8.1 + glPointSizePointerOES@Base 7.8.1 + glPointSizex@Base 7.8.1 + glPointSizexOES@Base 7.8.1 + glPolygonOffset@Base 7.8.1 + glPolygonOffsetx@Base 7.8.1 + glPolygonOffsetxOES@Base 7.8.1 + glPopMatrix@Base 7.8.1 + glPushMatrix@Base 7.8.1 + glQueryMatrixxOES@Base 7.8.1 + glReadPixels@Base 7.8.1 + glRenderbufferStorageOES@Base 7.8.1 + glRotatef@Base 7.8.1 + glRotatex@Base 7.8.1 + glRotatexOES@Base 7.8.1 + glSampleCoverage@Base 7.8.1 + glSampleCoveragex@Base 7.8.1 + glSampleCoveragexOES@Base 7.8.1 + glScalef@Base 7.8.1 + glScalex@Base 7.8.1 + glScalexOES@Base 7.8.1 + glScissor@Base 7.8.1 + glShadeModel@Base 7.8.1 + glStencilFunc@Base 7.8.1 + glStencilMask@Base 7.8.1 + glStencilOp@Base 7.8.1 + glTexCoordPointer@Base 7.8.1 + glTexEnvf@Base 7.8.1 + glTexEnvfv@Base 7.8.1 + glTexEnvi@Base 7.8.1 + glTexEnviv@Base 7.8.1 + glTexEnvx@Base 7.8.1 + glTexEnvxOES@Base 7.8.1 + glTexEnvxv@Base 7.8.1 + glTexEnvxvOES@Base 7.8.1 + glTexGenfOES@Base 7.8.1 + glTexGenfvOES@Base 7.8.1 + glTexGeniOES@Base 7.8.1 + glTexGenivOES@Base 7.8.1 + glTexGenxOES@Base 7.8.1 + glTexGenxvOES@Base 7.8.1 + glTexImage2D@Base 7.8.1 + glTexParameterf@Base 7.8.1 + glTexParameterfv@Base 7.8.1 + glTexParameteri@Base 7.8.1 + glTexParameteriv@Base 7.8.1 + glTexParameterx@Base 7.8.1 + glTexParameterxOES@Base 7.8.1 + glTexParameterxv@Base 7.8.1 + glTexParameterxvOES@Base 7.8.1 + glTexSubImage2D@Base 7.8.1 + glTranslatef@Base 7.8.1 + glTranslatex@Base 7.8.1 + glTranslatexOES@Base 7.8.1 + glUnmapBufferOES@Base 7.8.1 + glVertexPointer@Base 7.8.1 + glViewport@Base 7.8.1 +# These are internal gallium statetracker symbols. +# They should probably be hidden + st_api_OpenGL_ES1@Base 7.8.1 + st_bind_teximage@Base 7.8.1 + st_bind_texture_surface@Base 7.8.1 + st_copy_context_state@Base 7.8.1 + st_create_context@Base 7.8.1 + st_create_framebuffer@Base 7.8.1 + st_destroy_context@Base 7.8.1 + st_finish@Base 7.8.1 + st_flush@Base 7.8.1 + st_framebuffer_private@Base 7.8.1 + st_get_current@Base 7.8.1 + st_get_framebuffer_dimensions@Base 7.8.1 + st_get_framebuffer_surface@Base 7.8.1 + st_get_framebuffer_texture@Base 7.8.1 + st_get_proc_address@Base 7.8.1 + st_make_current@Base 7.8.1 + st_notify_swapbuffers@Base 7.8.1 + st_release_teximage@Base 7.8.1 + st_resize_framebuffer@Base 7.8.1 + st_set_framebuffer_surface@Base 7.8.1 + st_swapbuffers@Base 7.8.1 + st_unbind_texture_surface@Base 7.8.1 + st_unreference_framebuffer@Base 7.8.1 --- mesa-7.8.2.orig/debian/libgles2-mesa-dev.install +++ mesa-7.8.2/debian/libgles2-mesa-dev.install @@ -0,0 +1,3 @@ +dri/usr/lib/libGLESv2.so usr/lib +dri/usr/include/GLES2 usr/include +debian/glesv2.pc usr/lib/pkgconfig --- mesa-7.8.2.orig/debian/libgles2-mesa.install +++ mesa-7.8.2/debian/libgles2-mesa.install @@ -0,0 +1 @@ +dri/usr/lib/libGLESv2.so.2* usr/lib --- mesa-7.8.2.orig/debian/libgles2-mesa.lintian-overrides +++ mesa-7.8.2/debian/libgles2-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGLESv2-2 --- mesa-7.8.2.orig/debian/libgles2-mesa.symbols +++ mesa-7.8.2/debian/libgles2-mesa.symbols @@ -0,0 +1,189 @@ +libGLESv2.so.2 libgles2-mesa #MINVER# +# _glapi_* are internal GL dispatch symbols. They should probably be hidden. + (regex)"^_glapi_.*@Base$" 7.8.1 +# These are optimised assembly versions of functions, accessed through a +# dispatch table. They're arch-specific, and should probably be hidden. + (regex|optional=mesa internal ASM optimized functions)"^_mesa_.*@Base$" 7.8.1 + _glthread_GetID@Base 7.8.1 + glActiveTexture@Base 7.8.1 + glAttachShader@Base 7.8.1 + glBindAttribLocation@Base 7.8.1 + glBindBuffer@Base 7.8.1 + glBindFramebuffer@Base 7.8.1 + glBindRenderbuffer@Base 7.8.1 + glBindTexture@Base 7.8.1 + glBlendColor@Base 7.8.1 + glBlendEquation@Base 7.8.1 + glBlendEquationSeparate@Base 7.8.1 + glBlendFunc@Base 7.8.1 + glBlendFuncSeparate@Base 7.8.1 + glBufferData@Base 7.8.1 + glBufferSubData@Base 7.8.1 + glCheckFramebufferStatus@Base 7.8.1 + glClear@Base 7.8.1 + glClearColor@Base 7.8.1 + glClearDepthf@Base 7.8.1 + glClearStencil@Base 7.8.1 + glColorMask@Base 7.8.1 + glCompileShader@Base 7.8.1 + glCompressedTexImage2D@Base 7.8.1 + glCompressedTexImage3DOES@Base 7.8.1 + glCompressedTexSubImage2D@Base 7.8.1 + glCompressedTexSubImage3DOES@Base 7.8.1 + glCopyTexImage2D@Base 7.8.1 + glCopyTexSubImage2D@Base 7.8.1 + glCopyTexSubImage3DOES@Base 7.8.1 + glCreateProgram@Base 7.8.1 + glCreateShader@Base 7.8.1 + glCullFace@Base 7.8.1 + glDeleteBuffers@Base 7.8.1 + glDeleteFramebuffers@Base 7.8.1 + glDeleteProgram@Base 7.8.1 + glDeleteRenderbuffers@Base 7.8.1 + glDeleteShader@Base 7.8.1 + glDeleteTextures@Base 7.8.1 + glDepthFunc@Base 7.8.1 + glDepthMask@Base 7.8.1 + glDepthRangef@Base 7.8.1 + glDetachShader@Base 7.8.1 + glDisable@Base 7.8.1 + glDisableVertexAttribArray@Base 7.8.1 + glDrawArrays@Base 7.8.1 + glDrawElements@Base 7.8.1 + glEGLImageTargetRenderbufferStorageOES@Base 7.8.1 + glEGLImageTargetTexture2DOES@Base 7.8.1 + glEnable@Base 7.8.1 + glEnableVertexAttribArray@Base 7.8.1 + glFinish@Base 7.8.1 + glFlush@Base 7.8.1 + glFramebufferRenderbuffer@Base 7.8.1 + glFramebufferTexture2D@Base 7.8.1 + glFramebufferTexture3DOES@Base 7.8.1 + glFrontFace@Base 7.8.1 + glGenBuffers@Base 7.8.1 + glGenFramebuffers@Base 7.8.1 + glGenRenderbuffers@Base 7.8.1 + glGenTextures@Base 7.8.1 + glGenerateMipmap@Base 7.8.1 + glGetActiveAttrib@Base 7.8.1 + glGetActiveUniform@Base 7.8.1 + glGetAttachedShaders@Base 7.8.1 + glGetAttribLocation@Base 7.8.1 + glGetBooleanv@Base 7.8.1 + glGetBufferParameteriv@Base 7.8.1 + glGetBufferPointervOES@Base 7.8.1 + glGetError@Base 7.8.1 + glGetFloatv@Base 7.8.1 + glGetFramebufferAttachmentParameteriv@Base 7.8.1 + glGetIntegerv@Base 7.8.1 + glGetProgramBinaryOES@Base 7.8.1 + glGetProgramInfoLog@Base 7.8.1 + glGetProgramiv@Base 7.8.1 + glGetRenderbufferParameteriv@Base 7.8.1 + glGetShaderInfoLog@Base 7.8.1 + glGetShaderPrecisionFormat@Base 7.8.1 + glGetShaderSource@Base 7.8.1 + glGetShaderiv@Base 7.8.1 + glGetString@Base 7.8.1 + glGetTexParameterfv@Base 7.8.1 + glGetTexParameteriv@Base 7.8.1 + glGetUniformLocation@Base 7.8.1 + glGetUniformfv@Base 7.8.1 + glGetUniformiv@Base 7.8.1 + glGetVertexAttribPointerv@Base 7.8.1 + glGetVertexAttribfv@Base 7.8.1 + glGetVertexAttribiv@Base 7.8.1 + glHint@Base 7.8.1 + glIsBuffer@Base 7.8.1 + glIsEnabled@Base 7.8.1 + glIsFramebuffer@Base 7.8.1 + glIsProgram@Base 7.8.1 + glIsRenderbuffer@Base 7.8.1 + glIsShader@Base 7.8.1 + glIsTexture@Base 7.8.1 + glLineWidth@Base 7.8.1 + glLinkProgram@Base 7.8.1 + glMapBufferOES@Base 7.8.1 + glMultiDrawArraysEXT@Base 7.8.1 + glMultiDrawElementsEXT@Base 7.8.1 + glPixelStorei@Base 7.8.1 + glPolygonOffset@Base 7.8.1 + glProgramBinaryOES@Base 7.8.1 + glReadPixels@Base 7.8.1 + glReleaseShaderCompiler@Base 7.8.1 + glRenderbufferStorage@Base 7.8.1 + glSampleCoverage@Base 7.8.1 + glScissor@Base 7.8.1 + glShaderBinary@Base 7.8.1 + glShaderSource@Base 7.8.1 + glStencilFunc@Base 7.8.1 + glStencilFuncSeparate@Base 7.8.1 + glStencilMask@Base 7.8.1 + glStencilMaskSeparate@Base 7.8.1 + glStencilOp@Base 7.8.1 + glStencilOpSeparate@Base 7.8.1 + glTexImage2D@Base 7.8.1 + glTexImage3DOES@Base 7.8.1 + glTexParameterf@Base 7.8.1 + glTexParameterfv@Base 7.8.1 + glTexParameteri@Base 7.8.1 + glTexParameteriv@Base 7.8.1 + glTexSubImage2D@Base 7.8.1 + glTexSubImage3DOES@Base 7.8.1 + glUniform1f@Base 7.8.1 + glUniform1fv@Base 7.8.1 + glUniform1i@Base 7.8.1 + glUniform1iv@Base 7.8.1 + glUniform2f@Base 7.8.1 + glUniform2fv@Base 7.8.1 + glUniform2i@Base 7.8.1 + glUniform2iv@Base 7.8.1 + glUniform3f@Base 7.8.1 + glUniform3fv@Base 7.8.1 + glUniform3i@Base 7.8.1 + glUniform3iv@Base 7.8.1 + glUniform4f@Base 7.8.1 + glUniform4fv@Base 7.8.1 + glUniform4i@Base 7.8.1 + glUniform4iv@Base 7.8.1 + glUniformMatrix2fv@Base 7.8.1 + glUniformMatrix3fv@Base 7.8.1 + glUniformMatrix4fv@Base 7.8.1 + glUnmapBufferOES@Base 7.8.1 + glUseProgram@Base 7.8.1 + glValidateProgram@Base 7.8.1 + glVertexAttrib1f@Base 7.8.1 + glVertexAttrib1fv@Base 7.8.1 + glVertexAttrib2f@Base 7.8.1 + glVertexAttrib2fv@Base 7.8.1 + glVertexAttrib3f@Base 7.8.1 + glVertexAttrib3fv@Base 7.8.1 + glVertexAttrib4f@Base 7.8.1 + glVertexAttrib4fv@Base 7.8.1 + glVertexAttribPointer@Base 7.8.1 + glViewport@Base 7.8.1 +# These are internal gallium statetracker symbols. +# They should probably be hidden + st_api_OpenGL_ES2@Base 7.8.1 + st_bind_teximage@Base 7.8.1 + st_bind_texture_surface@Base 7.8.1 + st_copy_context_state@Base 7.8.1 + st_create_context@Base 7.8.1 + st_create_framebuffer@Base 7.8.1 + st_destroy_context@Base 7.8.1 + st_finish@Base 7.8.1 + st_flush@Base 7.8.1 + st_framebuffer_private@Base 7.8.1 + st_get_current@Base 7.8.1 + st_get_framebuffer_dimensions@Base 7.8.1 + st_get_framebuffer_surface@Base 7.8.1 + st_get_framebuffer_texture@Base 7.8.1 + st_get_proc_address@Base 7.8.1 + st_make_current@Base 7.8.1 + st_notify_swapbuffers@Base 7.8.1 + st_release_teximage@Base 7.8.1 + st_resize_framebuffer@Base 7.8.1 + st_set_framebuffer_surface@Base 7.8.1 + st_swapbuffers@Base 7.8.1 + st_unbind_texture_surface@Base 7.8.1 + st_unreference_framebuffer@Base 7.8.1 --- mesa-7.8.2.orig/debian/libglu1-mesa-dev.install +++ mesa-7.8.2/debian/libglu1-mesa-dev.install @@ -0,0 +1,5 @@ +usr/include/GL/glu.h +usr/include/GL/glu_mangle.h +usr/lib/libGLU.a +usr/lib/libGLU.so +usr/lib/pkgconfig/glu.pc --- mesa-7.8.2.orig/debian/libglu1-mesa.install +++ mesa-7.8.2/debian/libglu1-mesa.install @@ -0,0 +1 @@ +usr/lib/libGLU.so.* --- mesa-7.8.2.orig/debian/libglu1-mesa.lintian-overrides +++ mesa-7.8.2/debian/libglu1-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGLU1 --- mesa-7.8.2.orig/debian/libglu1-mesa.shlibs +++ mesa-7.8.2/debian/libglu1-mesa.shlibs @@ -0,0 +1 @@ +libGLU 1 libglu1-mesa | libglu1 --- mesa-7.8.2.orig/debian/libglw1-mesa-dev.install +++ mesa-7.8.2/debian/libglw1-mesa-dev.install @@ -0,0 +1,4 @@ +usr/include/GL/GLw*A.h +usr/lib/libGLw.a +usr/lib/libGLw.so +usr/lib/pkgconfig/glw.pc --- mesa-7.8.2.orig/debian/libglw1-mesa.install +++ mesa-7.8.2/debian/libglw1-mesa.install @@ -0,0 +1 @@ +usr/lib/libGLw.so.* --- mesa-7.8.2.orig/debian/libglw1-mesa.lintian-overrides +++ mesa-7.8.2/debian/libglw1-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libGLw1 --- mesa-7.8.2.orig/debian/libglw1-mesa.shlibs +++ mesa-7.8.2/debian/libglw1-mesa.shlibs @@ -0,0 +1 @@ +libGLw 1 libglw1-mesa | libglw1 --- mesa-7.8.2.orig/debian/libopenvg1-mesa-dev.install +++ mesa-7.8.2/debian/libopenvg1-mesa-dev.install @@ -0,0 +1,3 @@ +dri/usr/lib/libOpenVG.so usr/lib +dri/usr/include/VG usr/include +debian/vg.pc usr/lib/pkgconfig --- mesa-7.8.2.orig/debian/libopenvg1-mesa.install +++ mesa-7.8.2/debian/libopenvg1-mesa.install @@ -0,0 +1 @@ +dri/usr/lib/libOpenVG.so.1* usr/lib --- mesa-7.8.2.orig/debian/libopenvg1-mesa.lintian-overrides +++ mesa-7.8.2/debian/libopenvg1-mesa.lintian-overrides @@ -0,0 +1 @@ +package-name-doesnt-match-sonames libOpenVG1 --- mesa-7.8.2.orig/debian/libopenvg1-mesa.symbols +++ mesa-7.8.2/debian/libopenvg1-mesa.symbols @@ -0,0 +1,106 @@ +libOpenVG.so.1 libopenvg1-mesa #MINVER# + st_api_OpenVG@Base 7.8.1 + st_bind_texture_surface@Base 7.8.1 + st_copy_context_state@Base 7.8.1 + st_create_context@Base 7.8.1 + st_create_framebuffer@Base 7.8.1 + st_destroy_context@Base 7.8.1 + st_finish@Base 7.8.1 + st_flush@Base 7.8.1 + st_framebuffer_private@Base 7.8.1 + st_get_current@Base 7.8.1 + st_get_framebuffer_dimensions@Base 7.8.1 + st_get_framebuffer_surface@Base 7.8.1 + st_get_framebuffer_texture@Base 7.8.1 + st_get_proc_address@Base 7.8.1 + st_make_current@Base 7.8.1 + st_notify_swapbuffers@Base 7.8.1 + st_notify_swapbuffers_complete@Base 7.8.1 + st_resize_framebuffer@Base 7.8.1 + st_set_framebuffer_surface@Base 7.8.1 + st_unbind_texture_surface@Base 7.8.1 + st_unreference_framebuffer@Base 7.8.1 + vgAppendPath@Base 7.8.1 + vgAppendPathData@Base 7.8.1 + vgChildImage@Base 7.8.1 + vgClear@Base 7.8.1 + vgClearImage@Base 7.8.1 + vgClearPath@Base 7.8.1 + vgColorMatrix@Base 7.8.1 + vgConvolve@Base 7.8.1 + vgCopyImage@Base 7.8.1 + vgCopyPixels@Base 7.8.1 + vgCreateImage@Base 7.8.1 + vgCreatePaint@Base 7.8.1 + vgCreatePath@Base 7.8.1 + vgDestroyImage@Base 7.8.1 + vgDestroyPaint@Base 7.8.1 + vgDestroyPath@Base 7.8.1 + vgDrawImage@Base 7.8.1 + vgDrawPath@Base 7.8.1 + vgFinish@Base 7.8.1 + vgFlush@Base 7.8.1 + vgGaussianBlur@Base 7.8.1 + vgGetColor@Base 7.8.1 + vgGetError@Base 7.8.1 + vgGetImageSubData@Base 7.8.1 + vgGetMatrix@Base 7.8.1 + vgGetPaint@Base 7.8.1 + vgGetParameterVectorSize@Base 7.8.1 + vgGetParameterf@Base 7.8.1 + vgGetParameterfv@Base 7.8.1 + vgGetParameteri@Base 7.8.1 + vgGetParameteriv@Base 7.8.1 + vgGetParent@Base 7.8.1 + vgGetPathCapabilities@Base 7.8.1 + vgGetPixels@Base 7.8.1 + vgGetString@Base 7.8.1 + vgGetVectorSize@Base 7.8.1 + vgGetf@Base 7.8.1 + vgGetfv@Base 7.8.1 + vgGeti@Base 7.8.1 + vgGetiv@Base 7.8.1 + vgHardwareQuery@Base 7.8.1 + vgImageSubData@Base 7.8.1 + vgInterpolatePath@Base 7.8.1 + vgLoadIdentity@Base 7.8.1 + vgLoadMatrix@Base 7.8.1 + vgLookup@Base 7.8.1 + vgLookupSingle@Base 7.8.1 + vgMask@Base 7.8.1 + vgModifyPathCoords@Base 7.8.1 + vgMultMatrix@Base 7.8.1 + vgPaintPattern@Base 7.8.1 + vgPathBounds@Base 7.8.1 + vgPathLength@Base 7.8.1 + vgPathTransformedBounds@Base 7.8.1 + vgPointAlongPath@Base 7.8.1 + vgReadPixels@Base 7.8.1 + vgRemovePathCapabilities@Base 7.8.1 + vgRotate@Base 7.8.1 + vgScale@Base 7.8.1 + vgSeparableConvolve@Base 7.8.1 + vgSetColor@Base 7.8.1 + vgSetPaint@Base 7.8.1 + vgSetParameterf@Base 7.8.1 + vgSetParameterfv@Base 7.8.1 + vgSetParameteri@Base 7.8.1 + vgSetParameteriv@Base 7.8.1 + vgSetPixels@Base 7.8.1 + vgSetf@Base 7.8.1 + vgSetfv@Base 7.8.1 + vgSeti@Base 7.8.1 + vgSetiv@Base 7.8.1 + vgShear@Base 7.8.1 + vgTransformPath@Base 7.8.1 + vgTranslate@Base 7.8.1 + vgWritePixels@Base 7.8.1 + vguArc@Base 7.8.1 + vguComputeWarpQuadToQuad@Base 7.8.1 + vguComputeWarpQuadToSquare@Base 7.8.1 + vguComputeWarpSquareToQuad@Base 7.8.1 + vguEllipse@Base 7.8.1 + vguLine@Base 7.8.1 + vguPolygon@Base 7.8.1 + vguRect@Base 7.8.1 + vguRoundRect@Base 7.8.1 --- mesa-7.8.2.orig/debian/libosmesa6-dev.install +++ mesa-7.8.2/debian/libosmesa6-dev.install @@ -0,0 +1,8 @@ +usr/include/GL/osmesa.h +usr/lib/libOSMesa.a +usr/lib/libOSMesa.so +usr/lib/libOSMesa16.a +usr/lib/libOSMesa16.so +usr/lib/libOSMesa32.a +usr/lib/libOSMesa32.so +usr/lib/pkgconfig/osmesa.pc --- mesa-7.8.2.orig/debian/libosmesa6.install +++ mesa-7.8.2/debian/libosmesa6.install @@ -0,0 +1,3 @@ +usr/lib/libOSMesa.so.* +usr/lib/libOSMesa16.so.* +usr/lib/libOSMesa32.so.* --- mesa-7.8.2.orig/debian/libosmesa6.shlibs +++ mesa-7.8.2/debian/libosmesa6.shlibs @@ -0,0 +1,3 @@ +libOSMesa 6 libosmesa6 (>= 6.5.2-1) | libgl1-mesa-glide3 +libOSMesa16 6 libosmesa6 (>= 6.5.2-1) +libOSMesa32 6 libosmesa6 (>= 6.5.2-1) --- mesa-7.8.2.orig/debian/mesa-common-dev.docs +++ mesa-7.8.2/debian/mesa-common-dev.docs @@ -0,0 +1,8 @@ +docs/bugs.html +docs/debugging.html +docs/envvars.html +docs/faq.html +docs/osmesa.html +docs/RELNOTES-* +docs/relnotes* +docs/*.spec --- mesa-7.8.2.orig/debian/mesa-utils.install +++ mesa-7.8.2/debian/mesa-utils.install @@ -0,0 +1,4 @@ +dri/usr/bin/glxdemo usr/bin +dri/usr/bin/glxgears usr/bin +dri/usr/bin/glxheads usr/bin +dri/usr/bin/glxinfo usr/bin --- mesa-7.8.2.orig/debian/mesa-utils.manpages +++ mesa-7.8.2/debian/mesa-utils.manpages @@ -0,0 +1,4 @@ +debian/glxdemo.1 +debian/glxgears.1 +debian/glxheads.1 +debian/glxinfo.1 --- mesa-7.8.2.orig/debian/vg.pc +++ mesa-7.8.2/debian/vg.pc @@ -0,0 +1,12 @@ +prefix=/usr +exec_prefix=${prefix} +libdir=/usr/lib +includedir=/usr/include + +Name: vg +Description: Mesa OpenVG 1.0 library +Requires.private: +Version: 7.8.1 +Libs: -L${libdir} -lOpenVG +Libs.private: +Cflags: -I${includedir} --- mesa-7.8.2.orig/debian/mesa-common-dev.install +++ mesa-7.8.2/debian/mesa-common-dev.install @@ -0,0 +1,8 @@ +dri/usr/include/GL/gl.h usr/include/GL +dri/usr/include/GL/glext.h usr/include/GL +dri/usr/include/GL/gl_mangle.h usr/include/GL +dri/usr/include/GL/glx.h usr/include/GL +dri/usr/include/GL/glxext.h usr/include/GL +dri/usr/include/GL/glx_mangle.h usr/include/GL +dri/usr/include/GL/internal/dri_interface.h usr/include/GL/internal +dri/usr/lib/pkgconfig/dri.pc usr/lib/pkgconfig/ --- mesa-7.8.2.orig/debian/gbp.conf +++ mesa-7.8.2/debian/gbp.conf @@ -0,0 +1,2 @@ +[DEFAULT] +debian-branch=ubuntu --- mesa-7.8.2.orig/debian/libgl1-mesa-dev.install +++ mesa-7.8.2/debian/libgl1-mesa-dev.install @@ -0,0 +1,2 @@ +usr/lib/libGL.so usr/lib/mesa/ +usr/lib/pkgconfig/gl.pc --- mesa-7.8.2.orig/debian/libgl1-mesa-dev.links +++ mesa-7.8.2/debian/libgl1-mesa-dev.links @@ -0,0 +1 @@ +/usr/lib/mesa/libGL.so /usr/lib/libGL.so --- mesa-7.8.2.orig/debian/libgl1-mesa-glx.install +++ mesa-7.8.2/debian/libgl1-mesa-glx.install @@ -0,0 +1 @@ +dri/usr/lib/libGL.so.* usr/lib/mesa --- mesa-7.8.2.orig/debian/libgl1-mesa-glx.postinst +++ mesa-7.8.2/debian/libgl1-mesa-glx.postinst @@ -0,0 +1,26 @@ +#!/bin/sh + +set -e + +THIS_PACKAGE=libgl1-mesa-glx +THIS_SCRIPT=postinst + +case "$1" in + configure) + # Use alternatives to make it easier to switch between Mesa and 3rd party modules + update-alternatives --force \ + --install /etc/ld.so.conf.d/GL.conf gl_conf /usr/lib/mesa/ld.so.conf 500 \ + --slave /usr/lib/xorg/extra-modules xorg_extra_modules /usr/lib/xorg/x11-extra-modules + + # ldconfig needs to be run immediately as we're changing /etc/ld.so.conf.d/ with + # alternatives. + LDCONFIG_NOTRIGGER=y ldconfig + +esac + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=2 ts=2 tw=80: + --- mesa-7.8.2.orig/debian/libgl1-mesa-glx.prerm +++ mesa-7.8.2/debian/libgl1-mesa-glx.prerm @@ -0,0 +1,23 @@ +#!/bin/sh + +set -e + +THIS_PACKAGE=libgl1-mesa-glx +THIS_SCRIPT=prerm + +case "$1" in + remove) + # Use alternatives to make it easier to switch between Mesa and 3rd party modules + update-alternatives --remove gl_conf /usr/lib/GL/ld.so.conf + + # explicit ldconfig due to alternatives + ldconfig + +esac + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=2 ts=2 tw=80: + --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11-dev.install +++ mesa-7.8.2/debian/libgl1-mesa-swx11-dev.install @@ -0,0 +1,2 @@ +usr/lib/libGL.a usr/lib/mesa/ +usr/lib/libGL.so usr/lib/mesa/ --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11.install +++ mesa-7.8.2/debian/libgl1-mesa-swx11.install @@ -0,0 +1 @@ +usr/lib/libGL.so.* usr/lib/mesa/ --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11.postinst +++ mesa-7.8.2/debian/libgl1-mesa-swx11.postinst @@ -0,0 +1,26 @@ +#!/bin/sh + +set -e + +THIS_PACKAGE=libgl1-mesa-swx11 +THIS_SCRIPT=postinst + +case "$1" in + configure) + # Use alternatives to make it easier to switch between Mesa and 3rd party modules + update-alternatives --force \ + --install /etc/ld.so.conf.d/GL.conf gl_conf /usr/lib/mesa/ld.so.conf 500 \ + --slave /usr/lib/xorg/extra-modules xorg_extra_modules /usr/lib/xorg/x11-extra-modules + + # ldconfig needs to be run immediately as we're changing /etc/ld.so.conf.d/ with + # alternatives. + LDCONFIG_NOTRIGGER=y ldconfig + +esac + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=2 ts=2 tw=80: + --- mesa-7.8.2.orig/debian/libgl1-mesa-swx11.prerm +++ mesa-7.8.2/debian/libgl1-mesa-swx11.prerm @@ -0,0 +1,23 @@ +#!/bin/sh + +set -e + +THIS_PACKAGE=libgl1-mesa-swx11 +THIS_SCRIPT=prerm + +case "$1" in + remove) + # Use alternatives to make it easier to switch between Mesa and 3rd party modules + update-alternatives --remove gl_conf /usr/lib/GL/ld.so.conf + + # explicit ldconfig due to alternatives + ldconfig + +esac + +#DEBHELPER# + +exit 0 + +# vim:set ai et sw=2 ts=2 tw=80: + --- mesa-7.8.2.orig/debian/copyright +++ mesa-7.8.2/debian/copyright @@ -0,0 +1,196 @@ +This package was debianized by James A. Treacy treacy@debian.org on Thu, +6 Jan 2000 01:11:34 -0500. It was newly debianized by Marcelo E. +Magallon on Sat, 25 Dec 2004 14:50:02 -0600. It was +again debianized by Thierry Reding on Sat, 14 Oct 2006 +02:01:12 +0200. + +It was downloaded from http://www.mesa3d.org/download.html + +For more information see: + + http://www.mesa3d.org/ + +The tarball was built by combining MesaLib and MesaDemos tarballs, and +deleting the progs/objviewer/ directory. + +Copyright: + +Upstream Author: Brian Paul + +License: + + License / Copyright Information + + The Mesa distribution consists of several components. Different + copyrights and licenses apply to different components. For + example, GLUT is copyrighted by Mark Kilgard, some demo programs + are copyrighted by SGI, some of the Mesa device drivers are + copyrighted by their authors. See below for a list of Mesa's + components and the copyright/license for each. + + The core Mesa library is licensed according to the terms of the + XFree86 copyright (an MIT-style license). This allows integration + with the XFree86/DRI project. Unless otherwise stated, the Mesa + source code and documentation is licensed as follows: + + Copyright (C) 1999-2003 Brian Paul 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"), + to deal in the Software without restriction, including without limitation + the rights to use, copy, modify, merge, publish, distribute, sublicense, + and/or sell copies of the Software, and to permit persons to whom the + Software is furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included + in all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS + OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL + BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN + AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN + CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + Attention, Contributors + + When contributing to the Mesa project you must agree to relinquish + your work to the holder of the copyright for the particular + component you're contributing to. That is, you can't put your own + copyright on the code, unless it's a modular piece that can be + omitted from Mesa (like a new device driver). If for example, you + contribute a bug fix to Mesa's texture mapping code, your code + will become a part of the body of work which is copyrighted by + Brian Paul and licensed by the above terms. + +---------------------------------------------------------------------- + +Some files, as listed below, are made available under the SGI Free B +license. This license is as follows: + +SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008) + +Copyright (C) [dates of first publication] Silicon Graphics, 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"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: +The above copyright notice including the dates of first publication and either +this permission notice or a reference to http://oss.sgi.com/projects/FreeB/ +shall be included in all copies or substantial portions of the Software. +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL SILICON GRAPHICS, INC. BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR +IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS +IN THE SOFTWARE. +Except as contained in this notice, the name of Silicon Graphics, Inc. shall +not be used in advertising or otherwise to promote the sale, use or other +dealings in this Software without prior written authorization from Silicon +Graphics, Inc. + +-------------------------------------------------------------------------- + +Some other files listed below are made available from Silicon Graphics, +Inc. under a more liberal, MIT-style license, as follows: + + Permission to use, copy, modify, and distribute this software for + any purpose and without fee is hereby granted, provided that the above + copyright notice appear in all copies and that both the copyright notice + and this permission notice appear in supporting documentation, and that + the name of Silicon Graphics, Inc. not be used in advertising + or publicity pertaining to distribution of the software without specific, + written prior permission. + + THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS" + AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE + INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR + FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON + GRAPHICS, INC. BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT, + SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY + KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION, + LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF + THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC. HAS BEEN + ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON + ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE + POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE. + + US Government Users Restricted Rights + Use, duplication, or disclosure by the Government is subject to + restrictions set forth in FAR 52.227.19(c)(2) or subparagraph + (c)(1)(ii) of the Rights in Technical Data and Computer Software + clause at DFARS 252.227-7013 and/or in similar or successor + clauses in the FAR or the DOD or NASA FAR Supplement. + Unpublished-- rights reserved under the copyright laws of the + United States. Contractor/manufacturer is Silicon Graphics, + Inc., 2011 N. Shoreline Blvd., Mountain View, CA 94039-7311. + +-------------------------------------------------------------------------- + + Mesa Component Licenses: + + Component Files Primary Author License + ---------------------------------------------------------------------------- + core Mesa code src/*.[ch] Brian Paul Mesa + include/GL/gl.h + + GLX driver src/X/* Brian Paul Mesa + include/GL/glx.h + include/GL/xmesa.h + + OS/Mesa driver src/OSmesa/* Brian Paul Mesa + include/GL/osmesa.h + + 3Dfx driver src/FX/* David Bucciarelli Mesa + include/GL/fxmesa.h + + BeOS R4 driver mesa/drivers/beos/ Brian Paul Mesa + + MGL driver include/GL/mglmesa.h SciTech, Inc GNU LGPL + + Windows driver mesa/drivers/windows/ Li Wei GNU LGPL + include/GL/wmesa.h + + SVGA driver mesa/drivers/svga/ Brian Paul GNU LGPL + include/GL/svgamesa.h + + DOS driver mesa/drivers/dos/ Charlie Wallace GNU LGPL + include/GL/dosmesa.h + + GGI driver mesa/drivers/ggi/ Uwe Maurer GNU LGPL + include/GL/ggimesa.h + + GLUT src/glut/* Mark Kilgard Mark's copyright + include/GL/*glut*.h + + GLU library src/glu/* Brian Paul GNU LGPL + + SGI GLU library src/glu/sgi/* SGI SGI Free B + include/GL/glu.h + + Ext registry include/GL/glext.h SGI SGI Free B + include/GL/glxext.h + + demo programs progs/demos/* various see source files + + X demos progs/xdemos/* Brian Paul see source files + + SGI demos progs/samples/* SGI SGI MIT-style + + RedBook demos progs/redbook/* SGI SGI MIT-style + + +On Debian systems the full text of the GNU LGPL license is found in +/usr/share/common-licenses/LGPL. + +------------------------------------------------------------------------------ + +The Debian packaging is (C) 2006, Thierry Reding and +is licensed under the GPL, see `/usr/share/common-licenses/GPL'. + --- mesa-7.8.2.orig/debian/changelog +++ mesa-7.8.2/debian/changelog @@ -0,0 +1,2730 @@ +mesa (7.8.2-2ubuntu1) maverick; urgency=low + + * Merge from Debian experimental. Remaining Ubuntu changes: + - debian/control + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + + Drop i686 swx11 libgl package. + + Add libdrm-dev to mesa-common-dev Depends. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Use lzma compression for binary debs to save CD space. + - debian/patches + + 100_no_abi_tag.patch + + 101_ubuntu_hidden_glname.patch + + 103_savage-expose_fbmodes_with_nonzero_alpha.patch + + 107_glxgears_is_not_a_benchmark.patch + - rules, libgl1-mesa-{glx,dev,swx11,swx11-dev}.install, + libgl1-mesa-{glx,swx11}.{postinst,prerm}, libgl1-mesa-dev.links: + Install libGL.so* in /usr/lib/mesa to allow things to work with + alternatives. + * debian/rules: Drop get-orig-source target. mesa-demos is now split out + of git, so this divergence from Debian will no longer be informative. + + -- Christopher James Halse Rogers Tue, 27 Jul 2010 16:31:13 +1000 + +mesa (7.8.2-2) experimental; urgency=low + + * Add missing dependencies to libegl1-mesa-dev, thanks to Alexandros + Frantzis (LP: #600243). + * gallium: handle kfreebsd like freebsd, fixing FTBFS (closes: #585618) + * intel: Fix invalidate before initialisation (stolen from fdo bugzilla + #29091, fixes server 1.9rc crash when starting an app using GLX 1.3) + * Pull from 7.8-branch up to commit d06e011. + * Fixup hurd and kfreebsd patches to apply. + + -- Julien Cristau Tue, 20 Jul 2010 15:57:31 +0200 + +mesa (7.8.2-1) experimental; urgency=low + + [ Robert Hooker ] + * Adjust the build system to install the dri target in a separate + DESTDIR, no longer passing --libdir=/usr/lib/glx at configure time + messing with the .pc's since it is used for a majority of the + packages now. + * Fix up the mesa-common-dev header install location. + + [ Julien Cristau ] + * Add ${misc:Depends} to all packages. + * libc6-dev is build-essential, no need to depend on it. + * Replace nonsensical dependency of libglw1-mesa-dev on libxext6 with a + dependency on libxt-dev and lesstif2-dev. + * Add new lintian overrides for the package-name-doesnt-match-sonames stuff. + * Don't ship progs/objviewer in the tarball, it's insanely big and unused. + * New upstream release. + * Refresh patches. + * Stop shipping an upstream git log, it's unlikely to be useful to anyone, + and it's big. + * debian/scripts/choose-configs: use DEB_HOST_ARCH, not DEB_BUILD_ARCH + (closes: #451648). + * Rename radeong_dri.so to r300_dri.so in build, not binary. + + [ Christopher James Halse Rogers ] + * debian/patches/07-nouveau-update.diff: + - Pull in nouveau_class.h header no longer shipped by libdrm 2.4.21 and + update nouveau build to use it. Fixes FTBFS against libdrm 2.4.21. + * debian/rules: + - Simplify selecting which gallium drivers are built. Use this to only + act on gallium packages on archs where we're actually building them. + Part of the fix for FTBFS on Hurd and kFreeBSD. + + -- Julien Cristau Thu, 01 Jul 2010 12:50:18 +0200 + +mesa (7.8.1-3ubuntu3) maverick; urgency=low + + [ Alexandros Frantzis ] + * Make libegl1-mesa-dev depend on the following libraries which + contain the required .pc files, as specified in egl.pc: + libdrm-dev, x11proto-dri2-dev, x11proto-gl-dev, libx11-dev, + libxext-dev, libxxf86vm-dev, libxdamage-dev, libxfixes-dev. + + -- Alberto Milone Thu, 15 Jul 2010 19:01:10 +0200 + +mesa (7.8.1-3ubuntu2) maverick; urgency=low + + * Fix up the mesa-common-dev header installation location + causing FTBS on packages needing GL headers (LP: #594863) + + -- Robert Hooker Tue, 15 Jun 2010 19:04:38 -0400 + +mesa (7.8.1-3ubuntu1) maverick; urgency=low + + * Merge from Debian experimental git. Remaining Ubuntu changes: + - debian/control + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + + Drop i686 swx11 libgl package. + + Add libdrm-dev to mesa-common-dev Depends. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Use lzma compression for binary debs to save CD space. + - debian/patches + + 100_no_abi_tag.patch + + 101_ubuntu_hidden_glname.patch + + 103_savage-expose_fbmodes_with_nonzero_alpha.patch + + 107_glxgears_is_not_a_benchmark.patch + - rules, libgl1-mesa-{glx,dev,swx11,swx11-dev}.install, + libgl1-mesa-{glx,swx11}.{postinst,prerm}, libgl1-mesa-dev.links: + Install libGL.so* in /usr/lib/mesa to allow things to work with + alternatives. + + -- Christopher James Halse Rogers Tue, 15 Jun 2010 08:49:05 +1000 + +mesa (7.8.1-2) experimental; urgency=low + + [ Tormod Volden ] + * debian/rules: Do not strip the same packages twice + + [ Julien Cristau ] + * Stop building the ffb dri driver on sparc, it no longer exists. + * Merge changes from 7.7.1-2. + + [ Christopher James Halse Rogers ] + * debian/compat: + - Bump to v7 for dh_install search path behaviour + * debian/rules: + - Enable gallium for dri build. + - Enable egl for dri build. + - Build nouveau, radeon & swrast gallium drivers + - Build OpenVG, OpenGL|ES, dri, glx & egl state trackers + * debian/libegl1-mesa-dev.install: + * debian/libegl1-mesa.install: + * debian/libegl1-mesa.symbols: + - New libEGL package. + * debian/libgles1-mesa-dev.install: + * debian/libgles1-mesa.install: + * debian/libgles1-mesa.symbols: + - New OpenGL|ES v1.x package. + * debian/libgles2-mesa-dev.install: + * debian/libgles2-mesa.install: + * debian/libgles2-mesa.symbols: + - New OpenGL|ES v2.x package. + * debian/libopenvg1-mesa-dev.install: + * debian/libopenvg1-mesa.install: + * debian/libopenvg1-mesa.symbols: + - New OpenVG package. + * debian/libegl1-mesa-drivers-x11.install: + - New gallium EGL drivers package. + * debian/libegl1-mesa-drivers-kms.install: + - New gallium EGL kms driver package. + * debian/egl.pc: + * debian/vg.pc: + * debian/glesv1_cm.pc: + * debian/glesv2.pc: + - Pull pkg-config files from master and install them in the respective + -dev packages. + * debian/libgl1-mesa-dri-experimental.install: + * debian/libgl1-mesa-dri.install: + - “make install” puts classic and gallium drivers in the same path, but + builds gallium drivers in the gallium/ subdirectory. Copy the drivers + directly from the build path, rather than trying to separate them out + post-hock. + * debian/control: + - Add new packages. + - Add new build-depends on libx11-xcb-dev, libxcb-dri2-0-dev, + libxcb-xfixes0-dev and python-libxml2 for gallium. + - Bump build-depends on dpkg-dev for regex in symbols files. + + -- Julien Cristau Fri, 11 Jun 2010 03:19:09 +0200 + +mesa (7.8.1-1ubuntu1) maverick; urgency=low + + [ Timo Aaltonen ] + * Merged from Debian experimental, remaining changes: + - debian/control + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + - debian/patches + + 100_no_abi_tag.patch + + 101_ubuntu_hidden_glname.patch + + 103_savage-expose_fbmodes_with_nonzero_alpha.patch + + 107_glxgears_is_not_a_benchmark.patch + - rules, libgl1-mesa-{glx,dev,swx11,swx11-dev}.install, + libgl1-mesa-{glx,swx11}.{postinst,prerm}, libgl1-mesa-dev.links: + Install libGL.so* in /usr/lib/mesa to allow things to work with + alternatives. + * Dropped patches: + - 102_dont_vblank.patch: should be obsolete by now + - 104_savage_init_mesa.patch: merged upstream + * control: Drop dependencies on dpkg, since lucid has it and it's the + only version where upgrades are supported from. + * libgl1-mesa-dri.postinst: Drop, same as above. + + [ Robert Hooker ] + * debian/rules: Stop building/shipping abandoned the mach64 DRI driver. + + [ Christopher James Halse Rogers ] + * debian/patches/103_savage-expose_fbmodes_with_nonzero_alpha.patch + - Refresh for driCreateConfigs API change + * debian/gbp.conf + - Set debian-branch=ubuntu to make git-buildpackage less annoying + * debian/rules + - Add get-orig-source target to document the way the orig.tar.gz is + generated. + - The i386 architecture for Maverick is now i686, not i486. Adapt rules + so that the Intel DRI drivers are actually built. + - Drop LDFLAGS unexport. Mesa builds fine on amd64 with Ubuntu's + default LDFLAGS. + * debian/control: + - Drop libgl1-mesa-swx11-i686 package. This package is pointless on + Maverick, as i386 now defaults to i686 + * debian/scripts/choose-configs: + - Drop libgl1-mesa-swx11-i686 from CPU-optimised swrast configs. + + * Changes from unreleased debian-expemental 7.8.1-2 packaging: + [ Tormod Volden ] + * debian/rules: Do not strip the same packages twice + + [ Julien Cristau ] + * Stop building the ffb dri driver on sparc, it no longer exists. + + -- Christopher James Halse Rogers Wed, 19 May 2010 14:47:25 +1000 + +mesa (7.8.1-1) experimental; urgency=low + + * New upstream release. + + Pull from upstream 7.8 branch up to commit db3b3421. + * Refresh patches. + * Bump build dependency to libdrm-dev 2.4.19, x11proto-gl-dev 1.4.11, + and x11proto-dri2-dev 2.1. + + -- Brice Goglin Sun, 18 Apr 2010 09:25:39 +0200 + +mesa (7.7.1-2) unstable; urgency=low + + * debian/rules: use DEB_HOST_ARCH_CPU instead of DEB_HOST_GNU_CPU. Prompted + by Ubuntu which changed the latter to i686, breaking their packages on + i386. + * Pull from mesa_7_7_branch (commit 8ba378d). + + -- Julien Cristau Thu, 20 May 2010 17:34:19 +0200 + +mesa (7.7.1-1ubuntu3) lucid-proposed; urgency=low + + * Add 104_savage_init_mesa.patch: Savage driver needs to initialize + &ctx->Meta->Save. Fixes crash when using _mesa_CopyTexImage2D + on Savage hardware. Cherrypick from upstream. Thanks Tormod. + (LP: #562718) + + -- Bryce Harrington Wed, 21 Apr 2010 09:48:09 -0700 + +mesa (7.7.1-1ubuntu2) lucid; urgency=low + + * Add 103_savage-expose_fbmodes_with_nonzero_alpha.patch: Expose + fbmodes with non-zero alpha depth. Fixes issue where clutter apps + crash when using the savage driver. Thanks to knarf for developing + the fix. + (LP: #467474) + * mesa-common-dev should depend on libdrm-dev + (LP: #490811) + + -- Bryce Harrington Wed, 14 Apr 2010 12:06:00 -0700 + +mesa (7.7.1-1ubuntu1) lucid; urgency=low + + [ Alberto Milone ] + * debian/rules: pass --with-dri-searchpath=/usr/lib/dri:/usr/lib32/dri + to confflags-dri on i386 so that /usr/lib32/dri is used for 32 bit + compatibility on 64 bit systems (LP: #248392). + + -- Timo Aaltonen Thu, 01 Apr 2010 13:31:09 +0300 + +mesa (7.7.1-1) unstable; urgency=low + + [ Brice Goglin ] + * Remove Thierry Reding from Uploaders, closes: #572539. + * Bump Standards-Version to 3.8.4, no changes needed. + + [ Timo Aaltonen ] + * New upstream release. + + -- Brice Goglin Tue, 30 Mar 2010 17:15:09 +0200 + +mesa (7.7-4ubuntu1) lucid; urgency=low + + [Timo Aaltonen] + * libgl1-mesa-dri: Get rid of the old hook (65mesa-check-x86-64). + (LP: #460809) + + [Rolf Leggewie] + * debian/control: depend on dpkg package where u-a supports --force + (LP: #525592) + + -- Timo Aaltonen Tue, 02 Mar 2010 17:11:31 +0200 + +mesa (7.7-4) unstable; urgency=low + + * Pull from upstream mesa_7_7_branch up to commit 293f4d51. + + r6xx/r7xx: emit relocation for FRAG & TILE buffer, closes: #569663. + + -- Brice Goglin Wed, 24 Feb 2010 22:44:11 +0100 + +mesa (7.7-3ubuntu1) lucid; urgency=low + + [ Timo Aaltonen ] + * Merge from Debian experimental. + + [ Robert Hooker ] + * Add 100_no_abi_tag.patch: Removes the ABI tag in /usr/lib/libGL.so.1 + which prevented ldconfig from using a libGL from another directory + at a higher priority than the one in /usr/lib. + * Install libGL alternatives with libgl1-mesa-swx11 as well. (LP: #522048) + + -- Timo Aaltonen Fri, 19 Feb 2010 15:52:12 +0200 + +mesa (7.7-3) experimental; urgency=low + + * Pull from upstream mesa_7_7_branch up to commit f5145a6e. + * Build against libdrm-radeon1 2.4.17 to get DRI2 support. + + -- Brice Goglin Mon, 01 Feb 2010 22:55:36 +0100 + +mesa (7.7-2) experimental; urgency=low + + [ Julien Cristau ] + * Rename the build directory to not include DEB_BUILD_GNU_TYPE for no + good reason. Thanks, Colin Watson! + * Remove myself from Uploaders + + [ Brice Goglin ] + * Pull from upstream mesa_7_7_branch up to commit 2f28ca0a. + + Fix funky colors on radeon/r200/r300. + + -- Brice Goglin Wed, 27 Jan 2010 09:14:38 +0100 + +mesa (7.7-0ubuntu8) lucid; urgency=low + + * debian/libgl1-mesa-glx.postinst: + - Pass LDCONFIG_NOTRIGGER=y to ldconfig as it needs to be run + immediately as we're changing /etc/ld.so.conf.d/ with + alternatives. + + -- Alberto Milone Wed, 20 Jan 2010 13:17:54 +0100 + +mesa (7.7-0ubuntu7) lucid; urgency=low + + * debian/libgl1-mesa-glx.postinst + - Install alternative with --force so that files that + already exist are overwritten thus avoiding to install a + broken alternative. + + -- Alberto Milone Tue, 19 Jan 2010 17:29:19 +0100 + +mesa (7.7-0ubuntu6) lucid; urgency=low + + * debian/libgl1-mesa-glx.postinst + - Remove gl_libraries slave link as the file in ld.so.conf.d is + enough. + + -- Alberto Milone Sun, 17 Jan 2010 16:55:36 +0100 + +mesa (7.7-0ubuntu5) lucid; urgency=low + + * debian/rules: + - Remove invalid "install -d" command. + - Do not pass --libdir=/usr/lib/mesa flag any more. + * debian/libgl1-mesa-dev.install, libgl1-mesa-swx11-dev.install, + libgl1-mesa-swx11.install, libglu1-mesa-dev.install, + libglu1-mesa.install: + - Install *.pc files in /usr/lib/pkgconfig instead of + /usr/lib/mesa/pkgconfig. + - Do not Install libGLU* in /usr/lib/mesa (LP: #506547). + * debian/libglu1-mesa-dev.links: + - Remove file as we install libGLU in the right place now. + + -- Alberto Milone Wed, 13 Jan 2010 20:18:17 +0100 + +mesa (7.7-0ubuntu4) lucid; urgency=low + + * debian/libgl1-mesa-dev.links: + - Add link to /usr/lib/mesa/libGL.so in /usr/lib so as not to break + software that build against mesa (LP: #505359). + * debian/libgl1-mesa-glx.{postinst|prerm}: + - Use alternatives so that /usr/lib/GL is a slave which points to + /usr/lib/mesa. + * debian/libglu-mesa-dev.links: + - Add link to /usr/lib/mesa/libGLU.so in /usr/lib/libGLU.so. + * debian/rules: + - Install /usr/lib/mesa/ld.so.conf + - Create an empty directory (for alternatives) just to be sure: + /usr/lib/xorg/x11-extra-modules. + + -- Alberto Milone Mon, 11 Jan 2010 16:49:14 +0100 + +mesa (7.7-0ubuntu3) lucid; urgency=low + + * Add -l/usr/lib/mesa to dh_shlibdeps to fix FTBFS, thanks to + Albert Damen for the patch! + + -- Stefan Potyra Sun, 10 Jan 2010 00:41:48 +0100 + +mesa (7.7-0ubuntu2) lucid; urgency=low + + * Moving just libGL.so.* to /usr/lib/mesa broke all builds depending on + libGL.so or gl.pc. Fix the swx11 target --libdir to use /usr/lib/mesa. + + -- Timo Aaltonen Sat, 09 Jan 2010 11:21:13 +0200 + +mesa (7.7-0ubuntu1) lucid; urgency=low + + * Merge from Debian experimental. + + -- Timo Aaltonen Sat, 09 Jan 2010 00:12:29 +0200 + +mesa (7.7-1) experimental; urgency=low + + [ Brice Goglin ] + * Bump libdrm build dependency to 2.4.15, closes: #561058. + * New upstream release. + * Pull from upstream mesa_7_7_branch up to commit 6d6c9c66. + + [ Julien Cristau ] + * Add freedesktop.org ftp to watch file since that's where newer upstream + tarballs are. + * Don't include GLUT sources since we don't use them. + + -- Brice Goglin Mon, 11 Jan 2010 17:52:31 +0100 + +mesa (7.7~rc2-1) experimental; urgency=low + + * New upstream release candidate. + + s3v and trident DRI drivers removed since they never worked. + + -- Brice Goglin Sat, 12 Dec 2009 13:02:55 +0100 + +mesa (7.6.1-1) unstable; urgency=low + + * New upstream release + + Pull upstream mesa_7_6_branch up to commit da876fa3 + * Bump linux-libc-dev build-dep to 2.6.31 for the r600 dri driver (fixes + ftbfs on mips). + * Drop hunk from 05_hurd-ftbfs.diff that was applied upstream. Refresh + other patches. + + -- Julien Cristau Tue, 29 Dec 2009 10:42:24 +0000 + +mesa (7.6.1~rc3-1ubuntu2) lucid; urgency=low + + * debian/libgl1-mesa-glx.install: + - Install libGL.so* in /usr/lib/mesa so as to allow things to + work with alternatives. + + -- Alberto Milone Fri, 08 Jan 2010 19:38:14 +0100 + +mesa (7.6.1~rc3-1ubuntu1) lucid; urgency=low + + * Merge from Debian unstable. + + -- Timo Aaltonen Mon, 14 Dec 2009 16:49:11 +0200 + +mesa (7.6.1~rc3-1) unstable; urgency=low + + * New upstream release candidate. + + Pull upstream mesa_7_6_branch up to commit 7d41b424. + + Includes sparc64 xform asm patch from #560403. + * Update debian/rules to fix sparc64 FTBFS, thanks Aurelien Jarno, + closes: #560403. + * Build r600 DRI driver. + + -- Brice Goglin Fri, 11 Dec 2009 18:36:36 +0100 + +mesa (7.6.1~rc2-1ubuntu1) lucid; urgency=low + + * Merge from Debian unstable, remaining changes: + - debian/control + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Build .debs with lzma compression. + - debian/patches + + 101_ubuntu_hidden_glname.patch + + 102_dont_vblank.patch + + 107_glxgears_is_not_a_benchmark.patch + * Drop patches now included upstream: + - 108_fix_scissors_regression.patch + - 109_revert-dma-reuse.patch + - 110_dont_free.patch + + -- Timo Aaltonen Mon, 07 Dec 2009 18:07:26 +0200 + +mesa (7.6.1~rc2-1) unstable; urgency=low + + * New upstream release candidate. + + Pull upstream mesa_7_6_branch up to commit b2953ee. + + i965: Fix the bounds emitted in the vertex buffer packets, + closes: #556541. + + Fix window drawing regression in Kwin on older Radeon hardware, + fix assertion failure leading to crash on kwin when compositing + is enabled, closes: #549588. + + Refresh patches. + + -- Brice Goglin Sun, 06 Dec 2009 00:14:34 +0100 + +mesa (7.6.0-1ubuntu4) karmic; urgency=low + + * Add 110_dont_free.patch: It is not necessary to worry about freeing + the textures, VBOs, etc. in _mesa_meta_free() since these are already + handled by the normal context deallocation code. Fixes a crash in + Blender in brw_prepare_vertices(). + (LP: #438657) + + -- Bryce Harrington Tue, 13 Oct 2009 13:48:03 -0700 + +mesa (7.6.0-1ubuntu3) karmic; urgency=low + + * Add 109_revert-dma-reuse.patch: Fix assertion failure leading to crash + on kwin when compositing is enabled. This reverts commit 284a7af27. + (LP: #446578) + + -- Bryce Harrington Tue, 13 Oct 2009 00:52:32 -0700 + +mesa (7.6.0-1ubuntu2) karmic; urgency=low + + * Add 108_fix_scissors_regression.patch: Fix window drawing regression + in Kwin on older Radeon hardware. + (LP: #446425) + + -- Bryce Harrington Fri, 09 Oct 2009 14:12:44 -0700 + +mesa (7.6.0-1ubuntu1) karmic; urgency=low + + * Merge from Debian. (LP: #420803) + Remaining Ubuntu changes: + - debian/control + + Change maintainer address to Ubuntu. + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + + Require at least libdrm_2.4.12+git20090801.45078630 + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Build .debs with lzma compression. + + Serialize install phase as suggested by Julien Cristau, + fixes amd64 FTBFS. + - debian/patches + + 101_ubuntu_hidden_glname.patch + + 102_dont_vblank.patch + + 107_glxgears_is_not_a_benchmark.patch + * Drop patches now included upstream: + + 108_big_endian.patch + + 109_fix_relocation_delta_for_wm_surfaces.patch + + 110_deassociate_drawables.patch + + 111_dridrawable_nullptr.patch + + 112_dont_corrupt_random_number_state.patch + * Mesa 7.6 fixes the following Ubuntu bugs: + + Suppress excessive warnings on unsupported GLX 1.3 calls. + (LP: #433488) + * See http://www.mesa3d.org/relnotes-7.6.html for more details. + + -- Bryce Harrington Wed, 07 Oct 2009 14:51:41 -0700 + +mesa (7.6-1) unstable; urgency=low + + [ Brice Goglin ] + * New upstream release. + + Fix software fallback assertion on RS480, closes: #539162. + + Fix segfault in _swrast_ReadPixels on i915, closes: #545085. + + [ Julien Cristau ] + * Don't run install from the various configs in parallel, hopefully fixing a + bug in the previous debian/rules. Thanks to Bernhard R. Link for the + suggestions. + + -- Brice Goglin Tue, 29 Sep 2009 11:51:58 +0200 + +mesa (7.6.0~git20090817.7c422387-0ubuntu8) karmic; urgency=low + + * Add 112_dont_corrupt_random_number_state.patch: Fix predictable + numbers being seeded into the RNG in OpenGL when glutCreateWindow() is + called. + (LP: #421651) + + -- Bryce Harrington Wed, 07 Oct 2009 00:38:40 -0700 + +mesa (7.6.0~git20090817.7c422387-0ubuntu7) karmic; urgency=low + + * Add 110_deassociate_drawables.patch, 111_dridrawable_nullptr.patch: + Fix X crash when 3D wine applications are closed. + (LP: #401067) + + -- Bryce Harrington Fri, 02 Oct 2009 18:00:02 -0700 + +mesa (7.6.0~git20090817.7c422387-0ubuntu6) karmic; urgency=low + + * Fix build failures for big endian architectures, update + 108_big_endian.patch. + + -- Matthias Klose Sun, 27 Sep 2009 15:34:47 +0200 + +mesa (7.6.0~git20090817.7c422387-0ubuntu5) karmic; urgency=low + + * debian/rules: Disable r600: Disable r600 as 3D support is still + experimental and causes problems with the gnome session when + compiz is enabled (LP: #419126). + + -- Alberto Milone Wed, 16 Sep 2009 17:43:59 +0200 + +mesa (7.6.0~git20090817.7c422387-0ubuntu4) karmic; urgency=low + + * Add 109_fix_relocation_delta_for_wm_surfaces.patch: Fix relocation + delta for WM surfaces. This was a regression introduced in + 0f328c90dbc893e15005f2ab441d309c1c176245 (LP: #429241). + + -- Alberto Milone Tue, 15 Sep 2009 18:14:48 +0200 + +mesa (7.6.0~git20090817.7c422387-0ubuntu3) karmic; urgency=low + + * Add 108_big_endian.patch: Fix a couple build issues on big-endian hw. + * changelog: Restore missing changelog entries lost during merge. + + -- Bryce Harrington Wed, 26 Aug 2009 13:25:56 -0700 + +mesa (7.6.0~git20090817.7c422387-0ubuntu2) karmic; urgency=low + + * control: Require at least libdrm_2.4.12+git20090801.45078630 + + -- Bryce Harrington Fri, 21 Aug 2009 21:09:03 -0700 + +mesa (7.6.0~git20090817.7c422387-0ubuntu1) karmic; urgency=low + + [Bryce Harrington] + * Checkout from git 20090817 (master branch) up to commit + 7c4223876b4f8a78335687c7fcd7448b5a83ad10 + + Add DRI2 support to -ati + (LP: #329654, #404428, #327698, #321108) + + Fix portion of MythTV Frontend does not work with RADEON DRI + (LP: #341898) + + Fix selection mode on RS482 + (LP: #273329) + + Fix issue running 3D acceleration games on ATI chipsets + (LP: #374590) + + Provide DRI2 swap buffers + (LP: #377090) + + Fix blender unusable with UXA when DRI2 enabled + (LP: #353763) + + Fix glxgears blanking screens on -ati + (LP: #411251) + * Drop 108_bo_assertion.patch (applied upstream) + + [Robert Hooker] + * Only added debian/ tree from origin/ubuntu + * Enable r600 driver. Note that it requires seperate drm modules + not provided in this PPA or in ubuntu, and also does not work with + KMS. + + -- Bryce Harrington Fri, 21 Aug 2009 19:14:36 -0700 + +mesa (7.5.1-1) unstable; urgency=low + + [ Brice Goglin ] + * New upstream release. + * Add README.source. + * Bump Standards-Version to 3.8.3. + + [ Julien Cristau ] + * Override 'package-name-doesnt-match-sonames' lintian warnings for libGLU, + libGLw and both libGLs. + * Use dh_lintian and bump debhelper build-dep accordingly. + + -- Brice Goglin Fri, 04 Sep 2009 11:38:46 +0200 + +mesa (7.5-3) unstable; urgency=low + + * Pull from upstream mesa_7_5_branch up to commit b4ba6a66 + (early 7.5.1 release snapshot). + * Only install the huge upstream changelog in mesa-common-dev, + closes: #538094. + * Enable i686 optimized libraries on hurd-i386. + + -- Brice Goglin Fri, 24 Jul 2009 00:29:28 +0200 + +mesa (7.5-2) unstable; urgency=low + + * Pull from upstream mesa_7_5_branch up to commit a6b31415 + + radeon/DRI1: if we have HW stencil, only expose fbconfigs with stencil, + closes: #537732. + * Install the upstream changelog. + + -- Brice Goglin Tue, 21 Jul 2009 22:21:50 +0200 + +mesa (7.5-1ubuntu1) karmic; urgency=low + + * Merge from Debian. Remaining Ubuntu changes: + - debian/control + + Change maintainer address to Ubuntu. + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Build .debs with lzma compression. + + Serialize install phase as suggested by Julien Cristau, + fixes amd64 FTBFS. + - debian/patches + + 101_ubuntu_hidden_glname.patch + + 102_dont_vblank.patch + + 107_glxgears_is_not_a_benchmark.patch + * Dropped patches, applied upstream: + - 108_bo_assertion.patch + * Mesa 7.5 fixes the following Ubuntu bugs: + - Fixes intelTexImage Assertion failed (LP: #358403) + - Fixes segv during glean/makeCurrent (LP: #333748) + + -- Bryce Harrington Tue, 21 Jul 2009 00:41:19 -0700 + +mesa (7.5-1) unstable; urgency=low + + [ Timo Aaltonen ] + * Move dri.pc to mesa-common-dev (closes: #521667) + + [ Brice Goglin ] + * Enable i686 optimized libraries on kfreebsd-i386, closes: #537345. + * New upstream release: + + i915: Fix assertion failure on remapping a non-BO-backed VBO, + closes: #537147. + + GLX/DRI1: Mark GLX visuals with depth != screen depth non-conformant, + closes: #532980. + + -- Brice Goglin Sun, 19 Jul 2009 12:53:41 +0200 + +mesa (7.5~rc4-1ubuntu3) karmic; urgency=low + + * Add 108_bo_assertion.patch: Fix assertion failure on remapping a + non-BO-backed VBO with intel video. (LP: #396667) + + -- Robert Hooker (Sarvatt) Tue, 07 Jul 2009 14:35:54 -0400 + +mesa (7.5~rc4-1ubuntu2) karmic; urgency=low + + * rules: Add a missing semicolon (FTBFS). + + -- Timo Aaltonen Tue, 30 Jun 2009 19:49:17 +0300 + +mesa (7.5~rc4-1ubuntu1) karmic; urgency=low + + * Merge from Debian experimental, remaining changes: + - debian/control + + Change maintainer address to Ubuntu. + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Use --disable-glw for swx11 targets too. + + Don't enable motif for swx11 targets. + + Build .debs with lzma compression. + - debian/patches + + 101_ubuntu_hidden_glname.patch refreshed. + + 102_dont_vblank.patch refreshed. + - debian/mesa-common-dev.install + + Install dri.pc + * Dropped patches, applied upstream: + 104_fix_dri2_ext_tfp.diff + 105_glXWaitX_segfaults.patch + 108_destroy_intel_fb.patch + 109_release_direct_rendering_resources.patch + 110_null_ptr_during_screen_tear_down.patch + * rules: Serialize install phase as suggested by Julien Cristau, + fixes amd64 FTBFS. + + -- Timo Aaltonen Tue, 30 Jun 2009 17:52:14 +0300 + +mesa (7.5~rc4-1) experimental; urgency=low + + [ Timo Aaltonen ] + * New upstream release candidate. + + xdriinfo now works with DRI2 (closes: #527132) + * rules: Disable EGL. + * mesa-common-dev.install: Don't install glxew.h, conflicts with libglew. + + [ Julien Cristau ] + * Update patches: + + 02_use-ieee-fp-on-s390-and-m68k.patch moved from imports.h to compiler.h + + 03_optional-progs-and-install.patch refreshed + + 05_hurd-ftbfs.diff partly applied upstream + + 06_kfreebsd-ftbfs.diff refreshed + * Install dri.pc, which will be needed to build xorg-server 1.7. + * Don't build gallium for now. + + -- Julien Cristau Sun, 28 Jun 2009 20:21:37 +0200 + +mesa (7.4.4-1) unstable; urgency=low + + [ Julien Cristau ] + * New upstream release. + + fixes a crash in swrast glXWaitX (closes: #528708) + * Don't build hardware dri drivers on s390. + * Update 04_osmesa_version.diff, refresh 06_kfreebsd-ftbfs.diff. + + [ Brice Goglin ] + * Enable motif in GLw, closes: #527483. + + -- Julien Cristau Sun, 28 Jun 2009 18:58:27 +0200 + +mesa (7.4.1-1ubuntu6) karmic; urgency=low + + * Install dri.pc in libgl1-mesa-dev as well + (LP: #379797) + + -- Robert Hooker Wed, 24 Jun 2009 17:47:08 -0400 + +mesa (7.4.1-1ubuntu5) karmic; urgency=low + + * Drop 111_fix_mesa_ref_fb_call_syntax.patch: Testing showed that 110 + alone is sufficient to fix the issue. + + -- Bryce Harrington Wed, 24 Jun 2009 17:07:33 -0700 + +mesa (7.4.1-1ubuntu4) karmic; urgency=low + + * Add 110_null_ptr_during_screen_tear_down.patch and + 111_fix_mesa_ref_fb_call_syntax.patch to fix crashes caused by errors + in the previous memory leak fixes in -1u3. + (LP: #391808) + + -- Bryce Harrington Wed, 24 Jun 2009 15:32:54 -0700 + +mesa (7.4.1-1ubuntu3) karmic; urgency=low + + * Add 108_destroy_intel_fb.patch: Release fb backing regions in + intelDestroyBuffer(). Cherrypicked patch. Fixes memory leak when + destroying framebuffers. + (LP: #360319) + * Add 109_release_direct_rendering_resources.patch: Cherrypicked patch. + Also release direct rendering resources in glXDestroyGLXPixmap. + Fixes leak running compiz with direct rendering. + (LP: #376092) + + -- Bryce Harrington Tue, 23 Jun 2009 13:44:02 -0700 + +mesa (7.4.1-1ubuntu2) karmic; urgency=low + + * Add 107_glxgears_is_not_a_benchmark.patch: glxgears makes + troubleshooting performance issues difficult because bug reporters + see it provides fps output, and end up not looking for a better + benchmark. + + -- Bryce Harrington Mon, 04 May 2009 12:49:12 -0700 + +mesa (7.4.1-1ubuntu1) karmic; urgency=low + + * Merge from debian unstable, remaining changes: + - debian/control + + Change maintainer address to Ubuntu. + + Drop lesstif-dev from Build-Depends. + + Comment out GLw libs since it depends on lesstif-dev. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + use --disable-glw for swx11 targets too. + + Build .debs with lzma compression. + - debian/patches + + 101_ubuntu_hidden_glname.patch. + + 102_dont_vblank.patch: + + 104_fix_dri2_ext_tfp.diff + + 105_glXWaitX_segfaults.patch + + -- Timo Aaltonen Fri, 15 May 2009 14:50:57 +0300 + +mesa (7.4.1-1) unstable; urgency=low + + [ Julien Cristau ] + * Make libgl1-mesa-dev and mesa-common-dev 'Architecture: any'. This gets + rid of uninstallability when a new upstream version isn't built on all + architectures, and allows us to ship potentially arch-specific .pc files. + * Install pkgconfig files for libGLU, libOSMesa and libGLw. + * Make libgl1-mesa-dri{,-dbg} 'Architecture: any', as swrast_dri.so should + get built everywhere. + * Drop the dependency on libgl1-mesa-glx from -dri, and make -glx recommend + -dri instead. The dri drivers are also loaded by the X server, which + doesn't need libGL. On the other hand, libGL needs one of the dri drivers + for direct rendering (either software or hardware). Mark libgl1-mesa-dri + as breaking old xserver-xorg-core and libgl1-mesa-glx, to avoid + incompatibilities. + * Add patch by Samuel Thibault to fix FTBFS on hurd-i386. + * Pull from mesa_7_4_branch as of May 3rd (commit 63375254). + * Move -dbg packages to new 'debug' section. + + [ Brice Goglin ] + * Add patch by Aurelien Jarno to fix FTBFS on kfreebsd-i386, closes: #524690. + + -- Julien Cristau Sun, 03 May 2009 16:05:09 +0200 + +mesa (7.4-2) unstable; urgency=low + + * Upload to unstable. + + -- Julien Cristau Wed, 08 Apr 2009 23:53:47 +0100 + +mesa (7.4-1) experimental; urgency=low + + [ Timo Aaltonen ] + * New upstream release. + + -- Julien Cristau Wed, 01 Apr 2009 20:25:00 +0200 + +mesa (7.4-0ubuntu4) karmic; urgency=low + + * debian/patches/106_compiz_ring_switcher_xorg_segv_on_radeon.diff: + fix xserver segv triggered by compiz ring switcher plugin for users + with r300/r400 radeon chipsets and -ati driver. Patch previously + commited to mesa master as c28707b50701b1cf8727be29d61e2d939c6ee58f + and also to mesa_7_4_branch as a1ce4efefbb7f796a0a24544a1e893a56848f0c1. + Note: it was commited to the 7.4 branch after mesa 7.4.0 release. + (LP: #368049) + + -- Martin Olsson Mon, 04 May 2009 12:25:29 +0200 + +mesa (7.4-0ubuntu3) jaunty; urgency=low + + * Disable 103_bump_965_texture_limit.diff. This is suspected to cause X + freeze issues. + (LP: 359392, Reopen: 146298) + + -- Bryce Harrington Fri, 17 Apr 2009 11:48:50 -0700 + +mesa (7.4-0ubuntu2) jaunty; urgency=low + + * Add 105_glXWaitX_segfaults.patch. Resolves segfaults from unitialized + variables when using swrast based drivers. (LP: #355242) + + -- Mario Limonciello Wed, 15 Apr 2009 01:03:30 -0500 + +mesa (7.4-0ubuntu1) jaunty; urgency=low + + * New upstream release, merge from debian-experimental + (LP: #330476, #347171, #349127) + * Drop 103_rs600_support.patch, included in this version. + * Drop 104_swrast_fbconfigs.patch, included in this version. + * Add 103_bump_965_texture_limit.diff. (LP: #146298) + * Add 104_fix_dri2_ext_tfp.diff. (LP: #324854) + + -- Timo Aaltonen Fri, 03 Apr 2009 12:42:06 +0300 + +mesa (7.4~rc1-1) experimental; urgency=low + + * New upstream release candidate. + * Fix watch file to make uscan not consider release candidates as newer than + actual releases. + * debian/control: add lpia to the Architecture field for + libgl1-mesa-dri{,-dbg} to match Ubuntu. + * debian/rules: on lpia, only build the i915 and i965 dri drivers (based on + Ubuntu changes). + * Build-depend on linux-libc-dev >= 2.6.29 on linux archs. + + -- Julien Cristau Wed, 25 Mar 2009 11:34:42 +0100 + +mesa (7.3-1ubuntu4) jaunty; urgency=low + + * Backport 104_swrast_fbconfigs.patch from mesa git. + - Properly assigns an fbconfig for the root visual. This fixes + issues with MythTV not being able to show fonts when using a software + rasterizer. (LP: #341898) + + -- Mario Limonciello Fri, 27 Mar 2009 02:50:13 -0500 + +mesa (7.3-1ubuntu3) jaunty; urgency=low + + * Add 103_rs600_support.patch: Adds support for the RS600 chip and sets + the number of gb pipes properly for r3xx/r5xx cards. + + -- Bryce Harrington Tue, 03 Mar 2009 00:26:59 -0800 + +mesa (7.3-1ubuntu2) jaunty; urgency=low + + [ Julien Cristau ] + * Drop CFLAGS mangling for lpia and armel from debian/rules, the issue has + been fixed upstream. + + [ Timo Aaltonen ] + * 102_dont_vblank.patch: Disable vblank again for intel, and revisit it + again during the next cycle. + + -- Timo Aaltonen Mon, 23 Feb 2009 16:48:56 +0200 + +mesa (7.3-1ubuntu1) jaunty; urgency=low + + * Merge with Debian experimental. + * Drop 102_remove_flip.diff, included in 7.3.. + + -- Timo Aaltonen Sat, 31 Jan 2009 12:38:44 +0200 + +mesa (7.3-1) experimental; urgency=low + + [ Timo Aaltonen ] + * New upstream release. + + [ Julien Cristau ] + * Try to make the diff a bit smaller by removing directories that are in + upstream git but not in tarballs. + + -- Julien Cristau Fri, 30 Jan 2009 20:00:34 +0100 + +mesa (7.3~rc3-1ubuntu2) jaunty; urgency=low + + * 102_remove_flip.diff: Add a patch from upstream which removes the + remaining bits of pageflipping support. (LP: #320690) + + -- Timo Aaltonen Sun, 25 Jan 2009 00:00:04 +0200 + +mesa (7.3~rc3-1ubuntu1) jaunty; urgency=low + + * Merge with Debian experimental. + * Drop 102_dont_vblank.patch, since the new drm code in the kernel + fixes the bugs that it worked around. + * Bump the build-dependency of libdrm to 2.4.4. It's the first version + with necessary changes to build this. + + -- Timo Aaltonen Fri, 23 Jan 2009 10:20:24 +0200 + +mesa (7.3~rc3-1) experimental; urgency=low + + [ Timo Aaltonen ] + * New upstream release candidate. + + [ Julien Cristau ] + * Refresh patches 03 and 04. + + -- Julien Cristau Wed, 21 Jan 2009 19:01:21 +0100 + +mesa (7.3~rc1-1) experimental; urgency=low + + * New upstream release candidate. + + provides DRI2 (closes: #411141). + + i915: fallback for cube map texture. Fixes GPU hang with scorched3d + (closes: #484049). + + [ Timo Aaltonen ] + * Remove debian/patches/01_disable-intel-classic-warn.diff, the + warning is gone now. + * debian/control: + - Build-depend on x11proto-dri2-dev (>= 1.99.3) + + [ Julien Cristau ] + * Require libdrm-dev 2.4.3. + * Merge packaging changes from unstable, from 7.0.3-5 to 7.0.3-7. + * Delete unused configs/debian-*, and install-source.sh script. We've + switched to using autoconf, and mesa-swx11-source is gone. + * Delete some now unused code from debian/rules. + + -- Julien Cristau Sat, 10 Jan 2009 22:14:55 +0100 + +mesa (7.2+git20081209.a0d5c3cf-0ubuntu4) jaunty; urgency=low + + * debian/rules: Add -D_GNU_SOURCE for lpia & armel (FTBFS). + + -- Timo Aaltonen Fri, 12 Dec 2008 02:15:40 +0200 + +mesa (7.2+git20081209.a0d5c3cf-0ubuntu3) jaunty; urgency=low + + * debian/rules (CFLAGS): Avoid recursive reference. + + -- Matthias Klose Thu, 11 Dec 2008 22:34:43 +0100 + +mesa (7.2+git20081209.a0d5c3cf-0ubuntu2) jaunty; urgency=low + + * debian/rules: Add -D_BSD_SOURCE to CFLAGS for lpia & armel (FTBFS). + * Drop the Xsession.d hook, not needed anymore. + + -- Timo Aaltonen Thu, 11 Dec 2008 23:20:47 +0200 + +mesa (7.2+git20081209.a0d5c3cf-0ubuntu1) jaunty; urgency=low + + * Merge from debian-experimental git branch. + * 103_fix-crash-in-i830_emit_state.dpatch: deleted, included + upstream. + + -- Timo Aaltonen Tue, 09 Dec 2008 21:54:28 +0200 + +mesa (7.2-1ubuntu2) intrepid; urgency=low + + * debian/patches/103_fix-crash-in-i830_emit_state.dpatch: + - Apply upstream commit to fix a crash in i830_emit_state + (LP: #277709) + + -- Chris Coulson Tue, 21 Oct 2008 17:55:10 +0100 + +mesa (7.2-1ubuntu1) intrepid; urgency=low + + * Merge from Debian experimental. + + -- Timo Aaltonen Wed, 24 Sep 2008 21:00:38 +0300 + +mesa (7.2-1) experimental; urgency=low + + [ Brice Goglin ] + * Fix grammar and punctuation in glxinfo(1), thanks Sam Hocevar, + closes: #498595. + + [ Timo Aaltonen ] + * New upstream release. + * Refresh patch 04_osmesa_version.diff + + [ Julien Cristau ] + * Remove the build-dep on dri2proto, DRI2 support has been removed. + * intel: don't warn about TTM init failure. + + -- Julien Cristau Wed, 24 Sep 2008 14:28:21 +0200 + +mesa (7.1-1ubuntu3) intrepid; urgency=low + + * debian/rules: Build i915 and i965 DRI drivers on lpia. (LP: #270106) + + -- Timo Aaltonen Tue, 16 Sep 2008 13:07:02 +0300 + +mesa (7.1-1ubuntu2) intrepid; urgency=low + + * 102_dont_vblank.patch + - Revert the commit which defaults to vblank on intel. It breaks + DPMS with compiz, resulting in a hang. (LP: 262605) + + -- Timo Aaltonen Fri, 12 Sep 2008 11:25:01 +0300 + +mesa (7.1-1ubuntu1) intrepid; urgency=low + + * Merge from debian experimental, remaining changes: + - debian/control + + Change maintainer address to Ubuntu. + + Drop lesstif-dev from Build-Depends since it's a universe component + that Ubuntu doesn't want in main due to security concerns about it + (it's a large codebase without active development - last release >2 + yrs ago). + + Comment out GLw libs since it depends on lesstif-dev. + + Add lpia to -dri and -dri-dbg package in. + + Add Pre-Depends: dpkg (>= 1.14.12ubuntu3) to ensure dpkg + support for lzma. + - debian/rules + + Unexport LDFLAGS (amd64 FTBFS). + + Add Xsession hook to disable ASM optimizations when running on + 64-but processors that don't support them + (LP: 87661, Deb: 484180, fdo: 8724) + + use --disable-glw for swx11 targets too. + + Build .debs with lzma compression. + - debian/patches + + Add 101_ubuntu_hidden_glname.patch. + + -- Timo Aaltonen Thu, 28 Aug 2008 01:18:35 +0300 + +mesa (7.1-1) experimental; urgency=low + + * Add parallel build support. + * New upstream development release + + libGLU now only exports its public interface (closes: #319388) + * Some more parallel build updates. + + -- Julien Cristau Wed, 27 Aug 2008 19:52:24 +0200 + +mesa (7.1~rc3-1ubuntu4) intrepid; urgency=low + + * debian/control: Add Pre-Depends: dpkg (>= 1.14.12ubuntu3) to ensure dpkg + support for lzma. + + -- Martin Pitt Sun, 11 May 2008 10:42:54 +0200 + +mesa (7.1~rc3-1ubuntu3) intrepid; urgency=low + + * Build .debs with lzma compression to reduce libgl1-mesa-dri from 13.2 to + 2.8 MB. + + -- Martin Pitt Tue, 12 Aug 2008 09:31:01 +0200 + +mesa (7.1~rc3-1ubuntu2) intrepid; urgency=low + + * 102_fix-fdo-14441.diff: fix tfp on i965. (LP: #245888) + + -- Timo Aaltonen Fri, 01 Aug 2008 16:08:01 +0300 + +mesa (7.1~rc3-1ubuntu1) intrepid; urgency=low + + * merged with debian-experimental + + -- Michael Vogt Tue, 15 Jul 2008 15:07:41 +0100 + +mesa (7.1~rc3-1) experimental; urgency=low + + [ Julien Cristau ] + * New upstream release candidate (updated to git commit 4fab47b1). + * Build against libdrm >= 2.3.1. + * 04_osmesa_version.diff: fix libOSMesa versioning, to revert accidental + SONAME bump. + + [ Timo Aaltonen ] + * Refresh patches, and drop obsolete 00_create-libdir.patch and + 01_fix-makefile.patch. + * Build-depend on x11proto-dri2-dev. + * Drop mesa-swx11-source. + * Add dri_interface.h to mesa-common-dev. + * Add gl.pc to libgl1-mesa-dev + * rules: Replace the old build system with the new autotools-based + system. + * Run autoreconf before building the various flavours.. + * Add automake & autoconf to build-deps. + * Use --enable-glx-tls for dri. + + -- Julien Cristau Sun, 13 Jul 2008 19:41:42 +0200 + +mesa (7.1~rc1-0ubuntu2) intrepid; urgency=low + + * Merge with debian git, fixes FTBFS on sparc/hppa/ia64. + + -- Timo Aaltonen Mon, 07 Jul 2008 11:12:26 +0300 + +mesa (7.1~rc1-0ubuntu1) intrepid; urgency=low + + [ Bryce Harrington ] + * Merge from git.debian.org, remaining changes: + - Change maintainer address to Ubuntu. + - Drop lesstif-dev from Build-Depends since it's a universe component + that Ubuntu doesn't want in main due to security concerns about it + (it's a large codebase without active development - last release >2 + yrs ago). + - Comment out GLw libs from control since it depends on lesstif-dev. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add Xsession hook to disable ASM optimizations when running on + 64-but processors that don't support them + (LP: 87661, Deb: 484180, fdo: 8724) + - Add 101_ubuntu_hidden_glname.patch. + + [ Timo Aaltonen ] + * Dropped patches + 102_ubuntu_no_glw.patch: + - the new build system handles this better + 103_dlopen_in_driveropen.diff and 104_fix_driveropen.diff: + - upstream + * debian/rules: use --disable-glw for swx11 targets too. + * Unexport LDFLAGS (amd64 FTBFS). + + -- Timo Aaltonen Fri, 04 Jul 2008 13:19:57 +0300 + +mesa (7.0.3-7) unstable; urgency=low + + * Cherry-pick patch from upstream: + Use 3Dnow! x86-64 routines only on processors that support 3Dnow! + (closes: #484180). + * Also build the x86-specific dri drivers on kfreebsd (closes: #492894). + + -- Julien Cristau Sun, 14 Dec 2008 07:34:58 +0530 + +mesa (7.0.3-6) unstable; urgency=high + + * Update debian/copyright to the SGI Free Software License B, version 2.0. + It now mirrors the free X11 license used by X.Org (closes: #368560). + http://www.sgi.com/company_info/newsroom/press_releases/2008/september/opengl.html + + -- Julien Cristau Sat, 20 Sep 2008 16:30:44 +0200 + +mesa (7.0.3-5) unstable; urgency=low + + * Disable the i915tex driver, it doesn't build against libdrm 2.3.1. + * Pull from mesa_7_0_branch (27425708). + + -- Julien Cristau Sat, 12 Jul 2008 18:56:19 +0200 + +mesa (7.0.3-4) unstable; urgency=low + + * Pull from mesa_7_0_branch (2ac4919d). + * Put back our configs/ changes into the .diff.gz since choose-configs + needs them before quilt is invoked. Put 04_cleanup-osmesa-configs.patch + there as well for #485161. + + -- Brice Goglin Wed, 18 Jun 2008 20:59:14 +0200 + +mesa (7.0.3-3ubuntu1) intrepid; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer address to Ubuntu. + - Drop lesstif-dev from Build-Depends since it's a universe component + that Ubuntu doesn't want in main due to security concerns about it + (it's a large codebase without active development - last release >2 + yrs ago). + - Comment out GLw libs from control since it depends on lesstif-dev. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch to remove lesstif build depends since + its a universe component. + - Add 103_dlopen_in_driveropen.diff and 104_fix_driveropen.diff from + upstream; "Always call dlopen in DriverOpen". + (LP: 189580, fdo: 13541) + - Add Xsession hook to disable ASM optimizations when running on + 64-but processors that don't support them + (LP: 87661, Deb: 484180, fdo: 8724) + + -- Bryce Harrington Tue, 17 Jun 2008 16:47:35 -0700 + +mesa (7.0.3-3) unstable; urgency=low + + * Pull from mesa_7_0_branch (718724de). + + Fix intel_batchbuffer_space on i965, closes: #455817. + + Fix busy error in i915_wait_irq for real now, closes: #467319. + * Move our configs/ changes from the .diff.gz into our quilt patches, + with 04_cleanup-osmesa-configs.patch renamed into 04_debian-configs.patch, + closes: #485161. + + -- Brice Goglin Tue, 17 Jun 2008 20:00:51 +0200 + +mesa (7.0.3-2) unstable; urgency=low + + * Pull from mesa_7_0_branch (03447de3). + * Set right cliprects for the current draw region on Intel, closes: #467319. + * Use BRW_TEXCOORDMODE_CLAMP instead of BRW_TEXCOORDMODE_CLAMP_BORDER + to implement GL_CLAMP on i965, closes: #478880. + * Fix segment fault with BASE_LEVEL set to 5 for MipMap on i915, + closes: #451339. + * Disable low impact fallback on r300 by default, closes: #440868. + + -- Brice Goglin Fri, 13 Jun 2008 06:53:29 +0200 + +mesa (7.0.3-1ubuntu2) intrepid; urgency=low + + * Add Xsession hook to disable ASM optimizations when running on + 64-but processors that don't support them (LP: #87661) + + -- Tormod Volden Thu, 05 Jun 2008 12:41:25 +0200 + +mesa (7.0.3-1ubuntu1) intrepid; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer address. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + - Add 103_dlopen_in_driveropen.diff and 104_fix_driveropen.diff from + upstream; "Always call dlopen in DriverOpen". (LP: #189580) + + -- Timo Aaltonen Wed, 04 Jun 2008 18:38:43 +0300 + +mesa (7.0.3-1) unstable; urgency=low + + * New upstream release. + * Only call ProgramStringNotify if program parsing succeeded, + closes: #473551. + + -- Brice Goglin Fri, 11 Apr 2008 08:42:37 +0200 + +mesa (7.0.3~rc2-2) unstable; urgency=low + + * Pull from mesa_7_0_branch (1e83d70b). + * Fixes regression in the i965 dri driver (closes: #470984, #470084) + * Update 02_use-ieee-fp-on-s390-and-m68k.patch. + * Change libgl1-mesa-swx11-i686's pre-dependency on libgl1-mesa-swx11 to a + regular versioned dependency, and add ${shlibs:Depends}. + + -- Julien Cristau Mon, 31 Mar 2008 16:47:31 +0200 + +mesa (7.0.3~rc2-1ubuntu3) hardy; urgency=low + + * debian/patches/107_fix_-ve_rhw_regression.patch: Fixes regression + introduced upstream where a -ve rhw workaround is being applied only + for IGD systems, when it should be applied only for *non*-IGD systems. + This resulted in rendering issues in 3D games and drawing programs. + (LP: #199823, #206287) + + -- Bryce Harrington Fri, 04 Apr 2008 19:46:40 -0700 + +mesa (7.0.3~rc2-1ubuntu2) hardy; urgency=low + + [ Laurent Bigonville ] + * debian/patches/105_vblank_fix.patch: Fix "drmWaitVBlank returned -1" error + (LP: #186764) + + [ Timo Aaltonen ] + * Add 106_i965_wine_fix.diff from upstream, "Only call + ProgramStringNotify if program parsing succeeded". (LP: #178292) + + -- Timo Aaltonen Wed, 12 Mar 2008 12:33:41 +0200 + +mesa (7.0.3~rc2-1ubuntu1) hardy; urgency=low + + * Merge from debian unstable (LP: #189167), remaining changes: + - Change maintainer address. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + * Drop patch 103_fix_rv410se.diff, applied upstream. + * Add 103_dlopen_in_driveropen.diff and 104_fix_driveropen.diff from + upstream; "Always call dlopen in DriverOpen". (LP: #189580) + + -- Timo Aaltonen Tue, 26 Feb 2008 13:07:45 +0200 + +mesa (7.0.3~rc2-1) unstable; urgency=low + + * New upstream release candidate. + + enable user-defined clip planes for R300 (closes: #408679) + + 03_optional-progs-and-install.patch: partly applied upstream, fixed up + * Stop building with -O0 on hppa. Bug #451047 should be fixed in recent gcc + versions. + + -- Julien Cristau Sun, 24 Feb 2008 10:22:54 +0100 + +mesa (7.0.2-4ubuntu2) hardy; urgency=low + + * 103_fix_rv410se.diff: + - patch from upstream; "Fix rendering on x700 SE chips." + (LP: #151974) + + -- Timo Aaltonen Wed, 30 Jan 2008 13:18:23 +0200 + +mesa (7.0.2-4ubuntu1) hardy; urgency=low + + * Merge from debian unstable (LP: #151974), remaining changes: + - Change maintainer address. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + + -- Timo Aaltonen Tue, 29 Jan 2008 12:09:30 +0200 + +mesa (7.0.2-4) unstable; urgency=low + + * Update to mesa_7_0_branch head (commit 48ae5cf0). + * Add Vcs-Git, Vcs-Browser and Homepage fields in debian/control. + + -- Julien Cristau Thu, 17 Jan 2008 22:23:06 +0100 + +mesa (7.0.2-3ubuntu1) hardy; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer address. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + * debian/control: Do not build-depend on gcc-3.4 anymore. + * Drop 110_ubuntu_use_gcc-3.4_for_i965.patch + + -- Timo Aaltonen Sat, 05 Jan 2008 00:45:31 +0200 + +mesa (7.0.2-3) unstable; urgency=low + + * Update to mesa_7_0_branch head (commit 0107acde). + * Bump Standards-Version to 3.7.3. + * Move libgl1-mesa-swx11-dbg, mesa-common-dev and libosmesa6-dev to section + libdevel. + * libgl1-mesa-swx11 conflicts with libgl1-mesa-glx. Move it and + libgl1-mesa-swx11-dev to priority extra. + * Fix typo in mesa-common-dev's long description. + + -- Julien Cristau Tue, 18 Dec 2007 19:13:18 +0100 + +mesa (7.0.2-2ubuntu1) hardy; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer address. + - Add gcc-3.4 as a build dependency for amd64, i386 and lpia. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + - Add 110_ubuntu_use_gcc-3.4_for_i965.patch + + -- Timo Aaltonen Fri, 16 Nov 2007 09:00:24 +0200 + +mesa (7.0.2-2) unstable; urgency=low + + [ Julien Cristau ] + * Don't set -fno-strict-aliasing in configs/debian-default. It is set + upstream now. + * Workaround gcc ICE on hppa: build libOSMesa with -O0 (see bug#451047). + * Add build-dep on libxext-dev. Thanks, Timo Aaltonen! + + -- Brice Goglin Tue, 13 Nov 2007 21:43:40 +0100 + +mesa (7.0.2-1ubuntu2) hardy; urgency=low + + * Add libxext-dev to Build-Depends. + + -- Timo Aaltonen Mon, 12 Nov 2007 14:50:38 +0200 + +mesa (7.0.2-1ubuntu1) hardy; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer address. + - Add gcc-3.4 as a build dependency for amd64, i386 and lpia. + - Drop lesstif-dev from Build-Depends. + - Comment out GLw libs from control. + - Add lpia to -dri and -dri-dbg package in debian/control. + - Add lpia to ARCH_X86 in configs/debian-dri-default. + - Add 101_ubuntu_hidden_glname.patch + - Add 102_ubuntu_no_glw.patch + - Add 110_ubuntu_use_gcc-3.4_for_i965.patch + + -- Timo Aaltonen Mon, 12 Nov 2007 12:55:33 +0200 + +mesa (7.0.2-1) unstable; urgency=low + + * New upstream release. + + Fix Blender crash in triangle_twoside(), closes: #439668, #446315. + + Fix crash in _generic_read_RGBA_span_RGB565_MMX(), closes: #445313. + + Fix the new __gluInvertMatrix() function, closes: #440137 ,#441071. + + Refresh 03_optional-progs-and-install.patch since libGLU is not + built when building progs/xdemos. + + Refresh 04_cleanup-osmesa-configs.patch. + + Drop 05_static-nonpic.patch,, applied upstream. + + Remove DESTDIR from INSTALL_DIR in configs/debian-default since + the upstream Makefiles now support DESTDIR. + * Add myself to Uploaders. + + -- Brice Goglin Sun, 11 Nov 2007 11:53:26 +0100 + +mesa (7.0.1-2) unstable; urgency=low + + * Update to latest git (from mesa_7_0_branch) + + adds support for some new intel chipsets (i915 and i915_tex dri drivers) + (closes: #437333) + + broken inline asm in dri drivers fixed (closes: #423739) + + -- Julien Cristau Tue, 28 Aug 2007 12:11:30 +0200 + +mesa (7.0.1-1ubuntu3) gutsy; urgency=low + + * Add lpia to -dri and -dri-dbg package in debian/control. + * Add lpa top ARCH_X86 in configs/debian-dri-default. + + -- Tollef Fog Heen Fri, 12 Oct 2007 14:12:21 +0200 + +mesa (7.0.1-1ubuntu2) gutsy; urgency=low + + * Add fix-965-vblank.patch, pulled from upstream + b3fc9a1585f390274fa26b3e3f80bc6d16f4388a which fixes missed vbl + interrupts on Intel i965 hardware. + + -- Kyle McMartin Wed, 3 Oct 2007 11:11:22 -0400 + +mesa (7.0.1-1ubuntu1) gutsy; urgency=low + + * Merge from debian unstable, remaining changes: + - Change maintainer to Ubuntu + - Add gcc-3.4 as a build dependency for lpia. + - Add support for Intel 945GME, G33, Q33, Q35 + + 200_945gme.patch, upstream a74eec5af5397b612d60dd4b0d81666027f19bb0, + ad6351a994fd14af9d07da4f06837a7f9b9d0de4 + + 201_g33.patch, upstream 8331d9d7aa7cde7126d38d4e1eb5fe8a168077f3 + - Comment out GLw libs from control file + - Dropped Ubuntu addition of conflicts of libgl1-mesa-glx against + libgl1-mesa-swx11, since Debian has hadded a shlibs file for + libgl1-mesa-swx11-i686 + + -- Bryce Harrington Wed, 15 Aug 2007 15:08:32 -0700 + +mesa (7.0.1-1) unstable; urgency=low + + * New upstream release. + * Upload to unstable. + + -- Julien Cristau Thu, 09 Aug 2007 11:56:16 +0200 + +mesa (7.0.1~rc2-1) experimental; urgency=low + + [ David Nusinow ] + * New upstream release candidate + * Bite the bullet and add myself to uploaders + + [ Julien Cristau ] + * Modify the short descriptions of various packages so they fit in .changes + files without being cut off. Thanks, Marc 'HE' Brockschmidt! + * Add a shlibs file for libgl1-mesa-swx11-i686. + + -- Julien Cristau Fri, 27 Jul 2007 20:17:48 +0200 + +mesa (7.0.0-0ubuntu3) gutsy; urgency=low + + * Add gcc-3.4 as a build dependency for lpia. + + -- Matthias Klose Tue, 07 Aug 2007 17:15:37 +0000 + +mesa (7.0.0-0ubuntu2) gutsy; urgency=low + + [ Kyle McMartin ] + * Add support for Intel 945GME, G33, Q33, Q35 + - 200_945gme.patch, upstream a74eec5af5397b612d60dd4b0d81666027f19bb0, + ad6351a994fd14af9d07da4f06837a7f9b9d0de4 + - 201_g33.patch, upstream 8331d9d7aa7cde7126d38d4e1eb5fe8a168077f3 + + -- Kyle McMartin Tue, 03 Jul 2007 19:32:39 +0000 + +mesa (7.0.0-0ubuntu1) gutsy; urgency=low + + [ Bryce Harrington ] + * New upstream release + - Adds OpenGL 2.0 and 2.1 API support. + - Fixed a few fog-related bugs. + - Fixed broken GLSL mix() function. + - Fixed broken GLSL exp() functions. + - Fixed GLSL mod4(vec4, vec4) bug. + - Implemented GLSL asin(), acos(), atan() functions. + - Fixed an R300 driver bug that caused Xorg composite manager to + crash + - Fixed R300 vertex program/matrix bug (fdo# 10848) + - GLSL dFdx() and dFdy() work for fragment program inputs now + (texcoords) + - Fixed potential crash when specifying an invalid texture unit as a + sampler + - Fixed incorrect GLX protocol request for glXDestroyPBuffer() + (fdo# 10983) + - ARB vp state.light[n].half value was incorrect (fdo# 10987) + - Fixed a positional light source bug (fdo# 11009) + - Fixed point size attenuation problem (fdo# 11042) + - Fixed problem where glPopAttrib didn't restore texture object's + LOD bias (fdo# 11049) + - Fixed a TLS / TEXTREL problem (fdo# 7459) + - Some texture code consolidation and simplifiction + - R300 driver clean-ups. + + [ Sarah Hobbs ] + * Added a conflicts of libgl1-mesa-glx against libgl1-mesa-swx11, and vice + versa + + -- Sarah Hobbs Tue, 26 Jun 2007 15:32:00 +1000 + +mesa (6.5.3-1ubuntu1) gutsy; urgency=low + + * Update Maintainer for Ubuntu + + [ Kyle McMartin ] + * Merge with Debian experimental: + - Remove lesstif-dev from Build-Depends (Timo Aaltonen) + - Comment out GLw libs from control file + - Add 102_ubuntu_no_glw.patch to remove lesstif build depends + - Add libxext-dev to Build-Depends (Paul Sladen) + - Add gcc-3.4 [i386 amd64] to Build-Depends (Ben Collins) + - Add 110_ubuntu_use_gcc-3.4_for_i965.patch (Timo Aaltonen) + - Add 101_ubuntu_hidden_glname.patch + - Add 112_fedora-hush-synthetic-visual-warning.patch (Adam Jackson) + + * Dropped patches: + - 103_ubuntu_fd.org-9686-fog.patch merged upstream + - 104_r300_call_radeonsetcliprects.patch merged upstream + - 105_radeon_call_radeonsetcliprects.patch merged upstream + - 106_r200_call_radeonsetcliprects.patch merged upstream + - 107_r200_simplify_r200setcliprects.patch merged upstream + - 111_unichrome_remove_xdrawoffset.patch merged upstream + + -- Kyle McMartin Fri, 25 May 2007 16:43:31 +0000 + +mesa (6.5.3-1) experimental; urgency=low + + [ David Nusinow ] + * New upstream release + + [ Julien Cristau ] + * Cherry-pick commit 65faf023679988f93da82b4c7ebdc689f2094459 by Michel + Dänzer to fix r300 crash. + + -- Julien Cristau Mon, 21 May 2007 11:34:51 +0200 + +mesa (6.5.3~rc3-1) experimental; urgency=low + + [ Brice Goglin ] + * Split out libGLw libs and headers from libgl1-mesa-swx11 and ship both + static and shared libraries, creating libglw1-mesa and libglw1-mesa-dev + (closes: #374904). + + [ Julien Cristau ] + * New upstream release candidate. + + 06_fix_texture_data_corruption.patch, + 07_call_radeonSetCliprects_from_radeonMakeCurrent.patch, + 08_r300_update_window_state_when_bound_but_stamp_changed.patch, + 09_i915_always_enable_pixel_fog.patch: remove, included upstream. + + 01_fix-makefile.patch, 02_use-ieee-fp-on-s390-and-m68k.patch: refresh. + * Add build-dependencies on libxdamage-dev and libxfixes-dev. + * Resync debian/scripts/install-source.sh. + * Build mesa-swx11-source only in binary-indep. + * Update from upstream git (commit + dee1b0d5bbe91f83854813cbbcd3090327bcb5c2). + + -- Julien Cristau Wed, 25 Apr 2007 10:36:50 +0200 + +mesa (6.5.2-7) unstable; urgency=low + + [ Brice Goglin ] + * libgl1-mesa-dev does not need to depend on libgl1-mesa-dri, + libgl1-mesa-glx is enough (since their split in 6.4.1-0.1); + closes: #432081. Thanks, Samuel Thibault! + + [ Julien Cristau ] + * libgl1-mesa-dev Depends on libgl1-mesa-glx (>= ${source:Upstream-Version}) + instead of >= ${Source-Version}. This way it's still installable on + architectures where mesa isn't built yet when a minor revision is + uploaded. + + -- Julien Cristau Wed, 11 Jul 2007 05:50:45 +0200 + +mesa (6.5.2-6) unstable; urgency=low + + * libgl1-mesa-swx11 needs to depend on libosmesa6 (>= 6.5.2-1) because + it used to contain libOSMesa.so.6. This means that programs linked + against this lib got a dependency on -swx11 which was broken since + 6.5.2-1. + * Fix build on hurd-i386 (build libgl1-mesa-glx without dri support and + don't build the dri drivers); closes: #420403. Thanks, Samuel Thibault! + + -- Julien Cristau Thu, 05 Jul 2007 00:56:35 +0200 + +mesa (6.5.2-5) unstable; urgency=low + + [ Brice Goglin ] + * Add 07_call_radeonSetCliprects_from_radeonMakeCurrent.patch + (closes: #420164). Thanks to Christian Ohm. + * Add 08_r300_update_window_state_when_bound_but_stamp_changed.patch + * Add 09_i915_always_enable_pixel_fog.patch + + -- Julien Cristau Fri, 18 May 2007 13:36:25 +0200 + +mesa (6.5.2-4) unstable; urgency=low + + [ Julien Cristau ] + * debian/control: libgl1-mesa-dri now suggests libglide3, with an + explanation in the description (closes: #387339). + * Upload to unstable. + + [ Brice Goglin ] + * Add 06_fix_texture_data_corruption.patch (closes: #412346). + + -- Julien Cristau Fri, 20 Apr 2007 05:57:35 +0200 + +mesa (6.5.2-3) experimental; urgency=low + + * Set LIB_DIR and EXTRA_LIB_PATH in configs/debian-default to override + settings in configs/linux-x86-64. This fixes a FTBFS on amd64, thanks to + Marc 'HE' Brockschmidt for the report (closes: #410118). + + -- Julien Cristau Wed, 7 Feb 2007 23:04:28 +0100 + +mesa (6.5.2-2) experimental; urgency=low + + * Sync Section/Priority for all packages with the override. + * Build the arch:all debs in binary-indep, and use the debhelper -s option + for commands in binary-arch, to fix FTBFS on non-i386 archs, thanks to + Marc 'HE' Brockschmidt (closes: #409638). + * Add myself to Uploaders. + + -- Julien Cristau Sun, 4 Feb 2007 21:14:02 +0100 + +mesa (6.5.2-1) experimental; urgency=low + + [ Thierry Reding ] + * New upstream release. + * Set the Debian X Strike Force as maintainer. + * Add myself to uploaders. + * Build the i915tex DRI module on the i386 and amd64 architectures. + * Add patch 04_cleanup-osmesa-configs that makes the OSMesa configurations + behave as expected. + * Add patch 05_static-nonpic to build static libraries without -fPIC. + * Make debugging symbol packages depend on the corresponding binary package + and put them into the libdevel section. + * Bump shlibs file for the libosmesa6 package to account for added symbols. + Thanks Julien Cristau. + * Build the DRI modules with the default optimization flags. Thanks Julien + Cristau. + * mesa-common-dev now ships the GLX header files so it needs to replace + libgl1-mesa-swx11-dev and libgl1-mesa-dev. Thanks Julien Cristau. + * All OSMesa libraries were moved to the libosmesa6 and libosmesa6-dev + package, so have them replace libgl1-mesa-swx11, libgl1-mesa-swx11-dev and + mesa-common-dev respectively. Thanks Julien Cristau. + + [ Julien Cristau ] + * Drop obsolete depends on xlibs. + + -- Thierry Reding Thu, 11 Jan 2007 15:06:52 +0100 + +mesa (6.5.2~rc3-0.1) experimental; urgency=low + + * Non-maintainer upload. + * Update to latest upstream release candidate. + + -- Thierry Reding Fri, 1 Dec 2006 01:06:28 +0100 + +mesa (6.5.2~rc2-0.1) experimental; urgency=low + + * Non-maintainer upload. + * New upstream release candidate: + + Refresh 02_use-ieee-fp-on-s390-and-m68k.patch. + * Add manual pages for the glxdemo, glxgears, glxheads and glxinfo + utilities (Closes: #385463). + + -- Thierry Reding Wed, 22 Nov 2006 20:49:06 +0100 + +mesa (6.5.2~rc1-0.1) experimental; urgency=low + + * Non-maintainer upload. + * New upstream release candidate. + * Update patches: + + Drop hunk #2 of 01_fix-makefile.patch, applied upstream. + + Drop 03_handle-sync-and-dont-unlock-display.patch, applied upstream. + * Bump build-dependency on libdrm-dev (>= 2.2.0). + * Use the new upstream minstall utility to install files and directories. + Using /usr/bin/install would result in a symlink's target being copied + instead of the symlink. + + -- Thierry Reding Sat, 18 Nov 2006 22:23:04 +0100 + +mesa (6.5.1-0.6) experimental; urgency=low + + * Non-maintainer upload. + * Rewrote the debian/rules file to make it easier to understand. + * Provide i686 optimized versions in libgl1-mesa-swx11-i686 instead of in + libgl1-mesa-swx11. + * Statically link libOSMesa with the software rasterization code from libGL + so that it works independently of the installed libGL. (Closes: #387706) + * Make libosmesa6-dev depend on mesa-common-dev because it only needs the + gl.h header file and no libGL anymore. + * Move glx*.h headers from libgl1-mesa(-swx11)-dev into mesa-common-dev + because both packages provide identical files. + * Add debugging symbol packages for libgl1-mesa-swx11, libgl1-mesa-glx and + libgl1-mesa-dri. + * Repack the contents of the three Mesa tarballs (MesaDemos, MesaGLUT and + MesaLib) as the original source tarball. (Closes: #392715) + * Make mesa-common-dev depend on libx11-dev. + * Provide a new package: mesa-utils. These utilities are shipped in the + MesaDemos package so mesa is the right package to provide them. + + -- Thierry Reding Sat, 18 Nov 2006 18:50:07 +0100 + +mesa (6.5.1-0.5) unstable; urgency=low + + * Non-maintainer upload. + * Build with -fno-strict-aliasing to fix misbuild of i965_dri.so + (closes: #394311). Thanks to Michel Dänzer for the fix, and to Ryan + Richter for the report and testing. + + -- Julien Cristau Wed, 3 Jan 2007 13:48:20 +0100 + +mesa (6.5.1-0.4) unstable; urgency=medium + + * Non-maintainer upload (and brown paper bag release). + * _Depend_ on libx11-dev from libgl1-mesa-dev; revert previous change. + Fixes FTBFS in other packages. (Really Closes: #396498) + + -- Steinar H. Gunderson Sat, 11 Nov 2006 13:55:20 +0100 + +mesa (6.5.1-0.3) unstable; urgency=medium + + * Non-maintainer upload. + * Build-depend on libx11-dev; fixes FTBFS. (Closes: #396498) + + -- Steinar H. Gunderson Wed, 8 Nov 2006 20:58:40 +0100 + +mesa (6.5.1-0.2) unstable; urgency=low + + * Non-maintainer upload + * Disable generation of SSE instructions (closes: #390560) + * Remove duplicate and unused build configurations + * Remove extra source files left from CVS snapshots (closes: #389283) + * Enable i965 DRI driver on i386 and amd64. Thanks to Ryan Richter + for the patch. (closes: #392030) + * Enable Unichrome DRI driver on amd64 (closes: #391900) + * Enable FFB DRI driver on sparc, not i386 (closes: #388025) + * Consistently compile C sources as C99 (closes: #373623) + * Fix X display locking error in GLX. Thanks to Josh Triplett for + the patch. (closes: #391681) + + -- Ben Hutchings Fri, 13 Oct 2006 02:25:52 +0100 + +mesa (6.5.1-0.1) unstable; urgency=low + + * New upstream version + * Build-dep on x11proto-gl-dev >= 1.4.8 + * Stuff not in the upstream tarballs + + os2 glut stuff + + docs/gears.png + * Bump libdrm-dev build-dep to >= 2.0.2 + * Add libdrm cflags to the debian-dri config. This allows the build system + to find drm.h + * Make sure that libGl looks for the dri drivers in the proper location. Do + this by setting the appropriate variables in the debian config + * Re-add s390 and m68k to the USE_IEEE test in src/mesa/main/imports.h. This + package seriously needs to store patches somewhere that are easy to find + and re-apply. + * Add patch from Cyril Brulebois to allow package to build on HURD, which + lacks DRI and directfb. This includes not using lib-directfb in the + build-depends for hurd-i386. It also creates a new debian config, + debian-indirect, which is used when building for HURD. This config is + invoked in the debian-dri config on hurd-i386. Thanks to Cyril Brulebois + for the patch, Michael Banck, Michel Dänzer, and Samuel Thibault for + input on an appropriate fix. (closes: #358065) + + -- David Nusinow Mon, 25 Sep 2006 21:21:47 -0400 + +mesa (6.5.0.cvs.20060524-1.1) unstable; urgency=medium + + * Non-maintainer upload. + * Upload mesa 6.5 cvs to unstable, because we need it for Xorg 7.1. + * Upload with medium urgency instead of high, since this is a new + upstream that should get some testing in unstable in spite of the + multiple RC bugfixes. + * Update debian/copyright with the full text of the SGI Free B and SGI + MIT-style licenses in use in the package, and take a stab at + cleaning up the list of paths and licenses. + Closes: #368562. + * Make mesa-common-dev Replaces: xlibosmesa-dev from sarge. + Closes: #384057. + * Fix libgl1-mesa-glx to not Provides: libgl1-mesa-dri, since it + definitely doesn't provide DRI support and this Provides: breaks + upgrades from sarge. Closes: #384282. + * debian/libgl1-mesa-swx11.shlibs: create a static shlibs file, + because libOSMesa.so.6 is not provided by all implementations of + libGL and so needs a separate shlibs declaration. Also make + libgl1-mesa-glx the default alternative instead of libgl1-mesa-swx11 + for consistency even when building against libgl1-mesa-swx11, + because to the extent these are interchangeable (i.e., 99%...), + there should be no reason to prefer one over the other -- and to the + extent that they aren't interchangeable, it's wrong to list libgl1 + as an alternative dependency at all. Closes: #386185. + * Don't provide shlibs at all for libgl1-mesa-swx11-dbg; this is an + unnecessary duplication of the existing libgl1-mesa-swx11 shlibs + since packages should not really be linking against /usr/lib/debug/ + separately. + * src/mesa/tnl/t_vb_render.c: Drop a pointless printf() in the + RENDER_LINE macro, getting rid of copious debug output on console. + Closes: #369895. + * libgl1-mesa-swx11 has no reason to depend on libglu, anything that + wants libglu will have its own dependency on it; drop this + hard-coded dependency from debian/control. + * Have libglu1-mesa-dev Provides: xlibmesa-glu-dev, since it's the + successor to that package and xlibmesa-glu-dev is still referenced + in a number of places and this makes for more reliable builds than + depending on alternatives without requiring another dummy -dev + package from xorg. + * Replace references to Source-Version in debian/control with either + binary:Version or source:Version, depending on whether the + relationship references an arch: any or arch: all package, making + mesa binNMU-safe; add build-depends on dpkg-dev (>= 1.13.19) to + ensure these substvars are available. + + -- Steve Langasek Fri, 15 Sep 2006 15:51:16 -0700 + +mesa (6.5.0.cvs.20060524-1) experimental; urgency=low + + * The "-O666 -fwater-c00ling -DBE_F4ST" release + * New pull from CVS + * Merge back and forth with 6.4.2-1 + * configs/debian*_i386: disabled, optimized build fuxxored. + + -- Marcelo E. Magallon Wed, 24 May 2006 14:12:13 -0600 + +mesa (6.5.0.cvs.20060512-0.0.1) experimental; urgency=low + + * New upstream release (6.5.0) + * Pulled CVS as of 2006-05-12 + * debian/control: remove DirectFB packages + + -- Marcelo E. Magallon Fri, 12 May 2006 15:23:49 -0600 + +mesa (6.4.2-1) unstable; urgency=low + + * The "please, please, please don't hate me" release. + * New upstream release. + * Ack NMUs + * debian/control: mesa-common-dev Replaces xlibmesa-gl-dev (<< 1:7) + AGAINST MY BETTER JUDGEMENT. The problem here is gratuitous package + renames within a system that does not support them. (closes: + bug#362063) + * debian/control: hurd-i386 doesn't have drm. Doesn't fix #358065, + yet. + * bin/mklib: fix from Robert Millan to support hurd-i386 and + GNU/kFreeBSD. Thanks Robert. (closes: bug#358066) + * src/glx/x11/indirect_vertex_array.c, src/mesa/main/glheader.h, + src/mesa/drivers/dri/common/glcontextmodes.c: fix broken indirect + rendering on 64-bit platforms. Thanks Aaron M. Ucko. (closes: + bug#364228) + * debian/control: b-d on x11proto-gl-dev. Please don't hate me! + * debian/control: Standards-Version: 3.7.2 + * debian/rules: export DEB_HOST_ARCH + * configs/debian-dri: use DEB_HOST_ARCH to decide if certain DRI drivers + should be built or not. + + Built only for i386: i810 i830 sis. + Rationale: integrated chipsets available only for i386 processors. + + Built only for i386: ffb. + Rationale: Michel Dänzer said so, no idea why. + + Built only for i386, amd64: i915. + Rationale: Apparently this is available in the 64-bit Intel chipset. + Please file a bug report stating which drivers should be included/excluded + for which architectures. Positive lists are preferred. If possible state + why. + * debian/mesa-swx11-source.install: nuke this abomination. Dinamically + generate the list at build time. + * debian/drivers.map: add gl-debian-dri_i386 + * debian/README.build: updated, add big friendly letters in short sentences. + Perhaps I can read it myself this way... + * debian/rules, configs/debian, configs/debian-dri, configs/debian_i386, + configs/debian-dri_i386, debian/libdir.map, debian/drivers.map: hack in + support for variable driver's dir. If you want this for your pet + architecture please provide BOTH configs/debian_arch and + configs/debian-dri_arch. If you just want to include/exclude DRI drivers + on your architecture look in configs/debian-dri. + * configs/debian*_i386: disabled, optimized build fuxxored. + * debian/rules: remove misguided Perl construct, replace by something + simpler in shell. I actually meant to do something else with the Perl + thing, but got distracted and forgot about it. Thanks Aaron M. Ucko! + * debian/rules: make it work like debian/README.build says it works wrt to + building optimized targets. + + -- Marcelo E. Magallon Tue, 16 May 2006 18:07:53 -0600 + +mesa (6.4.1-0.4) unstable; urgency=low + + * NMU + * Add versioned conflict between libgl1-mesa-dri and xlibmesa-dri so that + the xlibmesa-dri transitional upgrade package works + + -- David Nusinow Mon, 6 Mar 2006 21:46:18 -0500 + +mesa (6.4.1-0.3) unstable; urgency=low + + * NMU + * Add s390 and m68k to the USE_IEEE test in src/mesa/main/imports.h. + (closes: #349437) + + -- David Nusinow Sat, 11 Feb 2006 17:59:26 -0500 + +mesa (6.4.1-0.2) unstable; urgency=low + + * NMU + * Re-add dh_installdirs call to binary-indep target so that we get + arch-specific dirs for the mesa-swx11-source package + * Remove makedepend from build-depends. Now we'll just build-dep on xutils + to get the app, which will translate over to our own xorg 7.0 plans. + + -- David Nusinow Tue, 31 Jan 2006 19:21:12 -0500 + +mesa (6.4.1-0.1) unstable; urgency=low + + [ Marcelo E. Magallon ] + * debian/control: build-depend on xutils + * include/GL/glx{int,proto,md,tokens}.h: missing upstream (closes: bug#326466) + * debian/libgl1-mesa-dri-dev.install: install GLX include files here, too. + * debian/rules: GLU and GLW don't have arch-specific targets. + + [ Daniel Stone ] + * New upstream version, incorporating changes from Ubuntu 6.3 packaging. + * Rename packages: + - mesag3 -> libgl1-mesa-swrast + - mesag-dev -> libgl1-mesa-swrast-dev + - libgl1-mesa-dri -> libgl1-mesa + - libgl1-mesa-dri-dev -> libgl1-mesa-dev + - libgl1-mesa-dri still exists, but now contains the DRI modules only. + * Drop dependency *from* mesa-common-dev on libgl1-mesa-dev and + libglu1-mesa-dev; it should be the other way around. (closes: #336565) + * Add Build-Depends on pkg-config to get flags from libdrm, and libexpat-dev + for DRI configuration. Break out xlibs-dev Build-Depends to the + individual libraries required. + * Bump libdrm-dev Build-Depends to >> 1.0.5, in order to get new + via_drm.h to build the unichrome DRI driver. + * Configs: pare DRI drivers down to a sensible set for each architecture. + * Remove completely broken Glide target, which caused FTBFS. + * Add mesa-swrast-source package, providing the source for the software + rasteriser for libGLcore in the X server. + * Drop tight libosmesa6 -> libgl1-mesa-swrast Depends, replace with + shlibs:Depends. + + [ David Nusinow ] + * New upstream version (6.4.1) (closes: #232665) + * Merge changes from Ubuntu version 6.4.1-0ubuntu1. + (closes: #341479, #340168, #334742) + + Add new files required by xorg-server GL build to mesa-swrast-source. + * NMU to begin getting Xorg 7.0 in to Debian + * Change libgl1-mesa-swrast Depends on libx11-6-dev to libx11-dev. + * Change libgl1-mesa-swrast to be named libgl1-mesa-swx11 + * Change libgl1-mesa to be named libgl1-mesa-glx + * mesa-swrast-src.install stop looking for the swx11 dir and look for swrast + + -- David Nusinow Sat, 21 Jan 2006 21:43:37 -0500 + +mesa (6.3.2-2.1) unstable; urgency=low + + * Non-maintainer upload. + * Adjust Build-Depends: + + xlibs transition (Closes: #347129). + + xutils, xlibmesa-gl-dev (Closes: #326466). + * mesag-dev: Depends: libx11-dev (Closes: #347205). + + -- Christoph Berg Fri, 20 Jan 2006 20:45:43 +0100 + +mesa (6.3.2-2) unstable; urgency=low + + * debian/rules: build only whatever needs to be build according to + debian/control. + * debian/libdir.map: it's usr/lib/debug not usr/lib/dbg + * debian/rules: select optimized targets for the current host architecture + only (thanks Michel!) + * debian/README.build: reword some of the directions, add more info. + * debian/control: forgot to add CPR relationships in the new packages + (thanks Michel!) + * debian/control: Set maintainer to pkg-mesa-devel, add myself as uploader + + -- Marcelo E. Magallon Sun, 28 Aug 2005 14:41:15 -0600 + +mesa (6.3.2-1) unstable; urgency=low + + * New upstream + * configs/debian-dri: new target + * debian/control: add build-depends on libdrm-dev + * debian/rules: pass SRC_DIRS instead of SUBDIRS on the command line. + This allows for configurations to override the command line in a + sane way. + * configs/debian-dri: override SRC_DIRS + * configs/debian: add -D_GNU_SOURCE (required by dri drivers) + * debian/control, debian/rules: drop glide out of this package, it + will be moved to the mesa-legacy package, forked from 6.2.1-7. + * debian/drivers.map, debian/rules: take into account that some + drivers have external components. + + To be fixed: debian/drivers.map hardcodes locations + * debian/control: libgl1-mesa-dri, libgl1-mesa-directfb: new drivers + * dh_makeshlibs for libgl1-mesa-dri and libgl1-mesa-directfb + * debian/control: priority is optional... again... + + -- Marcelo E. Magallon Sun, 21 Aug 2005 17:13:19 -0600 + +mesa (6.2.1-7) unstable; urgency=low + + * Previous upload got lost somewhere + + bin/mklib: add GNU/kFreeBSD, patch from Aurelien Jarno (closes: + bug#307154) + + recompile with newer g++ + + -- Marcelo E. Magallon Tue, 02 Aug 2005 06:47:20 -0600 + +mesa (6.2.1-6) unstable; urgency=low + + * bin/mklib: add GNU/kFreeBSD, patch from Aurelien Jarno (closes: + bug#307154) + * recompile with newer g++ + + -- Marcelo E. Magallon Sun, 24 Jul 2005 11:47:16 -0600 + +mesa (6.2.1-5) unstable; urgency=low + + * debian/rules: big mess up, files are not being moved to their proper + places. I naively assumed that command-line options to debhelper + commands would override DH_OPTIONS, that is, that having + DH_OPTIONS=-i (as suggested in the documentation) would mean + something like "use -i unless -p is passed on the command line". It + actually means "use -i in addition to -p passed on the command + line", which does not make any sense, but is consistent with the + wording in the documentation. (closes: bug#306499, bug#306918, + bug#307095) + + -- Marcelo E. Magallon Sun, 01 May 2005 09:45:12 -0600 + +mesa (6.2.1-4) unstable; urgency=low + + * debian/control: fix description to reflect the exact content and + purpose of package (libosmesa-dev, mesag-dev). + * debian/rules: DH_OPTIONS=-s added to binary-arch target. (closes: + bug#306091) + + -- Marcelo E. Magallon Sat, 26 Mar 2005 08:03:44 -0600 + +mesa (6.2.1-3) unstable; urgency=low + + * debian/control: try to match the override file. If mesa is "extra" + (for whatever reason), all the packages should be extra. + * debian/rules: quick workaround for left-over libGL.so in GLU -dev + package. + + -- Marcelo E. Magallon Thu, 24 Mar 2005 19:35:34 -0600 + +mesa (6.2.1-2) unstable; urgency=low + + * The "thank you so much, I'm still voting against you" release. + * debian/rules: correct artifact of me not having had a proper + pbuilder environment to build stuff on and the repackaging from the + previous release. The -glu- and -glw- targets now explicitly depend + on the matching -gl- target, and symlinks are placed in the build + directories in order to actually have a libGL.so to make ld happy + when creating the libraries. + * debian/rules: uncomment dh_install :-\ There was a reason why I had + commented that out... + * First change closes: bug#298922 + * Second change closes: bug#300302, bug#300284, bug#300430 + * debian/control: "An X", whatever, I've been corrected multiple times + in both ways (translators beware). (closes: bug#300012) + + -- Marcelo E. Magallon Sun, 20 Mar 2005 22:03:29 -0600 + +mesa (6.2.1-1) unstable; urgency=low + + * The "autobuilders, please please please don't hate me" release. + * New upstream. + * Repackage: + + Fall prey to debhelper + + Entries below this one preserved for historical reasons or + sentimental value, pick as many as you want. They bear NO + relation to the actual packages! + * configs/debian, configs/debian-debug, configs/debian-debug-i386, + configs/debian-glide, configs/debian-glide-i386, configs/debian-i386, + configs/debian-osmesa16, configs/debian-osmesa16-static, + configs/debian-osmesa32, configs/debian-osmesa32-static, + configs/debian-static, configs/debian-static-i386: new files. + * configs/debian-sparc: Dave Miller confirmed that the sparc assembly + files do work on Linux. I don't know where to install the optimized + libraries, so the file doesn't actually exist. Please read + debian/README.build if you want to have a sparc-optimized library. + * debian/control: GGI and glide2 are gone. glide is glide3. + * debian/rules: modify shlibs file for the glide3 target to require glide3 + and only glide3 because that library exports functions not available in + other libGLs. Rationale: if someone is compiling a Debian package and + uses the glide target either he doesn't know what he is doing or he knows + exactly what he is doing. In the first case the package should not be + installable and in the second case the package requires this particular + version. + * debian/control: libgl1-mesa-glide3-dev does NOT provide a proper OpenGL + development environment (see above). + * PCR is bound to be wrong... *sigh* + + -- Marcelo E. Magallon Sat, 25 Dec 2004 14:50:02 -0600 + +mesa (6.0.1-1) unstable; urgency=low + + * New upstream release. + * debian/rules: redid a bunch of stuff in order to support new build system + without autoconf and automake stuff. The next version is going to change + this _again_. + + -- Marcelo E. Magallon Sun, 11 Apr 2004 07:00:19 -0600 + +mesa (5.0.0-5.1) unstable; urgency=low + + * Non-Maintainer Upload. + * Rename "GGIMesa"-references in src/GGI/default/Makefile.am to + "MesaGGI", which makes the package build again with newer libtool. + (Closes: #213836) + + -- Steinar H. Gunderson Sun, 15 Feb 2004 17:37:08 +0100 + +mesa (5.0.0-5) unstable; urgency=low + + * debian/control: yank and put error? Remove hard-coded + nvidia-glx-dev from mesag-glide2-dev dependencies. + + -- Marcelo E. Magallon Sun, 09 Feb 2003 10:31:51 +0100 + +mesa (5.0.0-4) unstable; urgency=low + + * debian/rules: fix typo in definition of GLIDE_ARCHS. (closes: bug#179622) + + -- Marcelo E. Magallon Mon, 03 Feb 2003 20:19:12 +0100 + +mesa (5.0.0-3) unstable; urgency=low + + * The "it's amazing how people pick severities" release + * debian/control: mesa-common-dev conflicts with xlibmesa-dev. Actually put + dependency of mesa-common-dev on the mesa-*-dev packages to avoid having + to track other libgl-dev packages popping up. IMO this is less error + prone. You can't install mesa-common-dev without installing mesa-*-dev, + and those packages conflict with other libgl-dev packages. (closes: + bug#177996) + * Rename libglu1c102 to libglu1-mesa; the libglu1c102 is incorrent since + this library does not export C++ functions. Sorry about the mess. + * Rename libglu1-dev to libglu1-mesa-dev to be consistent + * debian/rules: use grep-dctrl to extract architectures from debian/control + * debian/control: add grep-dctrl to build-depends + * debian/shlibs.libglu: libglu1-mesa | libglu1 + * debian/rules: install include/GL/xmesa.h in /usr/include/GL/xmesa.h; I'm + not 100% sure this is the right thing to do, but it's a niche so I don't + think it will actually make trouble (closes: bug#148866) + * debian/rules: install include/GL/glx*.h in the common package. (closes: + bug#178562) + * debian/rules: nasty hack to work arround libtool's idea of how libraries + should be linked (closes: bug#178514) + * debian/rules: even nastier hack. Getting environment variables to + percolate thru all the make calls isn't getting anywhere. + * si-glu/Makefile.am: export only glu.* symbols + * si-glu/Makefile.am: add -lm to link line + * src/Makefile.am: god damm it. If you use libm link to it! + * debian/control: mesa-common-dev depends on libglu1-mesa-dev to satisfy + libgl-dev's requirements + + -- Marcelo E. Magallon Mon, 27 Jan 2003 17:15:25 +0100 + +mesa (5.0.0-2) unstable; urgency=low + + * debian/control: Not funny, I'm sure I put lesstif and xlibs-dev in the + build-depends. CVS says I didn't. (closes: bug#176730) + * debian/control, debian/rules: regenerate auto-stuff (closes: bug#176729) + * debian/control, debian/rules: GCC C++ 3.2 transition (libglu1c102 -- ugly!) + * remove Makefile.in from CVS control + * si-glu/libnurbs/interface/Makefile.am: fix INCLUDES macro + + -- Marcelo E. Magallon Sun, 19 Jan 2003 00:48:32 +0100 + +mesa (5.0.0-1) unstable; urgency=low + + * New upstream release, it looks like glide and GGI are in working + condition again. + * FX patches from previous releases gone. They'll be back later. + * debian/rules: some clean ups. + * debian/control: add libglu1 packages + * debian/control: Standards-Version: 3.5.8 + * debian/rules: Build Xt widgets (if you need this stuff, you need to depend + on mesag-dev, libgl-dev is not enough) + * debian/control, debian/rules: add mesa-common-dev package + * debian/control, debian/rules: add osmesa packages. + + -- Marcelo E. Magallon Sun, 15 Dec 2002 12:28:49 +0100 + +mesa (4.0.3-1) unstable; urgency=low + + * New (and long delayed) upstream version + * Redid a bunch of FX patches, probably broke. + + -- Marcelo E. Magallon Thu, 03 Oct 2002 11:27:29 +0200 + +mesa (3.5-1) unstable; urgency=low + + * New upstream version. + * Redid patches. + * Disabled building GGI target. Someone with a good understanding of GGI + needs to write a driver for mesa. The old version doesn't cut it + anymore. + * Most makefiles won't work. Copied them out of CVS. + * src/Makefile.am: add -lm to library list. (closes: bug#102717) + * configure.in: adjust GLU's version info to match previous release. + + -- Marcelo E. Magallon Mon, 25 Jun 2001 22:13:40 +0200 + +mesa3 (3.4.2.1-4) unstable; urgency=low + + * So, here's the deal: the 3Dfx backend is going nowhere in 4.x and 5.x is + just arround the corner. Same thing for the GGI stuff. In order to leave + the people who need this stuff with _something_ to work with, I'll compile + those targets out of the mesa3 source package and the mesa package will + stuck to plain old X. + * debian/control, debian/rules: strip out all the parts concerning to mesa3g + and mesa3g-dev + * debian/control: update GGI architectures, let's see what happens + * debian/rules: special case alpha for stripping options. Chris, did you + ever figure out what the problem actually is? (closes: bug#99284) + * debian/rules: hereby I decree that everything in etc is a conffile. Die + future bugs, die!. + * configure: fix ggi_libdir, ggi_confdir (closes: bug#139598) + + -- Marcelo E. Magallon Sun, 29 Sep 2002 11:21:00 +0200 + +mesa (3.4.2.1-3) unstable; urgency=low + + * Actually install widgets on the mesag-dev package (closes: bug#98988) + + -- Marcelo E. Magallon Sat, 9 Jun 2001 16:39:36 +0200 + +mesa (3.4.2.1-2) unstable; urgency=low + + * src/X/xmesa1.c: I knew it, I knew it. This was bound to break. Stupid + typo. Restored MESA_GLX_FX (got renamed to GLX_FX accidentally, if you + have to know) (closes: bug#94114) + + -- Marcelo E. Magallon Mon, 21 May 2001 08:52:07 +0200 + +mesa (3.4.2.1-1) unstable; urgency=low + + * Upstream released 3.4.2. + * Hmmm... thought about it on my way home. The code to parse 3dfx.conf + is wrong. Redid. Still not tested. (closes: bug#94114) + * debian/README.Debian: document 3dfx.conf + + -- Marcelo E. Magallon Sat, 19 May 2001 11:57:33 +0200 + +mesa (3.4.2-1) unstable; urgency=low + + * New upstream version. + * debian/config.guess, debian/config.sub: newest versions from + http://subversions.gnu.org/cgi-bin/cvsweb/config (closes: bug#95338) + * GAAAAAAARGGH! src/X/xmesa1.c: horrible hack to use /etc/mesa/3dfx.conf + if there's no MESA_GLX_FX environment variable defined. I. Hate. + This. I'll make a deal with you: you find another of these things, + and you send me a nice tested patch. I don't have a 3DFX card and I + *HATE* uploading stuff I can't fully test. (closes: bug#94114) + * debian/rules: use the new files + * debian/rules: s/TMPDIR/DTEMPDIR/g + * gl3DfxSetDitherModeEXT from Zephaniah (closes: bug#65860) + * Disable GL_EXT_shared_texture_palette per default. Patch looks funny, + but I'll blindly trust Zephaniah. + * Hmmm... I hope Zephaniah tested this, because it broke in a rather silly + way at compile time. + * Fancy what people regard as "pretty important". + + -- Marcelo E. Magallon Fri, 18 May 2001 09:23:49 +0200 + +mesa (3.4.1-3) unstable; urgency=low + + * PLEASE SUBMIT NMUs TO THE BTS, DAMN IT! + * debian/control: exclude m68k from libggi2-dev build-dependency. + + -- Marcelo E. Magallon Sat, 17 Mar 2001 19:45:09 +0100 + +mesa (3.4.1-2) unstable; urgency=low + + * debian/control: add missing dependency on xlibs-dev and corrected the + one for libglide2-dev + + -- Marcelo E. Magallon Wed, 14 Mar 2001 00:21:42 +0100 + +mesa (3.4.1-1) unstable; urgency=low + + * New upstream version. + * New maintainer. (closes: bug#81139) + * Some fixes to get it to compile. + * debian/rules: some reorganization happened to allow me test different + builds better. + * debian/control: nuked widgets package, if you miss it, you are doing + something wrong. + * debian/rules: -dev packages will be missing some garbage they used to + install. If you miss any of those files, I'm fairly confident you + are doing something wrong. + * configure, ltmain.sh, aclocal.m4, acinclude.m4, ...: vicious hacks to + allow the GGI version to compile. + * TODO: add the widgets to the packages + * TODO: make OSmesa packages + + -- Marcelo E. Magallon Sat, 10 Feb 2001 18:34:13 +0100 + +mesa (3.2.1-1) unstable; urgency=low + + * New upstream version. + + -- James A. Treacy Mon, 31 Jul 2000 15:13:34 -0400 + +mesa (3.2-2) frozen unstable; urgency=low + + * add MMX and 3Dnow opts for x86. + + -- James A. Treacy Fri, 7 Jul 2000 16:06:43 -0400 + +mesa (3.2-1) frozen unstable; urgency=low + + * New upstream version. + * Made minor changes to README.3DFX. Closes bug#56827 + * Added symlinks for mesa widget libraries. Closes bug#63115 + + -- James A. Treacy Wed, 28 Jun 2000 11:21:09 -0400 + +mesa (3.1-17) frozen unstable; urgency=low + + * Fixed Makefile for demos in mesag-widgets-dev. Closes bug#62674 + + -- James A. Treacy Fri, 19 May 2000 13:23:00 -0400 + +mesa (3.1-16) frozen unstable; urgency=low + + * Add --prefix=/usr to ggi build. Closes bug#61705, #61486 + + -- James A. Treacy Wed, 12 Apr 2000 15:12:48 -0400 + +mesa (3.1-15) frozen unstable; urgency=low + + * Remove ggi from the build on m68k. Closes bug#59273 + + -- James A. Treacy Mon, 6 Mar 2000 13:20:29 -0500 + +mesa (3.1-14) frozen unstable; urgency=low + + * Fixed hard-coded location of config file in library. This is release + critical, even though no bug was filed (relates to bug#58267). + + -- James A. Treacy Mon, 28 Feb 2000 10:58:34 -0500 + +mesa (3.1-13) frozen unstable; urgency=low + + * Add missing ggi libraries. Closes bug#58267, #57760 + + -- James A. Treacy Thu, 24 Feb 2000 00:59:30 -0500 + +mesa (3.1-12) frozen unstable; urgency=low + + * Dependencies are now computed in a more intelligent way. Closes: bug#55861 + + -- James A. Treacy Fri, 21 Jan 2000 16:26:40 -0500 + +mesa (3.1-11) frozen unstable; urgency=low + + * Remove svgalib support from the software only package of mesa + + -- James A. Treacy Sat, 22 Jan 2000 05:33:13 +0000 + +mesa (3.1-10) frozen unstable; urgency=low + + * Fix the mesag3-glide2 postinst. Closes bug#55462 + + -- James A. Treacy Sat, 22 Jan 2000 02:06:27 +0000 + +mesa (3.1-9) frozen unstable; urgency=low + + * The ggi based packages are now built with the other versions of mesa. Closes: bug#49218, #55221 + + -- James A. Treacy Sat, 15 Jan 2000 22:24:13 -0500 + +mesa (3.1-8) unstable; urgency=low + + * fixed the postinst and prerm for the glide packages + * added Provides: mesag-dev to the mesag-glide2-dev package to maintain + backwards compatability + + -- James A. Treacy Sat, 15 Jan 2000 01:01:58 -0500 + +mesa (3.1-7) unstable; urgency=low + + * Fix version number for soname in the shlib file. Closes: bug#54926 + + -- James A. Treacy Thu, 13 Jan 2000 01:37:03 -0500 + +mesa (3.1-6) unstable; urgency=low + + * Include docs/README.3DFX in mesag3-glide2 package. Closes: bug#54625 + * Remove Provides: libgl1 from mesag3-widgets. Closes: bug#54774 + * conflicts with older versions of mesa. Closes: bug#54831 + + -- James A. Treacy Mon, 10 Jan 2000 11:50:49 -0500 + +mesa (3.1-5) unstable; urgency=low + + * now Conflicts: libgl1 + * remove extra '.' in library name + + -- James A. Treacy Sun, 9 Jan 2000 20:47:31 -0500 + +mesa (3.1-4) unstable; urgency=low + + * Added links libGL.so.1 <- libMesaGL.so.3 so existing progs don't break + * Copyright changed for version 3.1 + + -- James A. Treacy Thu, 6 Jan 2000 17:11:11 -0500 + +mesa (3.1-3) unstable; urgency=low + + * copyright file now refers to /usr/share/common-license/LGPL. + + -- James A. Treacy Tue, 4 Jan 2000 11:50:45 -0500 + +mesa (3.1-2) unstable; urgency=low + + * Second try. Fixed shlibs file. + + -- James A. Treacy Tue, 4 Jan 2000 00:00:29 -0500 + +mesa (3.1-1) unstable; urgency=low + + * New upstream version. + * glide version of packages added, since glide is now under the GPL. + * mesa widget libraries are now in a separate package + * library names are changed to lib{GL,GLU}.* + + -- James A. Treacy Tue, 14 Dec 1999 10:06:14 -0500 + +mesa (3.0-2) unstable; urgency=low + + * added symlinks from libMesaGL* -> libGL*. Fixes bug #37160 + * added lines (commented out) for building a glide version of mesa. Fixes bug #39758 + + -- James A. Treacy Thu, 13 May 1999 01:02:42 -0400 + +mesa (3.0-1) unstable; urgency=low + + * mesa libs moved to /usr/lib. Fixes bug #26874 + * motif widget library libMesaGLwM added (compiled using headers from lesstif). Fixes bug #25380 + + -- James A. Treacy Thu, 6 Aug 1998 13:49:37 -0400 + +mesa (2.6-4) unstable; urgency=low + + * call to ldconfig in postinst put back in. Fixes bug #20552 + * changelog.Debian file created for the mesa-doc package. + * deleted miscellaneous files. Fixes bug #21481 + + -- James A. Treacy Sat, 23 May 1998 23:41:34 -0400 + +mesa (2.6-3) frozen unstable; urgency=low + + * No changes. Just trying (again) to get this back in the distribution + + -- James A. Treacy Tue, 24 Mar 1998 00:53:09 -0500 + +mesa (2.6-2) unstable frozen; urgency=low + + * point copyright to LPGL in /usr/doc/copyright. Fixes bug #19633 + + -- James A. Treacy Sun, 15 Mar 1998 14:00:33 -0500 + +mesa (2.6-1) unstable; urgency=low + + * New upstream Release + * strip static lib with --strip-debug and shared with strip--unneeded: Fixes bug#17301 + * create doc package in build-indep: Fixes bug#16090 + * added widgets-mesa library to package: Fixes bug#15729 + * created mesa-glide* packages + + -- James A. Treacy Mon, 19 Jan 1998 23:45:50 -0500 + +mesa (2.5-2) unstable; urgency=low + + * Corrected i386 specific debian/rules file: Fixes bug#15640 + + -- James A. Treacy Fri, 5 Nov 1997 11:46:13 -0500 + +mesa (2.5-1) unstable; urgency=low + + * New upstream release. + + -- James A. Treacy Sun, 23 Nov 1997 20:46:13 -0500 + +mesa (2.4-1) unstable; urgency=low + + * New upstream release. + * New maintainer. + * libc6 release. + + -- James A. Treacy Mon, 3 Nov 1997 01:11:34 -0500 + +mesa (2.2-2) unstable; urgency=low + + * debian/control: mesa-doc no longer depends on mesa (bug #8840). + + -- Karl Sackett Wed, 30 Apr 1997 10:25:25 -0500 + +mesa (2.2-1) unstable; urgency=low + + * New upstream release. + * Make-config: linux-elf libraries compiled with -D_REENTRANT. + + -- Karl Sackett Wed, 19 Mar 1997 09:10:22 -0600 + +mesa (2.1-4) unstable; urgency=low + + * debian/control: lib packages moved from 'graphics' to 'libs'. + * debian/rules: headers moved from /usr/include/mesa to /usr/include + (no more -I/usr/include/mesa). + + -- Karl Sackett Tue, 25 Feb 1997 09:30:23 -0600 + +mesa (2.1-3) unstable; urgency=low + + * debian/control: mesa2 provides mesa and conflicts with mesa + (bug #7394). + + -- Karl Sackett Mon, 17 Feb 1997 09:25:42 -0600 + +mesa (2.1-2) unstable; urgency=low + + * debian/rules: install gmesa.h, osmesa.h, FooMesa.h in mesa-dev + (bug #6864). + + -- Karl Sackett Tue, 28 Jan 1997 09:37:41 -0600 + +mesa (2.1-1) unstable; urgency=low + + * New upstream release. + * Added soname to mesa and mesa-widgets. + * Moved static libraries to mesa2-dbg. + * debian/postinst, postinst-widgets: call ldconfig without explicit + pathname (bugs #6176, 6180). + + -- Karl Sackett Mon, 6 Jan 1997 09:30:10 -0600 + +mesa (2.0-2) unstable; urgency=low + + * Created mesa-widgets and mesa-widgets-dev (Bug #5029). + + -- Karl Sackett Wed, 30 Oct 1996 08:44:19 -0600 + +mesa (2.0-1) unstable; urgency=low + + * src/draw.c: replaced with upstream patch. + * Make-config: linux-elf target builds libMesaGLw.so library, looks + for XLIBS in /usr/X11R6/lib, removed -mieee-mp from CFLAGS. + * widgets-sgi/Makefile: builds libMesaGlw.a library + * New upstream release. + * Converted to new package standard. + * Maintainer address changed. + + -- Karl Sackett Mon, 14 Oct 1996 15:37:19 -0500 + +1.2.8-3 + * Package split into runtime, development, and documentation + packages. + * widgets now made as a sharable library. + * GLUT removed. This will be released as a separate package. + +1.2.8-2 + * Support files now architecture-independent + +1.2.8-1 + * Upgrade to latest release + * Brought support files up to latest packaging requirements + * mondello/Makefile: fixed error in realclean target + +1.2.7-2 + * debian.rules: clean all Makefiles out of widgets directory + * debian.postrm: remove /usr/lib/mesa entry from /etc/ld.so.config + (bug #2817) + +1.2.7-1 + * Added Debian support files + * Included the GLUT OpenGL Utility Toolkit + * Makefile - disable building programs in demos, samples, and book + directories + * mklib.linux - disabled building *.a libraries + * widgets/Makefile.in - disabled building demo programs --- mesa-7.8.2.orig/debian/control +++ mesa-7.8.2/debian/control @@ -0,0 +1,706 @@ +Source: mesa +Section: graphics +Priority: optional +Maintainer: Ubuntu X-SWAT +XSBC-Original-Maintainer: Debian X Strike Force +Uploaders: David Nusinow , Brice Goglin +Standards-Version: 3.8.4 +Build-Depends: debhelper (>= 7.2.7), quilt (>= 0.40), pkg-config, + libdrm-dev (>= 2.4.19) [!hurd-i386], libx11-dev, xutils-dev, + x11proto-gl-dev (>= 1.4.11), libxxf86vm-dev, + libexpat1-dev, dpkg-dev (>= 1.15.6), libxfixes-dev, + libxdamage-dev, libxext-dev, autoconf, automake, x11proto-dri2-dev (>= 2.1), + linux-libc-dev (>= 2.6.31) [!hurd-i386 !kfreebsd-amd64 !kfreebsd-i386], + libx11-xcb-dev, libxcb-dri2-0-dev, libxcb-xfixes0-dev, python-libxml2, +Vcs-Git: git://git.debian.org/git/pkg-xorg/lib/mesa +Vcs-Browser: http://git.debian.org/?p=pkg-xorg/lib/mesa.git +Homepage: http://mesa3d.sourceforge.net/ + +Package: libgl1-mesa-swx11 +Section: libs +Priority: extra +Architecture: any +Depends: + libosmesa6 (>= 6.5.2-1), + ${shlibs:Depends}, + ${misc:Depends}, +Conflicts: mesag3-glide, mesag3-glide2, mesag3+ggi, libgl1, nvidia-glx, mesag3, libgl1-mesa-swrast +Provides: libgl1, mesag3, libgl1-mesa-swrast +Replaces: libgl1, mesag3, libgl1-mesa-swrast +Description: A free implementation of the OpenGL API -- runtime + Mesa is a 3-D graphics library with an API which is very similar to + that of OpenGL. To the extent that Mesa utilizes the OpenGL command + syntax or state machine, it is being used with authorization from + Silicon Graphics, Inc. However, the author makes no claim that Mesa + is in any way a compatible replacement for OpenGL or associated with + Silicon Graphics, Inc. + . + This library provides a pure software rasteriser; it does not provide + a direct rendering-capable library, or one which uses GLX. For that, + please see libgl1-mesa-glx. + . + On Linux, this library is also known as libGL or libGL.so.1. + +Package: libgl1-mesa-swx11-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libgl1-mesa-swx11 (= ${binary:Version}), + ${misc:Depends}, +Conflicts: libgl1-mesa-swrast-dbg +Provides: libgl1-mesa-swrast-dbg +Replaces: libgl1-mesa-swrast-dbg +Description: A free implementation of the OpenGL API -- debugging symbols + Mesa is a 3-D graphics library with an API which is very similar to + that of OpenGL. To the extent that Mesa utilizes the OpenGL command + syntax or state machine, it is being used with authorization from + Silicon Graphics, Inc. However, the author makes no claim that Mesa + is in any way a compatible replacement for OpenGL or associated with + Silicon Graphics, Inc. + . + This library provides a pure software rasteriser; it does not provide + a direct rendering-capable library, or one which uses GLX. For that, + please see libgl1-mesa-glx. + . + On Linux, this library is also known as libGL or libGL.so.1. + . + This package contains debugging symbols for the software rasterization GL + library. + +# Package: libgl1-mesa-swx11-i686 +# Section: libs +# Priority: extra +# Architecture: i386 kfreebsd-i386 hurd-i386 +# Depends: +# libgl1-mesa-swx11 (= ${binary:Version}), +# ${shlibs:Depends}, +# ${misc:Depends}, +# Description: Mesa OpenGL runtime [i686 optimized] +# Mesa is a 3-D graphics library with an API which is very similar to +# that of OpenGL. To the extent that Mesa utilizes the OpenGL command +# syntax or state machine, it is being used with authorization from +# Silicon Graphics, Inc. However, the author makes no claim that Mesa +# is in any way a compatible replacement for OpenGL or associated with +# Silicon Graphics, Inc. +# . +# This library provides a pure software rasteriser; it does not provide +# a direct rendering-capable library, or one which uses GLX. For that, +# please see libgl1-mesa-glx. +# . +# On Linux, this library is also known as libGL or libGL.so.1. +# . +# This set of libraries is optimized for i686 machines and will only be used if +# you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro, +# Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones +# such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla). + +Package: libgl1-mesa-swx11-dev +Section: libdevel +Priority: extra +Architecture: any +Depends: + libgl1-mesa-swx11 (= ${binary:Version}), + libx11-dev, + libxext6, + mesa-common-dev (= ${binary:Version}), + ${misc:Depends}, +Provides: libgl-dev, mesag-dev, libgl1-mesa-swrast-dev +Conflicts: mesa-dev, libgl-dev, mesag3 (<< 3.1-1), nvidia-glx-dev, mesag-dev, libgl1-mesa-swrast-dev +Replaces: libgl-dev, mesag-dev, libgl1-mesa-swrast-dev +Description: A free implementation of the OpenGL API -- development files + This package provides the development environment required for + compiling programs with Mesa. For a complete description of Mesa, + please look at the libgl1-mesa-swx11 package. + . + This library provides a pure software rasteriser; it does not provide + a direct rendering-capable library, or one which uses GLX. For that, + please see libgl1-mesa-dev. + +Package: libegl1-mesa +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Recommends: libegl1-mesa-drivers-x11 +Description: A free implementation of the EGL API -- runtime + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains modules to interface with the existing system GLX or + DRI2 drivers to provide OpenGL via EGL. The libegl1-mesa-drivers-x11 package + provides drivers to provide hardware-accelerated OpenGL|ES and OpenVG support. + +Package: libegl1-mesa-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libegl1-mesa (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the EGL API -- debugging symbols + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains the debugging symbols for the EGL library. + +Package: libegl1-mesa-dev +Section: libdevel +Architecture: any +Depends: + libegl1-mesa (= ${binary:Version}), + libdrm-dev (>= 2.4.19) [!hurd-i386], + x11proto-dri2-dev (>= 2.1), + x11proto-gl-dev (>= 1.4.11), + libx11-dev, + libxext-dev, + libxxf86vm-dev, + libxdamage-dev, + libxfixes-dev, + ${misc:Depends}, +Description: A free implementation of the EGL API -- development files + This package contains the development environment required for compiling + programs against EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package provides the development environment for compiling programs + against the EGL library. + +Package: libegl1-mesa-drivers-x11 +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the EGL API -- X11 drivers + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains the drivers required for hardware accelerated rendering + of EGL-based graphics libraries, such as OpenGL|ES and OpenVG, in an X11 + environment. + +Package: libegl1-mesa-drivers-x11-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libegl1-mesa-drivers-x11 (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the EGL API -- X11 driver debugging symbols + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains the debugging symbols for the drivers required for + hardware accelerated rendering of EGL-based graphics libraries, such as + OpenGL|ES and OpenVG, in an X11 environment. + +Package: libegl1-mesa-drivers-kms +Section: libs +Architecture: linux-any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the EGL API -- KMS drivers + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains the drivers required for hardware accelerated rendering + of EGL-based graphics libraries, such as OpenGL|ES and OpenVG in a raw + KMS-framebuffer environment. + +Package: libegl1-mesa-drivers-kms-dbg +Section: debug +Priority: extra +Architecture: linux-any +Depends: + libegl1-mesa-drivers-kms (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the EGL API -- KMS driver debugging symbols + This package contains the EGL native platform graphics interface library. + EGL provides a platform-agnostic mechanism for creating rendering surfaces + for use with other graphics libraries, such as OpenGL|ES and OpenVG. + . + This package contains the debugging symbols for the drivers required for + hardware accelerated rendering of EGL-based graphics libraries, such as + OpenGL|ES and OpenVG in a raw KMS-framebuffer environment. + +Package: libopenvg1-mesa +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the OpenVG API -- runtime + This package contains the mesa implementation of the OpenVG 2D acceleration + library. OpenVG provides a device independent and vendor-neutral interface + for sophisticated 2D graphical applications, while allowing device + manufacturers to provide hardware acceleration on devices ranging from wrist + watches to full microprocessor-based desktop and server machines. + +Package: libopenvg1-mesa-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libopenvg1-mesa (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the OpenVG API -- debugging symbols + This package contains the mesa implementation of the OpenVG 2D acceleration + library. OpenVG provides a device independent and vendor-neutral interface + for sophisticated 2D graphical applications, while allowing device + manufacturers to provide hardware acceleration on devices ranging from wrist + watches to full microprocessor-based desktop and server machines. + . + This package contains the debugging symbols for the OpenVG library. + +Package: libopenvg1-mesa-dev +Section: libdevel +Architecture: any +Depends: + libopenvg1-mesa (= ${binary:Version}), + libegl1-mesa-dev, + ${misc:Depends}, +Description: A free implementation of the OpenVG API -- development files + This package contains the mesa implementation of the OpenVG 2D acceleration + library. OpenVG provides a device independent and vendor-neutral interface + for sophisticated 2D graphical applications, while allowing device + manufacturers to provide hardware acceleration on devices ranging from wrist + watches to full microprocessor-based desktop and server machines. + . + This package contains the development environment required for compiling + programs against the OpenVG 2D acceleration library. + +Package: libgles1-mesa +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 1.x API -- runtime + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 1.x provides an API for fixed-function hardware. + +Package: libgles1-mesa-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libgles1-mesa (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 1.x API -- debugging symbols + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 1.x provides an API for fixed-function hardware. + . + This package contains the debugging symbols for the libGLESv1_CM library. + +Package: libgles1-mesa-dev +Section: libdevel +Architecture: any +Depends: + libgles1-mesa (= ${binary:Version}), + libegl1-mesa-dev, + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 1.x API -- development files + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 1.x provides an API for fixed-function hardware. + . + This package provides a development environment for building programs using + the OpenGL|ES 1.x APIs. + +Package: libgles2-mesa +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 2.x API -- runtime + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 2.x provides an API for programmable hardware including vertex + and fragment shaders. + +Package: libgles2-mesa-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libgles2-mesa (= ${binary:Version}), + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 2.x API -- debugging symbols + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 2.x provides an API for programmable hardware including vertex + and fragment shaders. + . + This package contains the debugging symbols for the libGLESv2 library. + +Package: libgles2-mesa-dev +Section: libdevel +Architecture: any +Depends: + libgles2-mesa (= ${binary:Version}), + libegl1-mesa-dev, + ${misc:Depends}, +Description: A free implementation of the OpenGL|ES 2.x API -- development files + OpenGL|ES is a cross-platform API for full-function 2D and 3D graphics on + embedded systems - including consoles, phones, appliances and vehicles. + It contains a subset of OpenGL plus a number of extensions for the + special needs of embedded systems. + . + OpenGL|ES 2.x provides an API for programmable hardware including vertex + and fragment shaders. + . + This package provides a development environment for building applications + using the OpenGL|ES 2.x APIs. + +Package: libgl1-mesa-glx +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends} +Recommends: libgl1-mesa-dri (>= 7.2) +Conflicts: libgl1, libgl1-mesa-dri (<< 6.4.0) +Replaces: libgl1, libgl1-mesa-dri (<< 6.4.0) +Provides: libgl1 +Description: A free implementation of the OpenGL API -- GLX runtime + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the modules themselves: these can be found + in the libgl1-mesa-dri package. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + +Package: libgl1-mesa-glx-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libgl1-mesa-glx (= ${binary:Version}), + ${misc:Depends}, +Description: Debugging symbols for the Mesa GLX runtime + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the modules themselves: these can be found + in the libgl1-mesa-dri package. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + . + This package contains debugging symbols for the GL library with GLX and DRI + capabilities. + +#Package: libgl1-mesa-glx-i686 +#Section: libs +#Priority: extra +#Architecture: i386 kfreebsd-i386 hurd-i386 +#Pre-Depends: libgl1-mesa-glx +#Description: A free implementation of the OpenGL API -- GLX runtime [i686 optimized] +# This version of Mesa provides GLX and DRI capabilities: it is capable of +# both direct and indirect rendering. For direct rendering, it can use DRI +# modules from the libgl1-mesa-dri package to accelerate drawing. +# . +# This package does not include the modules themselves: these can be found +# in the libgl1-mesa-dri package. +# . +# For a complete description of Mesa, please look at the +# libgl1-mesa-swx11 package. +# . +# This set of libraries is optimized for i686 machines and will only be used if +# you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro, +# Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones +# such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla). + +Package: libgl1-mesa-dri +Section: libs +Priority: optional +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends} +Suggests: libglide3 +Conflicts: xlibmesa-dri (<< 1:7.0.0) +Replaces: xlibmesa-dri (<< 1:7.0.0) +Breaks: xserver-xorg-core (<< 2:1.5), libgl1-mesa-glx (<< 7.2) +Description: A free implementation of the OpenGL API -- DRI modules + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the OpenGL library itself, only the DRI + modules for accelerating direct rendering. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + . + The tdfx DRI module needs libglide3 to enable direct rendering. + +Package: libgl1-mesa-dri-dbg +Section: debug +Priority: extra +Architecture: any +Depends: + libgl1-mesa-dri (= ${binary:Version}), + ${misc:Depends}, +Description: Debugging symbols for the Mesa DRI modules + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the OpenGL library itself, only the DRI + modules for accelerating direct rendering. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + . + This package contains debugging symbols for the DRI modules. + +Package: libgl1-mesa-dri-experimental +Section: libs +Architecture: linux-any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Description: A free implementation of the OpenGL API -- Extra DRI modules + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the OpenGL library itself, only the DRI + modules for accelerating direct and indirect rendering. The drivers + in this package may provide more features than the drivers in the + libgl1-mesa-dri at the cost of less stability. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + +Package: libgl1-mesa-dri-experimental-dbg +Section: debug +Priority: extra +Architecture: linux-any +Depends: + libgl1-mesa-dri-experimental (= ${binary:Version}), + ${misc:Depends}, +Description: Debugging symbols for the experimental Mesa DRI modules + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package does not include the OpenGL library itself, only the DRI + modules for accelerating direct rendering. + . + For a complete description of Mesa, please look at the + libgl1-mesa-swx11 package. + . + This package contains debugging symbols for the Gallium DRI modules. + +#Package: libgl1-mesa-dri-i686 +#Section: libs +#Priority: extra +#Architecture: i386 kfreebsd-i386 hurd-i386 +#Pre-Depends: libgl1-mesa-dri +#Description: A free implementation of the OpenGL API -- DRI modules [i686 optimized] +# This version of Mesa provides GLX and DRI capabilities: it is capable of +# both direct and indirect rendering. For direct rendering, it can use DRI +# modules from the libgl1-mesa-dri package to accelerate drawing. +# . +# This package does not include the OpenGL library itself, only the DRI +# modules for accelerating direct rendering. +# . +# For a complete description of Mesa, please look at the +# libgl1-mesa-swx11 package. +# . +# This set of libraries is optimized for i686 machines and will only be used if +# you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro, +# Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones +# such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla). + +Package: libgl1-mesa-dev +Section: libdevel +Architecture: any +Depends: + mesa-common-dev (= ${binary:Version}), + libgl1-mesa-glx (= ${binary:Version}), + ${misc:Depends}, +Conflicts: libgl-dev, libgl1-mesa-dri-dev +Replaces: libgl-dev, libgl1-mesa-dri-dev +Provides: libgl-dev, libgl1-mesa-dri-dev +Description: A free implementation of the OpenGL API -- GLX development files + This version of Mesa provides GLX and DRI capabilities: it is capable of + both direct and indirect rendering. For direct rendering, it can use DRI + modules from the libgl1-mesa-dri package to accelerate drawing. + . + This package includes headers and static libraries for compiling + programs with Mesa. + . + For a complete description of Mesa, please look at the libgl1-mesa-swx11 + package. + +Package: mesa-common-dev +Section: libdevel +Architecture: any +Replaces: xlibmesa-gl-dev (<< 1:7), xlibosmesa-dev, libgl1-mesa-swx11-dev (<< 6.5.2), libgl1-mesa-dev (<< 7.5~rc4-2) +Depends: + libx11-dev, + libdrm-dev, + ${misc:Depends}, +Description: Developer documentation for Mesa + This package includes the specifications for the Mesa-specific OpenGL + extensions, the complete set of release notes and the development header + files common to all Mesa packages. + +Package: libosmesa6 +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Replaces: libgl1-mesa-swx11 (<< 6.5.2) +Description: Mesa Off-screen rendering extension + OSmesa is a Mesa extension that allows programs to render to an + off-screen buffer using the OpenGL API without having to create a + rendering context on an X Server. It uses a pure software renderer. + . + This package provides both 16-bit and 32-bit versions of the off-screen + renderer which do not require external libraries to work. + +Package: libosmesa6-dev +Section: libdevel +Architecture: any +Depends: + libosmesa6 (= ${binary:Version}), + mesa-common-dev (= ${binary:Version}) | libgl-dev, + ${misc:Depends}, +Conflicts: xlibosmesa-dev, libosmesa4-dev, libosmesa-dev +Replaces: xlibosmesa-dev, libosmesa-dev, libgl1-mesa-swx11-dev (<< 6.5.2), mesa-common-dev (<< 6.5.2) +Provides: xlibosmesa-dev, libosmesa-dev +Description: Mesa Off-screen rendering extension -- development files + This package provides the required environment for developing programs + that use the off-screen rendering extension of Mesa. + . + For more information on OSmesa see the libosmesa6 package. + +Package: libglu1-mesa +Section: libs +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Provides: libglu1 +Conflicts: mesag3 (<< 5.0.0-1), xlibmesa3, libglu1 +Replaces: libglu1 +Description: The OpenGL utility library (GLU) + GLU offers simple interfaces for building mipmaps; checking for the + presence of extensions in the OpenGL (or other libraries which follow + the same conventions for advertising extensions); drawing + piecewise-linear curves, NURBS, quadrics and other primitives + (including, but not limited to, teapots); tesselating surfaces; setting + up projection matrices and unprojecting screen coordinates to world + coordinates. + . + On Linux, this library is also known as libGLU or libGLU.so.1. + . + This package provides the SGI implementation of GLU shipped with the + Mesa package (ergo the "-mesa" suffix). + +Package: libglu1-mesa-dev +Section: libdevel +Architecture: any +Depends: + libglu1-mesa (= ${binary:Version}), + libgl1-mesa-dev | libgl-dev, + ${misc:Depends}, +Provides: libglu-dev, xlibmesa-glu-dev +Conflicts: mesag-dev (<< 5.0.0-1), mesa-glide2-dev (<< 5.0.0-1), mesag3+ggi-dev (<< 5.0.0-1), xlibmesa-dev +Replaces: libglu-dev +Description: The OpenGL utility library -- development files + Includes headers and static libraries for compiling programs with GLU. + . + For a complete description of GLU, please look at the libglu1-mesa + package. + +# Package: libglw1-mesa +# Section: libs +# Architecture: any +# Depends: +# ${shlibs:Depends}, +# ${misc:Depends}, +# Provides: libglw1 +# Description: A free implementation of the OpenGL API -- runtime +# Mesa is a 3-D graphics library with an API which is very similar to +# that of OpenGL. To the extent that Mesa utilizes the OpenGL command +# syntax or state machine, it is being used with authorization from +# Silicon Graphics, Inc. However, the author makes no claim that Mesa +# is in any way a compatible replacement for OpenGL or associated with +# Silicon Graphics, Inc. +# . +# This package provides a simple widgets library, libGLw, which +# allows Motif-based applications to embed an OpenGL drawing context. +# . +# On Linux, this library is also known as libGLw or libGLw.so.1. + +# Package: libglw1-mesa-dev +# Section: libdevel +# Architecture: any +# Depends: +# libglw1-mesa (= ${binary:Version}), +# libx11-dev, +# libxt-dev, +# lesstif2-dev, +# mesa-common-dev (= ${binary:Version}), +# ${shlibs:Depends}, +# ${misc:Depends}, +# Provides: mesag3-widgets, mesag-widgets-dev, libglw-dev +# Conflicts: libglw-dev, libgl1-mesa-swx11-dev (<< 6.5.2-4) +# Replaces: libglw-dev +# Description: A free implementation of the OpenGL API -- development files +# This package provides the development environment required for +# compiling programs with the Mesa widgets library, libGLw, which +# allows Motif-based applications to embed an OpenGL drawing context. +# The headers and static libraries for compiling programs that use this +# library are included. + +Package: mesa-utils +Section: x11 +Priority: optional +Architecture: any +Depends: + ${shlibs:Depends}, + ${misc:Depends}, +Replaces: xbase-clients (<< 6.8.2-38) +Description: Miscellaneous Mesa GL utilities + This package provides several basic GL utilities built by Mesa, including + glxinfo and glxgears. + +# vim: tw=0 --- mesa-7.8.2.orig/debian/watch +++ mesa-7.8.2/debian/watch @@ -0,0 +1,6 @@ +version=3 +opts="uversionmangle=s/-rc/~rc/" \ +http://sf.net/mesa3d/MesaLib-(.*)\.tar\.gz + +opts="uversionmangle=s/-rc/~rc/" \ +ftp://freedesktop.org/pub/mesa/([\d\.]*)/ MesaLib-(.*)\.tar\.gz --- mesa-7.8.2.orig/debian/rules +++ mesa-7.8.2/debian/rules @@ -0,0 +1,340 @@ +#!/usr/bin/make -f +# debian/rules for the Debian mesa package +# Copyright © 2006 Thierry Reding + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +CFLAGS = -Wall -g +ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif +ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) + NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS))) + MAKEFLAGS += -j$(NUMJOBS) +endif + +DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH) +DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) +DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) +DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) +DEB_HOST_ARCH_CPU ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_CPU) +DEB_BUILD_DIR ?= $(CURDIR)/build +ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE)) + confflags += --build=$(DEB_HOST_GNU_TYPE) +else + confflags += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) +endif + +# choose which configurations to build +include debian/scripts/choose-configs + +# build the following configurations by default +CONFIGS = $(SWX11_GLU_CONFIGS) \ + dri \ + osmesa \ + osmesa-static \ + osmesa16 \ + osmesa16-static \ + osmesa32 \ + osmesa32-static + +STAMP_DIR = debian/stamp +STAMP = $(STAMP_DIR)/$(DEB_BUILD_GNU_TYPE) +BUILD_STAMPS = $(addprefix $(STAMP)-build-, $(CONFIGS)) + +QUILT_STAMPFN = $(STAMP_DIR)/patch +include /usr/share/quilt/quilt.make + +confflags-common = \ + --disable-glu \ + --disable-glut \ + --disable-glw \ + CFLAGS="$(CFLAGS)" + +DRI_DRIVERS = swrast +GALLIUM_DRIVERS = swrast +EGL_DISPLAYS = x11 + +# hurd doesn't do direct rendering +ifeq ($(DEB_HOST_ARCH_OS), hurd) + DIRECT_RENDERING = --disable-driglx-direct +else + DIRECT_RENDERING = --enable-driglx-direct + + ifeq ($(DEB_HOST_ARCH_OS), linux) +# Gallium drivers require libdrm-{nouveau,radeon}, only available on Linux + GALLIUM_DRIVERS += nouveau radeon +# Although the KMS egl drivers will probably build on kfreebsd & hurd +# only linux actually has KMS drivers implemented at this point. + EGL_DISPLAYS += kms + endif + + ifeq ($(DEB_HOST_ARCH), lpia) + DRI_DRIVERS += i915 i965 + GALLIUM_DRIVERS += intel + else ifneq ($(DEB_HOST_ARCH), s390) + DRI_DRIVERS += mga r128 r200 r300 r600 radeon savage tdfx + ifeq ($(DEB_HOST_ARCH_CPU), i386) + DRI_DRIVERS += i810 i915 i965 sis unichrome + GALLIUM_DRIVERS += intel + else ifeq ($(DEB_HOST_ARCH_CPU), amd64) + DRI_DRIVERS += i915 i965 sis unichrome + GALLIUM_DRIVERS += intel + endif + endif +endif + +ifeq ($(HAVE_KMS), yes) + EGL_DISPLAYS += kms +endif + +confflags-dri = \ + --with-driver=dri \ + --with-dri-drivers="$(DRI_DRIVERS)" \ + --with-demos=xdemos \ + --with-dri-driverdir=/usr/lib/dri \ + --with-egl-displays="$(EGL_DISPLAYS)" \ + --enable-glx-tls \ + $(addprefix --enable-gallium-,$(GALLIUM_DRIVERS)) \ + --with-state-trackers=egl,es,glx,dri,vega \ + $(DIRECT_RENDERING) \ + $(confflags-common) + +confflags-osmesa = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --with-demos= \ + $(confflags-common) + +confflags-osmesa-static = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --enable-static \ + --with-demos= \ + $(confflags-common) + +confflags-osmesa16 = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --with-osmesa-bits=16 \ + --with-demos= \ + $(confflags-common) + +confflags-osmesa16-static = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --with-osmesa-bits=16 \ + --enable-static \ + --with-demos= \ + $(confflags-common) + +confflags-osmesa32 = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --with-osmesa-bits=32 \ + --with-demos= \ + $(confflags-common) + +confflags-osmesa32-static = \ + --disable-egl \ + --disable-gallium \ + --with-driver=osmesa \ + --with-osmesa-bits=32 \ + --enable-static \ + --with-demos= \ + $(confflags-common) + +confflags-swx11+glu = \ + --disable-egl \ + --disable-gallium \ + --with-driver=xlib \ + --disable-gl-osmesa \ + --with-demos= \ + --disable-egl \ + --disable-glut \ + --disable-glw \ + CFLAGS="$(CFLAGS)" + +confflags-swx11+glu-static = \ + --disable-egl \ + --disable-gallium \ + --with-driver=xlib \ + --disable-gl-osmesa \ + --enable-static \ + --with-demos= \ + --disable-egl \ + --disable-glut \ + --disable-glw \ + CFLAGS="$(CFLAGS)" + +confflags-swx11+glu-i386-i686 = \ + --disable-egl \ + --disable-gallium \ + --with-driver=xlib \ + --disable-gl-osmesa \ + --with-demos= \ + --disable-glut \ + --disable-egl \ + --disable-glw \ + --libdir=/usr/lib/i686/cmov \ + CFLAGS="$(CFLAGS) -march=i686" + +# Add /usr/lib32/dri/ on 32 bit systems so that this path is used +# for 32 bit compatibility on 64 bit systems +ifeq ($(DEB_BUILD_ARCH),i386) + confflags-dri += --with-dri-searchpath=/usr/lib/dri:/usr/lib32/dri +endif + +configure: $(QUILT_STAMPFN) configure.ac + autoreconf -vfi + +# list the configurations that will built +configs: + @echo Building the following configurations: $(CONFIGS) + +$(STAMP_DIR)/stamp: + dh_testdir + mkdir -p $(STAMP_DIR) + >$@ + +$(QUILT_STAMPFN): $(STAMP_DIR)/stamp + +build: build-stamp + +build-stamp: $(BUILD_STAMPS) +ifeq ($(findstring radeon, $(GALLIUM_DRIVERS)), radeon) + # Radeon searches for r{200,300,600}_dri only, but the gallium driver + # is (at the moment) radeong_dri. Rename it to r300_dri, as it + # fails to support r600. + # We don't actually install radeong yet, although it will probably + # replace r300 classic soon. + mv build/dri/lib/gallium/radeong_dri.so \ + build/dri/lib/gallium/r300_dri.so +endif +ifeq ($(findstring intel, $(GALLIUM_DRIVERS)), intel) + # Intel i965 Gallium appears to do nothing more than generate GPU + # lockups. Kill it with fire. i915 is apparently useful. + rm build/dri/lib/gallium/i965_dri.so + rm build/dri/lib/egl_*_i965.so +endif + >$@ + +$(STAMP)-build-%: configure + dh_testdir + + mkdir -p $(DEB_BUILD_DIR)/$* + find $(CURDIR)/* -maxdepth 0 -not -path '$(DEB_BUILD_DIR)*' | \ + xargs cp -rlf -t $(DEB_BUILD_DIR)/$* + cd $(DEB_BUILD_DIR)/$* && \ + ../../configure --prefix=/usr --mandir=\$${prefix}/share/man \ + --infodir=\$${prefix}/share/info --sysconfdir=/etc \ + --localstatedir=/var $(confflags) $(confflags-$*) + cd $(DEB_BUILD_DIR)/$* && $(MAKE) + >$@ + +install: build + # Add here commands to install the package into debian/tmp + dh_testdir + dh_testroot + dh_prep + dh_installdirs + set -e; for config in $(filter-out dri, $(CONFIGS)); do \ + $(MAKE) -C $(DEB_BUILD_DIR)/$$config DESTDIR=$(CURDIR)/debian/tmp install; \ + done + $(MAKE) -C $(DEB_BUILD_DIR)/dri DESTDIR=$(CURDIR)/debian/tmp/dri install + +clean: unpatch + dh_testdir + dh_testroot + rm -rf .pc + + rm -f config.cache config.log config.status + rm -f */config.cache */config.log */config.status + rm -f conftest* */conftest* + rm -rf autom4te.cache */autom4te.cache + rm -rf build + rm -rf configure config.guess config.sub config.h.in + rm -rf $$(find -name Makefile.in) + rm -rf aclocal.m4 missing depcomp install-sh ltmain.sh + rm -rf $(STAMP_DIR) + + dh_clean + +# Build architecture-independent files here. +binary-indep: install + + +# Build architecture-dependent files here. +binary-arch: install + dh_testdir + dh_testroot + dh_installchangelogs -s + dh_installchangelogs -pmesa-common-dev + dh_installdocs -s + dh_installexamples -s + + # Classic DRI and Gallium DRI are mixed up together here + # Remove the whole tree to avoid false-positives in --list-missing, and + # install the right files manually. + rm -r debian/tmp/dri/usr/lib/dri + + dh_install -s --list-missing + + # Create an ld.so.conf which says where to find libGL from Mesa + echo "/usr/lib/mesa" \ + > $(CURDIR)/debian/libgl1-mesa-glx/usr/lib/mesa/ld.so.conf + echo "/usr/lib/mesa" \ + > $(CURDIR)/debian/libgl1-mesa-swx11/usr/lib/mesa/ld.so.conf + +ifeq ($(DEB_BUILD_ARCH),amd64) + # Add the path to 32bit libGL from Mesa (on 64 bit) + echo "/usr/lib32/mesa" \ + >> $(CURDIR)/debian/libgl1-mesa-glx/usr/lib/mesa/ld.so.conf + echo "/usr/lib32/mesa" \ + >> $(CURDIR)/debian/libgl1-mesa-swx11/usr/lib/mesa/ld.so.conf +endif + + # Empty directory for the alternative + mkdir -p $(CURDIR)/debian/libgl1-mesa-glx/usr/lib/xorg/x11-extra-modules + mkdir -p $(CURDIR)/debian/libgl1-mesa-swx11/usr/lib/xorg/x11-extra-modules + + dh_installman -s + dh_lintian -s + dh_link -s + dh_strip -plibgl1-mesa-swx11 --dbg-package=libgl1-mesa-swx11-dbg + dh_strip -plibgl1-mesa-glx --dbg-package=libgl1-mesa-glx-dbg + dh_strip -plibgl1-mesa-dri --dbg-package=libgl1-mesa-dri-dbg +# Mesa 7.8 doesn't build a gallium swrast DRI driver +# This is built in git, and will be built in 7.9 +ifneq ($(filter-out swrast, $(GALLIUM_DRIVERS)), ) + dh_strip -plibgl1-mesa-dri-experimental --dbg-package=libgl1-mesa-dri-experimental-dbg +endif + dh_strip -plibopenvg1-mesa --dbg-package=libopenvg1-mesa-dbg + dh_strip -plibegl1-mesa --dbg-package=libegl1-mesa-dbg + dh_strip -plibgles1-mesa --dbg-package=libgles1-mesa-dbg + dh_strip -plibgles2-mesa --dbg-package=libgles2-mesa-dbg + dh_strip -plibegl1-mesa-drivers-x11 --dbg-package=libegl1-mesa-drivers-x11-dbg +ifeq ($(findstring kms, $(EGL_DISPLAYS)), kms) + dh_strip -plibegl1-mesa-drivers-kms --dbg-package=libegl1-mesa-drivers-kms-dbg +endif + dh_strip -s --remaining-packages + dh_compress -s + dh_fixperms -s + dh_makeshlibs -s + dh_installdeb -s + dh_shlibdeps -s -l/usr/lib/mesa + dh_gencontrol -s + dh_md5sums -s + dh_builddeb -s -- -Zlzma + +binary: binary-indep binary-arch +.PHONY: configs build clean binary-indep binary-arch binary install --- mesa-7.8.2.orig/debian/patches/02_use-ieee-fp-on-s390-and-m68k.patch +++ mesa-7.8.2/debian/patches/02_use-ieee-fp-on-s390-and-m68k.patch @@ -0,0 +1,21 @@ +Patch that fixes Debian bug #349437. + +This patch by David Nusinow. + +--- + src/mesa/main/compiler.h | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +--- a/src/mesa/main/compiler.h ++++ b/src/mesa/main/compiler.h +@@ -353,8 +353,9 @@ static INLINE GLuint CPU_TO_LE32(GLuint + * USE_IEEE: Determine if we're using IEEE floating point + */ + #if defined(__i386__) || defined(__386__) || defined(__sparc__) || \ +- defined(__s390x__) || defined(__powerpc__) || \ ++ defined(__s390__) || defined(__s390x__) || defined(__powerpc__) || \ + defined(__x86_64__) || \ ++ defined(__m68k__) || \ + defined(ia64) || defined(__ia64__) || \ + defined(__hppa__) || defined(hpux) || \ + defined(__mips) || defined(_MIPS_ARCH) || \ --- mesa-7.8.2.orig/debian/patches/100_no_abi_tag.patch +++ mesa-7.8.2/debian/patches/100_no_abi_tag.patch @@ -0,0 +1,42 @@ +--- a/src/mesa/x86-64/glapi_x86-64.S ++++ b/src/mesa/x86-64/glapi_x86-64.S +@@ -30885,18 +30885,6 @@ GL_PREFIX(EGLImageTargetTexture2DOES): + .globl GL_PREFIX(FramebufferTextureLayer) ; .set GL_PREFIX(FramebufferTextureLayer), GL_PREFIX(FramebufferTextureLayerEXT) + .globl GL_PREFIX(ProvokingVertex) ; .set GL_PREFIX(ProvokingVertex), GL_PREFIX(ProvokingVertexEXT) + +-#if defined(GLX_USE_TLS) && defined(__linux__) +- .section ".note.ABI-tag", "a" +- .p2align 2 +- .long 1f - 0f /* name length */ +- .long 3f - 2f /* data length */ +- .long 1 /* note length */ +-0: .asciz "GNU" /* vendor name */ +-1: .p2align 2 +-2: .long 0 /* note data: the ABI tag */ +- .long 2,4,20 /* Minimum kernel version w/TLS */ +-3: .p2align 2 /* pad out section */ +-#endif /* GLX_USE_TLS */ + + #if defined (__ELF__) && defined (__linux__) + .section .note.GNU-stack,"",%progbits +--- a/src/mesa/x86/glapi_x86.S ++++ b/src/mesa/x86/glapi_x86.S +@@ -1279,18 +1279,6 @@ GLNAME(gl_dispatch_functions_start): + ALIGNTEXT16 + GLNAME(gl_dispatch_functions_end): + +-#if defined(GLX_USE_TLS) && defined(__linux__) +- .section ".note.ABI-tag", "a" +- .p2align 2 +- .long 1f - 0f /* name length */ +- .long 3f - 2f /* data length */ +- .long 1 /* note length */ +-0: .asciz "GNU" /* vendor name */ +-1: .p2align 2 +-2: .long 0 /* note data: the ABI tag */ +- .long 2,4,20 /* Minimum kernel version w/TLS */ +-3: .p2align 2 /* pad out section */ +-#endif /* GLX_USE_TLS */ + + #if defined (__ELF__) && defined (__linux__) + .section .note.GNU-stack,"",%progbits --- mesa-7.8.2.orig/debian/patches/101_ubuntu_hidden_glname.patch +++ mesa-7.8.2/debian/patches/101_ubuntu_hidden_glname.patch @@ -0,0 +1,12 @@ +Index: mesa/src/mesa/x86/glapi_x86.S +=================================================================== +--- mesa.orig/src/mesa/x86/glapi_x86.S 2009-06-29 14:43:07.000000000 +0300 ++++ mesa/src/mesa/x86/glapi_x86.S 2009-06-29 14:45:38.000000000 +0300 +@@ -148,7 +148,6 @@ + + ALIGNTEXT16 + GLOBL GLNAME(gl_dispatch_functions_start) +- HIDDEN(GLNAME(gl_dispatch_functions_start)) + GLNAME(gl_dispatch_functions_start): + + GL_STUB(NewList, _gloffset_NewList, NewList@8) --- mesa-7.8.2.orig/debian/patches/103_savage-expose_fbmodes_with_nonzero_alpha.patch +++ mesa-7.8.2/debian/patches/103_savage-expose_fbmodes_with_nonzero_alpha.patch @@ -0,0 +1,99 @@ +Index: mesa/src/mesa/drivers/dri/savage/savage_xmesa.c +=================================================================== +--- mesa.orig/src/mesa/drivers/dri/savage/savage_xmesa.c 2010-05-19 08:53:43.544920275 +1000 ++++ mesa/src/mesa/drivers/dri/savage/savage_xmesa.c 2010-05-19 10:59:49.573978367 +1000 +@@ -64,6 +64,8 @@ + + #include "xmlpool.h" + ++#define ARRAY_SIZE(x) (sizeof(x) / sizeof(x[0])) ++ + /* Driver-specific options + */ + #define SAVAGE_ENABLE_VDMA(def) \ +@@ -893,32 +895,33 @@ + unsigned stencil_bits, GLboolean have_back_buffer ) + { + __DRIconfig **configs; ++ __DRIconfig **configs_a8r8g8b8; ++ __DRIconfig **configs_x8r8g8b8; + __GLcontextModes * m; + unsigned depth_buffer_factor; + unsigned back_buffer_factor; +- GLenum fb_format; +- GLenum fb_type; ++ uint8_t depth_bits_array[2]; ++ uint8_t stencil_bits_array[2]; ++ uint8_t msaa_samples_array[1]; + int i; + + /* Right now GLX_SWAP_COPY_OML isn't supported, but it would be easy + * enough to add support. Basically, if a context is created with an + * fbconfig where the swap method is GLX_SWAP_COPY_OML, pageflipping + * will never be used. +- * +- * FK: What about drivers that don't use page flipping? Could they +- * just expose GLX_SWAP_COPY_OML? + */ + static const GLenum back_buffer_modes[] = { + GLX_NONE, GLX_SWAP_UNDEFINED_OML /*, GLX_SWAP_COPY_OML */ + }; + +- uint8_t depth_bits_array[2]; +- uint8_t stencil_bits_array[2]; +- uint8_t msaa_samples_array[1]; +- ++ /* This being a DRI1 driver the depth buffer is always allocated, ++ * so it does not make sense to expose visuals without it. If this ++ * driver ever gets ported to DRI2 the first array value should be ++ * changed to 0 to expose modes without a depth buffer. ++ */ + depth_bits_array[0] = depth_bits; + depth_bits_array[1] = depth_bits; +- ++ + /* Just like with the accumulation buffer, always provide some modes + * with a stencil buffer. It will be a sw fallback, but some apps won't + * care about that. +@@ -932,19 +935,32 @@ + back_buffer_factor = (have_back_buffer) ? 2 : 1; + + if ( pixel_bits == 16 ) { +- fb_format = GL_RGB; +- fb_type = GL_UNSIGNED_SHORT_5_6_5; ++ configs = driCreateConfigs(GL_RGB, GL_UNSIGNED_SHORT_5_6_5, ++ depth_bits_array, stencil_bits_array, ++ depth_buffer_factor, ++ back_buffer_modes, back_buffer_factor, ++ msaa_samples_array, 1, GL_TRUE); + } + else { +- fb_format = GL_BGR; +- fb_type = GL_UNSIGNED_INT_8_8_8_8_REV; ++ configs_a8r8g8b8 = driCreateConfigs(GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV, ++ depth_bits_array, ++ stencil_bits_array, ++ depth_buffer_factor, ++ back_buffer_modes, ++ back_buffer_factor, ++ msaa_samples_array, 1, ++ GL_TRUE); ++ configs_x8r8g8b8 = driCreateConfigs(GL_BGR, GL_UNSIGNED_INT_8_8_8_8_REV, ++ depth_bits_array, ++ stencil_bits_array, ++ depth_buffer_factor, ++ back_buffer_modes, ++ back_buffer_factor, ++ msaa_samples_array, 1, ++ GL_TRUE); ++ configs = driConcatConfigs(configs_a8r8g8b8, configs_x8r8g8b8); + } + +- configs = driCreateConfigs(fb_format, fb_type, +- depth_bits_array, stencil_bits_array, +- depth_buffer_factor, +- back_buffer_modes, back_buffer_factor, +- msaa_samples_array, 1, GL_TRUE); + if (configs == NULL) { + fprintf( stderr, "[%s:%u] Error creating FBConfig!\n", + __func__, __LINE__ ); --- mesa-7.8.2.orig/debian/patches/107_glxgears_is_not_a_benchmark.patch +++ mesa-7.8.2/debian/patches/107_glxgears_is_not_a_benchmark.patch @@ -0,0 +1,11 @@ +--- a/progs/xdemos/glxgears.c ++++ b/progs/xdemos/glxgears.c +@@ -347,7 +347,7 @@ draw_frame(Display *dpy, Window win) + if (t - tRate0 >= 5.0) { + GLfloat seconds = t - tRate0; + GLfloat fps = frames / seconds; +- printf("%d frames in %3.1f seconds = %6.3f FPS\n", frames, seconds, ++ printf("%d frames in %3.1f seconds\n", frames, seconds, + fps); + tRate0 = t; + frames = 0; --- mesa-7.8.2.orig/debian/patches/03_optional-progs-and-install.patch +++ mesa-7.8.2/debian/patches/03_optional-progs-and-install.patch @@ -0,0 +1,60 @@ +Allow the programs that are to be built to be defined in the build +configuration. + +Provide an install target for installing the programs in $(INSTALL_DIR)/bin. + +This patch by Thierry Reding. +Not submitted to Mesa. +-- +Also remove references to GLU library since it is not required +and we don't actually build it at this point. + + +--- + progs/Makefile | 6 +++++- + progs/xdemos/Makefile | 7 ++++++- + 2 files changed, 11 insertions(+), 2 deletions(-) + +Index: mesa/progs/xdemos/Makefile +=================================================================== +--- mesa.orig/progs/xdemos/Makefile ++++ mesa/progs/xdemos/Makefile +@@ -13,7 +13,7 @@ + + LIBS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) $(APP_LIB_DEPS) + +-PROGS = \ ++PROGS ?= \ + corender \ + glsync \ + glthreads \ +@@ -69,6 +69,11 @@ + extra: $(EXTRA_PROGS) + + ++install: $(PROGS) ++ $(INSTALL) -d $(DESTDIR)$(INSTALL_DIR)/bin ++ $(INSTALL) -m 755 $(PROGS) $(DESTDIR)$(INSTALL_DIR)/bin ++ ++ + clean: + -rm -f $(PROGS) $(EXTRA_PROGS) + -rm -f *.o *~ +Index: mesa/progs/Makefile +=================================================================== +--- mesa.orig/progs/Makefile ++++ mesa/progs/Makefile +@@ -21,8 +21,12 @@ + fi \ + done + +-# Dummy install target + install: ++ @for dir in $(SUBDIRS) ; do \ ++ if [ -d $$dir ] ; then \ ++ (cd $$dir ; $(MAKE) install) ; \ ++ fi \ ++ done + + clean: + @list='$(SUBDIRS)'; for dir in $$list tests ; do \ --- mesa-7.8.2.orig/debian/patches/04_osmesa_version.diff +++ mesa-7.8.2/debian/patches/04_osmesa_version.diff @@ -0,0 +1,17 @@ +--- + src/mesa/drivers/osmesa/Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: mesa/src/mesa/drivers/osmesa/Makefile +=================================================================== +--- mesa.orig/src/mesa/drivers/osmesa/Makefile ++++ mesa/src/mesa/drivers/osmesa/Makefile +@@ -37,7 +37,7 @@ + # -DCHAN_BITS=16/32. + $(TOP)/$(LIB_DIR)/$(OSMESA_LIB_NAME): $(OBJECTS) $(CORE_MESA) + $(MKLIB) -o $(OSMESA_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \ +- -major $(MESA_MAJOR) -minor $(MESA_MINOR) -patch $(MESA_TINY) \ ++ -major 6 -minor 5 -patch 3 \ + -install $(TOP)/$(LIB_DIR) $(MKLIB_OPTIONS) \ + -id $(INSTALL_LIB_DIR)/lib$(OSMESA_LIB).$(MESA_MAJOR).dylib \ + $(OSMESA_LIB_DEPS) $(OBJECTS) $(CORE_MESA) --- mesa-7.8.2.orig/debian/patches/05_hurd-ftbfs.diff +++ mesa-7.8.2/debian/patches/05_hurd-ftbfs.diff @@ -0,0 +1,59 @@ +From: Samuel Thibault +Subject: Fix build on GNU/Hurd + +--- + configure.ac | 27 +++++++++++++++------------ + 1 file changed, 15 insertions(+), 12 deletions(-) + +Index: mesa/configure.ac +=================================================================== +--- mesa.orig/configure.ac ++++ mesa/configure.ac +@@ -585,6 +585,13 @@ + enable_xcb=no + fi + ++dnl Direct rendering or just indirect rendering ++AC_ARG_ENABLE([driglx-direct], ++ [AS_HELP_STRING([--disable-driglx-direct], ++ [enable direct rendering in GLX and EGL for DRI @<:@default=enabled@:>@])], ++ [driglx_direct="$enableval"], ++ [driglx_direct="yes"]) ++ + dnl + dnl libGL configuration per driver + dnl +@@ -618,12 +625,14 @@ + AC_MSG_ERROR([Can't use static libraries for DRI drivers]) + fi + +- # Check for libdrm +- PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED]) +- PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED]) +- PKG_CHECK_MODULES([GLPROTO], [glproto >= $GLPROTO_REQUIRED]) +- GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED glproto >= $GLPROTO_REQUIRED" +- DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED" ++ if test x"$driglx_direct" = xyes; then ++ # Check for libdrm ++ PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED]) ++ PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED]) ++ PKG_CHECK_MODULES([GLPROTO], [glproto >= $GLPROTO_REQUIRED]) ++ GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED glproto >= $GLPROTO_REQUIRED" ++ DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED" ++ fi + + # find the DRI deps for libGL + if test "$x11_pkgconfig" = yes; then +@@ -697,12 +706,6 @@ + [DRI_DRIVER_SEARCH_DIR="$withval"], + [DRI_DRIVER_SEARCH_DIR='${DRI_DRIVER_INSTALL_DIR}']) + AC_SUBST([DRI_DRIVER_SEARCH_DIR]) +-dnl Direct rendering or just indirect rendering +-AC_ARG_ENABLE([driglx-direct], +- [AS_HELP_STRING([--disable-driglx-direct], +- [enable direct rendering in GLX and EGL for DRI @<:@default=enabled@:>@])], +- [driglx_direct="$enableval"], +- [driglx_direct="yes"]) + dnl Which drivers to build - default is chosen by platform + AC_ARG_WITH([dri-drivers], + [AS_HELP_STRING([--with-dri-drivers@<:@=DIRS...@:>@], --- mesa-7.8.2.orig/debian/patches/06_kfreebsd-ftbfs.diff +++ mesa-7.8.2/debian/patches/06_kfreebsd-ftbfs.diff @@ -0,0 +1,23 @@ +From: Aurelien Jarno + +mesa fails to build on GNU/kFreeBSD, since some parts are not enabled. + +http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=524690 + +--- + configure.ac | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +Index: mesa/configure.ac +=================================================================== +--- mesa.orig/configure.ac ++++ mesa/configure.ac +@@ -777,7 +777,7 @@ + ;; + esac + ;; +- freebsd* | dragonfly*) ++ freebsd* | dragonfly* | kfreebsd*-gnu*) + DEFINES="$DEFINES -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1" + DEFINES="$DEFINES -DIN_DRI_DRIVER -DHAVE_ALIAS" + DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING" --- mesa-7.8.2.orig/debian/patches/07-nouveau-update.diff +++ mesa-7.8.2/debian/patches/07-nouveau-update.diff @@ -0,0 +1,9059 @@ +From: Robert Hooker +Subject: nouveau: Import latest nouveau_class.h from renouveau + +And fix nv50_screen.c to compile against the updated header. + +Cherry-pick from upstream commit 54526154c5b02be0fbae6b0dad766c6be1bee21 +with modifications to apply to mesa 7.8 branch. +--- +Index: mesa/src/gallium/drivers/nouveau/nouveau_class.h +=================================================================== +--- /dev/null ++++ mesa/src/gallium/drivers/nouveau/nouveau_class.h +@@ -0,0 +1,9024 @@ ++/************************************************************************* ++ ++ Autogenerated file, do not edit ! ++ ++ This file was generated by renouveau-gen from renouveau.xml, the ++ XML database of nvidia objects and methods. renouveau-gen and ++ renouveau.xml can be found in CVS module renouveau of sourceforge.net ++ project nouveau: ++ ++cvs -z3 -d:pserver:anonymous@nouveau.cvs.sourceforge.net:/cvsroot/nouveau co -P renouveau ++ ++************************************************************************** ++ ++ Copyright (C) 2006-2008 : ++ Dmitry Baryshkov, ++ Laurent Carlier, ++ Matthieu Castet, ++ Dawid Gajownik, ++ Jeremy Kolb, ++ Stephane Loeuillet, ++ Patrice Mandin, ++ Stephane Marchesin, ++ Serge Martin, ++ Sylvain Munaut, ++ Simon Raffeiner, ++ Ben Skeggs, ++ Erik Waling, ++ koala_br, ++ ++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"), to deal in the Software without restriction, including ++without limitation the rights to use, copy, modify, merge, publish, ++distribute, sublicense, and/or sell copies of the Software, and to ++permit persons to whom the Software is furnished to do so, subject to ++the following conditions: ++ ++The above copyright notice and this permission notice (including the ++next paragraph) shall be included in all copies or substantial ++portions of the Software. ++ ++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, ++EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF ++MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. ++IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE ++LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION ++OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION ++WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ++ ++*************************************************************************/ ++ ++ ++#ifndef NOUVEAU_REG_H ++#define NOUVEAU_REG_H 1 ++ ++ ++#define NV01_ROOT 0x00000001 ++ ++ ++ ++#define NV01_CONTEXT_DMA 0x00000002 ++ ++ ++ ++#define NV01_DEVICE 0x00000003 ++ ++ ++ ++#define NV01_TIMER 0x00000004 ++ ++#define NV01_TIMER_SYNCHRONIZE 0x00000100 ++#define NV01_TIMER_STOP_ALARM 0x00000104 ++#define NV01_TIMER_DMA_NOTIFY 0x00000180 ++#define NV01_TIMER_TIME(x) (0x00000300+((x)*4)) ++#define NV01_TIMER_TIME__SIZE 0x00000002 ++#define NV01_TIMER_ALARM_NOTIFY 0x00000308 ++ ++ ++#define NV01_CONTEXT_BETA1 0x00000012 ++ ++#define NV01_CONTEXT_BETA1_NOP 0x00000100 ++#define NV01_CONTEXT_BETA1_NOTIFY 0x00000104 ++#define NV01_CONTEXT_BETA1_DMA_NOTIFY 0x00000180 ++#define NV01_CONTEXT_BETA1_BETA_1D31 0x00000300 ++ ++ ++#define NV01_CONTEXT_COLOR_KEY 0x00000017 ++ ++#define NV01_CONTEXT_COLOR_KEY_NOP 0x00000100 ++#define NV01_CONTEXT_COLOR_KEY_NOTIFY 0x00000104 ++#define NV01_CONTEXT_COLOR_KEY_DMA_NOTIFY 0x00000180 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT 0x00000300 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X16A8Y8 0x00000001 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X24Y8 0x00000002 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X16A1R5G5B5 0x00000003 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X17R5G5B5 0x00000004 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_A8R8G8B8 0x00000005 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X8R8G8B8 0x00000006 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_A16Y16 0x00000007 ++#define NV01_CONTEXT_COLOR_KEY_COLOR_FORMAT_X16Y16 0x00000008 ++#define NV01_CONTEXT_COLOR_KEY_COLOR 0x00000304 ++ ++ ++#define NV04_CONTEXT_COLOR_KEY 0x00000057 ++ ++ ++ ++#define NV01_CONTEXT_PATTERN 0x00000018 ++ ++#define NV01_CONTEXT_PATTERN_NOP 0x00000100 ++#define NV01_CONTEXT_PATTERN_NOTIFY 0x00000104 ++#define NV01_CONTEXT_PATTERN_DMA_NOTIFY 0x00000180 ++#define NV01_CONTEXT_PATTERN_COLOR_FORMAT 0x00000300 ++#define NV01_CONTEXT_PATTERN_MONOCHROME_FORMAT 0x00000304 ++#define NV01_CONTEXT_PATTERN_SHAPE 0x00000308 ++#define NV01_CONTEXT_PATTERN_COLOR(x) (0x00000310+((x)*4)) ++#define NV01_CONTEXT_PATTERN_COLOR__SIZE 0x00000002 ++#define NV01_CONTEXT_PATTERN_PATTERN(x) (0x00000318+((x)*4)) ++#define NV01_CONTEXT_PATTERN_PATTERN__SIZE 0x00000002 ++ ++ ++#define NV01_CONTEXT_CLIP_RECTANGLE 0x00000019 ++ ++#define NV01_CONTEXT_CLIP_RECTANGLE_NOP 0x00000100 ++#define NV01_CONTEXT_CLIP_RECTANGLE_NOTIFY 0x00000104 ++#define NV01_CONTEXT_CLIP_RECTANGLE_DMA_NOTIFY 0x00000180 ++#define NV01_CONTEXT_CLIP_RECTANGLE_POINT 0x00000300 ++#define NV01_CONTEXT_CLIP_RECTANGLE_POINT_X_SHIFT 0 ++#define NV01_CONTEXT_CLIP_RECTANGLE_POINT_X_MASK 0x0000ffff ++#define NV01_CONTEXT_CLIP_RECTANGLE_POINT_Y_SHIFT 16 ++#define NV01_CONTEXT_CLIP_RECTANGLE_POINT_Y_MASK 0xffff0000 ++#define NV01_CONTEXT_CLIP_RECTANGLE_SIZE 0x00000304 ++#define NV01_CONTEXT_CLIP_RECTANGLE_SIZE_W_SHIFT 0 ++#define NV01_CONTEXT_CLIP_RECTANGLE_SIZE_W_MASK 0x0000ffff ++#define NV01_CONTEXT_CLIP_RECTANGLE_SIZE_H_SHIFT 16 ++#define NV01_CONTEXT_CLIP_RECTANGLE_SIZE_H_MASK 0xffff0000 ++ ++ ++#define NV01_RENDER_SOLID_LINE 0x0000001c ++ ++#define NV01_RENDER_SOLID_LINE_NOP 0x00000100 ++#define NV01_RENDER_SOLID_LINE_NOTIFY 0x00000104 ++#define NV01_RENDER_SOLID_LINE_PATCH 0x0000010c ++#define NV01_RENDER_SOLID_LINE_DMA_NOTIFY 0x00000180 ++#define NV01_RENDER_SOLID_LINE_CLIP_RECTANGLE 0x00000184 ++#define NV01_RENDER_SOLID_LINE_PATTERN 0x00000188 ++#define NV01_RENDER_SOLID_LINE_ROP 0x0000018c ++#define NV01_RENDER_SOLID_LINE_BETA1 0x00000190 ++#define NV01_RENDER_SOLID_LINE_SURFACE 0x00000194 ++#define NV01_RENDER_SOLID_LINE_OPERATION 0x000002fc ++#define NV01_RENDER_SOLID_LINE_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV01_RENDER_SOLID_LINE_OPERATION_ROP_AND 0x00000001 ++#define NV01_RENDER_SOLID_LINE_OPERATION_BLEND_AND 0x00000002 ++#define NV01_RENDER_SOLID_LINE_OPERATION_SRCCOPY 0x00000003 ++#define NV01_RENDER_SOLID_LINE_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV01_RENDER_SOLID_LINE_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT 0x00000300 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X16A8Y8 0x00000001 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X24Y8 0x00000002 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X16A1R5G5B5 0x00000003 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X17R5G5B5 0x00000004 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_A8R8G8B8 0x00000005 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X8R8G8B8 0x00000006 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_A16Y16 0x00000007 ++#define NV01_RENDER_SOLID_LINE_COLOR_FORMAT_X16Y16 0x00000008 ++#define NV01_RENDER_SOLID_LINE_COLOR 0x00000304 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0(x) (0x00000400+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0_X_SHIFT 0 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT0_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1(x) (0x00000404+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1_X_SHIFT 0 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_LINE_LINE_POINT1_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT0_X(x) (0x00000480+((x)*16)) ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT0_X__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT0_Y(x) (0x00000484+((x)*16)) ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT0_Y__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT1_X(x) (0x00000488+((x)*16)) ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT1_X__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT1_Y(x) (0x0000048c+((x)*16)) ++#define NV01_RENDER_SOLID_LINE_LINE32_POINT1_Y__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_POLYLINE(x) (0x00000500+((x)*4)) ++#define NV01_RENDER_SOLID_LINE_POLYLINE__SIZE 0x00000020 ++#define NV01_RENDER_SOLID_LINE_POLYLINE_X_SHIFT 0 ++#define NV01_RENDER_SOLID_LINE_POLYLINE_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_LINE_POLYLINE_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_LINE_POLYLINE_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_LINE_POLYLINE32_POINT_X(x) (0x00000580+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_POLYLINE32_POINT_X__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_POLYLINE32_POINT_Y(x) (0x00000584+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_POLYLINE32_POINT_Y__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_COLOR(x) (0x00000600+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_COLOR__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT(x) (0x00000604+((x)*8)) ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT_X_SHIFT 0 ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_LINE_CPOLYLINE_POINT_Y_MASK 0xffff0000 ++ ++ ++#define NV04_RENDER_SOLID_LINE 0x0000005c ++ ++#define NV04_RENDER_SOLID_LINE_BETA4 0x00000194 ++#define NV04_RENDER_SOLID_LINE_SURFACE 0x00000198 ++ ++ ++#define NV01_RENDER_SOLID_TRIANGLE 0x0000001d ++ ++#define NV01_RENDER_SOLID_TRIANGLE_NOP 0x00000100 ++#define NV01_RENDER_SOLID_TRIANGLE_NOTIFY 0x00000104 ++#define NV01_RENDER_SOLID_TRIANGLE_PATCH 0x0000010c ++#define NV01_RENDER_SOLID_TRIANGLE_DMA_NOTIFY 0x00000180 ++#define NV01_RENDER_SOLID_TRIANGLE_CLIP_RECTANGLE 0x00000184 ++#define NV01_RENDER_SOLID_TRIANGLE_PATTERN 0x00000188 ++#define NV01_RENDER_SOLID_TRIANGLE_ROP 0x0000018c ++#define NV01_RENDER_SOLID_TRIANGLE_BETA1 0x00000190 ++#define NV01_RENDER_SOLID_TRIANGLE_SURFACE 0x00000194 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION 0x000002fc ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_ROP_AND 0x00000001 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_BLEND_AND 0x00000002 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_SRCCOPY 0x00000003 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV01_RENDER_SOLID_TRIANGLE_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV01_RENDER_SOLID_TRIANGLE_COLOR_FORMAT 0x00000300 ++#define NV01_RENDER_SOLID_TRIANGLE_COLOR 0x00000304 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT0 0x00000310 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT0_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT0_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT0_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT0_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT1 0x00000314 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT1_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT1_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT1_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT1_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT2 0x00000318 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT2_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT2_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT2_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE_POINT2_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT0_X 0x00000320 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT0_Y 0x00000324 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT1_X 0x00000328 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT1_Y 0x0000032c ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT2_X 0x00000330 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIANGLE32_POINT2_Y 0x00000334 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH(x) (0x00000400+((x)*4)) ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH__SIZE 0x00000020 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH32_POINT_X(x) (0x00000480+((x)*8)) ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH32_POINT_X__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH32_POINT_Y(x) (0x00000484+((x)*8)) ++#define NV01_RENDER_SOLID_TRIANGLE_TRIMESH32_POINT_Y__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_COLOR(x) (0x00000500+((x)*16)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_COLOR__SIZE 0x00000008 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0(x) (0x00000504+((x)*16)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0__SIZE 0x00000008 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT0_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1(x) (0x00000508+((x)*16)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1__SIZE 0x00000008 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT1_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2(x) (0x0000050c+((x)*16)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2__SIZE 0x00000008 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIANGLE_POINT2_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_COLOR(x) (0x00000580+((x)*8)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_COLOR__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT(x) (0x00000584+((x)*8)) ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT_X_SHIFT 0 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_TRIANGLE_CTRIMESH_POINT_Y_MASK 0xffff0000 ++ ++ ++#define NV04_RENDER_SOLID_TRIANGLE 0x0000005d ++ ++#define NV04_RENDER_SOLID_TRIANGLE_BETA4 0x00000194 ++#define NV04_RENDER_SOLID_TRIANGLE_SURFACE 0x00000198 ++ ++ ++#define NV01_RENDER_SOLID_RECTANGLE 0x0000001e ++ ++#define NV01_RENDER_SOLID_RECTANGLE_NOP 0x00000100 ++#define NV01_RENDER_SOLID_RECTANGLE_NOTIFY 0x00000104 ++#define NV01_RENDER_SOLID_RECTANGLE_PATCH 0x0000010c ++#define NV01_RENDER_SOLID_RECTANGLE_DMA_NOTIFY 0x00000180 ++#define NV01_RENDER_SOLID_RECTANGLE_CLIP_RECTANGLE 0x00000184 ++#define NV01_RENDER_SOLID_RECTANGLE_PATTERN 0x00000188 ++#define NV01_RENDER_SOLID_RECTANGLE_ROP 0x0000018c ++#define NV01_RENDER_SOLID_RECTANGLE_BETA1 0x00000190 ++#define NV01_RENDER_SOLID_RECTANGLE_SURFACE 0x00000194 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION 0x000002fc ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_ROP_AND 0x00000001 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_BLEND_AND 0x00000002 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_SRCCOPY 0x00000003 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV01_RENDER_SOLID_RECTANGLE_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV01_RENDER_SOLID_RECTANGLE_COLOR_FORMAT 0x00000300 ++#define NV01_RENDER_SOLID_RECTANGLE_COLOR 0x00000304 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT(x) (0x00000400+((x)*8)) ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT_X_SHIFT 0 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT_X_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT_Y_SHIFT 16 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_POINT_Y_MASK 0xffff0000 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE(x) (0x00000404+((x)*8)) ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE__SIZE 0x00000010 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE_W_SHIFT 0 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE_W_MASK 0x0000ffff ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE_H_SHIFT 16 ++#define NV01_RENDER_SOLID_RECTANGLE_RECTANGLE_SIZE_H_MASK 0xffff0000 ++ ++ ++#define NV04_RENDER_SOLID_RECTANGLE 0x0000005e ++ ++#define NV04_RENDER_SOLID_RECTANGLE_BETA4 0x00000194 ++#define NV04_RENDER_SOLID_RECTANGLE_SURFACE 0x00000198 ++ ++ ++#define NV01_IMAGE_BLIT 0x0000001f ++ ++#define NV01_IMAGE_BLIT_NOP 0x00000100 ++#define NV01_IMAGE_BLIT_NOTIFY 0x00000104 ++#define NV01_IMAGE_BLIT_PATCH 0x0000010c ++#define NV01_IMAGE_BLIT_DMA_NOTIFY 0x00000180 ++#define NV01_IMAGE_BLIT_COLOR_KEY 0x00000184 ++#define NV01_IMAGE_BLIT_CLIP_RECTANGLE 0x00000188 ++#define NV01_IMAGE_BLIT_PATTERN 0x0000018c ++#define NV01_IMAGE_BLIT_ROP 0x00000190 ++#define NV01_IMAGE_BLIT_BETA1 0x00000194 ++#define NV01_IMAGE_BLIT_SURFACE 0x0000019c ++#define NV01_IMAGE_BLIT_OPERATION 0x000002fc ++#define NV01_IMAGE_BLIT_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV01_IMAGE_BLIT_OPERATION_ROP_AND 0x00000001 ++#define NV01_IMAGE_BLIT_OPERATION_BLEND_AND 0x00000002 ++#define NV01_IMAGE_BLIT_OPERATION_SRCCOPY 0x00000003 ++#define NV01_IMAGE_BLIT_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV01_IMAGE_BLIT_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV01_IMAGE_BLIT_IMAGE_INPUT 0x00000204 ++#define NV01_IMAGE_BLIT_POINT_IN 0x00000300 ++#define NV01_IMAGE_BLIT_POINT_IN_X_SHIFT 0 ++#define NV01_IMAGE_BLIT_POINT_IN_X_MASK 0x0000ffff ++#define NV01_IMAGE_BLIT_POINT_IN_Y_SHIFT 16 ++#define NV01_IMAGE_BLIT_POINT_IN_Y_MASK 0xffff0000 ++#define NV01_IMAGE_BLIT_POINT_OUT 0x00000304 ++#define NV01_IMAGE_BLIT_POINT_OUT_X_SHIFT 0 ++#define NV01_IMAGE_BLIT_POINT_OUT_X_MASK 0x0000ffff ++#define NV01_IMAGE_BLIT_POINT_OUT_Y_SHIFT 16 ++#define NV01_IMAGE_BLIT_POINT_OUT_Y_MASK 0xffff0000 ++#define NV01_IMAGE_BLIT_SIZE 0x00000308 ++#define NV01_IMAGE_BLIT_SIZE_W_SHIFT 0 ++#define NV01_IMAGE_BLIT_SIZE_W_MASK 0x0000ffff ++#define NV01_IMAGE_BLIT_SIZE_H_SHIFT 16 ++#define NV01_IMAGE_BLIT_SIZE_H_MASK 0xffff0000 ++ ++ ++#define NV04_IMAGE_BLIT 0x0000005f ++ ++#define NV04_IMAGE_BLIT_ROP 0x00000190 ++#define NV04_IMAGE_BLIT_BETA4 0x00000198 ++#define NV04_IMAGE_BLIT_SURFACE 0x0000019c ++ ++ ++#define NV12_IMAGE_BLIT 0x0000009f ++ ++#define NV12_IMAGE_BLIT_WAIT_FOR_IDLE 0x00000108 ++ ++ ++#define NV01_IMAGE_FROM_CPU 0x00000021 ++ ++#define NV01_IMAGE_FROM_CPU_NOP 0x00000100 ++#define NV01_IMAGE_FROM_CPU_NOTIFY 0x00000104 ++#define NV01_IMAGE_FROM_CPU_PATCH 0x0000010c ++#define NV01_IMAGE_FROM_CPU_DMA_NOTIFY 0x00000180 ++#define NV01_IMAGE_FROM_CPU_COLOR_KEY 0x00000184 ++#define NV01_IMAGE_FROM_CPU_CLIP_RECTANGLE 0x00000188 ++#define NV01_IMAGE_FROM_CPU_PATTERN 0x0000018c ++#define NV01_IMAGE_FROM_CPU_ROP 0x00000190 ++#define NV01_IMAGE_FROM_CPU_BETA1 0x00000194 ++#define NV01_IMAGE_FROM_CPU_SURFACE 0x00000198 ++#define NV01_IMAGE_FROM_CPU_OPERATION 0x000002fc ++#define NV01_IMAGE_FROM_CPU_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV01_IMAGE_FROM_CPU_OPERATION_ROP_AND 0x00000001 ++#define NV01_IMAGE_FROM_CPU_OPERATION_BLEND_AND 0x00000002 ++#define NV01_IMAGE_FROM_CPU_OPERATION_SRCCOPY 0x00000003 ++#define NV01_IMAGE_FROM_CPU_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV01_IMAGE_FROM_CPU_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT 0x00000300 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT_Y8 0x00000001 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT_A1R5G5B5 0x00000002 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT_X1R5G5B5 0x00000003 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT_A8R8G8B8 0x00000004 ++#define NV01_IMAGE_FROM_CPU_COLOR_FORMAT_X8R8G8B8 0x00000005 ++#define NV01_IMAGE_FROM_CPU_POINT 0x00000304 ++#define NV01_IMAGE_FROM_CPU_POINT_X_SHIFT 0 ++#define NV01_IMAGE_FROM_CPU_POINT_X_MASK 0x0000ffff ++#define NV01_IMAGE_FROM_CPU_POINT_Y_SHIFT 16 ++#define NV01_IMAGE_FROM_CPU_POINT_Y_MASK 0xffff0000 ++#define NV01_IMAGE_FROM_CPU_SIZE_OUT 0x00000308 ++#define NV01_IMAGE_FROM_CPU_SIZE_OUT_W_SHIFT 0 ++#define NV01_IMAGE_FROM_CPU_SIZE_OUT_W_MASK 0x0000ffff ++#define NV01_IMAGE_FROM_CPU_SIZE_OUT_H_SHIFT 16 ++#define NV01_IMAGE_FROM_CPU_SIZE_OUT_H_MASK 0xffff0000 ++#define NV01_IMAGE_FROM_CPU_SIZE_IN 0x0000030c ++#define NV01_IMAGE_FROM_CPU_SIZE_IN_W_SHIFT 0 ++#define NV01_IMAGE_FROM_CPU_SIZE_IN_W_MASK 0x0000ffff ++#define NV01_IMAGE_FROM_CPU_SIZE_IN_H_SHIFT 16 ++#define NV01_IMAGE_FROM_CPU_SIZE_IN_H_MASK 0xffff0000 ++#define NV01_IMAGE_FROM_CPU_COLOR(x) (0x00000400+((x)*4)) ++#define NV01_IMAGE_FROM_CPU_COLOR__SIZE 0x00000020 ++ ++ ++#define NV04_IMAGE_FROM_CPU 0x00000061 ++ ++#define NV04_IMAGE_FROM_CPU_BETA4 0x00000198 ++#define NV04_IMAGE_FROM_CPU_SURFACE 0x0000019c ++ ++ ++#define NV05_IMAGE_FROM_CPU 0x00000065 ++ ++#define NV05_IMAGE_FROM_CPU_COLOR_CONVERSION 0x000002f8 ++ ++ ++#define NV10_IMAGE_FROM_CPU 0x0000008a ++ ++#define NV10_IMAGE_FROM_CPU_WAIT_FOR_IDLE 0x00000108 ++ ++ ++#define NV30_IMAGE_FROM_CPU 0x0000038a ++ ++ ++ ++#define NV40_IMAGE_FROM_CPU 0x0000308a ++ ++ ++ ++#define NV01_NULL 0x00000030 ++ ++ ++ ++#define NV03_STRETCHED_IMAGE_FROM_CPU 0x00000036 ++ ++#define NV03_STRETCHED_IMAGE_FROM_CPU_NOP 0x00000100 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_NOTIFY 0x00000104 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_PATCH 0x0000010c ++#define NV03_STRETCHED_IMAGE_FROM_CPU_DMA_NOTIFY 0x00000180 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_COLOR_KEY 0x00000184 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_PATTERN 0x00000188 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_ROP 0x0000018c ++#define NV03_STRETCHED_IMAGE_FROM_CPU_BETA1 0x00000190 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SURFACE 0x00000194 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_OPERATION 0x000002fc ++#define NV03_STRETCHED_IMAGE_FROM_CPU_COLOR_FORMAT 0x00000300 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SIZE_IN 0x00000304 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SIZE_IN_W_SHIFT 0 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SIZE_IN_W_MASK 0x0000ffff ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SIZE_IN_H_SHIFT 16 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_SIZE_IN_H_MASK 0xffff0000 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_DX_DU 0x00000308 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_DY_DV 0x0000030c ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_POINT 0x00000310 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_POINT_X_SHIFT 0 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_POINT_X_MASK 0x0000ffff ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_POINT_Y_SHIFT 16 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_POINT_Y_MASK 0xffff0000 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_SIZE 0x00000314 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_SIZE_W_SHIFT 0 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_SIZE_W_MASK 0x0000ffff ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_SIZE_H_SHIFT 16 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_CLIP_SIZE_H_MASK 0xffff0000 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_POINT12D4 0x00000318 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_POINT12D4_X_SHIFT 0 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_POINT12D4_X_MASK 0x0000ffff ++#define NV03_STRETCHED_IMAGE_FROM_CPU_POINT12D4_Y_SHIFT 16 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_POINT12D4_Y_MASK 0xffff0000 ++#define NV03_STRETCHED_IMAGE_FROM_CPU_COLOR(x) (0x00000400+((x)*4)) ++#define NV03_STRETCHED_IMAGE_FROM_CPU_COLOR__SIZE 0x00000020 ++ ++ ++#define NV04_STRETCHED_IMAGE_FROM_CPU 0x00000076 ++ ++#define NV04_STRETCHED_IMAGE_FROM_CPU_BETA4 0x00000194 ++#define NV04_STRETCHED_IMAGE_FROM_CPU_SURFACE 0x00000198 ++ ++ ++#define NV05_STRETCHED_IMAGE_FROM_CPU 0x00000066 ++ ++#define NV05_STRETCHED_IMAGE_FROM_CPU_COLOR_CONVERSION 0x000002f8 ++ ++ ++#define NV30_STRETCHED_IMAGE_FROM_CPU 0x00000366 ++ ++ ++ ++#define NV40_STRETCHED_IMAGE_FROM_CPU 0x00003066 ++ ++ ++ ++#define NV03_SCALED_IMAGE_FROM_MEMORY 0x00000037 ++ ++#define NV03_SCALED_IMAGE_FROM_MEMORY_NOP 0x00000100 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_NOTIFY 0x00000104 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_DMA_NOTIFY 0x00000180 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_DMA_IMAGE 0x00000184 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_PATTERN 0x00000188 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_ROP 0x0000018c ++#define NV03_SCALED_IMAGE_FROM_MEMORY_BETA1 0x00000190 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SURFACE 0x00000194 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT 0x00000300 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_A1R5G5B5 0x00000001 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_X1R5G5B5 0x00000002 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_A8R8G8B8 0x00000003 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_X8R8G8B8 0x00000004 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_V8YB8U8YA8 0x00000005 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_YB8V8YA8U8 0x00000006 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_R5G6B5 0x00000007 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_Y8 0x00000008 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_COLOR_FORMAT_AY8 0x00000009 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION 0x00000304 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_ROP_AND 0x00000001 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_BLEND_AND 0x00000002 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_SRCCOPY 0x00000003 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_POINT 0x00000308 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_POINT_X_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_POINT_X_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_POINT_Y_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_POINT_Y_MASK 0xffff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_SIZE 0x0000030c ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_SIZE_W_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_SIZE_W_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_SIZE_H_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_CLIP_SIZE_H_MASK 0xffff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_POINT 0x00000310 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_POINT_X_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_POINT_X_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_POINT_Y_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_POINT_Y_MASK 0xffff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_SIZE 0x00000314 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_SIZE_W_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_SIZE_W_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_SIZE_H_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OUT_SIZE_H_MASK 0xffff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_DU_DX 0x00000318 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_DV_DY 0x0000031c ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SIZE 0x00000400 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SIZE_W_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SIZE_W_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SIZE_H_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_SIZE_H_MASK 0xffff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT 0x00000404 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_PITCH_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_PITCH_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_ORIGIN_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_ORIGIN_MASK 0x00ff0000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_ORIGIN_CENTER 0x00010000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_ORIGIN_CORNER 0x00020000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_FILTER_SHIFT 24 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_FILTER_MASK 0xff000000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_FILTER_POINT_SAMPLE 0x00000000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_FORMAT_FILTER_BILINEAR 0x01000000 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_OFFSET 0x00000408 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_POINT 0x0000040c ++#define NV03_SCALED_IMAGE_FROM_MEMORY_POINT_U_SHIFT 0 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_POINT_U_MASK 0x0000ffff ++#define NV03_SCALED_IMAGE_FROM_MEMORY_POINT_V_SHIFT 16 ++#define NV03_SCALED_IMAGE_FROM_MEMORY_POINT_V_MASK 0xffff0000 ++ ++ ++#define NV04_SCALED_IMAGE_FROM_MEMORY 0x00000077 ++ ++#define NV04_SCALED_IMAGE_FROM_MEMORY_BETA4 0x00000194 ++#define NV04_SCALED_IMAGE_FROM_MEMORY_SURFACE 0x00000198 ++ ++ ++#define NV05_SCALED_IMAGE_FROM_MEMORY 0x00000063 ++ ++#define NV05_SCALED_IMAGE_FROM_MEMORY_COLOR_CONVERSION 0x000002fc ++#define NV05_SCALED_IMAGE_FROM_MEMORY_COLOR_CONVERSION_DITHER 0x00000000 ++#define NV05_SCALED_IMAGE_FROM_MEMORY_COLOR_CONVERSION_TRUNCATE 0x00000001 ++#define NV05_SCALED_IMAGE_FROM_MEMORY_COLOR_CONVERSION_SUBTR_TRUNCATE 0x00000002 ++ ++ ++#define NV10_SCALED_IMAGE_FROM_MEMORY 0x00000089 ++ ++#define NV10_SCALED_IMAGE_FROM_MEMORY_WAIT_FOR_IDLE 0x00000108 ++ ++ ++#define NV30_SCALED_IMAGE_FROM_MEMORY 0x00000389 ++ ++ ++ ++#define NV40_SCALED_IMAGE_FROM_MEMORY 0x00003089 ++ ++ ++ ++#define NV04_DVD_SUBPICTURE 0x00000038 ++ ++#define NV04_DVD_SUBPICTURE_NOP 0x00000100 ++#define NV04_DVD_SUBPICTURE_NOTIFY 0x00000104 ++#define NV04_DVD_SUBPICTURE_DMA_NOTIFY 0x00000180 ++#define NV04_DVD_SUBPICTURE_DMA_OVERLAY 0x00000184 ++#define NV04_DVD_SUBPICTURE_DMA_IMAGEIN 0x00000188 ++#define NV04_DVD_SUBPICTURE_DMA_IMAGEOUT 0x0000018c ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_POINT 0x00000300 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_POINT_X_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_POINT_X_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_POINT_Y_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_POINT_Y_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_SIZE 0x00000304 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_SIZE_W_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_SIZE_W_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_SIZE_H_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_SIZE_H_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_FORMAT 0x00000308 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_FORMAT_PITCH_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_FORMAT_PITCH_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_FORMAT_COLOR_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_FORMAT_COLOR_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_IMAGEOUT_OFFSET 0x0000030c ++#define NV04_DVD_SUBPICTURE_IMAGEIN_DELTA_DU_DX 0x00000310 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_DELTA_DV_DY 0x00000314 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_SIZE 0x00000318 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_SIZE_W_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_SIZE_W_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEIN_SIZE_H_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_SIZE_H_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_FORMAT 0x0000031c ++#define NV04_DVD_SUBPICTURE_IMAGEIN_FORMAT_PITCH_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_FORMAT_PITCH_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEIN_FORMAT_COLOR_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_FORMAT_COLOR_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_OFFSET 0x00000320 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_POINT 0x00000324 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_POINT_U_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_POINT_U_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_IMAGEIN_POINT_V_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_IMAGEIN_POINT_V_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_OVERLAY_DELTA_DU_DX 0x00000328 ++#define NV04_DVD_SUBPICTURE_OVERLAY_DELTA_DV_DY 0x0000032c ++#define NV04_DVD_SUBPICTURE_OVERLAY_SIZE 0x00000330 ++#define NV04_DVD_SUBPICTURE_OVERLAY_SIZE_W_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_OVERLAY_SIZE_W_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_OVERLAY_SIZE_H_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_OVERLAY_SIZE_H_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_OVERLAY_FORMAT 0x00000334 ++#define NV04_DVD_SUBPICTURE_OVERLAY_FORMAT_PITCH_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_OVERLAY_FORMAT_PITCH_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_OVERLAY_FORMAT_COLOR_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_OVERLAY_FORMAT_COLOR_MASK 0xffff0000 ++#define NV04_DVD_SUBPICTURE_OVERLAY_OFFSET 0x00000338 ++#define NV04_DVD_SUBPICTURE_OVERLAY_POINT 0x0000033c ++#define NV04_DVD_SUBPICTURE_OVERLAY_POINT_U_SHIFT 0 ++#define NV04_DVD_SUBPICTURE_OVERLAY_POINT_U_MASK 0x0000ffff ++#define NV04_DVD_SUBPICTURE_OVERLAY_POINT_V_SHIFT 16 ++#define NV04_DVD_SUBPICTURE_OVERLAY_POINT_V_MASK 0xffff0000 ++ ++ ++#define NV10_DVD_SUBPICTURE 0x00000088 ++ ++#define NV10_DVD_SUBPICTURE_WAIT_FOR_IDLE 0x00000108 ++ ++ ++#define NV04_MEMORY_TO_MEMORY_FORMAT 0x00000039 ++ ++#define NV04_MEMORY_TO_MEMORY_FORMAT_NOP 0x00000100 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_NOTIFY 0x00000104 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_DMA_NOTIFY 0x00000180 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_DMA_BUFFER_IN 0x00000184 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_DMA_BUFFER_OUT 0x00000188 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN 0x0000030c ++#define NV04_MEMORY_TO_MEMORY_FORMAT_OFFSET_OUT 0x00000310 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_PITCH_IN 0x00000314 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_PITCH_OUT 0x00000318 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_LINE_LENGTH_IN 0x0000031c ++#define NV04_MEMORY_TO_MEMORY_FORMAT_LINE_COUNT 0x00000320 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_FORMAT 0x00000324 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_FORMAT_INPUT_INC_SHIFT 0 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_FORMAT_INPUT_INC_MASK 0x000000ff ++#define NV04_MEMORY_TO_MEMORY_FORMAT_FORMAT_OUTPUT_INC_SHIFT 8 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_FORMAT_OUTPUT_INC_MASK 0x0000ff00 ++#define NV04_MEMORY_TO_MEMORY_FORMAT_BUF_NOTIFY 0x00000328 ++ ++ ++#define NV50_MEMORY_TO_MEMORY_FORMAT 0x00005039 ++ ++#define NV50_MEMORY_TO_MEMORY_FORMAT_SERIALIZE 0x00000110 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_LINEAR_IN 0x00000200 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_MODE_IN 0x00000204 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_PITCH_IN 0x00000208 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_HEIGHT_IN 0x0000020c ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_DEPTH_IN 0x00000210 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN_Z 0x00000214 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN 0x00000218 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN_X_SHIFT 0 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN_X_MASK 0x0000ffff ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN_Y_SHIFT 16 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_IN_Y_MASK 0xffff0000 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_LINEAR_OUT 0x0000021c ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_MODE_OUT 0x00000220 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_PITCH_OUT 0x00000224 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_HEIGHT_OUT 0x00000228 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_DEPTH_OUT 0x0000022c ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT_Z 0x00000230 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT 0x00000234 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT_X_SHIFT 0 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT_X_MASK 0x0000ffff ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT_Y_SHIFT 16 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_TILING_POSITION_OUT_Y_MASK 0xffff0000 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_OFFSET_IN_HIGH 0x00000238 ++#define NV50_MEMORY_TO_MEMORY_FORMAT_OFFSET_OUT_HIGH 0x0000023c ++ ++ ++#define NV01_MEMORY_LOCAL_BANKED 0x0000003d ++ ++ ++ ++#define NV01_MAPPING_SYSTEM 0x0000003e ++ ++ ++ ++#define NV03_MEMORY_LOCAL_CURSOR 0x0000003f ++ ++ ++ ++#define NV01_MEMORY_LOCAL_LINEAR 0x00000040 ++ ++ ++ ++#define NV01_MAPPING_LOCAL 0x00000041 ++ ++ ++ ++#define NV04_CONTEXT_SURFACES_2D 0x00000042 ++ ++#define NV04_CONTEXT_SURFACES_2D_NOP 0x00000100 ++#define NV04_CONTEXT_SURFACES_2D_NOTIFY 0x00000104 ++#define NV04_CONTEXT_SURFACES_2D_PM_TRIGGER 0x00000140 ++#define NV04_CONTEXT_SURFACES_2D_DMA_NOTIFY 0x00000180 ++#define NV04_CONTEXT_SURFACES_2D_DMA_IMAGE_SOURCE 0x00000184 ++#define NV04_CONTEXT_SURFACES_2D_DMA_IMAGE_DESTIN 0x00000188 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT 0x00000300 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_Y8 0x00000001 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X1R5G5B5_Z1R5G5B5 0x00000002 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X1R5G5B5_X1R5G5B5 0x00000003 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_R5G6B5 0x00000004 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_Y16 0x00000005 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X8R8G8B8_Z8R8G8B8 0x00000006 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X8R8G8B8_X8R8G8B8 0x00000007 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X1A7R8G8B8_Z1A7R8G8B8 0x00000008 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_X1A7R8G8B8_X1A7R8G8B8 0x00000009 ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_A8R8G8B8 0x0000000a ++#define NV04_CONTEXT_SURFACES_2D_FORMAT_Y32 0x0000000b ++#define NV04_CONTEXT_SURFACES_2D_PITCH 0x00000304 ++#define NV04_CONTEXT_SURFACES_2D_PITCH_SOURCE_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_2D_PITCH_SOURCE_MASK 0x0000ffff ++#define NV04_CONTEXT_SURFACES_2D_PITCH_DESTIN_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_2D_PITCH_DESTIN_MASK 0xffff0000 ++#define NV04_CONTEXT_SURFACES_2D_OFFSET_SOURCE 0x00000308 ++#define NV04_CONTEXT_SURFACES_2D_OFFSET_DESTIN 0x0000030c ++ ++ ++#define NV10_CONTEXT_SURFACES_2D 0x00000062 ++ ++ ++ ++#define NV30_CONTEXT_SURFACES_2D 0x00000362 ++ ++ ++ ++#define NV40_CONTEXT_SURFACES_2D 0x00003062 ++ ++ ++ ++#define NV03_CONTEXT_ROP 0x00000043 ++ ++#define NV03_CONTEXT_ROP_NOP 0x00000100 ++#define NV03_CONTEXT_ROP_NOTIFY 0x00000104 ++#define NV03_CONTEXT_ROP_DMA_NOTIFY 0x00000180 ++#define NV03_CONTEXT_ROP_ROP 0x00000300 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_SHIFT 0 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_MASK 0x0000000f ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_CLEAR 0x00000000 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_NOR 0x00000001 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_AND_INVERTED 0x00000002 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_COPY_INVERTED 0x00000003 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_AND_REVERSE 0x00000004 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_INVERT 0x00000005 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_XOR 0x00000006 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_NAND 0x00000007 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_AND 0x00000008 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_EQUI 0x00000009 ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_NOOP 0x0000000a ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_OR_INVERTED 0x0000000b ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_COPY 0x0000000c ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_OR_REVERSE 0x0000000d ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_OR 0x0000000e ++#define NV03_CONTEXT_ROP_ROP_DST_LOGIC_OP_SET 0x0000000f ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_SHIFT 4 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_MASK 0x000000f0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_CLEAR 0x00000000 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_NOR 0x00000010 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_AND_INVERTED 0x00000020 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_COPY_INVERTED 0x00000030 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_AND_REVERSE 0x00000040 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_INVERT 0x00000050 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_XOR 0x00000060 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_NAND 0x00000070 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_AND 0x00000080 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_EQUI 0x00000090 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_NOOP 0x000000a0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_OR_INVERTED 0x000000b0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_COPY 0x000000c0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_OR_REVERSE 0x000000d0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_OR 0x000000e0 ++#define NV03_CONTEXT_ROP_ROP_SRC_LOGIC_OP_SET 0x000000f0 ++ ++ ++#define NV04_IMAGE_PATTERN 0x00000044 ++ ++#define NV04_IMAGE_PATTERN_NOP 0x00000100 ++#define NV04_IMAGE_PATTERN_NOTIFY 0x00000104 ++#define NV04_IMAGE_PATTERN_DMA_NOTIFY 0x00000180 ++#define NV04_IMAGE_PATTERN_COLOR_FORMAT 0x00000300 ++#define NV04_IMAGE_PATTERN_COLOR_FORMAT_A16R5G6B5 0x00000001 ++#define NV04_IMAGE_PATTERN_COLOR_FORMAT_X16A1R5G5B5 0x00000002 ++#define NV04_IMAGE_PATTERN_COLOR_FORMAT_A8R8G8B8 0x00000003 ++#define NV04_IMAGE_PATTERN_MONOCHROME_FORMAT 0x00000304 ++#define NV04_IMAGE_PATTERN_MONOCHROME_FORMAT_CGA6 0x00000001 ++#define NV04_IMAGE_PATTERN_MONOCHROME_FORMAT_LE 0x00000002 ++#define NV04_IMAGE_PATTERN_MONOCHROME_SHAPE 0x00000308 ++#define NV04_IMAGE_PATTERN_MONOCHROME_SHAPE_8X8 0x00000000 ++#define NV04_IMAGE_PATTERN_MONOCHROME_SHAPE_64X1 0x00000001 ++#define NV04_IMAGE_PATTERN_MONOCHROME_SHAPE_1X64 0x00000002 ++#define NV04_IMAGE_PATTERN_PATTERN_SELECT 0x0000030c ++#define NV04_IMAGE_PATTERN_PATTERN_SELECT_MONO 0x00000001 ++#define NV04_IMAGE_PATTERN_PATTERN_SELECT_COLOR 0x00000002 ++#define NV04_IMAGE_PATTERN_MONOCHROME_COLOR0 0x00000310 ++#define NV04_IMAGE_PATTERN_MONOCHROME_COLOR1 0x00000314 ++#define NV04_IMAGE_PATTERN_MONOCHROME_PATTERN0 0x00000318 ++#define NV04_IMAGE_PATTERN_MONOCHROME_PATTERN1 0x0000031c ++#define NV04_IMAGE_PATTERN_PATTERN_Y8(x) (0x00000400+((x)*4)) ++#define NV04_IMAGE_PATTERN_PATTERN_Y8__SIZE 0x00000010 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y0_SHIFT 0 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y0_MASK 0x000000ff ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y1_SHIFT 8 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y1_MASK 0x0000ff00 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y2_SHIFT 16 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y2_MASK 0x00ff0000 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y3_SHIFT 24 ++#define NV04_IMAGE_PATTERN_PATTERN_Y8_Y3_MASK 0xff000000 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5(x) (0x00000500+((x)*4)) ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5__SIZE 0x00000020 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_B0_SHIFT 0 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_B0_MASK 0x0000001f ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_G0_SHIFT 5 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_G0_MASK 0x000007e0 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_R0_SHIFT 11 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_R0_MASK 0x0000f800 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_B1_SHIFT 16 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_B1_MASK 0x001f0000 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_G1_SHIFT 21 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_G1_MASK 0x07e00000 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_R1_SHIFT 27 ++#define NV04_IMAGE_PATTERN_PATTERN_R5G6B5_R1_MASK 0xf8000000 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5(x) (0x00000600+((x)*4)) ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5__SIZE 0x00000020 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_B0_SHIFT 0 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_B0_MASK 0x0000001f ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_G0_SHIFT 5 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_G0_MASK 0x000003e0 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_R0_SHIFT 10 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_R0_MASK 0x00007c00 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_B1_SHIFT 16 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_B1_MASK 0x001f0000 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_G1_SHIFT 21 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_G1_MASK 0x03e00000 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_R1_SHIFT 26 ++#define NV04_IMAGE_PATTERN_PATTERN_X1R5G5B5_R1_MASK 0x7c000000 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8(x) (0x00000700+((x)*4)) ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8__SIZE 0x00000040 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_B_SHIFT 0 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_B_MASK 0x000000ff ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_G_SHIFT 8 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_G_MASK 0x0000ff00 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_R_SHIFT 16 ++#define NV04_IMAGE_PATTERN_PATTERN_X8R8G8B8_R_MASK 0x00ff0000 ++ ++ ++#define NV03_VIDEO_LUT_CURSOR_DAC 0x00000046 ++ ++#define NV03_VIDEO_LUT_CURSOR_DAC_SYNCHRONIZE 0x00000100 ++#define NV03_VIDEO_LUT_CURSOR_DAC_STOP_IMAGE 0x00000104 ++#define NV03_VIDEO_LUT_CURSOR_DAC_STOP_CURSOR 0x00000108 ++#define NV03_VIDEO_LUT_CURSOR_DAC_STOP_DAC 0x0000010c ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_NOTIFY 0x00000180 ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_IMAGE(x) (0x00000184+((x)*4)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_IMAGE__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_LUT(x) (0x0000018c+((x)*4)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_LUT__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_CURSOR(x) (0x00000194+((x)*4)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_DMA_CURSOR__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_GET 0x000002fc ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_OFFSET(x) (0x00000300+((x)*8)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_OFFSET__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT(x) (0x00000304+((x)*8)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_PITCH_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_PITCH_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_COLOR_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_COLOR_MASK 0x0fff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_NOTIFY_SHIFT 28 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_IMAGE_FORMAT_NOTIFY_MASK 0xf0000000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_OFFSET(x) (0x00000340+((x)*12)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_OFFSET__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT(x) (0x00000344+((x)*12)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_X_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_X_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_Y_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_Y_MASK 0xffff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_FORMAT(x) (0x00000348+((x)*12)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_FORMAT__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_A 0x00000358 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_A_X_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_A_X_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_A_Y_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_CURSOR_POINT_OUT_A_Y_MASK 0xffff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE(x) (0x00000380+((x)*16)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE_W_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE_W_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE_H_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_IMAGE_SIZE_H_MASK 0xffff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC(x) (0x00000384+((x)*16)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_START_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_START_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_WIDTH_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_WIDTH_MASK 0x0fff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_POLARITY_SHIFT 28 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_HSYNC_POLARITY_MASK 0xf0000000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC(x) (0x00000388+((x)*16)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_START_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_START_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_WIDTH_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_WIDTH_MASK 0x0fff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_POLARITY_SHIFT 28 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_VSYNC_POLARITY_MASK 0xf0000000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE(x) (0x0000038c+((x)*16)) ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE__SIZE 0x00000002 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_WIDTH_SHIFT 0 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_WIDTH_MASK 0x0000ffff ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_HEIGHT_SHIFT 16 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_HEIGHT_MASK 0x0fff0000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_NOTIFY_SHIFT 28 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_DAC_TOTAL_SIZE_NOTIFY_MASK 0xf0000000 ++#define NV03_VIDEO_LUT_CURSOR_DAC_SET_PIXEL_CLOCK 0x000003a0 ++ ++ ++#define NV03_TEXTURED_TRIANGLE 0x00000048 ++ ++#define NV03_TEXTURED_TRIANGLE_NOP 0x00000100 ++#define NV03_TEXTURED_TRIANGLE_NOTIFY 0x00000104 ++#define NV03_TEXTURED_TRIANGLE_PATCH 0x0000010c ++#define NV03_TEXTURED_TRIANGLE_DMA_NOTIFY 0x00000180 ++#define NV03_TEXTURED_TRIANGLE_DMA_TEXTURE 0x00000184 ++#define NV03_TEXTURED_TRIANGLE_CLIP_RECTANGLE 0x00000188 ++#define NV03_TEXTURED_TRIANGLE_SURFACE 0x0000018c ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_OFFSET 0x00000304 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT 0x00000308 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_KEY_MASK_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_KEY_MASK_MASK 0x0000ffff ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_KEY_ENABLE_SHIFT 16 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_KEY_ENABLE_MASK 0x000f0000 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_SHIFT 20 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_COLOR_MASK 0x00f00000 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_SIZE_MIN_SHIFT 24 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_SIZE_MIN_MASK 0x0f000000 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_SIZE_MAX_SHIFT 28 ++#define NV03_TEXTURED_TRIANGLE_TEXTURE_FORMAT_SIZE_MAX_MASK 0xf0000000 ++#define NV03_TEXTURED_TRIANGLE_FILTER 0x0000030c ++#define NV03_TEXTURED_TRIANGLE_FILTER_SPREAD_X_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_FILTER_SPREAD_X_MASK 0x0000001f ++#define NV03_TEXTURED_TRIANGLE_FILTER_SPREAD_Y_SHIFT 8 ++#define NV03_TEXTURED_TRIANGLE_FILTER_SPREAD_Y_MASK 0x00001f00 ++#define NV03_TEXTURED_TRIANGLE_FILTER_SIZE_ADJUST_SHIFT 16 ++#define NV03_TEXTURED_TRIANGLE_FILTER_SIZE_ADJUST_MASK 0x00ff0000 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR 0x00000310 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_B_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_B_MASK 0x000000ff ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_G_SHIFT 8 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_G_MASK 0x0000ff00 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_R_SHIFT 16 ++#define NV03_TEXTURED_TRIANGLE_FOG_COLOR_R_MASK 0x00ff0000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT 0x00000314 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_INTERPOLATOR_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_INTERPOLATOR_MASK 0x0000000f ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_WRAP_U_SHIFT 4 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_WRAP_U_MASK 0x00000030 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_WRAP_V_SHIFT 6 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_WRAP_V_MASK 0x000000c0 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_SOURCE_COLOR_SHIFT 8 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_SOURCE_COLOR_MASK 0x00000f00 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_CULLING_SHIFT 12 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_CULLING_MASK 0x00007000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_Z_PERSPECTIVE_ENABLE (1 << 15) ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_Z_FUNC_SHIFT 16 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_Z_FUNC_MASK 0x000f0000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_Z_WRITE_ENABLE_SHIFT 20 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_Z_WRITE_ENABLE_MASK 0x00f00000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_COLOR_WRITE_ENABLE_SHIFT 24 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_COLOR_WRITE_ENABLE_MASK 0x07000000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_ROP_SHIFT 27 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_ROP_MASK 0x18000000 ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_BETA (1 << 29) ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_DST_BLEND (1 << 30) ++#define NV03_TEXTURED_TRIANGLE_CONTROL_OUT_SRC_BLEND (1 << 31) ++#define NV03_TEXTURED_TRIANGLE_ALPHA_CONTROL 0x00000318 ++#define NV03_TEXTURED_TRIANGLE_ALPHA_CONTROL_ALPHA_REF_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_ALPHA_CONTROL_ALPHA_REF_MASK 0x000000ff ++#define NV03_TEXTURED_TRIANGLE_ALPHA_CONTROL_ALPHA_FUNC_SHIFT 8 ++#define NV03_TEXTURED_TRIANGLE_ALPHA_CONTROL_ALPHA_FUNC_MASK 0xffffff00 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR(x) (0x00001000+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I0_SHIFT 0 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I0_MASK 0x0000000f ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I1_SHIFT 4 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I1_MASK 0x000000f0 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I2_SHIFT 8 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I2_MASK 0x00000f00 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I3_SHIFT 12 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I3_MASK 0x0000f000 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I4_SHIFT 16 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I4_MASK 0x000f0000 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I5_SHIFT 20 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_I5_MASK 0x00f00000 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_FOG_SHIFT 24 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_FOG_MASK 0xff000000 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_COLOR(x) (0x00001004+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_COLOR__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SX(x) (0x00001008+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SX__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SY(x) (0x0000100c+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SY__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SZ(x) (0x00001010+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_SZ__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_RHW(x) (0x00001014+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_RHW__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_TU(x) (0x00001018+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_TU__SIZE 0x00000080 ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_TV(x) (0x0000101c+((x)*32)) ++#define NV03_TEXTURED_TRIANGLE_TLVERTEX_TV__SIZE 0x00000080 ++ ++ ++#define NV04_GDI_RECTANGLE_TEXT 0x0000004a ++ ++#define NV04_GDI_RECTANGLE_TEXT_NOP 0x00000100 ++#define NV04_GDI_RECTANGLE_TEXT_NOTIFY 0x00000104 ++#define NV04_GDI_RECTANGLE_TEXT_PATCH 0x0000010c ++#define NV04_GDI_RECTANGLE_TEXT_PM_TRIGGER 0x00000140 ++#define NV04_GDI_RECTANGLE_TEXT_DMA_NOTIFY 0x00000180 ++#define NV04_GDI_RECTANGLE_TEXT_DMA_FONTS 0x00000184 ++#define NV04_GDI_RECTANGLE_TEXT_PATTERN 0x00000188 ++#define NV04_GDI_RECTANGLE_TEXT_ROP 0x0000018c ++#define NV04_GDI_RECTANGLE_TEXT_BETA1 0x00000190 ++#define NV04_GDI_RECTANGLE_TEXT_BETA4 0x00000194 ++#define NV04_GDI_RECTANGLE_TEXT_SURFACE 0x00000198 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION 0x000002fc ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_ROP_AND 0x00000001 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_BLEND_AND 0x00000002 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_SRCCOPY 0x00000003 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV04_GDI_RECTANGLE_TEXT_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR_FORMAT 0x00000300 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR_FORMAT_A16R5G6B5 0x00000001 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR_FORMAT_X16A1R5G5B5 0x00000002 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR_FORMAT_A8R8G8B8 0x00000003 ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_FORMAT 0x00000304 ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_FORMAT_CGA6 0x00000001 ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_FORMAT_LE 0x00000002 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_A 0x000003fc ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT(x) (0x00000400+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT__SIZE 0x00000020 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_Y_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_Y_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_X_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_X_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE(x) (0x00000404+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE__SIZE 0x00000020 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_H_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_H_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_W_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_W_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT0 0x000005f4 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT1 0x000005f8 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_B_POINT1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_B 0x000005fc ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0(x) (0x00000600+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0__SIZE 0x00000020 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1(x) (0x00000604+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1__SIZE 0x00000020 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT0 0x000007ec ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT1 0x000007f0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_C 0x000007f4 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_C 0x000007f8 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_C_W_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_C_W_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_C_H_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_C_H_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_C 0x000007fc ++#define NV04_GDI_RECTANGLE_TEXT_POINT_C_X_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_C_X_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_POINT_C_Y_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_C_Y_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_C(x) (0x00000800+((x)*4)) ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_C__SIZE 0x00000080 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT0 0x00000be4 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT1 0x00000be8 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR0_E 0x00000bec ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_E 0x00000bf0 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_IN_E 0x00000bf4 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_IN_E_W_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_IN_E_W_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_IN_E_H_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_IN_E_H_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_OUT_E 0x00000bf8 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_OUT_E_W_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_OUT_E_W_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_OUT_E_H_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_SIZE_OUT_E_H_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_E 0x00000bfc ++#define NV04_GDI_RECTANGLE_TEXT_POINT_E_X_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_E_X_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_POINT_E_Y_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_POINT_E_Y_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR01_E(x) (0x00000c00+((x)*4)) ++#define NV04_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR01_E__SIZE 0x00000080 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_F 0x00000ff0 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_F_OFFSET_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_F_OFFSET_MASK 0x0fffffff ++#define NV04_GDI_RECTANGLE_TEXT_FONT_F_PITCH_SHIFT 28 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_F_PITCH_MASK 0xf0000000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT0 0x00000ff4 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT1 0x00000ff8 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_F_POINT1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_F 0x00000ffc ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F(x) (0x00001000+((x)*4)) ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F__SIZE 0x00000100 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_INDEX_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_INDEX_MASK 0x000000ff ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_X_SHIFT 8 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_X_MASK 0x000fff00 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_Y_SHIFT 20 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_F_Y_MASK 0xfff00000 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_G 0x000017f0 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_G_OFFSET_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_G_OFFSET_MASK 0x0fffffff ++#define NV04_GDI_RECTANGLE_TEXT_FONT_G_PITCH_SHIFT 28 ++#define NV04_GDI_RECTANGLE_TEXT_FONT_G_PITCH_MASK 0xf0000000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT0 0x000017f4 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT0_L_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT0_L_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT0_T_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT0_T_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT1 0x000017f8 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT1_R_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT1_R_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT1_B_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CLIP_G_POINT1_B_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_COLOR1_G 0x000017fc ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT(x) (0x00001800+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT__SIZE 0x00000100 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT_X_SHIFT 0 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT_X_MASK 0x0000ffff ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT_Y_SHIFT 16 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_POINT_Y_MASK 0xffff0000 ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_INDEX(x) (0x00001804+((x)*8)) ++#define NV04_GDI_RECTANGLE_TEXT_CHARACTER_COLOR1_G_INDEX__SIZE 0x00000100 ++ ++ ++#define NV03_GDI_RECTANGLE_TEXT 0x0000004b ++ ++#define NV03_GDI_RECTANGLE_TEXT_NOP 0x00000100 ++#define NV03_GDI_RECTANGLE_TEXT_NOTIFY 0x00000104 ++#define NV03_GDI_RECTANGLE_TEXT_DMA_NOTIFY 0x00000180 ++#define NV03_GDI_RECTANGLE_TEXT_PATTERN 0x00000184 ++#define NV03_GDI_RECTANGLE_TEXT_ROP 0x00000188 ++#define NV03_GDI_RECTANGLE_TEXT_BETA1 0x0000018c ++#define NV03_GDI_RECTANGLE_TEXT_SURFACE 0x00000190 ++#define NV03_GDI_RECTANGLE_TEXT_OPERATION 0x000002fc ++#define NV03_GDI_RECTANGLE_TEXT_COLOR_FORMAT 0x00000300 ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_FORMAT 0x00000304 ++#define NV03_GDI_RECTANGLE_TEXT_COLOR1_A 0x000003fc ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT 0x00000400 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_Y_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_Y_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_X_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_POINT_X_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE 0x00000404 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_H_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_H_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_W_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_UNCLIPPED_RECTANGLE_SIZE_W_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT0_B 0x000007f4 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT0_B_L_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT0_B_L_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT0_B_T_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT0_B_T_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT1_B 0x000007f8 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT1_B_R_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT1_B_R_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT1_B_B_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_POINT1_B_B_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_COLOR1_B 0x000007fc ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0 0x00000800 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_L_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_L_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_T_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_0_T_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1 0x00000804 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_R_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_R_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_B_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIPPED_RECTANGLE_POINT_1_B_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT0 0x00000bec ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_L_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_L_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_T_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT0_T_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT1 0x00000bf0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_R_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_R_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_B_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_C_POINT1_B_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_COLOR1_C 0x00000bf4 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_C 0x00000bf8 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_C_W_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_C_W_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_C_H_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_C_H_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_C 0x00000bfc ++#define NV03_GDI_RECTANGLE_TEXT_POINT_C_X_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_C_X_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_POINT_C_Y_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_C_Y_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_C(x) (0x00000c00+((x)*4)) ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_C__SIZE 0x00000020 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT0 0x00000fe8 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT0_L_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT0_L_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT0_T_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT0_T_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT1 0x00000fec ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT1_R_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT1_R_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT1_B_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_D_POINT1_B_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_COLOR1_D 0x00000ff0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_D 0x00000ff4 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_D_W_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_D_W_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_D_H_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_D_H_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_D 0x00000ff8 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_D_W_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_D_W_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_D_H_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_D_H_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_D 0x00000ffc ++#define NV03_GDI_RECTANGLE_TEXT_POINT_D_X_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_D_X_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_POINT_D_Y_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_D_Y_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_D(x) (0x00001000+((x)*4)) ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR1_D__SIZE 0x00000020 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT0 0x000013e4 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_L_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_L_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_T_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT0_T_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT1 0x000013e8 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_R_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_R_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_B_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_CLIP_E_POINT1_B_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_COLOR0_E 0x000013ec ++#define NV03_GDI_RECTANGLE_TEXT_COLOR1_E 0x000013f0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_E 0x000013f4 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_E_W_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_E_W_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_E_H_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_IN_E_H_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_E 0x000013f8 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_E_W_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_E_W_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_E_H_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_SIZE_OUT_E_H_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_E 0x000013fc ++#define NV03_GDI_RECTANGLE_TEXT_POINT_E_X_SHIFT 0 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_E_X_MASK 0x0000ffff ++#define NV03_GDI_RECTANGLE_TEXT_POINT_E_Y_SHIFT 16 ++#define NV03_GDI_RECTANGLE_TEXT_POINT_E_Y_MASK 0xffff0000 ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR01_E(x) (0x00001400+((x)*4)) ++#define NV03_GDI_RECTANGLE_TEXT_MONOCHROME_COLOR01_E__SIZE 0x00000020 ++ ++ ++#define NV04_SWIZZLED_SURFACE 0x00000052 ++ ++#define NV04_SWIZZLED_SURFACE_NOP 0x00000100 ++#define NV04_SWIZZLED_SURFACE_NOTIFY 0x00000104 ++#define NV04_SWIZZLED_SURFACE_DMA_NOTIFY 0x00000180 ++#define NV04_SWIZZLED_SURFACE_DMA_IMAGE 0x00000184 ++#define NV04_SWIZZLED_SURFACE_FORMAT 0x00000300 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_SHIFT 0 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_MASK 0x000000ff ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_Y8 0x00000001 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X1R5G5B5_Z1R5G5B5 0x00000002 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X1R5G5B5_X1R5G5B5 0x00000003 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_R5G6B5 0x00000004 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_Y16 0x00000005 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X8R8G8B8_Z8R8G8B8 0x00000006 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X8R8G8B8_X8R8G8B8 0x00000007 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X1A7R8G8B8_Z1A7R8G8B8 0x00000008 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_X1A7R8G8B8_X1A7R8G8B8 0x00000009 ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_A8R8G8B8 0x0000000a ++#define NV04_SWIZZLED_SURFACE_FORMAT_COLOR_Y32 0x0000000b ++#define NV04_SWIZZLED_SURFACE_FORMAT_BASE_SIZE_U_SHIFT 16 ++#define NV04_SWIZZLED_SURFACE_FORMAT_BASE_SIZE_U_MASK 0x00ff0000 ++#define NV04_SWIZZLED_SURFACE_FORMAT_BASE_SIZE_V_SHIFT 24 ++#define NV04_SWIZZLED_SURFACE_FORMAT_BASE_SIZE_V_MASK 0xff000000 ++#define NV04_SWIZZLED_SURFACE_OFFSET 0x00000304 ++ ++ ++#define NV20_SWIZZLED_SURFACE 0x0000009e ++ ++ ++ ++#define NV30_SWIZZLED_SURFACE 0x0000039e ++ ++ ++ ++#define NV40_SWIZZLED_SURFACE 0x0000309e ++ ++ ++ ++#define NV04_CONTEXT_SURFACES_3D 0x00000053 ++ ++#define NV04_CONTEXT_SURFACES_3D_NOP 0x00000100 ++#define NV04_CONTEXT_SURFACES_3D_NOTIFY 0x00000104 ++#define NV04_CONTEXT_SURFACES_3D_DMA_NOTIFY 0x00000180 ++#define NV04_CONTEXT_SURFACES_3D_DMA_COLOR 0x00000184 ++#define NV04_CONTEXT_SURFACES_3D_DMA_ZETA 0x00000188 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_HORIZONTAL 0x000002f8 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_HORIZONTAL_X_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_HORIZONTAL_X_MASK 0x0000ffff ++#define NV04_CONTEXT_SURFACES_3D_CLIP_HORIZONTAL_W_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_HORIZONTAL_W_MASK 0xffff0000 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_VERTICAL 0x000002fc ++#define NV04_CONTEXT_SURFACES_3D_CLIP_VERTICAL_Y_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_VERTICAL_Y_MASK 0x0000ffff ++#define NV04_CONTEXT_SURFACES_3D_CLIP_VERTICAL_H_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_VERTICAL_H_MASK 0xffff0000 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT 0x00000300 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_MASK 0x000000ff ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X1R5G5B5_Z1R5G5B5 0x00000001 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X1R5G5B5_X1R5G5B5 0x00000002 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_R5G6B5 0x00000003 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X8R8G8B8_Z8R8G8B8 0x00000004 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X8R8G8B8_X8R8G8B8 0x00000005 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X1A7R8G8B8_Z1A7R8G8B8 0x00000006 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_X1A7R8G8B8_X1A7R8G8B8 0x00000007 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_COLOR_A8R8G8B8 0x00000008 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_TYPE_SHIFT 8 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_TYPE_MASK 0x0000ff00 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_TYPE_PITCH 0x00000100 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_TYPE_SWIZZLE 0x00000200 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_BASE_SIZE_U_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_BASE_SIZE_U_MASK 0x00ff0000 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_BASE_SIZE_V_SHIFT 24 ++#define NV04_CONTEXT_SURFACES_3D_FORMAT_BASE_SIZE_V_MASK 0xff000000 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_SIZE 0x00000304 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_SIZE_W_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_SIZE_W_MASK 0x0000ffff ++#define NV04_CONTEXT_SURFACES_3D_CLIP_SIZE_H_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_3D_CLIP_SIZE_H_MASK 0xffff0000 ++#define NV04_CONTEXT_SURFACES_3D_PITCH 0x00000308 ++#define NV04_CONTEXT_SURFACES_3D_PITCH_COLOR_SHIFT 0 ++#define NV04_CONTEXT_SURFACES_3D_PITCH_COLOR_MASK 0x0000ffff ++#define NV04_CONTEXT_SURFACES_3D_PITCH_ZETA_SHIFT 16 ++#define NV04_CONTEXT_SURFACES_3D_PITCH_ZETA_MASK 0xffff0000 ++#define NV04_CONTEXT_SURFACES_3D_OFFSET_COLOR 0x0000030c ++#define NV04_CONTEXT_SURFACES_3D_OFFSET_ZETA 0x00000310 ++ ++ ++#define NV10_CONTEXT_SURFACES_3D 0x00000093 ++ ++ ++ ++#define NV04_TEXTURED_TRIANGLE 0x00000054 ++ ++#define NV04_TEXTURED_TRIANGLE_NOP 0x00000100 ++#define NV04_TEXTURED_TRIANGLE_NOTIFY 0x00000104 ++#define NV04_TEXTURED_TRIANGLE_DMA_NOTIFY 0x00000180 ++#define NV04_TEXTURED_TRIANGLE_DMA_A 0x00000184 ++#define NV04_TEXTURED_TRIANGLE_DMA_B 0x00000188 ++#define NV04_TEXTURED_TRIANGLE_SURFACE 0x0000018c ++#define NV04_TEXTURED_TRIANGLE_COLORKEY 0x00000300 ++#define NV04_TEXTURED_TRIANGLE_OFFSET 0x00000304 ++#define NV04_TEXTURED_TRIANGLE_FORMAT 0x00000308 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_DMA_A (1 << 0) ++#define NV04_TEXTURED_TRIANGLE_FORMAT_DMA_B (1 << 1) ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_KEY_MATCH_SHIFT 2 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_KEY_MATCH_MASK 0x0000000c ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_ZOH_SHIFT 4 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_ZOH_MASK 0x00000030 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_ZOH_CENTER 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_ZOH_CORNER 0x00000020 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_FOH_SHIFT 6 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_FOH_MASK 0x000000c0 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_FOH_CENTER 0x00000040 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ORIGIN_FOH_CORNER 0x00000080 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_MASK 0x00000f00 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_Y8 0x00000100 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_A1R5G5B5 0x00000200 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_X1R5G5B5 0x00000300 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_A4R4G4B4 0x00000400 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_R5G6B5 0x00000500 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_A8R8G8B8 0x00000600 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_COLOR_X8R8G8B8 0x00000700 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_MIPMAP_LEVELS_SHIFT 12 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_MIPMAP_LEVELS_MASK 0x0000f000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_BASE_SIZE_U_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_BASE_SIZE_U_MASK 0x000f0000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_BASE_SIZE_V_SHIFT 20 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_BASE_SIZE_V_MASK 0x00f00000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_MASK 0x07000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_REPEAT 0x01000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_MIRRORED_REPEAT 0x02000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_CLAMP_TO_EDGE 0x03000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_CLAMP_TO_BORDER 0x04000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSU_CLAMP 0x05000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_WRAPU (1 << 27) ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_SHIFT 28 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_MASK 0x70000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_REPEAT 0x10000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_MIRRORED_REPEAT 0x20000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_CLAMP_TO_EDGE 0x30000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_CLAMP_TO_BORDER 0x40000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_ADDRESSV_CLAMP 0x50000000 ++#define NV04_TEXTURED_TRIANGLE_FORMAT_WRAPV (1 << 31) ++#define NV04_TEXTURED_TRIANGLE_FILTER 0x0000030c ++#define NV04_TEXTURED_TRIANGLE_FILTER_KERNEL_SIZE_X_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_FILTER_KERNEL_SIZE_X_MASK 0x000000ff ++#define NV04_TEXTURED_TRIANGLE_FILTER_KERNEL_SIZE_Y_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_FILTER_KERNEL_SIZE_Y_MASK 0x00007f00 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MIPMAP_DITHER_ENABLE (1 << 15) ++#define NV04_TEXTURED_TRIANGLE_FILTER_MIPMAP_LODBIAS_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MIPMAP_LODBIAS_MASK 0x00ff0000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_MASK 0x07000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_NEAREST 0x01000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_LINEAR 0x02000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_NEAREST_MIPMAP_NEAREST 0x03000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_LINEAR_MIPMAP_NEAREST 0x04000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_NEAREST_MIPMAP_LINEAR 0x05000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MINIFY_LINEAR_MIPMAP_LINEAR 0x06000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_ANISOTROPIC_MINIFY_ENABLE (1 << 27) ++#define NV04_TEXTURED_TRIANGLE_FILTER_MAGNIFY_SHIFT 28 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MAGNIFY_MASK 0x70000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MAGNIFY_NEAREST 0x10000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_MAGNIFY_LINEAR 0x20000000 ++#define NV04_TEXTURED_TRIANGLE_FILTER_ANISOTROPIC_MAGNIFY_ENABLE (1 << 31) ++#define NV04_TEXTURED_TRIANGLE_BLEND 0x00000310 ++#define NV04_TEXTURED_TRIANGLE_BLEND_TEXTURE_MAP_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_BLEND_TEXTURE_MAP_MASK 0x0000000f ++#define NV04_TEXTURED_TRIANGLE_BLEND_MASK_BIT_SHIFT 4 ++#define NV04_TEXTURED_TRIANGLE_BLEND_MASK_BIT_MASK 0x00000030 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SHADE_MODE_SHIFT 6 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SHADE_MODE_MASK 0x000000c0 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SHADE_MODE_FLAT 0x00000040 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SHADE_MODE_GOURAUD 0x00000080 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SHADE_MODE_PHONG 0x000000c0 ++#define NV04_TEXTURED_TRIANGLE_BLEND_TEXTURE_PERSPECTIVE_ENABLE (1 << 8) ++#define NV04_TEXTURED_TRIANGLE_BLEND_SPECULAR_ENABLE (1 << 12) ++#define NV04_TEXTURED_TRIANGLE_BLEND_FOG_ENABLE (1 << 16) ++#define NV04_TEXTURED_TRIANGLE_BLEND_BLEND_ENABLE (1 << 20) ++#define NV04_TEXTURED_TRIANGLE_BLEND_SRC_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_BLEND_SRC_MASK 0x0f000000 ++#define NV04_TEXTURED_TRIANGLE_BLEND_DST_SHIFT 28 ++#define NV04_TEXTURED_TRIANGLE_BLEND_DST_MASK 0xf0000000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL 0x00000314 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ALPHA_REF_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ALPHA_REF_MASK 0x000000ff ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ALPHA_FUNC_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ALPHA_FUNC_MASK 0x00000f00 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ALPHA_ENABLE (1 << 12) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_ORIGIN (1 << 13) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_ENABLE (1 << 14) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_FUNC_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_FUNC_MASK 0x000f0000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_SHIFT 20 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_MASK 0x00300000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_BOTH 0x00000000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_NONE 0x00100000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_CW 0x00200000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_CULL_MODE_CCW 0x00300000 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_DITHER_ENABLE (1 << 22) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_PERSPECTIVE_ENABLE (1 << 23) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_WRITE (1 << 24) ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_FORMAT_SHIFT 30 ++#define NV04_TEXTURED_TRIANGLE_CONTROL_Z_FORMAT_MASK 0xc0000000 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR 0x00000318 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_B_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_B_MASK 0x000000ff ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_G_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_G_MASK 0x0000ff00 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_R_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_R_MASK 0x00ff0000 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_A_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_FOGCOLOR_A_MASK 0xff000000 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SX(x) (0x00000400+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SX__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SY(x) (0x00000404+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SY__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SZ(x) (0x00000408+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SZ__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_RHW(x) (0x0000040c+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_RHW__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR(x) (0x00000410+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_B_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_B_MASK 0x000000ff ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_G_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_G_MASK 0x0000ff00 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_R_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_R_MASK 0x00ff0000 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_A_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_COLOR_A_MASK 0xff000000 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR(x) (0x00000414+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_B_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_B_MASK 0x000000ff ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_G_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_G_MASK 0x0000ff00 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_R_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_R_MASK 0x00ff0000 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_FOG_SHIFT 24 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_SPECULAR_FOG_MASK 0xff000000 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_TU(x) (0x00000418+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_TU__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_TV(x) (0x0000041c+((x)*32)) ++#define NV04_TEXTURED_TRIANGLE_TLVERTEX_TV__SIZE 0x00000010 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE(x) (0x00000600+((x)*4)) ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE__SIZE 0x00000040 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I0_SHIFT 0 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I0_MASK 0x0000000f ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I1_SHIFT 4 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I1_MASK 0x000000f0 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I2_SHIFT 8 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I2_MASK 0x00000f00 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I3_SHIFT 12 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I3_MASK 0x0000f000 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I4_SHIFT 16 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I4_MASK 0x000f0000 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I5_SHIFT 20 ++#define NV04_TEXTURED_TRIANGLE_DRAWPRIMITIVE_I5_MASK 0x00f00000 ++ ++ ++#define NV10_TEXTURED_TRIANGLE 0x00000094 ++ ++ ++ ++#define NV04_MULTITEX_TRIANGLE 0x00000055 ++ ++#define NV04_MULTITEX_TRIANGLE_NOP 0x00000100 ++#define NV04_MULTITEX_TRIANGLE_NOTIFY 0x00000104 ++#define NV04_MULTITEX_TRIANGLE_DMA_NOTIFY 0x00000180 ++#define NV04_MULTITEX_TRIANGLE_DMA_A 0x00000184 ++#define NV04_MULTITEX_TRIANGLE_DMA_B 0x00000188 ++#define NV04_MULTITEX_TRIANGLE_SURFACE 0x0000018c ++#define NV04_MULTITEX_TRIANGLE_OFFSET(x) (0x00000308+((x)*4)) ++#define NV04_MULTITEX_TRIANGLE_OFFSET__SIZE 0x00000002 ++#define NV04_MULTITEX_TRIANGLE_FORMAT(x) (0x00000310+((x)*4)) ++#define NV04_MULTITEX_TRIANGLE_FORMAT__SIZE 0x00000002 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_DMA_A (1 << 0) ++#define NV04_MULTITEX_TRIANGLE_FORMAT_DMA_B (1 << 1) ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ORIGIN_ZOH_SHIFT 4 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ORIGIN_ZOH_MASK 0x00000030 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ORIGIN_FOH_SHIFT 6 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ORIGIN_FOH_MASK 0x000000c0 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_COLOR_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_COLOR_MASK 0x00000f00 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_MIPMAP_LEVELS_SHIFT 12 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_MIPMAP_LEVELS_MASK 0x0000f000 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_BASE_SIZE_U_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_BASE_SIZE_U_MASK 0x000f0000 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_BASE_SIZE_V_SHIFT 20 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_BASE_SIZE_V_MASK 0x00f00000 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ADDRESSU_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ADDRESSU_MASK 0x07000000 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_WRAPU (1 << 27) ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ADDRESSV_SHIFT 28 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_ADDRESSV_MASK 0x70000000 ++#define NV04_MULTITEX_TRIANGLE_FORMAT_WRAPV (1 << 31) ++#define NV04_MULTITEX_TRIANGLE_FILTER(x) (0x00000318+((x)*4)) ++#define NV04_MULTITEX_TRIANGLE_FILTER__SIZE 0x00000002 ++#define NV04_MULTITEX_TRIANGLE_FILTER_KERNEL_SIZE_X_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_FILTER_KERNEL_SIZE_X_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_FILTER_KERNEL_SIZE_Y_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_FILTER_KERNEL_SIZE_Y_MASK 0x00007f00 ++#define NV04_MULTITEX_TRIANGLE_FILTER_MIPMAP_DITHER_ENABLE (1 << 15) ++#define NV04_MULTITEX_TRIANGLE_FILTER_MIPMAP_LODBIAS_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_FILTER_MIPMAP_LODBIAS_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_FILTER_MINIFY_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_FILTER_MINIFY_MASK 0x07000000 ++#define NV04_MULTITEX_TRIANGLE_FILTER_ANISOTROPIC_MINIFY_ENABLE (1 << 27) ++#define NV04_MULTITEX_TRIANGLE_FILTER_MAGNIFY_SHIFT 28 ++#define NV04_MULTITEX_TRIANGLE_FILTER_MAGNIFY_MASK 0x70000000 ++#define NV04_MULTITEX_TRIANGLE_FILTER_ANISOTROPIC_MAGNIFY_ENABLE (1 << 31) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA(x) (0x00000320+((x)*12)) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA__SIZE 0x00000002 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_INVERSE0 (1 << 0) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_SHIFT 2 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_MASK 0x000000fc ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_ZERO 0x00000004 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_CONSTANT 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_PRIMARY_COLOR 0x0000000c ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_PREVIOUS 0x00000010 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_TEXTURE0 0x00000014 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT0_TEXTURE1 0x00000018 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_INVERSE1 (1 << 8) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_SHIFT 10 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_MASK 0x0000fc00 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_ZERO 0x00000400 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_CONSTANT 0x00000800 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_PRIMARY_COLOR 0x00000c00 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_PREVIOUS 0x00001000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_TEXTURE0 0x00001400 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT1_TEXTURE1 0x00001800 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_INVERSE2 (1 << 16) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_SHIFT 18 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_MASK 0x00fc0000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_ZERO 0x00040000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_CONSTANT 0x00080000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_PRIMARY_COLOR 0x000c0000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_PREVIOUS 0x00100000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_TEXTURE0 0x00140000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT2_TEXTURE1 0x00180000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_INVERSE3 (1 << 24) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_SHIFT 26 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_MASK 0x1c000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_ZERO 0x04000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_CONSTANT 0x08000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_PRIMARY_COLOR 0x0c000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_PREVIOUS 0x10000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_TEXTURE0 0x14000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_ARGUMENT3_TEXTURE1 0x18000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_SHIFT 29 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_MASK 0xe0000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_IDENTITY 0x20000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_SCALE2 0x40000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_SCALE4 0x60000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_BIAS 0x80000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_ALPHA_MAP_BIAS_SCALE2 0xe0000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR(x) (0x00000324+((x)*12)) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR__SIZE 0x00000002 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_INVERSE0 (1 << 0) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ALPHA0 (1 << 1) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_SHIFT 2 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_MASK 0x000000fc ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_ZERO 0x00000004 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_CONSTANT 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_PRIMARY_COLOR 0x0000000c ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_PREVIOUS 0x00000010 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_TEXTURE0 0x00000014 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT0_TEXTURE1 0x00000018 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_INVERSE1 (1 << 8) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ALPHA1 (1 << 9) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_SHIFT 10 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_MASK 0x0000fc00 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_ZERO 0x00000400 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_CONSTANT 0x00000800 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_PRIMARY_COLOR 0x00000c00 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_PREVIOUS 0x00001000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_TEXTURE0 0x00001400 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT1_TEXTURE1 0x00001800 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_INVERSE2 (1 << 16) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ALPHA2 (1 << 17) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_SHIFT 18 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_MASK 0x00fc0000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_ZERO 0x00040000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_CONSTANT 0x00080000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_PRIMARY_COLOR 0x000c0000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_PREVIOUS 0x00100000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_TEXTURE0 0x00140000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT2_TEXTURE1 0x00180000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_INVERSE3 (1 << 24) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ALPHA3 (1 << 25) ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_SHIFT 26 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_MASK 0x1c000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_ZERO 0x04000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_CONSTANT 0x08000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_PRIMARY_COLOR 0x0c000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_PREVIOUS 0x10000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_TEXTURE0 0x14000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_ARGUMENT3_TEXTURE1 0x18000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_SHIFT 29 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_MASK 0xe0000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_IDENTITY 0x20000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_SCALE2 0x40000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_SCALE4 0x60000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_BIAS 0x80000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_COLOR_MAP_BIAS_SCALE2 0xe0000000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR 0x00000334 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_B_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_B_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_G_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_G_MASK 0x0000ff00 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_R_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_R_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_A_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_COMBINE_FACTOR_A_MASK 0xff000000 ++#define NV04_MULTITEX_TRIANGLE_BLEND 0x00000338 ++#define NV04_MULTITEX_TRIANGLE_BLEND_MASK_BIT_SHIFT 4 ++#define NV04_MULTITEX_TRIANGLE_BLEND_MASK_BIT_MASK 0x00000030 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SHADE_MODE_SHIFT 6 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SHADE_MODE_MASK 0x000000c0 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SHADE_MODE_FLAT 0x00000040 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SHADE_MODE_GOURAUD 0x00000080 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SHADE_MODE_PHONG 0x000000c0 ++#define NV04_MULTITEX_TRIANGLE_BLEND_TEXTURE_PERSPECTIVE_ENABLE (1 << 8) ++#define NV04_MULTITEX_TRIANGLE_BLEND_SPECULAR_ENABLE (1 << 12) ++#define NV04_MULTITEX_TRIANGLE_BLEND_FOG_ENABLE (1 << 16) ++#define NV04_MULTITEX_TRIANGLE_BLEND_BLEND_ENABLE (1 << 20) ++#define NV04_MULTITEX_TRIANGLE_BLEND_SRC_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_BLEND_SRC_MASK 0x0f000000 ++#define NV04_MULTITEX_TRIANGLE_BLEND_DST_SHIFT 28 ++#define NV04_MULTITEX_TRIANGLE_BLEND_DST_MASK 0xf0000000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0 0x0000033c ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_REF_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_REF_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_FUNC_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_FUNC_MASK 0x00000f00 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_ENABLE (1 << 12) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ORIGIN (1 << 13) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_ENABLE (1 << 14) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_FUNC_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_FUNC_MASK 0x000f0000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_SHIFT 20 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_MASK 0x00300000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_BOTH 0x00000000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_NONE 0x00100000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_CW 0x00200000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_CULL_MODE_CCW 0x00300000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_DITHER_ENABLE (1 << 22) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_PERSPECTIVE_ENABLE (1 << 23) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_WRITE (1 << 24) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_STENCIL_WRITE (1 << 25) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_ALPHA_WRITE (1 << 26) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_RED_WRITE (1 << 27) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_GREEN_WRITE (1 << 28) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_BLUE_WRITE (1 << 29) ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_FORMAT_SHIFT 30 ++#define NV04_MULTITEX_TRIANGLE_CONTROL0_Z_FORMAT_MASK 0xc0000000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1 0x00000340 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_ENABLE (1 << 0) ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_FUNC_SHIFT 4 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_FUNC_MASK 0x000000f0 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_REF_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_REF_MASK 0x0000ff00 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_MASK_READ_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_MASK_READ_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_MASK_WRITE_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_CONTROL1_STENCIL_MASK_WRITE_MASK 0xff000000 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2 0x00000344 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_FAIL_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_FAIL_MASK 0x0000000f ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_ZFAIL_SHIFT 4 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_ZFAIL_MASK 0x000000f0 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_ZPASS_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_CONTROL2_STENCIL_OP_ZPASS_MASK 0x00000f00 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR 0x00000348 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_B_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_B_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_G_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_G_MASK 0x0000ff00 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_R_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_R_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_A_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_FOGCOLOR_A_MASK 0xff000000 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SX(x) (0x00000400+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SX__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SY(x) (0x00000404+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SY__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SZ(x) (0x00000408+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SZ__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_RHW(x) (0x0000040c+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_RHW__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR(x) (0x00000410+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_B_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_B_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_G_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_G_MASK 0x0000ff00 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_R_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_R_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_A_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_COLOR_A_MASK 0xff000000 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR(x) (0x00000414+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_B_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_B_MASK 0x000000ff ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_G_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_G_MASK 0x0000ff00 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_R_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_R_MASK 0x00ff0000 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_FOG_SHIFT 24 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_SPECULAR_FOG_MASK 0xff000000 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TU0(x) (0x00000418+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TU0__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TV0(x) (0x0000041c+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TV0__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TU1(x) (0x00000420+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TU1__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TV1(x) (0x00000424+((x)*40)) ++#define NV04_MULTITEX_TRIANGLE_TLMTVERTEX_TV1__SIZE 0x00000008 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE(x) (0x00000540+((x)*4)) ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE__SIZE 0x00000030 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I0_SHIFT 0 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I0_MASK 0x0000000f ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I1_SHIFT 4 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I1_MASK 0x000000f0 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I2_SHIFT 8 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I2_MASK 0x00000f00 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I3_SHIFT 12 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I3_MASK 0x0000f000 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I4_SHIFT 16 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I4_MASK 0x000f0000 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I5_SHIFT 20 ++#define NV04_MULTITEX_TRIANGLE_DRAWPRIMITIVE_I5_MASK 0x00f00000 ++ ++ ++#define NV10_MULTITEX_TRIANGLE 0x00000095 ++ ++ ++ ++#define NV10TCL 0x00000056 ++ ++#define NV10TCL_NOP 0x00000100 ++#define NV10TCL_NOTIFY 0x00000104 ++#define NV10TCL_DMA_NOTIFY 0x00000180 ++#define NV10TCL_DMA_IN_MEMORY0 0x00000184 ++#define NV10TCL_DMA_IN_MEMORY1 0x00000188 ++#define NV10TCL_DMA_VTXBUF0 0x0000018c ++#define NV10TCL_DMA_IN_MEMORY2 0x00000194 ++#define NV10TCL_DMA_IN_MEMORY3 0x00000198 ++#define NV10TCL_RT_HORIZ 0x00000200 ++#define NV10TCL_RT_HORIZ_X_SHIFT 0 ++#define NV10TCL_RT_HORIZ_X_MASK 0x0000ffff ++#define NV10TCL_RT_HORIZ_W_SHIFT 16 ++#define NV10TCL_RT_HORIZ_W_MASK 0xffff0000 ++#define NV10TCL_RT_VERT 0x00000204 ++#define NV10TCL_RT_VERT_Y_SHIFT 0 ++#define NV10TCL_RT_VERT_Y_MASK 0x0000ffff ++#define NV10TCL_RT_VERT_H_SHIFT 16 ++#define NV10TCL_RT_VERT_H_MASK 0xffff0000 ++#define NV10TCL_RT_FORMAT 0x00000208 ++#define NV10TCL_RT_FORMAT_TYPE_SHIFT 8 ++#define NV10TCL_RT_FORMAT_TYPE_MASK 0x00000f00 ++#define NV10TCL_RT_FORMAT_TYPE_LINEAR 0x00000100 ++#define NV10TCL_RT_FORMAT_TYPE_SWIZZLED 0x00000200 ++#define NV10TCL_RT_FORMAT_COLOR_SHIFT 0 ++#define NV10TCL_RT_FORMAT_COLOR_MASK 0x0000001f ++#define NV10TCL_RT_FORMAT_COLOR_R5G6B5 0x00000003 ++#define NV10TCL_RT_FORMAT_COLOR_X8R8G8B8 0x00000005 ++#define NV10TCL_RT_FORMAT_COLOR_A8R8G8B8 0x00000008 ++#define NV10TCL_RT_FORMAT_COLOR_B8 0x00000009 ++#define NV10TCL_RT_FORMAT_COLOR_UNKNOWN 0x0000000d ++#define NV10TCL_RT_FORMAT_COLOR_X8B8G8R8 0x0000000f ++#define NV10TCL_RT_FORMAT_COLOR_A8B8G8R8 0x00000010 ++#define NV10TCL_RT_PITCH 0x0000020c ++#define NV10TCL_RT_PITCH_COLOR_PITCH_SHIFT 0 ++#define NV10TCL_RT_PITCH_COLOR_PITCH_MASK 0x0000ffff ++#define NV10TCL_RT_PITCH_ZETA_PITCH_SHIFT 16 ++#define NV10TCL_RT_PITCH_ZETA_PITCH_MASK 0xffff0000 ++#define NV10TCL_COLOR_OFFSET 0x00000210 ++#define NV10TCL_ZETA_OFFSET 0x00000214 ++#define NV10TCL_TX_OFFSET(x) (0x00000218+((x)*4)) ++#define NV10TCL_TX_OFFSET__SIZE 0x00000002 ++#define NV10TCL_TX_FORMAT(x) (0x00000220+((x)*4)) ++#define NV10TCL_TX_FORMAT__SIZE 0x00000002 ++#define NV10TCL_TX_FORMAT_DMA0 (1 << 0) ++#define NV10TCL_TX_FORMAT_DMA1 (1 << 1) ++#define NV10TCL_TX_FORMAT_CUBE_MAP (1 << 2) ++#define NV10TCL_TX_FORMAT_FORMAT_SHIFT 7 ++#define NV10TCL_TX_FORMAT_FORMAT_MASK 0x00000f80 ++#define NV10TCL_TX_FORMAT_FORMAT_L8 0x00000000 ++#define NV10TCL_TX_FORMAT_FORMAT_A8 0x00000080 ++#define NV10TCL_TX_FORMAT_FORMAT_A1R5G5B5 0x00000100 ++#define NV10TCL_TX_FORMAT_FORMAT_A4R4G4B4 0x00000200 ++#define NV10TCL_TX_FORMAT_FORMAT_R5G6B5 0x00000280 ++#define NV10TCL_TX_FORMAT_FORMAT_A8R8G8B8 0x00000300 ++#define NV10TCL_TX_FORMAT_FORMAT_X8R8G8B8 0x00000380 ++#define NV10TCL_TX_FORMAT_FORMAT_INDEX8 0x00000580 ++#define NV10TCL_TX_FORMAT_FORMAT_DXT1 0x00000600 ++#define NV10TCL_TX_FORMAT_FORMAT_DXT3 0x00000700 ++#define NV10TCL_TX_FORMAT_FORMAT_DXT5 0x00000780 ++#define NV10TCL_TX_FORMAT_FORMAT_A1R5G5B5_RECT 0x00000800 ++#define NV10TCL_TX_FORMAT_FORMAT_R5G6B5_RECT 0x00000880 ++#define NV10TCL_TX_FORMAT_FORMAT_A8R8G8B8_RECT 0x00000900 ++#define NV10TCL_TX_FORMAT_FORMAT_A8_RECT 0x00000980 ++#define NV10TCL_TX_FORMAT_MIPMAP (1 << 15) ++#define NV10TCL_TX_FORMAT_BASE_SIZE_U_SHIFT 16 ++#define NV10TCL_TX_FORMAT_BASE_SIZE_U_MASK 0x000f0000 ++#define NV10TCL_TX_FORMAT_BASE_SIZE_V_SHIFT 20 ++#define NV10TCL_TX_FORMAT_BASE_SIZE_V_MASK 0x00f00000 ++#define NV10TCL_TX_FORMAT_WRAP_S_SHIFT 24 ++#define NV10TCL_TX_FORMAT_WRAP_S_MASK 0x0f000000 ++#define NV10TCL_TX_FORMAT_WRAP_S_REPEAT 0x01000000 ++#define NV10TCL_TX_FORMAT_WRAP_S_MIRRORED_REPEAT 0x02000000 ++#define NV10TCL_TX_FORMAT_WRAP_S_CLAMP_TO_EDGE 0x03000000 ++#define NV10TCL_TX_FORMAT_WRAP_S_CLAMP_TO_BORDER 0x04000000 ++#define NV10TCL_TX_FORMAT_WRAP_S_CLAMP 0x05000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_SHIFT 28 ++#define NV10TCL_TX_FORMAT_WRAP_T_MASK 0xf0000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_REPEAT 0x10000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_MIRRORED_REPEAT 0x20000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_CLAMP_TO_EDGE 0x30000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_CLAMP_TO_BORDER 0x40000000 ++#define NV10TCL_TX_FORMAT_WRAP_T_CLAMP 0x50000000 ++#define NV10TCL_TX_ENABLE(x) (0x00000228+((x)*4)) ++#define NV10TCL_TX_ENABLE__SIZE 0x00000002 ++#define NV10TCL_TX_ENABLE_CULL_SHIFT 0 ++#define NV10TCL_TX_ENABLE_CULL_MASK 0x0000000f ++#define NV10TCL_TX_ENABLE_CULL_DISABLED 0x00000000 ++#define NV10TCL_TX_ENABLE_CULL_TEST_ALL 0x00000003 ++#define NV10TCL_TX_ENABLE_CULL_TEST_ALPHA 0x00000004 ++#define NV10TCL_TX_ENABLE_ANISOTROPY_SHIFT 4 ++#define NV10TCL_TX_ENABLE_ANISOTROPY_MASK 0x00000030 ++#define NV10TCL_TX_ENABLE_MIPMAP_MAX_LOD_SHIFT 14 ++#define NV10TCL_TX_ENABLE_MIPMAP_MAX_LOD_MASK 0x0003c000 ++#define NV10TCL_TX_ENABLE_MIPMAP_MIN_LOD_SHIFT 26 ++#define NV10TCL_TX_ENABLE_MIPMAP_MIN_LOD_MASK 0x3c000000 ++#define NV10TCL_TX_ENABLE_ENABLE (1 << 30) ++#define NV10TCL_TX_NPOT_PITCH(x) (0x00000230+((x)*4)) ++#define NV10TCL_TX_NPOT_PITCH__SIZE 0x00000002 ++#define NV10TCL_TX_NPOT_PITCH_PITCH_SHIFT 16 ++#define NV10TCL_TX_NPOT_PITCH_PITCH_MASK 0xffff0000 ++#define NV10TCL_TX_NPOT_SIZE(x) (0x00000240+((x)*4)) ++#define NV10TCL_TX_NPOT_SIZE__SIZE 0x00000002 ++#define NV10TCL_TX_NPOT_SIZE_H_SHIFT 0 ++#define NV10TCL_TX_NPOT_SIZE_H_MASK 0x0000ffff ++#define NV10TCL_TX_NPOT_SIZE_W_SHIFT 16 ++#define NV10TCL_TX_NPOT_SIZE_W_MASK 0xffff0000 ++#define NV10TCL_TX_FILTER(x) (0x00000248+((x)*4)) ++#define NV10TCL_TX_FILTER__SIZE 0x00000002 ++#define NV10TCL_TX_FILTER_LOD_BIAS_SHIFT 8 ++#define NV10TCL_TX_FILTER_LOD_BIAS_MASK 0x00000f00 ++#define NV10TCL_TX_FILTER_MINIFY_SHIFT 24 ++#define NV10TCL_TX_FILTER_MINIFY_MASK 0x0f000000 ++#define NV10TCL_TX_FILTER_MINIFY_NEAREST 0x01000000 ++#define NV10TCL_TX_FILTER_MINIFY_LINEAR 0x02000000 ++#define NV10TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_NEAREST 0x03000000 ++#define NV10TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_NEAREST 0x04000000 ++#define NV10TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_LINEAR 0x05000000 ++#define NV10TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_LINEAR 0x06000000 ++#define NV10TCL_TX_FILTER_MAGNIFY_SHIFT 28 ++#define NV10TCL_TX_FILTER_MAGNIFY_MASK 0xf0000000 ++#define NV10TCL_TX_FILTER_MAGNIFY_NEAREST 0x10000000 ++#define NV10TCL_TX_FILTER_MAGNIFY_LINEAR 0x20000000 ++#define NV10TCL_TX_PALETTE_OFFSET(x) (0x00000250+((x)*4)) ++#define NV10TCL_TX_PALETTE_OFFSET__SIZE 0x00000002 ++#define NV10TCL_RC_IN_ALPHA(x) (0x00000260+((x)*4)) ++#define NV10TCL_RC_IN_ALPHA__SIZE 0x00000002 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_SHIFT 0 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_MASK 0x0000000f ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_FOG 0x00000003 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_TEXTURE0 0x00000008 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_TEXTURE1 0x00000009 ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_SPARE0 0x0000000c ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_SPARE1 0x0000000d ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_E_TIMES_F 0x0000000f ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_TEXTURE2 0x0000000a ++#define NV10TCL_RC_IN_ALPHA_D_INPUT_TEXTURE3 0x0000000b ++#define NV10TCL_RC_IN_ALPHA_D_COMPONENT_USAGE (1 << 4) ++#define NV10TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_SHIFT 5 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_MASK 0x000000e0 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV10TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_SHIFT 8 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_MASK 0x00000f00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_FOG 0x00000300 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_IN_ALPHA_C_INPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_IN_ALPHA_C_COMPONENT_USAGE (1 << 12) ++#define NV10TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_SHIFT 13 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_MASK 0x0000e000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV10TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_SHIFT 16 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_MASK 0x000f0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_FOG 0x00030000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_TEXTURE0 0x00080000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_TEXTURE1 0x00090000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_SPARE0 0x000c0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_SPARE1 0x000d0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_TEXTURE2 0x000a0000 ++#define NV10TCL_RC_IN_ALPHA_B_INPUT_TEXTURE3 0x000b0000 ++#define NV10TCL_RC_IN_ALPHA_B_COMPONENT_USAGE (1 << 20) ++#define NV10TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_SHIFT 21 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_MASK 0x00e00000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV10TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_SHIFT 24 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_MASK 0x0f000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_FOG 0x03000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_TEXTURE0 0x08000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_TEXTURE1 0x09000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_SPARE0 0x0c000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_SPARE1 0x0d000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_TEXTURE2 0x0a000000 ++#define NV10TCL_RC_IN_ALPHA_A_INPUT_TEXTURE3 0x0b000000 ++#define NV10TCL_RC_IN_ALPHA_A_COMPONENT_USAGE (1 << 28) ++#define NV10TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_SHIFT 29 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_MASK 0xe0000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV10TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV10TCL_RC_IN_RGB(x) (0x00000268+((x)*4)) ++#define NV10TCL_RC_IN_RGB__SIZE 0x00000002 ++#define NV10TCL_RC_IN_RGB_D_INPUT_SHIFT 0 ++#define NV10TCL_RC_IN_RGB_D_INPUT_MASK 0x0000000f ++#define NV10TCL_RC_IN_RGB_D_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV10TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV10TCL_RC_IN_RGB_D_INPUT_FOG 0x00000003 ++#define NV10TCL_RC_IN_RGB_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV10TCL_RC_IN_RGB_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV10TCL_RC_IN_RGB_D_INPUT_TEXTURE0 0x00000008 ++#define NV10TCL_RC_IN_RGB_D_INPUT_TEXTURE1 0x00000009 ++#define NV10TCL_RC_IN_RGB_D_INPUT_SPARE0 0x0000000c ++#define NV10TCL_RC_IN_RGB_D_INPUT_SPARE1 0x0000000d ++#define NV10TCL_RC_IN_RGB_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV10TCL_RC_IN_RGB_D_INPUT_E_TIMES_F 0x0000000f ++#define NV10TCL_RC_IN_RGB_D_INPUT_TEXTURE2 0x0000000a ++#define NV10TCL_RC_IN_RGB_D_INPUT_TEXTURE3 0x0000000b ++#define NV10TCL_RC_IN_RGB_D_COMPONENT_USAGE (1 << 4) ++#define NV10TCL_RC_IN_RGB_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_IN_RGB_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_SHIFT 5 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_MASK 0x000000e0 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV10TCL_RC_IN_RGB_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV10TCL_RC_IN_RGB_C_INPUT_SHIFT 8 ++#define NV10TCL_RC_IN_RGB_C_INPUT_MASK 0x00000f00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_IN_RGB_C_INPUT_FOG 0x00000300 ++#define NV10TCL_RC_IN_RGB_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_IN_RGB_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_IN_RGB_C_INPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_IN_RGB_C_INPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_IN_RGB_C_INPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_IN_RGB_C_INPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_IN_RGB_C_COMPONENT_USAGE (1 << 12) ++#define NV10TCL_RC_IN_RGB_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_IN_RGB_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_SHIFT 13 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_MASK 0x0000e000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV10TCL_RC_IN_RGB_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_SHIFT 16 ++#define NV10TCL_RC_IN_RGB_B_INPUT_MASK 0x000f0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_FOG 0x00030000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_TEXTURE0 0x00080000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_TEXTURE1 0x00090000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_SPARE0 0x000c0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_SPARE1 0x000d0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_TEXTURE2 0x000a0000 ++#define NV10TCL_RC_IN_RGB_B_INPUT_TEXTURE3 0x000b0000 ++#define NV10TCL_RC_IN_RGB_B_COMPONENT_USAGE (1 << 20) ++#define NV10TCL_RC_IN_RGB_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_IN_RGB_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_SHIFT 21 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_MASK 0x00e00000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV10TCL_RC_IN_RGB_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_SHIFT 24 ++#define NV10TCL_RC_IN_RGB_A_INPUT_MASK 0x0f000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_FOG 0x03000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_TEXTURE0 0x08000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_TEXTURE1 0x09000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_SPARE0 0x0c000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_SPARE1 0x0d000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_TEXTURE2 0x0a000000 ++#define NV10TCL_RC_IN_RGB_A_INPUT_TEXTURE3 0x0b000000 ++#define NV10TCL_RC_IN_RGB_A_COMPONENT_USAGE (1 << 28) ++#define NV10TCL_RC_IN_RGB_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_IN_RGB_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_SHIFT 29 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_MASK 0xe0000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV10TCL_RC_IN_RGB_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV10TCL_RC_COLOR(x) (0x00000270+((x)*4)) ++#define NV10TCL_RC_COLOR__SIZE 0x00000002 ++#define NV10TCL_RC_COLOR_B_SHIFT 0 ++#define NV10TCL_RC_COLOR_B_MASK 0x000000ff ++#define NV10TCL_RC_COLOR_G_SHIFT 8 ++#define NV10TCL_RC_COLOR_G_MASK 0x0000ff00 ++#define NV10TCL_RC_COLOR_R_SHIFT 16 ++#define NV10TCL_RC_COLOR_R_MASK 0x00ff0000 ++#define NV10TCL_RC_COLOR_A_SHIFT 24 ++#define NV10TCL_RC_COLOR_A_MASK 0xff000000 ++#define NV10TCL_RC_OUT_ALPHA(x) (0x00000278+((x)*4)) ++#define NV10TCL_RC_OUT_ALPHA__SIZE 0x00000002 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_SHIFT 0 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_MASK 0x0000000f ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_FOG 0x00000003 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0 0x0000000c ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE1 0x0000000d ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV10TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_SHIFT 4 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_MASK 0x000000f0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_FOG 0x00000030 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV10TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_SHIFT 8 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_MASK 0x00000f00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_FOG 0x00000300 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_OUT_ALPHA_CD_DOT_PRODUCT (1 << 12) ++#define NV10TCL_RC_OUT_ALPHA_AB_DOT_PRODUCT (1 << 13) ++#define NV10TCL_RC_OUT_ALPHA_MUX_SUM (1 << 14) ++#define NV10TCL_RC_OUT_ALPHA_BIAS (1 << 15) ++#define NV10TCL_RC_OUT_ALPHA_BIAS_NONE 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_SHIFT 17 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_MASK 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_NONE 0x00000000 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV10TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV10TCL_RC_OUT_RGB(x) (0x00000280+((x)*4)) ++#define NV10TCL_RC_OUT_RGB__SIZE 0x00000002 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_SHIFT 0 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_MASK 0x0000000f ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_FOG 0x00000003 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0 0x0000000c ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_SPARE1 0x0000000d ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV10TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_SHIFT 4 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_MASK 0x000000f0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_FOG 0x00000030 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV10TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_SHIFT 8 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_MASK 0x00000f00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_ZERO 0x00000000 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_FOG 0x00000300 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_OUT_RGB_CD_DOT_PRODUCT (1 << 12) ++#define NV10TCL_RC_OUT_RGB_AB_DOT_PRODUCT (1 << 13) ++#define NV10TCL_RC_OUT_RGB_MUX_SUM (1 << 14) ++#define NV10TCL_RC_OUT_RGB_BIAS (1 << 15) ++#define NV10TCL_RC_OUT_RGB_BIAS_NONE 0x00000000 ++#define NV10TCL_RC_OUT_RGB_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV10TCL_RC_OUT_RGB_SCALE_SHIFT 17 ++#define NV10TCL_RC_OUT_RGB_SCALE_MASK 0x00000000 ++#define NV10TCL_RC_OUT_RGB_SCALE_NONE 0x00000000 ++#define NV10TCL_RC_OUT_RGB_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV10TCL_RC_OUT_RGB_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV10TCL_RC_OUT_RGB_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV10TCL_RC_OUT_RGB_OPERATION_SHIFT 27 ++#define NV10TCL_RC_OUT_RGB_OPERATION_MASK 0x38000000 ++#define NV10TCL_RC_FINAL0 0x00000288 ++#define NV10TCL_RC_FINAL0_D_INPUT_SHIFT 0 ++#define NV10TCL_RC_FINAL0_D_INPUT_MASK 0x0000000f ++#define NV10TCL_RC_FINAL0_D_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV10TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV10TCL_RC_FINAL0_D_INPUT_FOG 0x00000003 ++#define NV10TCL_RC_FINAL0_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV10TCL_RC_FINAL0_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV10TCL_RC_FINAL0_D_INPUT_TEXTURE0 0x00000008 ++#define NV10TCL_RC_FINAL0_D_INPUT_TEXTURE1 0x00000009 ++#define NV10TCL_RC_FINAL0_D_INPUT_SPARE0 0x0000000c ++#define NV10TCL_RC_FINAL0_D_INPUT_SPARE1 0x0000000d ++#define NV10TCL_RC_FINAL0_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV10TCL_RC_FINAL0_D_INPUT_E_TIMES_F 0x0000000f ++#define NV10TCL_RC_FINAL0_D_INPUT_TEXTURE2 0x0000000a ++#define NV10TCL_RC_FINAL0_D_INPUT_TEXTURE3 0x0000000b ++#define NV10TCL_RC_FINAL0_D_COMPONENT_USAGE (1 << 4) ++#define NV10TCL_RC_FINAL0_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL0_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV10TCL_RC_FINAL0_D_MAPPING_SHIFT 5 ++#define NV10TCL_RC_FINAL0_D_MAPPING_MASK 0x000000e0 ++#define NV10TCL_RC_FINAL0_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL0_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV10TCL_RC_FINAL0_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV10TCL_RC_FINAL0_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV10TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV10TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV10TCL_RC_FINAL0_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV10TCL_RC_FINAL0_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV10TCL_RC_FINAL0_C_INPUT_SHIFT 8 ++#define NV10TCL_RC_FINAL0_C_INPUT_MASK 0x00000f00 ++#define NV10TCL_RC_FINAL0_C_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_FINAL0_C_INPUT_FOG 0x00000300 ++#define NV10TCL_RC_FINAL0_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_FINAL0_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_FINAL0_C_INPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_FINAL0_C_INPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_FINAL0_C_INPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_FINAL0_C_INPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_FINAL0_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_FINAL0_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_FINAL0_C_INPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_FINAL0_C_INPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_FINAL0_C_COMPONENT_USAGE (1 << 12) ++#define NV10TCL_RC_FINAL0_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL0_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_SHIFT 13 ++#define NV10TCL_RC_FINAL0_C_MAPPING_MASK 0x0000e000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV10TCL_RC_FINAL0_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV10TCL_RC_FINAL0_B_INPUT_SHIFT 16 ++#define NV10TCL_RC_FINAL0_B_INPUT_MASK 0x000f0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV10TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV10TCL_RC_FINAL0_B_INPUT_FOG 0x00030000 ++#define NV10TCL_RC_FINAL0_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV10TCL_RC_FINAL0_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV10TCL_RC_FINAL0_B_INPUT_TEXTURE0 0x00080000 ++#define NV10TCL_RC_FINAL0_B_INPUT_TEXTURE1 0x00090000 ++#define NV10TCL_RC_FINAL0_B_INPUT_SPARE0 0x000c0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_SPARE1 0x000d0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_TEXTURE2 0x000a0000 ++#define NV10TCL_RC_FINAL0_B_INPUT_TEXTURE3 0x000b0000 ++#define NV10TCL_RC_FINAL0_B_COMPONENT_USAGE (1 << 20) ++#define NV10TCL_RC_FINAL0_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL0_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_SHIFT 21 ++#define NV10TCL_RC_FINAL0_B_MAPPING_MASK 0x00e00000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV10TCL_RC_FINAL0_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV10TCL_RC_FINAL0_A_INPUT_SHIFT 24 ++#define NV10TCL_RC_FINAL0_A_INPUT_MASK 0x0f000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_FOG 0x03000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_TEXTURE0 0x08000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_TEXTURE1 0x09000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_SPARE0 0x0c000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_SPARE1 0x0d000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_TEXTURE2 0x0a000000 ++#define NV10TCL_RC_FINAL0_A_INPUT_TEXTURE3 0x0b000000 ++#define NV10TCL_RC_FINAL0_A_COMPONENT_USAGE (1 << 28) ++#define NV10TCL_RC_FINAL0_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL0_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_SHIFT 29 ++#define NV10TCL_RC_FINAL0_A_MAPPING_MASK 0xe0000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV10TCL_RC_FINAL0_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV10TCL_RC_FINAL1 0x0000028c ++#define NV10TCL_RC_FINAL1_COLOR_SUM_CLAMP (1 << 7) ++#define NV10TCL_RC_FINAL1_G_INPUT_SHIFT 8 ++#define NV10TCL_RC_FINAL1_G_INPUT_MASK 0x00000f00 ++#define NV10TCL_RC_FINAL1_G_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV10TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV10TCL_RC_FINAL1_G_INPUT_FOG 0x00000300 ++#define NV10TCL_RC_FINAL1_G_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV10TCL_RC_FINAL1_G_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV10TCL_RC_FINAL1_G_INPUT_TEXTURE0 0x00000800 ++#define NV10TCL_RC_FINAL1_G_INPUT_TEXTURE1 0x00000900 ++#define NV10TCL_RC_FINAL1_G_INPUT_SPARE0 0x00000c00 ++#define NV10TCL_RC_FINAL1_G_INPUT_SPARE1 0x00000d00 ++#define NV10TCL_RC_FINAL1_G_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV10TCL_RC_FINAL1_G_INPUT_E_TIMES_F 0x00000f00 ++#define NV10TCL_RC_FINAL1_G_INPUT_TEXTURE2 0x00000a00 ++#define NV10TCL_RC_FINAL1_G_INPUT_TEXTURE3 0x00000b00 ++#define NV10TCL_RC_FINAL1_G_COMPONENT_USAGE (1 << 12) ++#define NV10TCL_RC_FINAL1_G_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL1_G_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_SHIFT 13 ++#define NV10TCL_RC_FINAL1_G_MAPPING_MASK 0x0000e000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV10TCL_RC_FINAL1_G_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV10TCL_RC_FINAL1_F_INPUT_SHIFT 16 ++#define NV10TCL_RC_FINAL1_F_INPUT_MASK 0x000f0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV10TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV10TCL_RC_FINAL1_F_INPUT_FOG 0x00030000 ++#define NV10TCL_RC_FINAL1_F_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV10TCL_RC_FINAL1_F_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV10TCL_RC_FINAL1_F_INPUT_TEXTURE0 0x00080000 ++#define NV10TCL_RC_FINAL1_F_INPUT_TEXTURE1 0x00090000 ++#define NV10TCL_RC_FINAL1_F_INPUT_SPARE0 0x000c0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_SPARE1 0x000d0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_E_TIMES_F 0x000f0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_TEXTURE2 0x000a0000 ++#define NV10TCL_RC_FINAL1_F_INPUT_TEXTURE3 0x000b0000 ++#define NV10TCL_RC_FINAL1_F_COMPONENT_USAGE (1 << 20) ++#define NV10TCL_RC_FINAL1_F_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL1_F_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_SHIFT 21 ++#define NV10TCL_RC_FINAL1_F_MAPPING_MASK 0x00e00000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV10TCL_RC_FINAL1_F_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV10TCL_RC_FINAL1_E_INPUT_SHIFT 24 ++#define NV10TCL_RC_FINAL1_E_INPUT_MASK 0x0f000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_ZERO 0x00000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_FOG 0x03000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_TEXTURE0 0x08000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_TEXTURE1 0x09000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_SPARE0 0x0c000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_SPARE1 0x0d000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_E_TIMES_F 0x0f000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_TEXTURE2 0x0a000000 ++#define NV10TCL_RC_FINAL1_E_INPUT_TEXTURE3 0x0b000000 ++#define NV10TCL_RC_FINAL1_E_COMPONENT_USAGE (1 << 28) ++#define NV10TCL_RC_FINAL1_E_COMPONENT_USAGE_RGB 0x00000000 ++#define NV10TCL_RC_FINAL1_E_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_SHIFT 29 ++#define NV10TCL_RC_FINAL1_E_MAPPING_MASK 0xe0000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV10TCL_RC_FINAL1_E_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV10TCL_LIGHT_MODEL 0x00000294 ++#define NV10TCL_LIGHT_MODEL_VERTEX_SPECULAR (1 << 0) ++#define NV10TCL_LIGHT_MODEL_SEPARATE_SPECULAR (1 << 1) ++#define NV10TCL_LIGHT_MODEL_LOCAL_VIEWER (1 << 16) ++#define NV10TCL_COLOR_MATERIAL 0x00000298 ++#define NV10TCL_COLOR_MATERIAL_EMISSION (1 << 0) ++#define NV10TCL_COLOR_MATERIAL_AMBIENT (1 << 1) ++#define NV10TCL_COLOR_MATERIAL_DIFFUSE (1 << 2) ++#define NV10TCL_COLOR_MATERIAL_SPECULAR (1 << 3) ++#define NV10TCL_FOG_MODE 0x0000029c ++#define NV10TCL_FOG_MODE_LINEAR 0x00002601 ++#define NV10TCL_FOG_MODE_EXP 0x00000800 ++#define NV10TCL_FOG_MODE_EXP_ABS 0x00000802 ++#define NV10TCL_FOG_MODE_EXP2 0x00000803 ++#define NV10TCL_FOG_COORD 0x000002a0 ++#define NV10TCL_FOG_COORD_FOG 0x00000000 ++#define NV10TCL_FOG_COORD_DIST_RADIAL 0x00000001 ++#define NV10TCL_FOG_COORD_DIST_ORTHOGONAL 0x00000002 ++#define NV10TCL_FOG_COORD_DIST_ORTHOGONAL_ABS 0x00000003 ++#define NV10TCL_FOG_ENABLE 0x000002a4 ++#define NV10TCL_FOG_COLOR 0x000002a8 ++#define NV10TCL_FOG_COLOR_R_SHIFT 0 ++#define NV10TCL_FOG_COLOR_R_MASK 0x000000ff ++#define NV10TCL_FOG_COLOR_G_SHIFT 8 ++#define NV10TCL_FOG_COLOR_G_MASK 0x0000ff00 ++#define NV10TCL_FOG_COLOR_B_SHIFT 16 ++#define NV10TCL_FOG_COLOR_B_MASK 0x00ff0000 ++#define NV10TCL_FOG_COLOR_A_SHIFT 24 ++#define NV10TCL_FOG_COLOR_A_MASK 0xff000000 ++#define NV10TCL_VIEWPORT_CLIP_MODE 0x000002b4 ++#define NV10TCL_VIEWPORT_CLIP_HORIZ(x) (0x000002c0+((x)*4)) ++#define NV10TCL_VIEWPORT_CLIP_HORIZ__SIZE 0x00000008 ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_L_SHIFT 0 ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_L_MASK 0x000007ff ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_LEFT_ENABLE (1 << 11) ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_R_SHIFT 16 ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_R_MASK 0x07ff0000 ++#define NV10TCL_VIEWPORT_CLIP_HORIZ_CLIP_RIGHT_ENABLE (1 << 27) ++#define NV10TCL_VIEWPORT_CLIP_VERT(x) (0x000002e0+((x)*4)) ++#define NV10TCL_VIEWPORT_CLIP_VERT__SIZE 0x00000008 ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_T_SHIFT 0 ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_T_MASK 0x000007ff ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_TOP_ENABLE (1 << 11) ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_B_SHIFT 16 ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_B_MASK 0x07ff0000 ++#define NV10TCL_VIEWPORT_CLIP_VERT_CLIP_BOTTOM_ENABLE (1 << 27) ++#define NV10TCL_ALPHA_FUNC_ENABLE 0x00000300 ++#define NV10TCL_BLEND_FUNC_ENABLE 0x00000304 ++#define NV10TCL_CULL_FACE_ENABLE 0x00000308 ++#define NV10TCL_DEPTH_TEST_ENABLE 0x0000030c ++#define NV10TCL_DITHER_ENABLE 0x00000310 ++#define NV10TCL_LIGHTING_ENABLE 0x00000314 ++#define NV10TCL_POINT_PARAMETERS_ENABLE 0x00000318 ++#define NV10TCL_POINT_SMOOTH_ENABLE 0x0000031c ++#define NV10TCL_LINE_SMOOTH_ENABLE 0x00000320 ++#define NV10TCL_POLYGON_SMOOTH_ENABLE 0x00000324 ++#define NV10TCL_VERTEX_WEIGHT_ENABLE 0x00000328 ++#define NV10TCL_STENCIL_ENABLE 0x0000032c ++#define NV10TCL_POLYGON_OFFSET_POINT_ENABLE 0x00000330 ++#define NV10TCL_POLYGON_OFFSET_LINE_ENABLE 0x00000334 ++#define NV10TCL_POLYGON_OFFSET_FILL_ENABLE 0x00000338 ++#define NV10TCL_ALPHA_FUNC_FUNC 0x0000033c ++#define NV10TCL_ALPHA_FUNC_FUNC_NEVER 0x00000200 ++#define NV10TCL_ALPHA_FUNC_FUNC_LESS 0x00000201 ++#define NV10TCL_ALPHA_FUNC_FUNC_EQUAL 0x00000202 ++#define NV10TCL_ALPHA_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV10TCL_ALPHA_FUNC_FUNC_GREATER 0x00000204 ++#define NV10TCL_ALPHA_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV10TCL_ALPHA_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV10TCL_ALPHA_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV10TCL_ALPHA_FUNC_REF 0x00000340 ++#define NV10TCL_BLEND_FUNC_SRC 0x00000344 ++#define NV10TCL_BLEND_FUNC_SRC_ZERO 0x00000000 ++#define NV10TCL_BLEND_FUNC_SRC_ONE 0x00000001 ++#define NV10TCL_BLEND_FUNC_SRC_SRC_COLOR 0x00000300 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV10TCL_BLEND_FUNC_SRC_SRC_ALPHA 0x00000302 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV10TCL_BLEND_FUNC_SRC_DST_ALPHA 0x00000304 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV10TCL_BLEND_FUNC_SRC_DST_COLOR 0x00000306 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV10TCL_BLEND_FUNC_SRC_SRC_ALPHA_SATURATE 0x00000308 ++#define NV10TCL_BLEND_FUNC_SRC_CONSTANT_COLOR 0x00008001 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV10TCL_BLEND_FUNC_SRC_CONSTANT_ALPHA 0x00008003 ++#define NV10TCL_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV10TCL_BLEND_FUNC_DST 0x00000348 ++#define NV10TCL_BLEND_FUNC_DST_ZERO 0x00000000 ++#define NV10TCL_BLEND_FUNC_DST_ONE 0x00000001 ++#define NV10TCL_BLEND_FUNC_DST_SRC_COLOR 0x00000300 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV10TCL_BLEND_FUNC_DST_SRC_ALPHA 0x00000302 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV10TCL_BLEND_FUNC_DST_DST_ALPHA 0x00000304 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV10TCL_BLEND_FUNC_DST_DST_COLOR 0x00000306 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV10TCL_BLEND_FUNC_DST_SRC_ALPHA_SATURATE 0x00000308 ++#define NV10TCL_BLEND_FUNC_DST_CONSTANT_COLOR 0x00008001 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV10TCL_BLEND_FUNC_DST_CONSTANT_ALPHA 0x00008003 ++#define NV10TCL_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV10TCL_BLEND_COLOR 0x0000034c ++#define NV10TCL_BLEND_COLOR_B_SHIFT 0 ++#define NV10TCL_BLEND_COLOR_B_MASK 0x000000ff ++#define NV10TCL_BLEND_COLOR_G_SHIFT 8 ++#define NV10TCL_BLEND_COLOR_G_MASK 0x0000ff00 ++#define NV10TCL_BLEND_COLOR_R_SHIFT 16 ++#define NV10TCL_BLEND_COLOR_R_MASK 0x00ff0000 ++#define NV10TCL_BLEND_COLOR_A_SHIFT 24 ++#define NV10TCL_BLEND_COLOR_A_MASK 0xff000000 ++#define NV10TCL_BLEND_EQUATION 0x00000350 ++#define NV10TCL_BLEND_EQUATION_FUNC_ADD 0x00008006 ++#define NV10TCL_BLEND_EQUATION_MIN 0x00008007 ++#define NV10TCL_BLEND_EQUATION_MAX 0x00008008 ++#define NV10TCL_BLEND_EQUATION_FUNC_SUBTRACT 0x0000800a ++#define NV10TCL_BLEND_EQUATION_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV10TCL_DEPTH_FUNC 0x00000354 ++#define NV10TCL_DEPTH_FUNC_NEVER 0x00000200 ++#define NV10TCL_DEPTH_FUNC_LESS 0x00000201 ++#define NV10TCL_DEPTH_FUNC_EQUAL 0x00000202 ++#define NV10TCL_DEPTH_FUNC_LEQUAL 0x00000203 ++#define NV10TCL_DEPTH_FUNC_GREATER 0x00000204 ++#define NV10TCL_DEPTH_FUNC_NOTEQUAL 0x00000205 ++#define NV10TCL_DEPTH_FUNC_GEQUAL 0x00000206 ++#define NV10TCL_DEPTH_FUNC_ALWAYS 0x00000207 ++#define NV10TCL_COLOR_MASK 0x00000358 ++#define NV10TCL_COLOR_MASK_B (1 << 0) ++#define NV10TCL_COLOR_MASK_G (1 << 8) ++#define NV10TCL_COLOR_MASK_R (1 << 16) ++#define NV10TCL_COLOR_MASK_A (1 << 24) ++#define NV10TCL_DEPTH_WRITE_ENABLE 0x0000035c ++#define NV10TCL_STENCIL_MASK 0x00000360 ++#define NV10TCL_STENCIL_FUNC_FUNC 0x00000364 ++#define NV10TCL_STENCIL_FUNC_FUNC_NEVER 0x00000200 ++#define NV10TCL_STENCIL_FUNC_FUNC_LESS 0x00000201 ++#define NV10TCL_STENCIL_FUNC_FUNC_EQUAL 0x00000202 ++#define NV10TCL_STENCIL_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV10TCL_STENCIL_FUNC_FUNC_GREATER 0x00000204 ++#define NV10TCL_STENCIL_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV10TCL_STENCIL_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV10TCL_STENCIL_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV10TCL_STENCIL_FUNC_REF 0x00000368 ++#define NV10TCL_STENCIL_FUNC_MASK 0x0000036c ++#define NV10TCL_STENCIL_OP_FAIL 0x00000370 ++#define NV10TCL_STENCIL_OP_FAIL_ZERO 0x00000000 ++#define NV10TCL_STENCIL_OP_FAIL_INVERT 0x0000150a ++#define NV10TCL_STENCIL_OP_FAIL_KEEP 0x00001e00 ++#define NV10TCL_STENCIL_OP_FAIL_REPLACE 0x00001e01 ++#define NV10TCL_STENCIL_OP_FAIL_INCR 0x00001e02 ++#define NV10TCL_STENCIL_OP_FAIL_DECR 0x00001e03 ++#define NV10TCL_STENCIL_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV10TCL_STENCIL_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV10TCL_STENCIL_OP_ZFAIL 0x00000374 ++#define NV10TCL_STENCIL_OP_ZFAIL_ZERO 0x00000000 ++#define NV10TCL_STENCIL_OP_ZFAIL_INVERT 0x0000150a ++#define NV10TCL_STENCIL_OP_ZFAIL_KEEP 0x00001e00 ++#define NV10TCL_STENCIL_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV10TCL_STENCIL_OP_ZFAIL_INCR 0x00001e02 ++#define NV10TCL_STENCIL_OP_ZFAIL_DECR 0x00001e03 ++#define NV10TCL_STENCIL_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV10TCL_STENCIL_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV10TCL_STENCIL_OP_ZPASS 0x00000378 ++#define NV10TCL_STENCIL_OP_ZPASS_ZERO 0x00000000 ++#define NV10TCL_STENCIL_OP_ZPASS_INVERT 0x0000150a ++#define NV10TCL_STENCIL_OP_ZPASS_KEEP 0x00001e00 ++#define NV10TCL_STENCIL_OP_ZPASS_REPLACE 0x00001e01 ++#define NV10TCL_STENCIL_OP_ZPASS_INCR 0x00001e02 ++#define NV10TCL_STENCIL_OP_ZPASS_DECR 0x00001e03 ++#define NV10TCL_STENCIL_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV10TCL_STENCIL_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV10TCL_SHADE_MODEL 0x0000037c ++#define NV10TCL_SHADE_MODEL_FLAT 0x00001d00 ++#define NV10TCL_SHADE_MODEL_SMOOTH 0x00001d01 ++#define NV10TCL_LINE_WIDTH 0x00000380 ++#define NV10TCL_POLYGON_OFFSET_FACTOR 0x00000384 ++#define NV10TCL_POLYGON_OFFSET_UNITS 0x00000388 ++#define NV10TCL_POLYGON_MODE_FRONT 0x0000038c ++#define NV10TCL_POLYGON_MODE_FRONT_POINT 0x00001b00 ++#define NV10TCL_POLYGON_MODE_FRONT_LINE 0x00001b01 ++#define NV10TCL_POLYGON_MODE_FRONT_FILL 0x00001b02 ++#define NV10TCL_POLYGON_MODE_BACK 0x00000390 ++#define NV10TCL_POLYGON_MODE_BACK_POINT 0x00001b00 ++#define NV10TCL_POLYGON_MODE_BACK_LINE 0x00001b01 ++#define NV10TCL_POLYGON_MODE_BACK_FILL 0x00001b02 ++#define NV10TCL_DEPTH_RANGE_NEAR 0x00000394 ++#define NV10TCL_DEPTH_RANGE_FAR 0x00000398 ++#define NV10TCL_CULL_FACE 0x0000039c ++#define NV10TCL_CULL_FACE_FRONT 0x00000404 ++#define NV10TCL_CULL_FACE_BACK 0x00000405 ++#define NV10TCL_CULL_FACE_FRONT_AND_BACK 0x00000408 ++#define NV10TCL_FRONT_FACE 0x000003a0 ++#define NV10TCL_FRONT_FACE_CW 0x00000900 ++#define NV10TCL_FRONT_FACE_CCW 0x00000901 ++#define NV10TCL_NORMALIZE_ENABLE 0x000003a4 ++#define NV10TCL_MATERIAL_FACTOR_R 0x000003a8 ++#define NV10TCL_MATERIAL_FACTOR_G 0x000003ac ++#define NV10TCL_MATERIAL_FACTOR_B 0x000003b0 ++#define NV10TCL_MATERIAL_FACTOR_A 0x000003b4 ++#define NV10TCL_SEPARATE_SPECULAR_ENABLE 0x000003b8 ++#define NV10TCL_ENABLED_LIGHTS 0x000003bc ++#define NV10TCL_ENABLED_LIGHTS_0_SHIFT 0 ++#define NV10TCL_ENABLED_LIGHTS_0_MASK 0x00000003 ++#define NV10TCL_ENABLED_LIGHTS_0_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_0_NONPOSITIONAL 0x00000001 ++#define NV10TCL_ENABLED_LIGHTS_0_POSITIONAL 0x00000002 ++#define NV10TCL_ENABLED_LIGHTS_0_DIRECTIONAL 0x00000003 ++#define NV10TCL_ENABLED_LIGHTS_1_SHIFT 2 ++#define NV10TCL_ENABLED_LIGHTS_1_MASK 0x0000000c ++#define NV10TCL_ENABLED_LIGHTS_1_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_1_NONPOSITIONAL 0x00000004 ++#define NV10TCL_ENABLED_LIGHTS_1_POSITIONAL 0x00000008 ++#define NV10TCL_ENABLED_LIGHTS_1_DIRECTIONAL 0x0000000c ++#define NV10TCL_ENABLED_LIGHTS_2_SHIFT 4 ++#define NV10TCL_ENABLED_LIGHTS_2_MASK 0x00000030 ++#define NV10TCL_ENABLED_LIGHTS_2_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_2_NONPOSITIONAL 0x00000010 ++#define NV10TCL_ENABLED_LIGHTS_2_POSITIONAL 0x00000020 ++#define NV10TCL_ENABLED_LIGHTS_2_DIRECTIONAL 0x00000030 ++#define NV10TCL_ENABLED_LIGHTS_3_SHIFT 6 ++#define NV10TCL_ENABLED_LIGHTS_3_MASK 0x000000c0 ++#define NV10TCL_ENABLED_LIGHTS_3_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_3_NONPOSITIONAL 0x00000040 ++#define NV10TCL_ENABLED_LIGHTS_3_POSITIONAL 0x00000080 ++#define NV10TCL_ENABLED_LIGHTS_3_DIRECTIONAL 0x000000c0 ++#define NV10TCL_ENABLED_LIGHTS_4_SHIFT 8 ++#define NV10TCL_ENABLED_LIGHTS_4_MASK 0x00000300 ++#define NV10TCL_ENABLED_LIGHTS_4_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_4_NONPOSITIONAL 0x00000100 ++#define NV10TCL_ENABLED_LIGHTS_4_POSITIONAL 0x00000200 ++#define NV10TCL_ENABLED_LIGHTS_4_DIRECTIONAL 0x00000300 ++#define NV10TCL_ENABLED_LIGHTS_5_SHIFT 10 ++#define NV10TCL_ENABLED_LIGHTS_5_MASK 0x00000c00 ++#define NV10TCL_ENABLED_LIGHTS_5_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_5_NONPOSITIONAL 0x00000400 ++#define NV10TCL_ENABLED_LIGHTS_5_POSITIONAL 0x00000800 ++#define NV10TCL_ENABLED_LIGHTS_5_DIRECTIONAL 0x00000c00 ++#define NV10TCL_ENABLED_LIGHTS_6_SHIFT 12 ++#define NV10TCL_ENABLED_LIGHTS_6_MASK 0x00003000 ++#define NV10TCL_ENABLED_LIGHTS_6_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_6_NONPOSITIONAL 0x00001000 ++#define NV10TCL_ENABLED_LIGHTS_6_POSITIONAL 0x00002000 ++#define NV10TCL_ENABLED_LIGHTS_6_DIRECTIONAL 0x00003000 ++#define NV10TCL_ENABLED_LIGHTS_7_SHIFT 14 ++#define NV10TCL_ENABLED_LIGHTS_7_MASK 0x0000c000 ++#define NV10TCL_ENABLED_LIGHTS_7_DISABLED 0x00000000 ++#define NV10TCL_ENABLED_LIGHTS_7_NONPOSITIONAL 0x00004000 ++#define NV10TCL_ENABLED_LIGHTS_7_POSITIONAL 0x00008000 ++#define NV10TCL_ENABLED_LIGHTS_7_DIRECTIONAL 0x0000c000 ++#define NV10TCL_TX_GEN_MODE_S(x) (0x000003c0+((x)*16)) ++#define NV10TCL_TX_GEN_MODE_S__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_MODE_S_FALSE 0x00000000 ++#define NV10TCL_TX_GEN_MODE_S_EYE_LINEAR 0x00002400 ++#define NV10TCL_TX_GEN_MODE_S_OBJECT_LINEAR 0x00002401 ++#define NV10TCL_TX_GEN_MODE_S_SPHERE_MAP 0x00002402 ++#define NV10TCL_TX_GEN_MODE_S_NORMAL_MAP 0x00008511 ++#define NV10TCL_TX_GEN_MODE_S_REFLECTION_MAP 0x00008512 ++#define NV10TCL_TX_GEN_MODE_T(x) (0x000003c4+((x)*16)) ++#define NV10TCL_TX_GEN_MODE_T__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_MODE_T_FALSE 0x00000000 ++#define NV10TCL_TX_GEN_MODE_T_EYE_LINEAR 0x00002400 ++#define NV10TCL_TX_GEN_MODE_T_OBJECT_LINEAR 0x00002401 ++#define NV10TCL_TX_GEN_MODE_T_SPHERE_MAP 0x00002402 ++#define NV10TCL_TX_GEN_MODE_T_NORMAL_MAP 0x00008511 ++#define NV10TCL_TX_GEN_MODE_T_REFLECTION_MAP 0x00008512 ++#define NV10TCL_TX_GEN_MODE_R(x) (0x000003c8+((x)*16)) ++#define NV10TCL_TX_GEN_MODE_R__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_MODE_R_FALSE 0x00000000 ++#define NV10TCL_TX_GEN_MODE_R_EYE_LINEAR 0x00002400 ++#define NV10TCL_TX_GEN_MODE_R_OBJECT_LINEAR 0x00002401 ++#define NV10TCL_TX_GEN_MODE_R_SPHERE_MAP 0x00002402 ++#define NV10TCL_TX_GEN_MODE_R_NORMAL_MAP 0x00008511 ++#define NV10TCL_TX_GEN_MODE_R_REFLECTION_MAP 0x00008512 ++#define NV10TCL_TX_GEN_MODE_Q(x) (0x000003cc+((x)*16)) ++#define NV10TCL_TX_GEN_MODE_Q__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_MODE_Q_FALSE 0x00000000 ++#define NV10TCL_TX_GEN_MODE_Q_EYE_LINEAR 0x00002400 ++#define NV10TCL_TX_GEN_MODE_Q_OBJECT_LINEAR 0x00002401 ++#define NV10TCL_TX_GEN_MODE_Q_SPHERE_MAP 0x00002402 ++#define NV10TCL_TX_GEN_MODE_Q_NORMAL_MAP 0x00008511 ++#define NV10TCL_TX_GEN_MODE_Q_REFLECTION_MAP 0x00008512 ++#define NV10TCL_TX_MATRIX_ENABLE(x) (0x000003e0+((x)*4)) ++#define NV10TCL_TX_MATRIX_ENABLE__SIZE 0x00000002 ++#define NV10TCL_VIEW_MATRIX_ENABLE 0x000003e8 ++#define NV10TCL_VIEW_MATRIX_ENABLE_MODELVIEW1 (1 << 0) ++#define NV10TCL_VIEW_MATRIX_ENABLE_MODELVIEW0 (1 << 1) ++#define NV10TCL_VIEW_MATRIX_ENABLE_PROJECTION (1 << 2) ++#define NV10TCL_POINT_SIZE 0x000003ec ++#define NV10TCL_MODELVIEW0_MATRIX(x) (0x00000400+((x)*4)) ++#define NV10TCL_MODELVIEW0_MATRIX__SIZE 0x00000010 ++#define NV10TCL_MODELVIEW1_MATRIX(x) (0x00000440+((x)*4)) ++#define NV10TCL_MODELVIEW1_MATRIX__SIZE 0x00000010 ++#define NV10TCL_INVERSE_MODELVIEW0_MATRIX(x) (0x00000480+((x)*4)) ++#define NV10TCL_INVERSE_MODELVIEW0_MATRIX__SIZE 0x00000010 ++#define NV10TCL_INVERSE_MODELVIEW1_MATRIX(x) (0x000004c0+((x)*4)) ++#define NV10TCL_INVERSE_MODELVIEW1_MATRIX__SIZE 0x00000010 ++#define NV10TCL_PROJECTION_MATRIX(x) (0x00000500+((x)*4)) ++#define NV10TCL_PROJECTION_MATRIX__SIZE 0x00000010 ++#define NV10TCL_TX0_MATRIX(x) (0x00000540+((x)*4)) ++#define NV10TCL_TX0_MATRIX__SIZE 0x00000010 ++#define NV10TCL_TX1_MATRIX(x) (0x00000580+((x)*4)) ++#define NV10TCL_TX1_MATRIX__SIZE 0x00000010 ++#define NV10TCL_TX_GEN_COEFF_S_A(x) (0x00000600+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_S_A__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_S_B(x) (0x00000604+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_S_B__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_S_C(x) (0x00000608+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_S_C__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_S_D(x) (0x0000060c+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_S_D__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_T_A(x) (0x00000610+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_T_A__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_T_B(x) (0x00000614+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_T_B__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_T_C(x) (0x00000618+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_T_C__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_T_D(x) (0x0000061c+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_T_D__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_R_A(x) (0x00000620+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_R_A__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_R_B(x) (0x00000624+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_R_B__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_R_C(x) (0x00000628+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_R_C__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_R_D(x) (0x0000062c+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_R_D__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_Q_A(x) (0x00000630+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_Q_A__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_Q_B(x) (0x00000634+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_Q_B__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_Q_C(x) (0x00000638+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_Q_C__SIZE 0x00000002 ++#define NV10TCL_TX_GEN_COEFF_Q_D(x) (0x0000063c+((x)*64)) ++#define NV10TCL_TX_GEN_COEFF_Q_D__SIZE 0x00000002 ++#define NV10TCL_FOG_EQUATION_CONSTANT 0x00000680 ++#define NV10TCL_FOG_EQUATION_LINEAR 0x00000684 ++#define NV10TCL_FOG_EQUATION_QUADRATIC 0x00000688 ++#define NV10TCL_MATERIAL_SHININESS(x) (0x000006a0+((x)*4)) ++#define NV10TCL_MATERIAL_SHININESS__SIZE 0x00000006 ++#define NV10TCL_LIGHT_MODEL_AMBIENT_R 0x000006c4 ++#define NV10TCL_LIGHT_MODEL_AMBIENT_G 0x000006c8 ++#define NV10TCL_LIGHT_MODEL_AMBIENT_B 0x000006cc ++#define NV10TCL_VIEWPORT_TRANSLATE_X 0x000006e8 ++#define NV10TCL_VIEWPORT_TRANSLATE_Y 0x000006ec ++#define NV10TCL_VIEWPORT_TRANSLATE_Z 0x000006f0 ++#define NV10TCL_VIEWPORT_TRANSLATE_W 0x000006f4 ++#define NV10TCL_POINT_PARAMETER(x) (0x000006f8+((x)*4)) ++#define NV10TCL_POINT_PARAMETER__SIZE 0x00000008 ++#define NV10TCL_LIGHT_AMBIENT_R(x) (0x00000800+((x)*128)) ++#define NV10TCL_LIGHT_AMBIENT_R__SIZE 0x00000008 ++#define NV10TCL_LIGHT_AMBIENT_G(x) (0x00000804+((x)*128)) ++#define NV10TCL_LIGHT_AMBIENT_G__SIZE 0x00000008 ++#define NV10TCL_LIGHT_AMBIENT_B(x) (0x00000808+((x)*128)) ++#define NV10TCL_LIGHT_AMBIENT_B__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIFFUSE_R(x) (0x0000080c+((x)*128)) ++#define NV10TCL_LIGHT_DIFFUSE_R__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIFFUSE_G(x) (0x00000810+((x)*128)) ++#define NV10TCL_LIGHT_DIFFUSE_G__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIFFUSE_B(x) (0x00000814+((x)*128)) ++#define NV10TCL_LIGHT_DIFFUSE_B__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPECULAR_R(x) (0x00000818+((x)*128)) ++#define NV10TCL_LIGHT_SPECULAR_R__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPECULAR_G(x) (0x0000081c+((x)*128)) ++#define NV10TCL_LIGHT_SPECULAR_G__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPECULAR_B(x) (0x00000820+((x)*128)) ++#define NV10TCL_LIGHT_SPECULAR_B__SIZE 0x00000008 ++#define NV10TCL_LIGHT_HALF_VECTOR_X(x) (0x00000828+((x)*128)) ++#define NV10TCL_LIGHT_HALF_VECTOR_X__SIZE 0x00000008 ++#define NV10TCL_LIGHT_HALF_VECTOR_Y(x) (0x0000082c+((x)*128)) ++#define NV10TCL_LIGHT_HALF_VECTOR_Y__SIZE 0x00000008 ++#define NV10TCL_LIGHT_HALF_VECTOR_Z(x) (0x00000830+((x)*128)) ++#define NV10TCL_LIGHT_HALF_VECTOR_Z__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIRECTION_X(x) (0x00000834+((x)*128)) ++#define NV10TCL_LIGHT_DIRECTION_X__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIRECTION_Y(x) (0x00000838+((x)*128)) ++#define NV10TCL_LIGHT_DIRECTION_Y__SIZE 0x00000008 ++#define NV10TCL_LIGHT_DIRECTION_Z(x) (0x0000083c+((x)*128)) ++#define NV10TCL_LIGHT_DIRECTION_Z__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_CUTOFF_A(x) (0x00000840+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_CUTOFF_A__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_CUTOFF_B(x) (0x00000844+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_CUTOFF_B__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_CUTOFF_C(x) (0x00000848+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_CUTOFF_C__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_DIR_X(x) (0x0000084c+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_DIR_X__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_DIR_Y(x) (0x00000850+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_DIR_Y__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_DIR_Z(x) (0x00000854+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_DIR_Z__SIZE 0x00000008 ++#define NV10TCL_LIGHT_SPOT_CUTOFF_D(x) (0x00000858+((x)*128)) ++#define NV10TCL_LIGHT_SPOT_CUTOFF_D__SIZE 0x00000008 ++#define NV10TCL_LIGHT_POSITION_X(x) (0x0000085c+((x)*128)) ++#define NV10TCL_LIGHT_POSITION_X__SIZE 0x00000008 ++#define NV10TCL_LIGHT_POSITION_Y(x) (0x00000860+((x)*128)) ++#define NV10TCL_LIGHT_POSITION_Y__SIZE 0x00000008 ++#define NV10TCL_LIGHT_POSITION_Z(x) (0x00000864+((x)*128)) ++#define NV10TCL_LIGHT_POSITION_Z__SIZE 0x00000008 ++#define NV10TCL_LIGHT_ATTENUATION_CONSTANT(x) (0x00000868+((x)*128)) ++#define NV10TCL_LIGHT_ATTENUATION_CONSTANT__SIZE 0x00000008 ++#define NV10TCL_LIGHT_ATTENUATION_LINEAR(x) (0x0000086c+((x)*128)) ++#define NV10TCL_LIGHT_ATTENUATION_LINEAR__SIZE 0x00000008 ++#define NV10TCL_LIGHT_ATTENUATION_QUADRATIC(x) (0x00000870+((x)*128)) ++#define NV10TCL_LIGHT_ATTENUATION_QUADRATIC__SIZE 0x00000008 ++#define NV10TCL_VERTEX_POS_3F_X 0x00000c00 ++#define NV10TCL_VERTEX_POS_3F_Y 0x00000c04 ++#define NV10TCL_VERTEX_POS_3F_Z 0x00000c08 ++#define NV10TCL_VERTEX_POS_4F_X 0x00000c18 ++#define NV10TCL_VERTEX_POS_4F_Y 0x00000c1c ++#define NV10TCL_VERTEX_POS_4F_Z 0x00000c20 ++#define NV10TCL_VERTEX_POS_4F_W 0x00000c24 ++#define NV10TCL_VERTEX_NOR_3F_X 0x00000c30 ++#define NV10TCL_VERTEX_NOR_3F_Y 0x00000c34 ++#define NV10TCL_VERTEX_NOR_3F_Z 0x00000c38 ++#define NV10TCL_VERTEX_NOR_3I_XY 0x00000c40 ++#define NV10TCL_VERTEX_NOR_3I_XY_X_SHIFT 0 ++#define NV10TCL_VERTEX_NOR_3I_XY_X_MASK 0x0000ffff ++#define NV10TCL_VERTEX_NOR_3I_XY_Y_SHIFT 16 ++#define NV10TCL_VERTEX_NOR_3I_XY_Y_MASK 0xffff0000 ++#define NV10TCL_VERTEX_NOR_3I_Z 0x00000c44 ++#define NV10TCL_VERTEX_NOR_3I_Z_Z_SHIFT 0 ++#define NV10TCL_VERTEX_NOR_3I_Z_Z_MASK 0x0000ffff ++#define NV10TCL_VERTEX_COL_4F_R 0x00000c50 ++#define NV10TCL_VERTEX_COL_4F_G 0x00000c54 ++#define NV10TCL_VERTEX_COL_4F_B 0x00000c58 ++#define NV10TCL_VERTEX_COL_4F_A 0x00000c5c ++#define NV10TCL_VERTEX_COL_3F_R 0x00000c60 ++#define NV10TCL_VERTEX_COL_3F_G 0x00000c64 ++#define NV10TCL_VERTEX_COL_3F_B 0x00000c68 ++#define NV10TCL_VERTEX_COL_4I 0x00000c6c ++#define NV10TCL_VERTEX_COL_4I_R_SHIFT 0 ++#define NV10TCL_VERTEX_COL_4I_R_MASK 0x000000ff ++#define NV10TCL_VERTEX_COL_4I_G_SHIFT 8 ++#define NV10TCL_VERTEX_COL_4I_G_MASK 0x0000ff00 ++#define NV10TCL_VERTEX_COL_4I_B_SHIFT 16 ++#define NV10TCL_VERTEX_COL_4I_B_MASK 0x00ff0000 ++#define NV10TCL_VERTEX_COL_4I_A_SHIFT 24 ++#define NV10TCL_VERTEX_COL_4I_A_MASK 0xff000000 ++#define NV10TCL_VERTEX_COL2_3F_R 0x00000c80 ++#define NV10TCL_VERTEX_COL2_3F_G 0x00000c84 ++#define NV10TCL_VERTEX_COL2_3F_B 0x00000c88 ++#define NV10TCL_VERTEX_COL2_3I 0x00000c8c ++#define NV10TCL_VERTEX_COL2_3I_R_SHIFT 0 ++#define NV10TCL_VERTEX_COL2_3I_R_MASK 0x000000ff ++#define NV10TCL_VERTEX_COL2_3I_G_SHIFT 8 ++#define NV10TCL_VERTEX_COL2_3I_G_MASK 0x0000ff00 ++#define NV10TCL_VERTEX_COL2_3I_B_SHIFT 16 ++#define NV10TCL_VERTEX_COL2_3I_B_MASK 0x00ff0000 ++#define NV10TCL_VERTEX_TX0_2F_S 0x00000c90 ++#define NV10TCL_VERTEX_TX0_2F_T 0x00000c94 ++#define NV10TCL_VERTEX_TX0_2I 0x00000c98 ++#define NV10TCL_VERTEX_TX0_2I_S_SHIFT 0 ++#define NV10TCL_VERTEX_TX0_2I_S_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX0_2I_T_SHIFT 16 ++#define NV10TCL_VERTEX_TX0_2I_T_MASK 0xffff0000 ++#define NV10TCL_VERTEX_TX0_4F_S 0x00000ca0 ++#define NV10TCL_VERTEX_TX0_4F_T 0x00000ca4 ++#define NV10TCL_VERTEX_TX0_4F_R 0x00000ca8 ++#define NV10TCL_VERTEX_TX0_4F_Q 0x00000cac ++#define NV10TCL_VERTEX_TX0_4I_ST 0x00000cb0 ++#define NV10TCL_VERTEX_TX0_4I_ST_S_SHIFT 0 ++#define NV10TCL_VERTEX_TX0_4I_ST_S_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX0_4I_ST_T_SHIFT 16 ++#define NV10TCL_VERTEX_TX0_4I_ST_T_MASK 0xffff0000 ++#define NV10TCL_VERTEX_TX0_4I_RQ 0x00000cb4 ++#define NV10TCL_VERTEX_TX0_4I_RQ_R_SHIFT 0 ++#define NV10TCL_VERTEX_TX0_4I_RQ_R_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX0_4I_RQ_Q_SHIFT 16 ++#define NV10TCL_VERTEX_TX0_4I_RQ_Q_MASK 0xffff0000 ++#define NV10TCL_VERTEX_TX1_2F_S 0x00000cb8 ++#define NV10TCL_VERTEX_TX1_2F_T 0x00000cbc ++#define NV10TCL_VERTEX_TX1_2I 0x00000cc0 ++#define NV10TCL_VERTEX_TX1_2I_S_SHIFT 0 ++#define NV10TCL_VERTEX_TX1_2I_S_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX1_2I_T_SHIFT 16 ++#define NV10TCL_VERTEX_TX1_2I_T_MASK 0xffff0000 ++#define NV10TCL_VERTEX_TX1_4F_S 0x00000cc8 ++#define NV10TCL_VERTEX_TX1_4F_T 0x00000ccc ++#define NV10TCL_VERTEX_TX1_4F_R 0x00000cd0 ++#define NV10TCL_VERTEX_TX1_4F_Q 0x00000cd4 ++#define NV10TCL_VERTEX_TX1_4I_ST 0x00000cd8 ++#define NV10TCL_VERTEX_TX1_4I_ST_S_SHIFT 0 ++#define NV10TCL_VERTEX_TX1_4I_ST_S_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX1_4I_ST_T_SHIFT 16 ++#define NV10TCL_VERTEX_TX1_4I_ST_T_MASK 0xffff0000 ++#define NV10TCL_VERTEX_TX1_4I_RQ 0x00000cdc ++#define NV10TCL_VERTEX_TX1_4I_RQ_R_SHIFT 0 ++#define NV10TCL_VERTEX_TX1_4I_RQ_R_MASK 0x0000ffff ++#define NV10TCL_VERTEX_TX1_4I_RQ_Q_SHIFT 16 ++#define NV10TCL_VERTEX_TX1_4I_RQ_Q_MASK 0xffff0000 ++#define NV10TCL_VERTEX_FOG_1F 0x00000ce0 ++#define NV10TCL_VERTEX_WGH_1F 0x00000ce4 ++#define NV10TCL_EDGEFLAG_ENABLE 0x00000cec ++#define NV10TCL_VERTEX_ARRAY_VALIDATE 0x00000cf0 ++#define NV10TCL_VTXBUF_ADDRESS(x) (0x00000d00+((x)*8)) ++#define NV10TCL_VTXBUF_ADDRESS__SIZE 0x00000008 ++#define NV10TCL_VTXFMT(x) (0x00000d04+((x)*8)) ++#define NV10TCL_VTXFMT__SIZE 0x00000008 ++#define NV10TCL_VTXFMT_TYPE_SHIFT 0 ++#define NV10TCL_VTXFMT_TYPE_MASK 0x0000000f ++#define NV10TCL_VTXFMT_TYPE_BYTE_BGRA 0x00000000 ++#define NV10TCL_VTXFMT_TYPE_SHORT 0x00000001 ++#define NV10TCL_VTXFMT_TYPE_FLOAT 0x00000002 ++#define NV10TCL_VTXFMT_TYPE_BYTE_RGBA 0x00000004 ++#define NV10TCL_VTXFMT_FIELDS_SHIFT 4 ++#define NV10TCL_VTXFMT_FIELDS_MASK 0x000000f0 ++#define NV10TCL_VTXFMT_STRIDE_SHIFT 8 ++#define NV10TCL_VTXFMT_STRIDE_MASK 0x0000ff00 ++#define NV10TCL_VTXFMT_POS_HOMOGENEOUS (1 << 24) ++#define NV10TCL_VERTEX_BEGIN_END 0x00000dfc ++#define NV10TCL_VERTEX_BEGIN_END_STOP 0x00000000 ++#define NV10TCL_VERTEX_BEGIN_END_POINTS 0x00000001 ++#define NV10TCL_VERTEX_BEGIN_END_LINES 0x00000002 ++#define NV10TCL_VERTEX_BEGIN_END_LINE_LOOP 0x00000003 ++#define NV10TCL_VERTEX_BEGIN_END_LINE_STRIP 0x00000004 ++#define NV10TCL_VERTEX_BEGIN_END_TRIANGLES 0x00000005 ++#define NV10TCL_VERTEX_BEGIN_END_TRIANGLE_STRIP 0x00000006 ++#define NV10TCL_VERTEX_BEGIN_END_TRIANGLE_FAN 0x00000007 ++#define NV10TCL_VERTEX_BEGIN_END_QUADS 0x00000008 ++#define NV10TCL_VERTEX_BEGIN_END_QUAD_STRIP 0x00000009 ++#define NV10TCL_VERTEX_BEGIN_END_POLYGON 0x0000000a ++#define NV10TCL_VB_ELEMENT_U16 0x00000e00 ++#define NV10TCL_VB_ELEMENT_U16_I0_SHIFT 0 ++#define NV10TCL_VB_ELEMENT_U16_I0_MASK 0x0000ffff ++#define NV10TCL_VB_ELEMENT_U16_I1_SHIFT 16 ++#define NV10TCL_VB_ELEMENT_U16_I1_MASK 0xffff0000 ++#define NV10TCL_VB_ELEMENT_U32 0x00001100 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END 0x000013fc ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_STOP 0x00000000 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_POINTS 0x00000001 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_LINES 0x00000002 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_LINE_LOOP 0x00000003 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_LINE_STRIP 0x00000004 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_TRIANGLES 0x00000005 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_TRIANGLE_STRIP 0x00000006 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_TRIANGLE_FAN 0x00000007 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_QUADS 0x00000008 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_QUAD_STRIP 0x00000009 ++#define NV10TCL_VERTEX_BUFFER_BEGIN_END_POLYGON 0x0000000a ++#define NV10TCL_VERTEX_BUFFER_DRAW_ARRAYS 0x00001400 ++#define NV10TCL_VERTEX_BUFFER_DRAW_ARRAYS_FIRST_SHIFT 0 ++#define NV10TCL_VERTEX_BUFFER_DRAW_ARRAYS_FIRST_MASK 0x0000ffff ++#define NV10TCL_VERTEX_BUFFER_DRAW_ARRAYS_LAST_SHIFT 24 ++#define NV10TCL_VERTEX_BUFFER_DRAW_ARRAYS_LAST_MASK 0xff000000 ++#define NV10TCL_VERTEX_ARRAY_DATA 0x00001800 ++ ++ ++#define NV11TCL 0x00000096 ++ ++#define NV11TCL_COLOR_LOGIC_OP_ENABLE 0x00000d40 ++#define NV11TCL_COLOR_LOGIC_OP_OP 0x00000d44 ++#define NV11TCL_COLOR_LOGIC_OP_OP_CLEAR 0x00001500 ++#define NV11TCL_COLOR_LOGIC_OP_OP_AND 0x00001501 ++#define NV11TCL_COLOR_LOGIC_OP_OP_AND_REVERSE 0x00001502 ++#define NV11TCL_COLOR_LOGIC_OP_OP_COPY 0x00001503 ++#define NV11TCL_COLOR_LOGIC_OP_OP_AND_INVERTED 0x00001504 ++#define NV11TCL_COLOR_LOGIC_OP_OP_NOOP 0x00001505 ++#define NV11TCL_COLOR_LOGIC_OP_OP_XOR 0x00001506 ++#define NV11TCL_COLOR_LOGIC_OP_OP_OR 0x00001507 ++#define NV11TCL_COLOR_LOGIC_OP_OP_NOR 0x00001508 ++#define NV11TCL_COLOR_LOGIC_OP_OP_EQUIV 0x00001509 ++#define NV11TCL_COLOR_LOGIC_OP_OP_INVERT 0x0000150a ++#define NV11TCL_COLOR_LOGIC_OP_OP_OR_REVERSE 0x0000150b ++#define NV11TCL_COLOR_LOGIC_OP_OP_COPY_INVERTED 0x0000150c ++#define NV11TCL_COLOR_LOGIC_OP_OP_OR_INVERTED 0x0000150d ++#define NV11TCL_COLOR_LOGIC_OP_OP_NAND 0x0000150e ++#define NV11TCL_COLOR_LOGIC_OP_OP_SET 0x0000150f ++ ++ ++#define NV17TCL 0x00000099 ++ ++#define NV17TCL_DMA_IN_MEMORY4 0x000001ac ++#define NV17TCL_DMA_IN_MEMORY5 0x000001b0 ++#define NV17TCL_COLOR_MASK_ENABLE 0x000002bc ++#define NV17TCL_LMA_DEPTH_BUFFER_PITCH 0x00000d5c ++#define NV17TCL_LMA_DEPTH_BUFFER_OFFSET 0x00000d60 ++#define NV17TCL_LMA_DEPTH_FILL_VALUE 0x00000d68 ++#define NV17TCL_LMA_DEPTH_BUFFER_CLEAR 0x00000d6c ++#define NV17TCL_LMA_DEPTH_WINDOW_X 0x00001638 ++#define NV17TCL_LMA_DEPTH_WINDOW_Y 0x0000163c ++#define NV17TCL_LMA_DEPTH_WINDOW_Z 0x00001640 ++#define NV17TCL_LMA_DEPTH_WINDOW_W 0x00001644 ++#define NV17TCL_LMA_DEPTH_ENABLE 0x00001658 ++ ++ ++#define NV03_CONTEXT_SURFACES_2D 0x00000058 ++ ++#define NV03_CONTEXT_SURFACES_2D_SYNCHRONIZE 0x00000100 ++#define NV03_CONTEXT_SURFACES_2D_DMA_NOTIFY 0x00000180 ++#define NV03_CONTEXT_SURFACES_2D_DMA_SOURCE 0x00000184 ++#define NV03_CONTEXT_SURFACES_2D_DMA_DESTIN 0x00000188 ++#define NV03_CONTEXT_SURFACES_2D_COLOR_FORMAT 0x00000300 ++#define NV03_CONTEXT_SURFACES_2D_PITCH 0x00000304 ++#define NV03_CONTEXT_SURFACES_2D_PITCH_SOURCE_SHIFT 0 ++#define NV03_CONTEXT_SURFACES_2D_PITCH_SOURCE_MASK 0x0000ffff ++#define NV03_CONTEXT_SURFACES_2D_PITCH_DESTIN_SHIFT 16 ++#define NV03_CONTEXT_SURFACES_2D_PITCH_DESTIN_MASK 0xffff0000 ++#define NV03_CONTEXT_SURFACES_2D_OFFSET_SOURCE 0x00000308 ++#define NV03_CONTEXT_SURFACES_2D_OFFSET_DESTIN 0x0000030c ++ ++ ++#define NV03_CONTEXT_SURFACES_3D 0x0000005a ++ ++#define NV03_CONTEXT_SURFACES_3D_SYNCHRONIZE 0x00000100 ++#define NV03_CONTEXT_SURFACES_3D_DMA_NOTIFY 0x00000180 ++#define NV03_CONTEXT_SURFACES_3D_DMA_SURFACE 0x00000184 ++#define NV03_CONTEXT_SURFACES_3D_PITCH 0x00000300 ++#define NV03_CONTEXT_SURFACES_3D_OFFSET_COLOR 0x00000304 ++#define NV03_CONTEXT_SURFACES_3D_OFFSET_ZETA 0x00000308 ++ ++ ++#define NV04_INDEXED_IMAGE_FROM_CPU 0x00000060 ++ ++#define NV04_INDEXED_IMAGE_FROM_CPU_NOP 0x00000100 ++#define NV04_INDEXED_IMAGE_FROM_CPU_NOTIFY 0x00000104 ++#define NV04_INDEXED_IMAGE_FROM_CPU_PATCH 0x0000010c ++#define NV04_INDEXED_IMAGE_FROM_CPU_DMA_NOTIFY 0x00000180 ++#define NV04_INDEXED_IMAGE_FROM_CPU_DMA_LUT 0x00000184 ++#define NV04_INDEXED_IMAGE_FROM_CPU_COLOR_KEY 0x00000188 ++#define NV04_INDEXED_IMAGE_FROM_CPU_CLIP_RECTANGLE 0x0000018c ++#define NV04_INDEXED_IMAGE_FROM_CPU_PATTERN 0x00000190 ++#define NV04_INDEXED_IMAGE_FROM_CPU_ROP 0x00000194 ++#define NV04_INDEXED_IMAGE_FROM_CPU_BETA1 0x00000198 ++#define NV04_INDEXED_IMAGE_FROM_CPU_BETA4 0x0000019c ++#define NV04_INDEXED_IMAGE_FROM_CPU_SURFACE 0x000001a0 ++#define NV04_INDEXED_IMAGE_FROM_CPU_OPERATION 0x000003e4 ++#define NV04_INDEXED_IMAGE_FROM_CPU_COLOR_FORMAT 0x000003e8 ++#define NV04_INDEXED_IMAGE_FROM_CPU_INDEX_FORMAT 0x000003ec ++#define NV04_INDEXED_IMAGE_FROM_CPU_LUT_OFFSET 0x000003f0 ++#define NV04_INDEXED_IMAGE_FROM_CPU_POINT 0x000003f4 ++#define NV04_INDEXED_IMAGE_FROM_CPU_SIZE_OUT 0x000003f8 ++#define NV04_INDEXED_IMAGE_FROM_CPU_SIZE_IN 0x000003fc ++#define NV04_INDEXED_IMAGE_FROM_CPU_COLOR(x) (0x00000400+((x)*4)) ++#define NV04_INDEXED_IMAGE_FROM_CPU_COLOR__SIZE 0x00000700 ++ ++ ++#define NV05_INDEXED_IMAGE_FROM_CPU 0x00000064 ++ ++#define NV05_INDEXED_IMAGE_FROM_CPU_COLOR_CONVERSION 0x000003e0 ++ ++ ++#define NV03_CHANNEL_PIO 0x0000006a ++ ++ ++ ++#define NV03_CHANNEL_DMA 0x0000006b ++ ++ ++ ++#define NV04_BETA_SOLID 0x00000072 ++ ++#define NV04_BETA_SOLID_NOP 0x00000100 ++#define NV04_BETA_SOLID_NOTIFY 0x00000104 ++#define NV04_BETA_SOLID_DMA_NOTIFY 0x00000180 ++#define NV04_BETA_SOLID_BETA_OUTPUT 0x00000200 ++#define NV04_BETA_SOLID_BETA_FACTOR 0x00000300 ++ ++ ++#define NV10_TEXTURE_FROM_CPU 0x0000007b ++ ++#define NV10_TEXTURE_FROM_CPU_NOP 0x00000100 ++#define NV10_TEXTURE_FROM_CPU_NOTIFY 0x00000104 ++#define NV10_TEXTURE_FROM_CPU_WAIT_FOR_IDLE 0x00000108 ++#define NV10_TEXTURE_FROM_CPU_PM_TRIGGER 0x00000140 ++#define NV10_TEXTURE_FROM_CPU_DMA_NOTIFY 0x00000180 ++#define NV10_TEXTURE_FROM_CPU_SURFACE 0x00000184 ++#define NV10_TEXTURE_FROM_CPU_COLOR_FORMAT 0x00000300 ++#define NV10_TEXTURE_FROM_CPU_POINT 0x00000304 ++#define NV10_TEXTURE_FROM_CPU_POINT_X_SHIFT 0 ++#define NV10_TEXTURE_FROM_CPU_POINT_X_MASK 0x0000ffff ++#define NV10_TEXTURE_FROM_CPU_POINT_Y_SHIFT 16 ++#define NV10_TEXTURE_FROM_CPU_POINT_Y_MASK 0xffff0000 ++#define NV10_TEXTURE_FROM_CPU_SIZE 0x00000308 ++#define NV10_TEXTURE_FROM_CPU_SIZE_W_SHIFT 0 ++#define NV10_TEXTURE_FROM_CPU_SIZE_W_MASK 0x0000ffff ++#define NV10_TEXTURE_FROM_CPU_SIZE_H_SHIFT 16 ++#define NV10_TEXTURE_FROM_CPU_SIZE_H_MASK 0xffff0000 ++#define NV10_TEXTURE_FROM_CPU_CLIP_HORIZONTAL 0x0000030c ++#define NV10_TEXTURE_FROM_CPU_CLIP_HORIZONTAL_X_SHIFT 0 ++#define NV10_TEXTURE_FROM_CPU_CLIP_HORIZONTAL_X_MASK 0x0000ffff ++#define NV10_TEXTURE_FROM_CPU_CLIP_HORIZONTAL_W_SHIFT 16 ++#define NV10_TEXTURE_FROM_CPU_CLIP_HORIZONTAL_W_MASK 0xffff0000 ++#define NV10_TEXTURE_FROM_CPU_CLIP_VERTICAL 0x00000310 ++#define NV10_TEXTURE_FROM_CPU_CLIP_VERTICAL_Y_SHIFT 0 ++#define NV10_TEXTURE_FROM_CPU_CLIP_VERTICAL_Y_MASK 0x0000ffff ++#define NV10_TEXTURE_FROM_CPU_CLIP_VERTICAL_H_SHIFT 16 ++#define NV10_TEXTURE_FROM_CPU_CLIP_VERTICAL_H_MASK 0xffff0000 ++#define NV10_TEXTURE_FROM_CPU_COLOR(x) (0x00000400+((x)*4)) ++#define NV10_TEXTURE_FROM_CPU_COLOR__SIZE 0x00000700 ++ ++ ++#define NV30_TEXTURE_FROM_CPU 0x0000037b ++ ++ ++ ++#define NV40_TEXTURE_FROM_CPU 0x0000307b ++ ++ ++ ++#define NV10_VIDEO_DISPLAY 0x0000007c ++ ++ ++ ++#define NV20TCL 0x00000097 ++ ++#define NV20TCL_NOP 0x00000100 ++#define NV20TCL_NOTIFY 0x00000104 ++#define NV20TCL_DMA_NOTIFY 0x00000180 ++#define NV20TCL_DMA_TEXTURE0 0x00000184 ++#define NV20TCL_DMA_TEXTURE1 0x00000188 ++#define NV20TCL_DMA_COLOR 0x00000194 ++#define NV20TCL_DMA_ZETA 0x00000198 ++#define NV20TCL_DMA_VTXBUF0 0x0000019c ++#define NV20TCL_DMA_VTXBUF1 0x000001a0 ++#define NV20TCL_DMA_FENCE 0x000001a4 ++#define NV20TCL_DMA_QUERY 0x000001a8 ++#define NV20TCL_RT_HORIZ 0x00000200 ++#define NV20TCL_RT_HORIZ_X_SHIFT 0 ++#define NV20TCL_RT_HORIZ_X_MASK 0x0000ffff ++#define NV20TCL_RT_HORIZ_W_SHIFT 16 ++#define NV20TCL_RT_HORIZ_W_MASK 0xffff0000 ++#define NV20TCL_RT_VERT 0x00000204 ++#define NV20TCL_RT_VERT_Y_SHIFT 0 ++#define NV20TCL_RT_VERT_Y_MASK 0x0000ffff ++#define NV20TCL_RT_VERT_H_SHIFT 16 ++#define NV20TCL_RT_VERT_H_MASK 0xffff0000 ++#define NV20TCL_RT_FORMAT 0x00000208 ++#define NV20TCL_RT_FORMAT_TYPE_SHIFT 8 ++#define NV20TCL_RT_FORMAT_TYPE_MASK 0x00000f00 ++#define NV20TCL_RT_FORMAT_TYPE_LINEAR 0x00000100 ++#define NV20TCL_RT_FORMAT_TYPE_SWIZZLED 0x00000200 ++#define NV20TCL_RT_FORMAT_COLOR_SHIFT 0 ++#define NV20TCL_RT_FORMAT_COLOR_MASK 0x0000001f ++#define NV20TCL_RT_FORMAT_COLOR_R5G6B5 0x00000003 ++#define NV20TCL_RT_FORMAT_COLOR_X8R8G8B8 0x00000005 ++#define NV20TCL_RT_FORMAT_COLOR_A8R8G8B8 0x00000008 ++#define NV20TCL_RT_FORMAT_COLOR_B8 0x00000009 ++#define NV20TCL_RT_FORMAT_COLOR_UNKNOWN 0x0000000d ++#define NV20TCL_RT_FORMAT_COLOR_X8B8G8R8 0x0000000f ++#define NV20TCL_RT_FORMAT_COLOR_A8B8G8R8 0x00000010 ++#define NV20TCL_RT_PITCH 0x0000020c ++#define NV20TCL_RT_PITCH_COLOR_PITCH_SHIFT 0 ++#define NV20TCL_RT_PITCH_COLOR_PITCH_MASK 0x0000ffff ++#define NV20TCL_RT_PITCH_ZETA_PITCH_SHIFT 16 ++#define NV20TCL_RT_PITCH_ZETA_PITCH_MASK 0xffff0000 ++#define NV20TCL_COLOR_OFFSET 0x00000210 ++#define NV20TCL_ZETA_OFFSET 0x00000214 ++#define NV20TCL_RC_IN_ALPHA(x) (0x00000260+((x)*4)) ++#define NV20TCL_RC_IN_ALPHA__SIZE 0x00000008 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_SHIFT 0 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_MASK 0x0000000f ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_FOG 0x00000003 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_TEXTURE0 0x00000008 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_TEXTURE1 0x00000009 ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_SPARE0 0x0000000c ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_SPARE1 0x0000000d ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_E_TIMES_F 0x0000000f ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_TEXTURE2 0x0000000a ++#define NV20TCL_RC_IN_ALPHA_D_INPUT_TEXTURE3 0x0000000b ++#define NV20TCL_RC_IN_ALPHA_D_COMPONENT_USAGE (1 << 4) ++#define NV20TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_SHIFT 5 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_MASK 0x000000e0 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV20TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_SHIFT 8 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_MASK 0x00000f00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_FOG 0x00000300 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_IN_ALPHA_C_INPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_IN_ALPHA_C_COMPONENT_USAGE (1 << 12) ++#define NV20TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_SHIFT 13 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_MASK 0x0000e000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV20TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_SHIFT 16 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_MASK 0x000f0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_FOG 0x00030000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_TEXTURE0 0x00080000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_TEXTURE1 0x00090000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_SPARE0 0x000c0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_SPARE1 0x000d0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_TEXTURE2 0x000a0000 ++#define NV20TCL_RC_IN_ALPHA_B_INPUT_TEXTURE3 0x000b0000 ++#define NV20TCL_RC_IN_ALPHA_B_COMPONENT_USAGE (1 << 20) ++#define NV20TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_SHIFT 21 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_MASK 0x00e00000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV20TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_SHIFT 24 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_MASK 0x0f000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_FOG 0x03000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_TEXTURE0 0x08000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_TEXTURE1 0x09000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_SPARE0 0x0c000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_SPARE1 0x0d000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_TEXTURE2 0x0a000000 ++#define NV20TCL_RC_IN_ALPHA_A_INPUT_TEXTURE3 0x0b000000 ++#define NV20TCL_RC_IN_ALPHA_A_COMPONENT_USAGE (1 << 28) ++#define NV20TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_SHIFT 29 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_MASK 0xe0000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV20TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV20TCL_RC_FINAL0 0x00000288 ++#define NV20TCL_RC_FINAL0_D_INPUT_SHIFT 0 ++#define NV20TCL_RC_FINAL0_D_INPUT_MASK 0x0000000f ++#define NV20TCL_RC_FINAL0_D_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV20TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV20TCL_RC_FINAL0_D_INPUT_FOG 0x00000003 ++#define NV20TCL_RC_FINAL0_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV20TCL_RC_FINAL0_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV20TCL_RC_FINAL0_D_INPUT_TEXTURE0 0x00000008 ++#define NV20TCL_RC_FINAL0_D_INPUT_TEXTURE1 0x00000009 ++#define NV20TCL_RC_FINAL0_D_INPUT_SPARE0 0x0000000c ++#define NV20TCL_RC_FINAL0_D_INPUT_SPARE1 0x0000000d ++#define NV20TCL_RC_FINAL0_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV20TCL_RC_FINAL0_D_INPUT_E_TIMES_F 0x0000000f ++#define NV20TCL_RC_FINAL0_D_INPUT_TEXTURE2 0x0000000a ++#define NV20TCL_RC_FINAL0_D_INPUT_TEXTURE3 0x0000000b ++#define NV20TCL_RC_FINAL0_D_COMPONENT_USAGE (1 << 4) ++#define NV20TCL_RC_FINAL0_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL0_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV20TCL_RC_FINAL0_D_MAPPING_SHIFT 5 ++#define NV20TCL_RC_FINAL0_D_MAPPING_MASK 0x000000e0 ++#define NV20TCL_RC_FINAL0_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL0_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV20TCL_RC_FINAL0_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV20TCL_RC_FINAL0_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV20TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV20TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV20TCL_RC_FINAL0_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV20TCL_RC_FINAL0_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV20TCL_RC_FINAL0_C_INPUT_SHIFT 8 ++#define NV20TCL_RC_FINAL0_C_INPUT_MASK 0x00000f00 ++#define NV20TCL_RC_FINAL0_C_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_FINAL0_C_INPUT_FOG 0x00000300 ++#define NV20TCL_RC_FINAL0_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_FINAL0_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_FINAL0_C_INPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_FINAL0_C_INPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_FINAL0_C_INPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_FINAL0_C_INPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_FINAL0_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_FINAL0_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_FINAL0_C_INPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_FINAL0_C_INPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_FINAL0_C_COMPONENT_USAGE (1 << 12) ++#define NV20TCL_RC_FINAL0_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL0_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_SHIFT 13 ++#define NV20TCL_RC_FINAL0_C_MAPPING_MASK 0x0000e000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV20TCL_RC_FINAL0_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV20TCL_RC_FINAL0_B_INPUT_SHIFT 16 ++#define NV20TCL_RC_FINAL0_B_INPUT_MASK 0x000f0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV20TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV20TCL_RC_FINAL0_B_INPUT_FOG 0x00030000 ++#define NV20TCL_RC_FINAL0_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV20TCL_RC_FINAL0_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV20TCL_RC_FINAL0_B_INPUT_TEXTURE0 0x00080000 ++#define NV20TCL_RC_FINAL0_B_INPUT_TEXTURE1 0x00090000 ++#define NV20TCL_RC_FINAL0_B_INPUT_SPARE0 0x000c0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_SPARE1 0x000d0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_TEXTURE2 0x000a0000 ++#define NV20TCL_RC_FINAL0_B_INPUT_TEXTURE3 0x000b0000 ++#define NV20TCL_RC_FINAL0_B_COMPONENT_USAGE (1 << 20) ++#define NV20TCL_RC_FINAL0_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL0_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_SHIFT 21 ++#define NV20TCL_RC_FINAL0_B_MAPPING_MASK 0x00e00000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV20TCL_RC_FINAL0_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV20TCL_RC_FINAL0_A_INPUT_SHIFT 24 ++#define NV20TCL_RC_FINAL0_A_INPUT_MASK 0x0f000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_FOG 0x03000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_TEXTURE0 0x08000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_TEXTURE1 0x09000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_SPARE0 0x0c000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_SPARE1 0x0d000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_TEXTURE2 0x0a000000 ++#define NV20TCL_RC_FINAL0_A_INPUT_TEXTURE3 0x0b000000 ++#define NV20TCL_RC_FINAL0_A_COMPONENT_USAGE (1 << 28) ++#define NV20TCL_RC_FINAL0_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL0_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_SHIFT 29 ++#define NV20TCL_RC_FINAL0_A_MAPPING_MASK 0xe0000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV20TCL_RC_FINAL0_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV20TCL_RC_FINAL1 0x0000028c ++#define NV20TCL_RC_FINAL1_COLOR_SUM_CLAMP (1 << 7) ++#define NV20TCL_RC_FINAL1_G_INPUT_SHIFT 8 ++#define NV20TCL_RC_FINAL1_G_INPUT_MASK 0x00000f00 ++#define NV20TCL_RC_FINAL1_G_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_FINAL1_G_INPUT_FOG 0x00000300 ++#define NV20TCL_RC_FINAL1_G_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_FINAL1_G_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_FINAL1_G_INPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_FINAL1_G_INPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_FINAL1_G_INPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_FINAL1_G_INPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_FINAL1_G_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_FINAL1_G_INPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_FINAL1_G_INPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_FINAL1_G_INPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_FINAL1_G_COMPONENT_USAGE (1 << 12) ++#define NV20TCL_RC_FINAL1_G_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL1_G_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_SHIFT 13 ++#define NV20TCL_RC_FINAL1_G_MAPPING_MASK 0x0000e000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV20TCL_RC_FINAL1_G_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV20TCL_RC_FINAL1_F_INPUT_SHIFT 16 ++#define NV20TCL_RC_FINAL1_F_INPUT_MASK 0x000f0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV20TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV20TCL_RC_FINAL1_F_INPUT_FOG 0x00030000 ++#define NV20TCL_RC_FINAL1_F_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV20TCL_RC_FINAL1_F_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV20TCL_RC_FINAL1_F_INPUT_TEXTURE0 0x00080000 ++#define NV20TCL_RC_FINAL1_F_INPUT_TEXTURE1 0x00090000 ++#define NV20TCL_RC_FINAL1_F_INPUT_SPARE0 0x000c0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_SPARE1 0x000d0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_E_TIMES_F 0x000f0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_TEXTURE2 0x000a0000 ++#define NV20TCL_RC_FINAL1_F_INPUT_TEXTURE3 0x000b0000 ++#define NV20TCL_RC_FINAL1_F_COMPONENT_USAGE (1 << 20) ++#define NV20TCL_RC_FINAL1_F_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL1_F_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_SHIFT 21 ++#define NV20TCL_RC_FINAL1_F_MAPPING_MASK 0x00e00000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV20TCL_RC_FINAL1_F_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV20TCL_RC_FINAL1_E_INPUT_SHIFT 24 ++#define NV20TCL_RC_FINAL1_E_INPUT_MASK 0x0f000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_FOG 0x03000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_TEXTURE0 0x08000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_TEXTURE1 0x09000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_SPARE0 0x0c000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_SPARE1 0x0d000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_E_TIMES_F 0x0f000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_TEXTURE2 0x0a000000 ++#define NV20TCL_RC_FINAL1_E_INPUT_TEXTURE3 0x0b000000 ++#define NV20TCL_RC_FINAL1_E_COMPONENT_USAGE (1 << 28) ++#define NV20TCL_RC_FINAL1_E_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_FINAL1_E_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_SHIFT 29 ++#define NV20TCL_RC_FINAL1_E_MAPPING_MASK 0xe0000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV20TCL_RC_FINAL1_E_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV20TCL_LIGHT_MODEL 0x00000294 ++#define NV20TCL_LIGHT_MODEL_VIEWER_SHIFT 16 ++#define NV20TCL_LIGHT_MODEL_VIEWER_MASK 0x00030000 ++#define NV20TCL_LIGHT_MODEL_VIEWER_NONLOCAL 0x00020000 ++#define NV20TCL_LIGHT_MODEL_VIEWER_LOCAL 0x00030000 ++#define NV20TCL_LIGHT_MODEL_SEPARATE_SPECULAR (1 << 0) ++#define NV20TCL_COLOR_MATERIAL 0x00000298 ++#define NV20TCL_COLOR_MATERIAL_FRONT_EMISSION_SHIFT 0 ++#define NV20TCL_COLOR_MATERIAL_FRONT_EMISSION_MASK 0x00000003 ++#define NV20TCL_COLOR_MATERIAL_FRONT_EMISSION_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_FRONT_EMISSION_COL1 0x00000001 ++#define NV20TCL_COLOR_MATERIAL_FRONT_EMISSION_COL2 0x00000002 ++#define NV20TCL_COLOR_MATERIAL_FRONT_AMBIENT_SHIFT 2 ++#define NV20TCL_COLOR_MATERIAL_FRONT_AMBIENT_MASK 0x0000000c ++#define NV20TCL_COLOR_MATERIAL_FRONT_AMBIENT_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_FRONT_AMBIENT_COL1 0x00000004 ++#define NV20TCL_COLOR_MATERIAL_FRONT_AMBIENT_COL2 0x00000008 ++#define NV20TCL_COLOR_MATERIAL_FRONT_DIFFUSE_SHIFT 4 ++#define NV20TCL_COLOR_MATERIAL_FRONT_DIFFUSE_MASK 0x00000030 ++#define NV20TCL_COLOR_MATERIAL_FRONT_DIFFUSE_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_FRONT_DIFFUSE_COL1 0x00000010 ++#define NV20TCL_COLOR_MATERIAL_FRONT_DIFFUSE_COL2 0x00000020 ++#define NV20TCL_COLOR_MATERIAL_FRONT_SPECULAR_SHIFT 6 ++#define NV20TCL_COLOR_MATERIAL_FRONT_SPECULAR_MASK 0x000000c0 ++#define NV20TCL_COLOR_MATERIAL_FRONT_SPECULAR_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_FRONT_SPECULAR_COL1 0x00000040 ++#define NV20TCL_COLOR_MATERIAL_FRONT_SPECULAR_COL2 0x00000080 ++#define NV20TCL_COLOR_MATERIAL_BACK_EMISSION_SHIFT 8 ++#define NV20TCL_COLOR_MATERIAL_BACK_EMISSION_MASK 0x00000300 ++#define NV20TCL_COLOR_MATERIAL_BACK_EMISSION_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_BACK_EMISSION_COL1 0x00000100 ++#define NV20TCL_COLOR_MATERIAL_BACK_EMISSION_COL2 0x00000200 ++#define NV20TCL_COLOR_MATERIAL_BACK_AMBIENT_SHIFT 10 ++#define NV20TCL_COLOR_MATERIAL_BACK_AMBIENT_MASK 0x00000c00 ++#define NV20TCL_COLOR_MATERIAL_BACK_AMBIENT_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_BACK_AMBIENT_COL1 0x00000400 ++#define NV20TCL_COLOR_MATERIAL_BACK_AMBIENT_COL2 0x00000800 ++#define NV20TCL_COLOR_MATERIAL_BACK_DIFFUSE_SHIFT 12 ++#define NV20TCL_COLOR_MATERIAL_BACK_DIFFUSE_MASK 0x00003000 ++#define NV20TCL_COLOR_MATERIAL_BACK_DIFFUSE_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_BACK_DIFFUSE_COL1 0x00001000 ++#define NV20TCL_COLOR_MATERIAL_BACK_DIFFUSE_COL2 0x00002000 ++#define NV20TCL_COLOR_MATERIAL_BACK_SPECULAR_SHIFT 14 ++#define NV20TCL_COLOR_MATERIAL_BACK_SPECULAR_MASK 0x0000c000 ++#define NV20TCL_COLOR_MATERIAL_BACK_SPECULAR_OFF 0x00000000 ++#define NV20TCL_COLOR_MATERIAL_BACK_SPECULAR_COL1 0x00004000 ++#define NV20TCL_COLOR_MATERIAL_BACK_SPECULAR_COL2 0x00008000 ++#define NV20TCL_FOG_MODE 0x0000029c ++#define NV20TCL_FOG_MODE_LINEAR_UNSIGNED 0x00000804 ++#define NV20TCL_FOG_MODE_LINEAR_SIGNED 0x00002601 ++#define NV20TCL_FOG_MODE_EXP_UNSIGNED 0x00000802 ++#define NV20TCL_FOG_MODE_EXP_SIGNED 0x00000800 ++#define NV20TCL_FOG_MODE_EXP2_UNSIGNED 0x00000803 ++#define NV20TCL_FOG_MODE_EXP2_SIGNED 0x00000801 ++#define NV20TCL_FOG_COORD 0x000002a0 ++#define NV20TCL_FOG_COORD_DIST_RADIAL 0x00000001 ++#define NV20TCL_FOG_COORD_DIST_ORTHOGONAL 0x00000002 ++#define NV20TCL_FOG_COORD_DIST_ORTHOGONAL_ABS 0x00000003 ++#define NV20TCL_FOG_COORD_FOG 0x00000006 ++#define NV20TCL_FOG_ENABLE 0x000002a4 ++#define NV20TCL_FOG_COLOR 0x000002a8 ++#define NV20TCL_FOG_COLOR_R_SHIFT 0 ++#define NV20TCL_FOG_COLOR_R_MASK 0x000000ff ++#define NV20TCL_FOG_COLOR_G_SHIFT 8 ++#define NV20TCL_FOG_COLOR_G_MASK 0x0000ff00 ++#define NV20TCL_FOG_COLOR_B_SHIFT 16 ++#define NV20TCL_FOG_COLOR_B_MASK 0x00ff0000 ++#define NV20TCL_FOG_COLOR_A_SHIFT 24 ++#define NV20TCL_FOG_COLOR_A_MASK 0xff000000 ++#define NV20TCL_VIEWPORT_CLIP_MODE 0x000002b4 ++#define NV20TCL_VIEWPORT_CLIP_HORIZ(x) (0x000002c0+((x)*4)) ++#define NV20TCL_VIEWPORT_CLIP_HORIZ__SIZE 0x00000008 ++#define NV20TCL_VIEWPORT_CLIP_VERT(x) (0x000002e0+((x)*4)) ++#define NV20TCL_VIEWPORT_CLIP_VERT__SIZE 0x00000008 ++#define NV20TCL_ALPHA_FUNC_ENABLE 0x00000300 ++#define NV20TCL_BLEND_FUNC_ENABLE 0x00000304 ++#define NV20TCL_CULL_FACE_ENABLE 0x00000308 ++#define NV20TCL_DEPTH_TEST_ENABLE 0x0000030c ++#define NV20TCL_DITHER_ENABLE 0x00000310 ++#define NV20TCL_LIGHTING_ENABLE 0x00000314 ++#define NV20TCL_POINT_PARAMETERS_ENABLE 0x00000318 ++#define NV20TCL_POINT_SMOOTH_ENABLE 0x0000031c ++#define NV20TCL_LINE_SMOOTH_ENABLE 0x00000320 ++#define NV20TCL_POLYGON_SMOOTH_ENABLE 0x00000324 ++#define NV20TCL_STENCIL_ENABLE 0x0000032c ++#define NV20TCL_POLYGON_OFFSET_POINT_ENABLE 0x00000330 ++#define NV20TCL_POLYGON_OFFSET_LINE_ENABLE 0x00000334 ++#define NV20TCL_POLYGON_OFFSET_FILL_ENABLE 0x00000338 ++#define NV20TCL_ALPHA_FUNC_FUNC 0x0000033c ++#define NV20TCL_ALPHA_FUNC_FUNC_NEVER 0x00000200 ++#define NV20TCL_ALPHA_FUNC_FUNC_LESS 0x00000201 ++#define NV20TCL_ALPHA_FUNC_FUNC_EQUAL 0x00000202 ++#define NV20TCL_ALPHA_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV20TCL_ALPHA_FUNC_FUNC_GREATER 0x00000204 ++#define NV20TCL_ALPHA_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV20TCL_ALPHA_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV20TCL_ALPHA_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV20TCL_ALPHA_FUNC_REF 0x00000340 ++#define NV20TCL_BLEND_FUNC_SRC 0x00000344 ++#define NV20TCL_BLEND_FUNC_SRC_ZERO 0x00000000 ++#define NV20TCL_BLEND_FUNC_SRC_ONE 0x00000001 ++#define NV20TCL_BLEND_FUNC_SRC_SRC_COLOR 0x00000300 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV20TCL_BLEND_FUNC_SRC_SRC_ALPHA 0x00000302 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV20TCL_BLEND_FUNC_SRC_DST_ALPHA 0x00000304 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV20TCL_BLEND_FUNC_SRC_DST_COLOR 0x00000306 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV20TCL_BLEND_FUNC_SRC_SRC_ALPHA_SATURATE 0x00000308 ++#define NV20TCL_BLEND_FUNC_SRC_CONSTANT_COLOR 0x00008001 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV20TCL_BLEND_FUNC_SRC_CONSTANT_ALPHA 0x00008003 ++#define NV20TCL_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV20TCL_BLEND_FUNC_DST 0x00000348 ++#define NV20TCL_BLEND_FUNC_DST_ZERO 0x00000000 ++#define NV20TCL_BLEND_FUNC_DST_ONE 0x00000001 ++#define NV20TCL_BLEND_FUNC_DST_SRC_COLOR 0x00000300 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV20TCL_BLEND_FUNC_DST_SRC_ALPHA 0x00000302 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV20TCL_BLEND_FUNC_DST_DST_ALPHA 0x00000304 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV20TCL_BLEND_FUNC_DST_DST_COLOR 0x00000306 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV20TCL_BLEND_FUNC_DST_SRC_ALPHA_SATURATE 0x00000308 ++#define NV20TCL_BLEND_FUNC_DST_CONSTANT_COLOR 0x00008001 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV20TCL_BLEND_FUNC_DST_CONSTANT_ALPHA 0x00008003 ++#define NV20TCL_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV20TCL_BLEND_COLOR 0x0000034c ++#define NV20TCL_BLEND_COLOR_B_SHIFT 0 ++#define NV20TCL_BLEND_COLOR_B_MASK 0x000000ff ++#define NV20TCL_BLEND_COLOR_G_SHIFT 8 ++#define NV20TCL_BLEND_COLOR_G_MASK 0x0000ff00 ++#define NV20TCL_BLEND_COLOR_R_SHIFT 16 ++#define NV20TCL_BLEND_COLOR_R_MASK 0x00ff0000 ++#define NV20TCL_BLEND_COLOR_A_SHIFT 24 ++#define NV20TCL_BLEND_COLOR_A_MASK 0xff000000 ++#define NV20TCL_BLEND_EQUATION 0x00000350 ++#define NV20TCL_BLEND_EQUATION_FUNC_ADD 0x00008006 ++#define NV20TCL_BLEND_EQUATION_MIN 0x00008007 ++#define NV20TCL_BLEND_EQUATION_MAX 0x00008008 ++#define NV20TCL_BLEND_EQUATION_FUNC_SUBTRACT 0x0000800a ++#define NV20TCL_BLEND_EQUATION_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV20TCL_DEPTH_FUNC 0x00000354 ++#define NV20TCL_DEPTH_FUNC_NEVER 0x00000200 ++#define NV20TCL_DEPTH_FUNC_LESS 0x00000201 ++#define NV20TCL_DEPTH_FUNC_EQUAL 0x00000202 ++#define NV20TCL_DEPTH_FUNC_LEQUAL 0x00000203 ++#define NV20TCL_DEPTH_FUNC_GREATER 0x00000204 ++#define NV20TCL_DEPTH_FUNC_NOTEQUAL 0x00000205 ++#define NV20TCL_DEPTH_FUNC_GEQUAL 0x00000206 ++#define NV20TCL_DEPTH_FUNC_ALWAYS 0x00000207 ++#define NV20TCL_COLOR_MASK 0x00000358 ++#define NV20TCL_COLOR_MASK_B (1 << 0) ++#define NV20TCL_COLOR_MASK_G (1 << 8) ++#define NV20TCL_COLOR_MASK_R (1 << 16) ++#define NV20TCL_COLOR_MASK_A (1 << 24) ++#define NV20TCL_DEPTH_WRITE_ENABLE 0x0000035c ++#define NV20TCL_STENCIL_MASK 0x00000360 ++#define NV20TCL_STENCIL_FUNC_FUNC 0x00000364 ++#define NV20TCL_STENCIL_FUNC_FUNC_NEVER 0x00000200 ++#define NV20TCL_STENCIL_FUNC_FUNC_LESS 0x00000201 ++#define NV20TCL_STENCIL_FUNC_FUNC_EQUAL 0x00000202 ++#define NV20TCL_STENCIL_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV20TCL_STENCIL_FUNC_FUNC_GREATER 0x00000204 ++#define NV20TCL_STENCIL_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV20TCL_STENCIL_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV20TCL_STENCIL_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV20TCL_STENCIL_FUNC_REF 0x00000368 ++#define NV20TCL_STENCIL_FUNC_MASK 0x0000036c ++#define NV20TCL_STENCIL_OP_FAIL 0x00000370 ++#define NV20TCL_STENCIL_OP_FAIL_ZERO 0x00000000 ++#define NV20TCL_STENCIL_OP_FAIL_INVERT 0x0000150a ++#define NV20TCL_STENCIL_OP_FAIL_KEEP 0x00001e00 ++#define NV20TCL_STENCIL_OP_FAIL_REPLACE 0x00001e01 ++#define NV20TCL_STENCIL_OP_FAIL_INCR 0x00001e02 ++#define NV20TCL_STENCIL_OP_FAIL_DECR 0x00001e03 ++#define NV20TCL_STENCIL_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV20TCL_STENCIL_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV20TCL_STENCIL_OP_ZFAIL 0x00000374 ++#define NV20TCL_STENCIL_OP_ZFAIL_ZERO 0x00000000 ++#define NV20TCL_STENCIL_OP_ZFAIL_INVERT 0x0000150a ++#define NV20TCL_STENCIL_OP_ZFAIL_KEEP 0x00001e00 ++#define NV20TCL_STENCIL_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV20TCL_STENCIL_OP_ZFAIL_INCR 0x00001e02 ++#define NV20TCL_STENCIL_OP_ZFAIL_DECR 0x00001e03 ++#define NV20TCL_STENCIL_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV20TCL_STENCIL_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV20TCL_STENCIL_OP_ZPASS 0x00000378 ++#define NV20TCL_STENCIL_OP_ZPASS_ZERO 0x00000000 ++#define NV20TCL_STENCIL_OP_ZPASS_INVERT 0x0000150a ++#define NV20TCL_STENCIL_OP_ZPASS_KEEP 0x00001e00 ++#define NV20TCL_STENCIL_OP_ZPASS_REPLACE 0x00001e01 ++#define NV20TCL_STENCIL_OP_ZPASS_INCR 0x00001e02 ++#define NV20TCL_STENCIL_OP_ZPASS_DECR 0x00001e03 ++#define NV20TCL_STENCIL_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV20TCL_STENCIL_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV20TCL_SHADE_MODEL 0x0000037c ++#define NV20TCL_SHADE_MODEL_FLAT 0x00001d00 ++#define NV20TCL_SHADE_MODEL_SMOOTH 0x00001d01 ++#define NV20TCL_LINE_WIDTH 0x00000380 ++#define NV20TCL_POLYGON_OFFSET_FACTOR 0x00000384 ++#define NV20TCL_POLYGON_OFFSET_UNITS 0x00000388 ++#define NV20TCL_POLYGON_MODE_FRONT 0x0000038c ++#define NV20TCL_POLYGON_MODE_FRONT_POINT 0x00001b00 ++#define NV20TCL_POLYGON_MODE_FRONT_LINE 0x00001b01 ++#define NV20TCL_POLYGON_MODE_FRONT_FILL 0x00001b02 ++#define NV20TCL_POLYGON_MODE_BACK 0x00000390 ++#define NV20TCL_POLYGON_MODE_BACK_POINT 0x00001b00 ++#define NV20TCL_POLYGON_MODE_BACK_LINE 0x00001b01 ++#define NV20TCL_POLYGON_MODE_BACK_FILL 0x00001b02 ++#define NV20TCL_DEPTH_RANGE_NEAR 0x00000394 ++#define NV20TCL_DEPTH_RANGE_FAR 0x00000398 ++#define NV20TCL_CULL_FACE 0x0000039c ++#define NV20TCL_CULL_FACE_FRONT 0x00000404 ++#define NV20TCL_CULL_FACE_BACK 0x00000405 ++#define NV20TCL_CULL_FACE_FRONT_AND_BACK 0x00000408 ++#define NV20TCL_FRONT_FACE 0x000003a0 ++#define NV20TCL_FRONT_FACE_CW 0x00000900 ++#define NV20TCL_FRONT_FACE_CCW 0x00000901 ++#define NV20TCL_NORMALIZE_ENABLE 0x000003a4 ++#define NV20TCL_MATERIAL_FACTOR_FRONT_R 0x000003a8 ++#define NV20TCL_MATERIAL_FACTOR_FRONT_G 0x000003ac ++#define NV20TCL_MATERIAL_FACTOR_FRONT_B 0x000003b0 ++#define NV20TCL_MATERIAL_FACTOR_FRONT_A 0x000003b4 ++#define NV20TCL_SEPARATE_SPECULAR_ENABLE 0x000003b8 ++#define NV20TCL_ENABLED_LIGHTS 0x000003bc ++#define NV20TCL_ENABLED_LIGHTS_0_SHIFT 0 ++#define NV20TCL_ENABLED_LIGHTS_0_MASK 0x00000003 ++#define NV20TCL_ENABLED_LIGHTS_0_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_0_NONPOSITIONAL 0x00000001 ++#define NV20TCL_ENABLED_LIGHTS_0_POSITIONAL 0x00000002 ++#define NV20TCL_ENABLED_LIGHTS_0_DIRECTIONAL 0x00000003 ++#define NV20TCL_ENABLED_LIGHTS_1_SHIFT 2 ++#define NV20TCL_ENABLED_LIGHTS_1_MASK 0x0000000c ++#define NV20TCL_ENABLED_LIGHTS_1_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_1_NONPOSITIONAL 0x00000004 ++#define NV20TCL_ENABLED_LIGHTS_1_POSITIONAL 0x00000008 ++#define NV20TCL_ENABLED_LIGHTS_1_DIRECTIONAL 0x0000000c ++#define NV20TCL_ENABLED_LIGHTS_2_SHIFT 4 ++#define NV20TCL_ENABLED_LIGHTS_2_MASK 0x00000030 ++#define NV20TCL_ENABLED_LIGHTS_2_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_2_NONPOSITIONAL 0x00000010 ++#define NV20TCL_ENABLED_LIGHTS_2_POSITIONAL 0x00000020 ++#define NV20TCL_ENABLED_LIGHTS_2_DIRECTIONAL 0x00000030 ++#define NV20TCL_ENABLED_LIGHTS_3_SHIFT 6 ++#define NV20TCL_ENABLED_LIGHTS_3_MASK 0x000000c0 ++#define NV20TCL_ENABLED_LIGHTS_3_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_3_NONPOSITIONAL 0x00000040 ++#define NV20TCL_ENABLED_LIGHTS_3_POSITIONAL 0x00000080 ++#define NV20TCL_ENABLED_LIGHTS_3_DIRECTIONAL 0x000000c0 ++#define NV20TCL_ENABLED_LIGHTS_4_SHIFT 8 ++#define NV20TCL_ENABLED_LIGHTS_4_MASK 0x00000300 ++#define NV20TCL_ENABLED_LIGHTS_4_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_4_NONPOSITIONAL 0x00000100 ++#define NV20TCL_ENABLED_LIGHTS_4_POSITIONAL 0x00000200 ++#define NV20TCL_ENABLED_LIGHTS_4_DIRECTIONAL 0x00000300 ++#define NV20TCL_ENABLED_LIGHTS_5_SHIFT 10 ++#define NV20TCL_ENABLED_LIGHTS_5_MASK 0x00000c00 ++#define NV20TCL_ENABLED_LIGHTS_5_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_5_NONPOSITIONAL 0x00000400 ++#define NV20TCL_ENABLED_LIGHTS_5_POSITIONAL 0x00000800 ++#define NV20TCL_ENABLED_LIGHTS_5_DIRECTIONAL 0x00000c00 ++#define NV20TCL_ENABLED_LIGHTS_6_SHIFT 12 ++#define NV20TCL_ENABLED_LIGHTS_6_MASK 0x00003000 ++#define NV20TCL_ENABLED_LIGHTS_6_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_6_NONPOSITIONAL 0x00001000 ++#define NV20TCL_ENABLED_LIGHTS_6_POSITIONAL 0x00002000 ++#define NV20TCL_ENABLED_LIGHTS_6_DIRECTIONAL 0x00003000 ++#define NV20TCL_ENABLED_LIGHTS_7_SHIFT 14 ++#define NV20TCL_ENABLED_LIGHTS_7_MASK 0x0000c000 ++#define NV20TCL_ENABLED_LIGHTS_7_DISABLED 0x00000000 ++#define NV20TCL_ENABLED_LIGHTS_7_NONPOSITIONAL 0x00004000 ++#define NV20TCL_ENABLED_LIGHTS_7_POSITIONAL 0x00008000 ++#define NV20TCL_ENABLED_LIGHTS_7_DIRECTIONAL 0x0000c000 ++#define NV20TCL_TX_GEN_MODE_S(x) (0x000003c0+((x)*16)) ++#define NV20TCL_TX_GEN_MODE_S__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_MODE_S_FALSE 0x00000000 ++#define NV20TCL_TX_GEN_MODE_S_EYE_LINEAR 0x00002400 ++#define NV20TCL_TX_GEN_MODE_S_OBJECT_LINEAR 0x00002401 ++#define NV20TCL_TX_GEN_MODE_S_SPHERE_MAP 0x00002402 ++#define NV20TCL_TX_GEN_MODE_S_NORMAL_MAP 0x00008511 ++#define NV20TCL_TX_GEN_MODE_S_REFLECTION_MAP 0x00008512 ++#define NV20TCL_TX_GEN_MODE_T(x) (0x000003c4+((x)*16)) ++#define NV20TCL_TX_GEN_MODE_T__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_MODE_T_FALSE 0x00000000 ++#define NV20TCL_TX_GEN_MODE_T_EYE_LINEAR 0x00002400 ++#define NV20TCL_TX_GEN_MODE_T_OBJECT_LINEAR 0x00002401 ++#define NV20TCL_TX_GEN_MODE_T_SPHERE_MAP 0x00002402 ++#define NV20TCL_TX_GEN_MODE_T_NORMAL_MAP 0x00008511 ++#define NV20TCL_TX_GEN_MODE_T_REFLECTION_MAP 0x00008512 ++#define NV20TCL_TX_GEN_MODE_R(x) (0x000003c8+((x)*16)) ++#define NV20TCL_TX_GEN_MODE_R__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_MODE_R_FALSE 0x00000000 ++#define NV20TCL_TX_GEN_MODE_R_EYE_LINEAR 0x00002400 ++#define NV20TCL_TX_GEN_MODE_R_OBJECT_LINEAR 0x00002401 ++#define NV20TCL_TX_GEN_MODE_R_SPHERE_MAP 0x00002402 ++#define NV20TCL_TX_GEN_MODE_R_NORMAL_MAP 0x00008511 ++#define NV20TCL_TX_GEN_MODE_R_REFLECTION_MAP 0x00008512 ++#define NV20TCL_TX_GEN_MODE_Q(x) (0x000003cc+((x)*16)) ++#define NV20TCL_TX_GEN_MODE_Q__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_MODE_Q_FALSE 0x00000000 ++#define NV20TCL_TX_GEN_MODE_Q_EYE_LINEAR 0x00002400 ++#define NV20TCL_TX_GEN_MODE_Q_OBJECT_LINEAR 0x00002401 ++#define NV20TCL_TX_GEN_MODE_Q_SPHERE_MAP 0x00002402 ++#define NV20TCL_TX_GEN_MODE_Q_NORMAL_MAP 0x00008511 ++#define NV20TCL_TX_GEN_MODE_Q_REFLECTION_MAP 0x00008512 ++#define NV20TCL_TX_MATRIX_ENABLE(x) (0x00000420+((x)*4)) ++#define NV20TCL_TX_MATRIX_ENABLE__SIZE 0x00000004 ++#define NV20TCL_POINT_SIZE 0x0000043c ++#define NV20TCL_MODELVIEW0_MATRIX(x) (0x00000480+((x)*4)) ++#define NV20TCL_MODELVIEW0_MATRIX__SIZE 0x00000010 ++#define NV20TCL_MODELVIEW1_MATRIX(x) (0x000004c0+((x)*4)) ++#define NV20TCL_MODELVIEW1_MATRIX__SIZE 0x00000010 ++#define NV20TCL_MODELVIEW2_MATRIX(x) (0x00000500+((x)*4)) ++#define NV20TCL_MODELVIEW2_MATRIX__SIZE 0x00000010 ++#define NV20TCL_MODELVIEW3_MATRIX(x) (0x00000540+((x)*4)) ++#define NV20TCL_MODELVIEW3_MATRIX__SIZE 0x00000010 ++#define NV20TCL_INVERSE_MODELVIEW0_MATRIX(x) (0x00000580+((x)*4)) ++#define NV20TCL_INVERSE_MODELVIEW0_MATRIX__SIZE 0x00000010 ++#define NV20TCL_INVERSE_MODELVIEW1_MATRIX(x) (0x000005c0+((x)*4)) ++#define NV20TCL_INVERSE_MODELVIEW1_MATRIX__SIZE 0x00000010 ++#define NV20TCL_INVERSE_MODELVIEW2_MATRIX(x) (0x00000600+((x)*4)) ++#define NV20TCL_INVERSE_MODELVIEW2_MATRIX__SIZE 0x00000010 ++#define NV20TCL_INVERSE_MODELVIEW3_MATRIX(x) (0x00000640+((x)*4)) ++#define NV20TCL_INVERSE_MODELVIEW3_MATRIX__SIZE 0x00000010 ++#define NV20TCL_PROJECTION_MATRIX(x) (0x00000680+((x)*4)) ++#define NV20TCL_PROJECTION_MATRIX__SIZE 0x00000010 ++#define NV20TCL_TX0_MATRIX(x) (0x000006c0+((x)*4)) ++#define NV20TCL_TX0_MATRIX__SIZE 0x00000010 ++#define NV20TCL_TX1_MATRIX(x) (0x00000700+((x)*4)) ++#define NV20TCL_TX1_MATRIX__SIZE 0x00000010 ++#define NV20TCL_TX2_MATRIX(x) (0x00000740+((x)*4)) ++#define NV20TCL_TX2_MATRIX__SIZE 0x00000010 ++#define NV20TCL_TX3_MATRIX(x) (0x00000780+((x)*4)) ++#define NV20TCL_TX3_MATRIX__SIZE 0x00000010 ++#define NV20TCL_TX_GEN_COEFF_S_A(x) (0x00000840+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_S_A__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_S_B(x) (0x00000844+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_S_B__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_S_C(x) (0x00000848+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_S_C__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_S_D(x) (0x0000084c+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_S_D__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_T_A(x) (0x00000850+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_T_A__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_T_B(x) (0x00000854+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_T_B__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_T_C(x) (0x00000858+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_T_C__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_T_D(x) (0x0000085c+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_T_D__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_R_A(x) (0x00000860+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_R_A__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_R_B(x) (0x00000864+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_R_B__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_R_C(x) (0x00000868+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_R_C__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_R_D(x) (0x0000086c+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_R_D__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_Q_A(x) (0x00000870+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_Q_A__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_Q_B(x) (0x00000874+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_Q_B__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_Q_C(x) (0x00000878+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_Q_C__SIZE 0x00000004 ++#define NV20TCL_TX_GEN_COEFF_Q_D(x) (0x0000087c+((x)*64)) ++#define NV20TCL_TX_GEN_COEFF_Q_D__SIZE 0x00000004 ++#define NV20TCL_FOG_EQUATION_CONSTANT 0x000009c0 ++#define NV20TCL_FOG_EQUATION_LINEAR 0x000009c4 ++#define NV20TCL_FOG_EQUATION_QUADRATIC 0x000009c8 ++#define NV20TCL_FRONT_MATERIAL_SHININESS(x) (0x000009e0+((x)*4)) ++#define NV20TCL_FRONT_MATERIAL_SHININESS__SIZE 0x00000006 ++#define NV20TCL_LIGHT_MODEL_FRONT_AMBIENT_R 0x00000a10 ++#define NV20TCL_LIGHT_MODEL_FRONT_AMBIENT_G 0x00000a14 ++#define NV20TCL_LIGHT_MODEL_FRONT_AMBIENT_B 0x00000a18 ++#define NV20TCL_VIEWPORT_TRANSLATE_X 0x00000a20 ++#define NV20TCL_VIEWPORT_TRANSLATE_Y 0x00000a24 ++#define NV20TCL_VIEWPORT_TRANSLATE_Z 0x00000a28 ++#define NV20TCL_VIEWPORT_TRANSLATE_W 0x00000a2c ++#define NV20TCL_POINT_PARAMETER(x) (0x00000a30+((x)*4)) ++#define NV20TCL_POINT_PARAMETER__SIZE 0x00000008 ++#define NV20TCL_RC_CONSTANT_COLOR0(x) (0x00000a60+((x)*4)) ++#define NV20TCL_RC_CONSTANT_COLOR0__SIZE 0x00000008 ++#define NV20TCL_RC_CONSTANT_COLOR0_B_SHIFT 0 ++#define NV20TCL_RC_CONSTANT_COLOR0_B_MASK 0x000000ff ++#define NV20TCL_RC_CONSTANT_COLOR0_G_SHIFT 8 ++#define NV20TCL_RC_CONSTANT_COLOR0_G_MASK 0x0000ff00 ++#define NV20TCL_RC_CONSTANT_COLOR0_R_SHIFT 16 ++#define NV20TCL_RC_CONSTANT_COLOR0_R_MASK 0x00ff0000 ++#define NV20TCL_RC_CONSTANT_COLOR0_A_SHIFT 24 ++#define NV20TCL_RC_CONSTANT_COLOR0_A_MASK 0xff000000 ++#define NV20TCL_RC_CONSTANT_COLOR1(x) (0x00000a80+((x)*4)) ++#define NV20TCL_RC_CONSTANT_COLOR1__SIZE 0x00000008 ++#define NV20TCL_RC_CONSTANT_COLOR1_B_SHIFT 0 ++#define NV20TCL_RC_CONSTANT_COLOR1_B_MASK 0x000000ff ++#define NV20TCL_RC_CONSTANT_COLOR1_G_SHIFT 8 ++#define NV20TCL_RC_CONSTANT_COLOR1_G_MASK 0x0000ff00 ++#define NV20TCL_RC_CONSTANT_COLOR1_R_SHIFT 16 ++#define NV20TCL_RC_CONSTANT_COLOR1_R_MASK 0x00ff0000 ++#define NV20TCL_RC_CONSTANT_COLOR1_A_SHIFT 24 ++#define NV20TCL_RC_CONSTANT_COLOR1_A_MASK 0xff000000 ++#define NV20TCL_RC_OUT_ALPHA(x) (0x00000aa0+((x)*4)) ++#define NV20TCL_RC_OUT_ALPHA__SIZE 0x00000008 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_SHIFT 0 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_MASK 0x0000000f ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_FOG 0x00000003 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0 0x0000000c ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE1 0x0000000d ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV20TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_SHIFT 4 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_MASK 0x000000f0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_FOG 0x00000030 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV20TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_SHIFT 8 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_MASK 0x00000f00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_FOG 0x00000300 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_OUT_ALPHA_CD_DOT_PRODUCT (1 << 12) ++#define NV20TCL_RC_OUT_ALPHA_AB_DOT_PRODUCT (1 << 13) ++#define NV20TCL_RC_OUT_ALPHA_MUX_SUM (1 << 14) ++#define NV20TCL_RC_OUT_ALPHA_BIAS (1 << 15) ++#define NV20TCL_RC_OUT_ALPHA_BIAS_NONE 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_SHIFT 17 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_MASK 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_NONE 0x00000000 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV20TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV20TCL_RC_IN_RGB(x) (0x00000ac0+((x)*4)) ++#define NV20TCL_RC_IN_RGB__SIZE 0x00000008 ++#define NV20TCL_RC_IN_RGB_D_INPUT_SHIFT 0 ++#define NV20TCL_RC_IN_RGB_D_INPUT_MASK 0x0000000f ++#define NV20TCL_RC_IN_RGB_D_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV20TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV20TCL_RC_IN_RGB_D_INPUT_FOG 0x00000003 ++#define NV20TCL_RC_IN_RGB_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV20TCL_RC_IN_RGB_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV20TCL_RC_IN_RGB_D_INPUT_TEXTURE0 0x00000008 ++#define NV20TCL_RC_IN_RGB_D_INPUT_TEXTURE1 0x00000009 ++#define NV20TCL_RC_IN_RGB_D_INPUT_SPARE0 0x0000000c ++#define NV20TCL_RC_IN_RGB_D_INPUT_SPARE1 0x0000000d ++#define NV20TCL_RC_IN_RGB_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV20TCL_RC_IN_RGB_D_INPUT_E_TIMES_F 0x0000000f ++#define NV20TCL_RC_IN_RGB_D_INPUT_TEXTURE2 0x0000000a ++#define NV20TCL_RC_IN_RGB_D_INPUT_TEXTURE3 0x0000000b ++#define NV20TCL_RC_IN_RGB_D_COMPONENT_USAGE (1 << 4) ++#define NV20TCL_RC_IN_RGB_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_IN_RGB_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_SHIFT 5 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_MASK 0x000000e0 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV20TCL_RC_IN_RGB_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV20TCL_RC_IN_RGB_C_INPUT_SHIFT 8 ++#define NV20TCL_RC_IN_RGB_C_INPUT_MASK 0x00000f00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_IN_RGB_C_INPUT_FOG 0x00000300 ++#define NV20TCL_RC_IN_RGB_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_IN_RGB_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_IN_RGB_C_INPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_IN_RGB_C_INPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_IN_RGB_C_INPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_IN_RGB_C_INPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_IN_RGB_C_COMPONENT_USAGE (1 << 12) ++#define NV20TCL_RC_IN_RGB_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_IN_RGB_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_SHIFT 13 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_MASK 0x0000e000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV20TCL_RC_IN_RGB_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_SHIFT 16 ++#define NV20TCL_RC_IN_RGB_B_INPUT_MASK 0x000f0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_FOG 0x00030000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_TEXTURE0 0x00080000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_TEXTURE1 0x00090000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_SPARE0 0x000c0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_SPARE1 0x000d0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_TEXTURE2 0x000a0000 ++#define NV20TCL_RC_IN_RGB_B_INPUT_TEXTURE3 0x000b0000 ++#define NV20TCL_RC_IN_RGB_B_COMPONENT_USAGE (1 << 20) ++#define NV20TCL_RC_IN_RGB_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_IN_RGB_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_SHIFT 21 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_MASK 0x00e00000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV20TCL_RC_IN_RGB_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_SHIFT 24 ++#define NV20TCL_RC_IN_RGB_A_INPUT_MASK 0x0f000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_ZERO 0x00000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_FOG 0x03000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_TEXTURE0 0x08000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_TEXTURE1 0x09000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_SPARE0 0x0c000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_SPARE1 0x0d000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_TEXTURE2 0x0a000000 ++#define NV20TCL_RC_IN_RGB_A_INPUT_TEXTURE3 0x0b000000 ++#define NV20TCL_RC_IN_RGB_A_COMPONENT_USAGE (1 << 28) ++#define NV20TCL_RC_IN_RGB_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV20TCL_RC_IN_RGB_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_SHIFT 29 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_MASK 0xe0000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV20TCL_RC_IN_RGB_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV20TCL_VIEWPORT_SCALE_X 0x00000af0 ++#define NV20TCL_VIEWPORT_SCALE_Y 0x00000af4 ++#define NV20TCL_VIEWPORT_SCALE_Z 0x00000af8 ++#define NV20TCL_VIEWPORT_SCALE_W 0x00000afc ++#define NV20TCL_VP_UPLOAD_INST(x) (0x00000b00+((x)*4)) ++#define NV20TCL_VP_UPLOAD_INST__SIZE 0x00000004 ++#define NV20TCL_VP_UPLOAD_CONST(x) (0x00000b80+((x)*4)) ++#define NV20TCL_VP_UPLOAD_CONST__SIZE 0x00000004 ++#define NV20TCL_LIGHT_BACK_AMBIENT_R(x) (0x00000c00+((x)*64)) ++#define NV20TCL_LIGHT_BACK_AMBIENT_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_AMBIENT_G(x) (0x00000c04+((x)*64)) ++#define NV20TCL_LIGHT_BACK_AMBIENT_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_AMBIENT_B(x) (0x00000c08+((x)*64)) ++#define NV20TCL_LIGHT_BACK_AMBIENT_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_DIFFUSE_R(x) (0x00000c0c+((x)*64)) ++#define NV20TCL_LIGHT_BACK_DIFFUSE_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_DIFFUSE_G(x) (0x00000c10+((x)*64)) ++#define NV20TCL_LIGHT_BACK_DIFFUSE_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_DIFFUSE_B(x) (0x00000c14+((x)*64)) ++#define NV20TCL_LIGHT_BACK_DIFFUSE_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_SPECULAR_R(x) (0x00000c18+((x)*64)) ++#define NV20TCL_LIGHT_BACK_SPECULAR_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_SPECULAR_G(x) (0x00000c1c+((x)*64)) ++#define NV20TCL_LIGHT_BACK_SPECULAR_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_BACK_SPECULAR_B(x) (0x00000c20+((x)*64)) ++#define NV20TCL_LIGHT_BACK_SPECULAR_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_AMBIENT_R(x) (0x00001000+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_AMBIENT_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_AMBIENT_G(x) (0x00001004+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_AMBIENT_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_AMBIENT_B(x) (0x00001008+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_AMBIENT_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_R(x) (0x0000100c+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_G(x) (0x00001010+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_B(x) (0x00001014+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_DIFFUSE_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_SPECULAR_R(x) (0x00001018+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_SPECULAR_R__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_SPECULAR_G(x) (0x0000101c+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_SPECULAR_G__SIZE 0x00000008 ++#define NV20TCL_LIGHT_FRONT_SPECULAR_B(x) (0x00001020+((x)*128)) ++#define NV20TCL_LIGHT_FRONT_SPECULAR_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_HALF_VECTOR_X(x) (0x00001028+((x)*128)) ++#define NV20TCL_LIGHT_HALF_VECTOR_X__SIZE 0x00000008 ++#define NV20TCL_LIGHT_HALF_VECTOR_Y(x) (0x0000102c+((x)*128)) ++#define NV20TCL_LIGHT_HALF_VECTOR_Y__SIZE 0x00000008 ++#define NV20TCL_LIGHT_HALF_VECTOR_Z(x) (0x00001030+((x)*128)) ++#define NV20TCL_LIGHT_HALF_VECTOR_Z__SIZE 0x00000008 ++#define NV20TCL_LIGHT_DIRECTION_X(x) (0x00001034+((x)*128)) ++#define NV20TCL_LIGHT_DIRECTION_X__SIZE 0x00000008 ++#define NV20TCL_LIGHT_DIRECTION_Y(x) (0x00001038+((x)*128)) ++#define NV20TCL_LIGHT_DIRECTION_Y__SIZE 0x00000008 ++#define NV20TCL_LIGHT_DIRECTION_Z(x) (0x0000103c+((x)*128)) ++#define NV20TCL_LIGHT_DIRECTION_Z__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_CUTOFF_A(x) (0x00001040+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_CUTOFF_A__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_CUTOFF_B(x) (0x00001044+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_CUTOFF_B__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_CUTOFF_C(x) (0x00001048+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_CUTOFF_C__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_DIR_X(x) (0x0000104c+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_DIR_X__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_DIR_Y(x) (0x00001050+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_DIR_Y__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_DIR_Z(x) (0x00001054+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_DIR_Z__SIZE 0x00000008 ++#define NV20TCL_LIGHT_SPOT_CUTOFF_D(x) (0x00001058+((x)*128)) ++#define NV20TCL_LIGHT_SPOT_CUTOFF_D__SIZE 0x00000008 ++#define NV20TCL_LIGHT_POSITION_X(x) (0x0000105c+((x)*128)) ++#define NV20TCL_LIGHT_POSITION_X__SIZE 0x00000008 ++#define NV20TCL_LIGHT_POSITION_Y(x) (0x00001060+((x)*128)) ++#define NV20TCL_LIGHT_POSITION_Y__SIZE 0x00000008 ++#define NV20TCL_LIGHT_POSITION_Z(x) (0x00001064+((x)*128)) ++#define NV20TCL_LIGHT_POSITION_Z__SIZE 0x00000008 ++#define NV20TCL_LIGHT_ATTENUATION_CONSTANT(x) (0x00001068+((x)*128)) ++#define NV20TCL_LIGHT_ATTENUATION_CONSTANT__SIZE 0x00000008 ++#define NV20TCL_LIGHT_ATTENUATION_LINEAR(x) (0x0000106c+((x)*128)) ++#define NV20TCL_LIGHT_ATTENUATION_LINEAR__SIZE 0x00000008 ++#define NV20TCL_LIGHT_ATTENUATION_QUADRATIC(x) (0x00001070+((x)*128)) ++#define NV20TCL_LIGHT_ATTENUATION_QUADRATIC__SIZE 0x00000008 ++#define NV20TCL_POLYGON_STIPPLE_ENABLE 0x0000147c ++#define NV20TCL_POLYGON_STIPPLE_PATTERN(x) (0x00001480+((x)*4)) ++#define NV20TCL_POLYGON_STIPPLE_PATTERN__SIZE 0x00000020 ++#define NV20TCL_VERTEX_POS_3F_X 0x00001500 ++#define NV20TCL_VERTEX_POS_3F_Y 0x00001504 ++#define NV20TCL_VERTEX_POS_3F_Z 0x00001508 ++#define NV20TCL_VERTEX_POS_4F_X 0x00001518 ++#define NV20TCL_VERTEX_POS_4F_Y 0x0000151c ++#define NV20TCL_VERTEX_POS_4F_Z 0x00001520 ++#define NV20TCL_VERTEX_POS_3I_XY 0x00001528 ++#define NV20TCL_VERTEX_POS_3I_XY_X_SHIFT 0 ++#define NV20TCL_VERTEX_POS_3I_XY_X_MASK 0x0000ffff ++#define NV20TCL_VERTEX_POS_3I_XY_Y_SHIFT 16 ++#define NV20TCL_VERTEX_POS_3I_XY_Y_MASK 0xffff0000 ++#define NV20TCL_VERTEX_POS_3I_Z 0x0000152c ++#define NV20TCL_VERTEX_POS_3I_Z_Z_SHIFT 0 ++#define NV20TCL_VERTEX_POS_3I_Z_Z_MASK 0x0000ffff ++#define NV20TCL_VERTEX_NOR_3F_X 0x00001530 ++#define NV20TCL_VERTEX_NOR_3F_Y 0x00001534 ++#define NV20TCL_VERTEX_NOR_3F_Z 0x00001538 ++#define NV20TCL_VERTEX_NOR_3I_XY 0x00001540 ++#define NV20TCL_VERTEX_NOR_3I_XY_X_SHIFT 0 ++#define NV20TCL_VERTEX_NOR_3I_XY_X_MASK 0x0000ffff ++#define NV20TCL_VERTEX_NOR_3I_XY_Y_SHIFT 16 ++#define NV20TCL_VERTEX_NOR_3I_XY_Y_MASK 0xffff0000 ++#define NV20TCL_VERTEX_NOR_3I_Z 0x00001544 ++#define NV20TCL_VERTEX_NOR_3I_Z_Z_SHIFT 0 ++#define NV20TCL_VERTEX_NOR_3I_Z_Z_MASK 0x0000ffff ++#define NV20TCL_VERTEX_COL_4F_X 0x00001550 ++#define NV20TCL_VERTEX_COL_4F_Y 0x00001554 ++#define NV20TCL_VERTEX_COL_4F_Z 0x00001558 ++#define NV20TCL_VERTEX_COL_4F_W 0x0000155c ++#define NV20TCL_VERTEX_COL_3F_X 0x00001560 ++#define NV20TCL_VERTEX_COL_3F_Y 0x00001564 ++#define NV20TCL_VERTEX_COL_3F_Z 0x00001568 ++#define NV20TCL_VERTEX_COL_4I 0x0000156c ++#define NV20TCL_VERTEX_COL_4I_R_SHIFT 0 ++#define NV20TCL_VERTEX_COL_4I_R_MASK 0x000000ff ++#define NV20TCL_VERTEX_COL_4I_G_SHIFT 8 ++#define NV20TCL_VERTEX_COL_4I_G_MASK 0x0000ff00 ++#define NV20TCL_VERTEX_COL_4I_B_SHIFT 16 ++#define NV20TCL_VERTEX_COL_4I_B_MASK 0x00ff0000 ++#define NV20TCL_VERTEX_COL_4I_A_SHIFT 24 ++#define NV20TCL_VERTEX_COL_4I_A_MASK 0xff000000 ++#define NV20TCL_VERTEX_COL2_3F_X 0x00001580 ++#define NV20TCL_VERTEX_COL2_3F_Y 0x00001584 ++#define NV20TCL_VERTEX_COL2_3F_Z 0x00001588 ++#define NV20TCL_VERTEX_COL2_4I 0x0000158c ++#define NV20TCL_VERTEX_COL2_4I_R_SHIFT 0 ++#define NV20TCL_VERTEX_COL2_4I_R_MASK 0x000000ff ++#define NV20TCL_VERTEX_COL2_4I_G_SHIFT 8 ++#define NV20TCL_VERTEX_COL2_4I_G_MASK 0x0000ff00 ++#define NV20TCL_VERTEX_COL2_4I_B_SHIFT 16 ++#define NV20TCL_VERTEX_COL2_4I_B_MASK 0x00ff0000 ++#define NV20TCL_VERTEX_COL2_4I_A_SHIFT 24 ++#define NV20TCL_VERTEX_COL2_4I_A_MASK 0xff000000 ++#define NV20TCL_VERTEX_TX0_2F_S 0x00001590 ++#define NV20TCL_VERTEX_TX0_2F_T 0x00001594 ++#define NV20TCL_VERTEX_TX0_2I 0x00001598 ++#define NV20TCL_VERTEX_TX0_2I_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX0_2I_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX0_2I_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX0_2I_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX0_4F_S 0x000015a0 ++#define NV20TCL_VERTEX_TX0_4F_T 0x000015a4 ++#define NV20TCL_VERTEX_TX0_4F_R 0x000015a8 ++#define NV20TCL_VERTEX_TX0_4F_Q 0x000015ac ++#define NV20TCL_VERTEX_TX0_4I_ST 0x000015b0 ++#define NV20TCL_VERTEX_TX0_4I_ST_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX0_4I_ST_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX0_4I_ST_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX0_4I_ST_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX0_4I_RQ 0x000015b4 ++#define NV20TCL_VERTEX_TX0_4I_RQ_R_SHIFT 0 ++#define NV20TCL_VERTEX_TX0_4I_RQ_R_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX0_4I_RQ_Q_SHIFT 16 ++#define NV20TCL_VERTEX_TX0_4I_RQ_Q_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX1_2F_S 0x000015b8 ++#define NV20TCL_VERTEX_TX1_2F_T 0x000015bc ++#define NV20TCL_VERTEX_TX1_2I 0x000015c0 ++#define NV20TCL_VERTEX_TX1_2I_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX1_2I_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX1_2I_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX1_2I_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX1_4F_S 0x000015c8 ++#define NV20TCL_VERTEX_TX1_4F_T 0x000015cc ++#define NV20TCL_VERTEX_TX1_4F_R 0x000015d0 ++#define NV20TCL_VERTEX_TX1_4F_Q 0x000015d4 ++#define NV20TCL_VERTEX_TX1_4I_ST 0x000015d8 ++#define NV20TCL_VERTEX_TX1_4I_ST_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX1_4I_ST_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX1_4I_ST_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX1_4I_ST_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX1_4I_RQ 0x000015dc ++#define NV20TCL_VERTEX_TX1_4I_RQ_R_SHIFT 0 ++#define NV20TCL_VERTEX_TX1_4I_RQ_R_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX1_4I_RQ_Q_SHIFT 16 ++#define NV20TCL_VERTEX_TX1_4I_RQ_Q_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX2_2F_S 0x000015e0 ++#define NV20TCL_VERTEX_TX2_2F_T 0x000015e4 ++#define NV20TCL_VERTEX_TX2_2I 0x000015e8 ++#define NV20TCL_VERTEX_TX2_2I_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX2_2I_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX2_2I_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX2_2I_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX2_4F_S 0x000015f0 ++#define NV20TCL_VERTEX_TX2_4F_T 0x000015f4 ++#define NV20TCL_VERTEX_TX2_4F_R 0x000015f8 ++#define NV20TCL_VERTEX_TX2_4F_Q 0x000015fc ++#define NV20TCL_VERTEX_TX2_4I_ST 0x00001600 ++#define NV20TCL_VERTEX_TX2_4I_ST_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX2_4I_ST_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX2_4I_ST_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX2_4I_ST_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX2_4I_RQ 0x00001604 ++#define NV20TCL_VERTEX_TX2_4I_RQ_R_SHIFT 0 ++#define NV20TCL_VERTEX_TX2_4I_RQ_R_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX2_4I_RQ_Q_SHIFT 16 ++#define NV20TCL_VERTEX_TX2_4I_RQ_Q_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX3_2F_S 0x00001608 ++#define NV20TCL_VERTEX_TX3_2F_T 0x0000160c ++#define NV20TCL_VERTEX_TX3_2I 0x00001610 ++#define NV20TCL_VERTEX_TX3_2I_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX3_2I_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX3_2I_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX3_2I_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX3_4F_S 0x00001620 ++#define NV20TCL_VERTEX_TX3_4F_T 0x00001624 ++#define NV20TCL_VERTEX_TX3_4F_R 0x00001628 ++#define NV20TCL_VERTEX_TX3_4F_Q 0x0000162c ++#define NV20TCL_VERTEX_TX3_4I_ST 0x00001630 ++#define NV20TCL_VERTEX_TX3_4I_ST_S_SHIFT 0 ++#define NV20TCL_VERTEX_TX3_4I_ST_S_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX3_4I_ST_T_SHIFT 16 ++#define NV20TCL_VERTEX_TX3_4I_ST_T_MASK 0xffff0000 ++#define NV20TCL_VERTEX_TX3_4I_RQ 0x00001634 ++#define NV20TCL_VERTEX_TX3_4I_RQ_R_SHIFT 0 ++#define NV20TCL_VERTEX_TX3_4I_RQ_R_MASK 0x0000ffff ++#define NV20TCL_VERTEX_TX3_4I_RQ_Q_SHIFT 16 ++#define NV20TCL_VERTEX_TX3_4I_RQ_Q_MASK 0xffff0000 ++#define NV20TCL_VERTEX_FOG_1F 0x00001698 ++#define NV20TCL_EDGEFLAG_ENABLE 0x000016bc ++#define NV20TCL_VTX_CACHE_INVALIDATE 0x00001710 ++#define NV20TCL_VTXBUF_ADDRESS(x) (0x00001720+((x)*4)) ++#define NV20TCL_VTXBUF_ADDRESS__SIZE 0x00000010 ++#define NV20TCL_VTXBUF_ADDRESS_DMA1 (1 << 31) ++#define NV20TCL_VTXBUF_ADDRESS_OFFSET_SHIFT 0 ++#define NV20TCL_VTXBUF_ADDRESS_OFFSET_MASK 0x0fffffff ++#define NV20TCL_VTXFMT(x) (0x00001760+((x)*4)) ++#define NV20TCL_VTXFMT__SIZE 0x00000010 ++#define NV20TCL_VTXFMT_TYPE_SHIFT 0 ++#define NV20TCL_VTXFMT_TYPE_MASK 0x0000000f ++#define NV20TCL_VTXFMT_TYPE_FLOAT 0x00000002 ++#define NV20TCL_VTXFMT_TYPE_UBYTE 0x00000004 ++#define NV20TCL_VTXFMT_TYPE_USHORT 0x00000005 ++#define NV20TCL_VTXFMT_SIZE_SHIFT 4 ++#define NV20TCL_VTXFMT_SIZE_MASK 0x000000f0 ++#define NV20TCL_VTXFMT_STRIDE_SHIFT 8 ++#define NV20TCL_VTXFMT_STRIDE_MASK 0x0000ff00 ++#define NV20TCL_LIGHT_MODEL_BACK_AMBIENT_R 0x000017a0 ++#define NV20TCL_LIGHT_MODEL_BACK_AMBIENT_G 0x000017a4 ++#define NV20TCL_LIGHT_MODEL_BACK_AMBIENT_B 0x000017a8 ++#define NV20TCL_MATERIAL_FACTOR_BACK_A 0x000017ac ++#define NV20TCL_MATERIAL_FACTOR_BACK_R 0x000017b0 ++#define NV20TCL_MATERIAL_FACTOR_BACK_G 0x000017b4 ++#define NV20TCL_MATERIAL_FACTOR_BACK_B 0x000017b8 ++#define NV20TCL_COLOR_LOGIC_OP_ENABLE 0x000017bc ++#define NV20TCL_COLOR_LOGIC_OP_OP 0x000017c0 ++#define NV20TCL_COLOR_LOGIC_OP_OP_CLEAR 0x00001500 ++#define NV20TCL_COLOR_LOGIC_OP_OP_AND 0x00001501 ++#define NV20TCL_COLOR_LOGIC_OP_OP_AND_REVERSE 0x00001502 ++#define NV20TCL_COLOR_LOGIC_OP_OP_COPY 0x00001503 ++#define NV20TCL_COLOR_LOGIC_OP_OP_AND_INVERTED 0x00001504 ++#define NV20TCL_COLOR_LOGIC_OP_OP_NOOP 0x00001505 ++#define NV20TCL_COLOR_LOGIC_OP_OP_XOR 0x00001506 ++#define NV20TCL_COLOR_LOGIC_OP_OP_OR 0x00001507 ++#define NV20TCL_COLOR_LOGIC_OP_OP_NOR 0x00001508 ++#define NV20TCL_COLOR_LOGIC_OP_OP_EQUIV 0x00001509 ++#define NV20TCL_COLOR_LOGIC_OP_OP_INVERT 0x0000150a ++#define NV20TCL_COLOR_LOGIC_OP_OP_OR_REVERSE 0x0000150b ++#define NV20TCL_COLOR_LOGIC_OP_OP_COPY_INVERTED 0x0000150c ++#define NV20TCL_COLOR_LOGIC_OP_OP_OR_INVERTED 0x0000150d ++#define NV20TCL_COLOR_LOGIC_OP_OP_NAND 0x0000150e ++#define NV20TCL_COLOR_LOGIC_OP_OP_SET 0x0000150f ++#define NV20TCL_LIGHT_MODEL_TWO_SIDE_ENABLE 0x000017c4 ++#define NV20TCL_TX_SHADER_CULL_MODE 0x000017f8 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_S (1 << 0) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_S_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_S_LESS 0x00000001 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_T (1 << 1) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_T_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_T_LESS 0x00000002 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_R (1 << 2) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_R_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_R_LESS 0x00000004 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_Q (1 << 3) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_Q_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX0_Q_LESS 0x00000008 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_S (1 << 4) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_S_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_S_LESS 0x00000010 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_T (1 << 5) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_T_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_T_LESS 0x00000020 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_R (1 << 6) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_R_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_R_LESS 0x00000040 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_Q (1 << 7) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_Q_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX1_Q_LESS 0x00000080 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_S (1 << 8) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_S_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_S_LESS 0x00000100 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_T (1 << 9) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_T_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_T_LESS 0x00000200 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_R (1 << 10) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_R_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_R_LESS 0x00000400 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_Q (1 << 11) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_Q_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX2_Q_LESS 0x00000800 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_S (1 << 12) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_S_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_S_LESS 0x00001000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_T (1 << 13) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_T_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_T_LESS 0x00002000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_R (1 << 14) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_R_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_R_LESS 0x00004000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_Q (1 << 15) ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_Q_GEQUAL 0x00000000 ++#define NV20TCL_TX_SHADER_CULL_MODE_TX3_Q_LESS 0x00008000 ++#define NV20TCL_VERTEX_BEGIN_END 0x000017fc ++#define NV20TCL_VERTEX_BEGIN_END_STOP 0x00000000 ++#define NV20TCL_VERTEX_BEGIN_END_POINTS 0x00000001 ++#define NV20TCL_VERTEX_BEGIN_END_LINES 0x00000002 ++#define NV20TCL_VERTEX_BEGIN_END_LINE_LOOP 0x00000003 ++#define NV20TCL_VERTEX_BEGIN_END_LINE_STRIP 0x00000004 ++#define NV20TCL_VERTEX_BEGIN_END_TRIANGLES 0x00000005 ++#define NV20TCL_VERTEX_BEGIN_END_TRIANGLE_STRIP 0x00000006 ++#define NV20TCL_VERTEX_BEGIN_END_TRIANGLE_FAN 0x00000007 ++#define NV20TCL_VERTEX_BEGIN_END_QUADS 0x00000008 ++#define NV20TCL_VERTEX_BEGIN_END_QUAD_STRIP 0x00000009 ++#define NV20TCL_VERTEX_BEGIN_END_POLYGON 0x0000000a ++#define NV20TCL_VB_ELEMENT_U16 0x00001800 ++#define NV20TCL_VB_ELEMENT_U16_I0_SHIFT 0 ++#define NV20TCL_VB_ELEMENT_U16_I0_MASK 0x0000ffff ++#define NV20TCL_VB_ELEMENT_U16_I1_SHIFT 16 ++#define NV20TCL_VB_ELEMENT_U16_I1_MASK 0xffff0000 ++#define NV20TCL_VB_ELEMENT_U32 0x00001808 ++#define NV20TCL_VB_VERTEX_BATCH 0x00001810 ++#define NV20TCL_VB_VERTEX_BATCH_OFFSET_SHIFT 0 ++#define NV20TCL_VB_VERTEX_BATCH_OFFSET_MASK 0x00ffffff ++#define NV20TCL_VB_VERTEX_BATCH_COUNT_SHIFT 24 ++#define NV20TCL_VB_VERTEX_BATCH_COUNT_MASK 0xff000000 ++#define NV20TCL_VERTEX_DATA 0x00001818 ++#define NV20TCL_TX_SHADER_CONST_EYE_X 0x0000181c ++#define NV20TCL_TX_SHADER_CONST_EYE_Y 0x00001820 ++#define NV20TCL_TX_SHADER_CONST_EYE_Z 0x00001824 ++#define NV20TCL_VTX_ATTR_4F_X(x) (0x00001a00+((x)*16)) ++#define NV20TCL_VTX_ATTR_4F_X__SIZE 0x00000010 ++#define NV20TCL_VTX_ATTR_4F_Y(x) (0x00001a04+((x)*16)) ++#define NV20TCL_VTX_ATTR_4F_Y__SIZE 0x00000010 ++#define NV20TCL_VTX_ATTR_4F_Z(x) (0x00001a08+((x)*16)) ++#define NV20TCL_VTX_ATTR_4F_Z__SIZE 0x00000010 ++#define NV20TCL_VTX_ATTR_4F_W(x) (0x00001a0c+((x)*16)) ++#define NV20TCL_VTX_ATTR_4F_W__SIZE 0x00000010 ++#define NV20TCL_TX_OFFSET(x) (0x00001b00+((x)*64)) ++#define NV20TCL_TX_OFFSET__SIZE 0x00000004 ++#define NV20TCL_TX_FORMAT(x) (0x00001b04+((x)*64)) ++#define NV20TCL_TX_FORMAT__SIZE 0x00000004 ++#define NV20TCL_TX_FORMAT_DMA0 (1 << 0) ++#define NV20TCL_TX_FORMAT_DMA1 (1 << 1) ++#define NV20TCL_TX_FORMAT_CUBIC (1 << 2) ++#define NV20TCL_TX_FORMAT_NO_BORDER (1 << 3) ++#define NV20TCL_TX_FORMAT_DIMS_SHIFT 4 ++#define NV20TCL_TX_FORMAT_DIMS_MASK 0x000000f0 ++#define NV20TCL_TX_FORMAT_DIMS_1D 0x00000010 ++#define NV20TCL_TX_FORMAT_DIMS_2D 0x00000020 ++#define NV20TCL_TX_FORMAT_DIMS_3D 0x00000030 ++#define NV20TCL_TX_FORMAT_FORMAT_SHIFT 8 ++#define NV20TCL_TX_FORMAT_FORMAT_MASK 0x0000ff00 ++#define NV20TCL_TX_FORMAT_FORMAT_L8 0x00000000 ++#define NV20TCL_TX_FORMAT_FORMAT_A8 0x00000100 ++#define NV20TCL_TX_FORMAT_FORMAT_A1R5G5B5 0x00000200 ++#define NV20TCL_TX_FORMAT_FORMAT_A4R4G4B4 0x00000400 ++#define NV20TCL_TX_FORMAT_FORMAT_R5G6B5 0x00000500 ++#define NV20TCL_TX_FORMAT_FORMAT_A8R8G8B8 0x00000600 ++#define NV20TCL_TX_FORMAT_FORMAT_X8R8G8B8 0x00000700 ++#define NV20TCL_TX_FORMAT_FORMAT_INDEX8 0x00000b00 ++#define NV20TCL_TX_FORMAT_FORMAT_DXT1 0x00000c00 ++#define NV20TCL_TX_FORMAT_FORMAT_DXT3 0x00000e00 ++#define NV20TCL_TX_FORMAT_FORMAT_DXT5 0x00000f00 ++#define NV20TCL_TX_FORMAT_FORMAT_A1R5G5B5_RECT 0x00001000 ++#define NV20TCL_TX_FORMAT_FORMAT_R5G6B5_RECT 0x00001100 ++#define NV20TCL_TX_FORMAT_FORMAT_A8R8G8B8_RECT 0x00001200 ++#define NV20TCL_TX_FORMAT_FORMAT_L8_RECT 0x00001300 ++#define NV20TCL_TX_FORMAT_FORMAT_DSDT8_RECT 0x00001700 ++#define NV20TCL_TX_FORMAT_FORMAT_A8L8 0x00001a00 ++#define NV20TCL_TX_FORMAT_FORMAT_A8_RECT 0x00001b00 ++#define NV20TCL_TX_FORMAT_FORMAT_A4R4G4B4_RECT 0x00001d00 ++#define NV20TCL_TX_FORMAT_FORMAT_R8G8B8_RECT 0x00001e00 ++#define NV20TCL_TX_FORMAT_FORMAT_A8L8_RECT 0x00002000 ++#define NV20TCL_TX_FORMAT_FORMAT_DSDT8 0x00002800 ++#define NV20TCL_TX_FORMAT_FORMAT_HILO16 0x00003300 ++#define NV20TCL_TX_FORMAT_FORMAT_HILO16_RECT 0x00003600 ++#define NV20TCL_TX_FORMAT_FORMAT_HILO8 0x00004400 ++#define NV20TCL_TX_FORMAT_FORMAT_SIGNED_HILO8 0x00004500 ++#define NV20TCL_TX_FORMAT_FORMAT_HILO8_RECT 0x00004600 ++#define NV20TCL_TX_FORMAT_FORMAT_SIGNED_HILO8_RECT 0x00004700 ++#define NV20TCL_TX_FORMAT_FORMAT_A16 0x00003200 ++#define NV20TCL_TX_FORMAT_FORMAT_A16_RECT 0x00003500 ++#define NV20TCL_TX_FORMAT_FORMAT_FLOAT_RGBA16_NV 0x00004a00 ++#define NV20TCL_TX_FORMAT_FORMAT_FLOAT_RGBA32_NV 0x00004b00 ++#define NV20TCL_TX_FORMAT_FORMAT_FLOAT_R32_NV 0x00004c00 ++#define NV20TCL_TX_FORMAT_MIPMAP (1 << 19) ++#define NV20TCL_TX_FORMAT_BASE_SIZE_U_SHIFT 20 ++#define NV20TCL_TX_FORMAT_BASE_SIZE_U_MASK 0x00f00000 ++#define NV20TCL_TX_FORMAT_BASE_SIZE_V_SHIFT 24 ++#define NV20TCL_TX_FORMAT_BASE_SIZE_V_MASK 0x0f000000 ++#define NV20TCL_TX_FORMAT_BASE_SIZE_W_SHIFT 28 ++#define NV20TCL_TX_FORMAT_BASE_SIZE_W_MASK 0xf0000000 ++#define NV20TCL_TX_WRAP(x) (0x00001b08+((x)*64)) ++#define NV20TCL_TX_WRAP__SIZE 0x00000004 ++#define NV20TCL_TX_WRAP_S_SHIFT 0 ++#define NV20TCL_TX_WRAP_S_MASK 0x000000ff ++#define NV20TCL_TX_WRAP_S_REPEAT 0x00000001 ++#define NV20TCL_TX_WRAP_S_MIRRORED_REPEAT 0x00000002 ++#define NV20TCL_TX_WRAP_S_CLAMP_TO_EDGE 0x00000003 ++#define NV20TCL_TX_WRAP_S_CLAMP_TO_BORDER 0x00000004 ++#define NV20TCL_TX_WRAP_S_CLAMP 0x00000005 ++#define NV20TCL_TX_WRAP_T_SHIFT 8 ++#define NV20TCL_TX_WRAP_T_MASK 0x00000f00 ++#define NV20TCL_TX_WRAP_T_REPEAT 0x00000100 ++#define NV20TCL_TX_WRAP_T_MIRRORED_REPEAT 0x00000200 ++#define NV20TCL_TX_WRAP_T_CLAMP_TO_EDGE 0x00000300 ++#define NV20TCL_TX_WRAP_T_CLAMP_TO_BORDER 0x00000400 ++#define NV20TCL_TX_WRAP_T_CLAMP 0x00000500 ++#define NV20TCL_TX_WRAP_R_SHIFT 16 ++#define NV20TCL_TX_WRAP_R_MASK 0x000f0000 ++#define NV20TCL_TX_WRAP_R_REPEAT 0x00010000 ++#define NV20TCL_TX_WRAP_R_MIRRORED_REPEAT 0x00020000 ++#define NV20TCL_TX_WRAP_R_CLAMP_TO_EDGE 0x00030000 ++#define NV20TCL_TX_WRAP_R_CLAMP_TO_BORDER 0x00040000 ++#define NV20TCL_TX_WRAP_R_CLAMP 0x00050000 ++#define NV20TCL_TX_ENABLE(x) (0x00001b0c+((x)*64)) ++#define NV20TCL_TX_ENABLE__SIZE 0x00000004 ++#define NV20TCL_TX_ENABLE_ANISO_SHIFT 4 ++#define NV20TCL_TX_ENABLE_ANISO_MASK 0x00000030 ++#define NV20TCL_TX_ENABLE_ANISO_NONE 0x00000000 ++#define NV20TCL_TX_ENABLE_ANISO_2X 0x00000010 ++#define NV20TCL_TX_ENABLE_ANISO_4X 0x00000020 ++#define NV20TCL_TX_ENABLE_ANISO_8X 0x00000030 ++#define NV20TCL_TX_ENABLE_MIPMAP_MAX_LOD_SHIFT 14 ++#define NV20TCL_TX_ENABLE_MIPMAP_MAX_LOD_MASK 0x0003c000 ++#define NV20TCL_TX_ENABLE_MIPMAP_MIN_LOD_SHIFT 26 ++#define NV20TCL_TX_ENABLE_MIPMAP_MIN_LOD_MASK 0x3c000000 ++#define NV20TCL_TX_ENABLE_ENABLE (1 << 30) ++#define NV20TCL_TX_NPOT_PITCH(x) (0x00001b10+((x)*64)) ++#define NV20TCL_TX_NPOT_PITCH__SIZE 0x00000004 ++#define NV20TCL_TX_NPOT_PITCH_PITCH_SHIFT 16 ++#define NV20TCL_TX_NPOT_PITCH_PITCH_MASK 0xffff0000 ++#define NV20TCL_TX_FILTER(x) (0x00001b14+((x)*64)) ++#define NV20TCL_TX_FILTER__SIZE 0x00000004 ++#define NV20TCL_TX_FILTER_LOD_BIAS_SHIFT 8 ++#define NV20TCL_TX_FILTER_LOD_BIAS_MASK 0x00000f00 ++#define NV20TCL_TX_FILTER_MINIFY_SHIFT 16 ++#define NV20TCL_TX_FILTER_MINIFY_MASK 0x000f0000 ++#define NV20TCL_TX_FILTER_MINIFY_NEAREST 0x00010000 ++#define NV20TCL_TX_FILTER_MINIFY_LINEAR 0x00020000 ++#define NV20TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_NEAREST 0x00030000 ++#define NV20TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_NEAREST 0x00040000 ++#define NV20TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_LINEAR 0x00050000 ++#define NV20TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_LINEAR 0x00060000 ++#define NV20TCL_TX_FILTER_MAGNIFY_SHIFT 24 ++#define NV20TCL_TX_FILTER_MAGNIFY_MASK 0x0f000000 ++#define NV20TCL_TX_FILTER_MAGNIFY_NEAREST 0x01000000 ++#define NV20TCL_TX_FILTER_MAGNIFY_LINEAR 0x02000000 ++#define NV20TCL_TX_NPOT_SIZE(x) (0x00001b1c+((x)*64)) ++#define NV20TCL_TX_NPOT_SIZE__SIZE 0x00000004 ++#define NV20TCL_TX_NPOT_SIZE_H_SHIFT 0 ++#define NV20TCL_TX_NPOT_SIZE_H_MASK 0x0000ffff ++#define NV20TCL_TX_NPOT_SIZE_W_SHIFT 16 ++#define NV20TCL_TX_NPOT_SIZE_W_MASK 0xffff0000 ++#define NV20TCL_TX_PALETTE_OFFSET(x) (0x00001b20+((x)*64)) ++#define NV20TCL_TX_PALETTE_OFFSET__SIZE 0x00000004 ++#define NV20TCL_TX_BORDER_COLOR(x) (0x00001b24+((x)*64)) ++#define NV20TCL_TX_BORDER_COLOR__SIZE 0x00000004 ++#define NV20TCL_TX_BORDER_COLOR_B_SHIFT 0 ++#define NV20TCL_TX_BORDER_COLOR_B_MASK 0x000000ff ++#define NV20TCL_TX_BORDER_COLOR_G_SHIFT 8 ++#define NV20TCL_TX_BORDER_COLOR_G_MASK 0x0000ff00 ++#define NV20TCL_TX_BORDER_COLOR_R_SHIFT 16 ++#define NV20TCL_TX_BORDER_COLOR_R_MASK 0x00ff0000 ++#define NV20TCL_TX_BORDER_COLOR_A_SHIFT 24 ++#define NV20TCL_TX_BORDER_COLOR_A_MASK 0xff000000 ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX00(x) (0x00001b28+((x)*64)) ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX00__SIZE 0x00000004 ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX01(x) (0x00001b2c+((x)*64)) ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX01__SIZE 0x00000004 ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX11(x) (0x00001b30+((x)*64)) ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX11__SIZE 0x00000004 ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX10(x) (0x00001b34+((x)*64)) ++#define NV20TCL_TX_SHADER_OFFSET_MATRIX10__SIZE 0x00000004 ++#define NV20TCL_DEPTH_UNK17D8 0x00001d78 ++#define NV20TCL_DEPTH_UNK17D8_CLAMP_SHIFT 4 ++#define NV20TCL_DEPTH_UNK17D8_CLAMP_MASK 0x000000f0 ++#define NV20TCL_MULTISAMPLE_CONTROL 0x00001d7c ++#define NV20TCL_CLEAR_DEPTH_VALUE 0x00001d8c ++#define NV20TCL_CLEAR_VALUE 0x00001d90 ++#define NV20TCL_CLEAR_BUFFERS 0x00001d94 ++#define NV20TCL_CLEAR_BUFFERS_COLOR_A (1 << 7) ++#define NV20TCL_CLEAR_BUFFERS_COLOR_B (1 << 6) ++#define NV20TCL_CLEAR_BUFFERS_COLOR_G (1 << 5) ++#define NV20TCL_CLEAR_BUFFERS_COLOR_R (1 << 4) ++#define NV20TCL_CLEAR_BUFFERS_STENCIL (1 << 1) ++#define NV20TCL_CLEAR_BUFFERS_DEPTH (1 << 0) ++#define NV20TCL_RC_COLOR0 0x00001e20 ++#define NV20TCL_RC_COLOR0_B_SHIFT 0 ++#define NV20TCL_RC_COLOR0_B_MASK 0x000000ff ++#define NV20TCL_RC_COLOR0_G_SHIFT 8 ++#define NV20TCL_RC_COLOR0_G_MASK 0x0000ff00 ++#define NV20TCL_RC_COLOR0_R_SHIFT 16 ++#define NV20TCL_RC_COLOR0_R_MASK 0x00ff0000 ++#define NV20TCL_RC_COLOR0_A_SHIFT 24 ++#define NV20TCL_RC_COLOR0_A_MASK 0xff000000 ++#define NV20TCL_RC_COLOR1 0x00001e24 ++#define NV20TCL_RC_COLOR1_B_SHIFT 0 ++#define NV20TCL_RC_COLOR1_B_MASK 0x000000ff ++#define NV20TCL_RC_COLOR1_G_SHIFT 8 ++#define NV20TCL_RC_COLOR1_G_MASK 0x0000ff00 ++#define NV20TCL_RC_COLOR1_R_SHIFT 16 ++#define NV20TCL_RC_COLOR1_R_MASK 0x00ff0000 ++#define NV20TCL_RC_COLOR1_A_SHIFT 24 ++#define NV20TCL_RC_COLOR1_A_MASK 0xff000000 ++#define NV20TCL_BACK_MATERIAL_SHININESS(x) (0x00001e28+((x)*4)) ++#define NV20TCL_BACK_MATERIAL_SHININESS__SIZE 0x00000006 ++#define NV20TCL_RC_OUT_RGB(x) (0x00001e40+((x)*4)) ++#define NV20TCL_RC_OUT_RGB__SIZE 0x00000008 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_SHIFT 0 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_MASK 0x0000000f ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_FOG 0x00000003 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0 0x0000000c ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_SPARE1 0x0000000d ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV20TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_SHIFT 4 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_MASK 0x000000f0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_FOG 0x00000030 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV20TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_SHIFT 8 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_MASK 0x00000f00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_ZERO 0x00000000 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_FOG 0x00000300 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV20TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV20TCL_RC_OUT_RGB_CD_DOT_PRODUCT (1 << 12) ++#define NV20TCL_RC_OUT_RGB_AB_DOT_PRODUCT (1 << 13) ++#define NV20TCL_RC_OUT_RGB_MUX_SUM (1 << 14) ++#define NV20TCL_RC_OUT_RGB_BIAS (1 << 15) ++#define NV20TCL_RC_OUT_RGB_BIAS_NONE 0x00000000 ++#define NV20TCL_RC_OUT_RGB_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV20TCL_RC_OUT_RGB_SCALE_SHIFT 17 ++#define NV20TCL_RC_OUT_RGB_SCALE_MASK 0x00000000 ++#define NV20TCL_RC_OUT_RGB_SCALE_NONE 0x00000000 ++#define NV20TCL_RC_OUT_RGB_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV20TCL_RC_OUT_RGB_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV20TCL_RC_OUT_RGB_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV20TCL_RC_ENABLE 0x00001e60 ++#define NV20TCL_RC_ENABLE_NUM_COMBINERS_SHIFT 0 ++#define NV20TCL_RC_ENABLE_NUM_COMBINERS_MASK 0x0000000f ++#define NV20TCL_TX_RCOMP 0x00001e6c ++#define NV20TCL_TX_RCOMP_NEVER 0x00000000 ++#define NV20TCL_TX_RCOMP_GREATER 0x00000001 ++#define NV20TCL_TX_RCOMP_EQUAL 0x00000002 ++#define NV20TCL_TX_RCOMP_GEQUAL 0x00000003 ++#define NV20TCL_TX_RCOMP_LESS 0x00000004 ++#define NV20TCL_TX_RCOMP_NOTEQUAL 0x00000005 ++#define NV20TCL_TX_RCOMP_LEQUAL 0x00000006 ++#define NV20TCL_TX_RCOMP_ALWAYS 0x00000007 ++#define NV20TCL_TX_SHADER_OP 0x00001e70 ++#define NV20TCL_TX_SHADER_OP_TX0_SHIFT 0 ++#define NV20TCL_TX_SHADER_OP_TX0_MASK 0x0000001f ++#define NV20TCL_TX_SHADER_OP_TX0_NONE 0x00000000 ++#define NV20TCL_TX_SHADER_OP_TX0_TEXTURE_2D 0x00000001 ++#define NV20TCL_TX_SHADER_OP_TX0_PASS_THROUGH 0x00000004 ++#define NV20TCL_TX_SHADER_OP_TX0_CULL_FRAGMENT 0x00000005 ++#define NV20TCL_TX_SHADER_OP_TX0_OFFSET_TEXTURE_2D 0x00000006 ++#define NV20TCL_TX_SHADER_OP_TX0_DOT_PRODUCT_TEXTURE_2D 0x00000009 ++#define NV20TCL_TX_SHADER_OP_TX0_DOT_PRODUCT_DEPTH_REPLACE 0x0000000a ++#define NV20TCL_TX_SHADER_OP_TX0_DEPENDANT_AR_TEXTURE_2D 0x0000000f ++#define NV20TCL_TX_SHADER_OP_TX0_DEPENDANT_GB_TEXTURE_2D 0x00000010 ++#define NV20TCL_TX_SHADER_OP_TX0_DOT_PRODUCT 0x00000011 ++#define NV20TCL_TX_SHADER_OP_TX1_SHIFT 5 ++#define NV20TCL_TX_SHADER_OP_TX1_MASK 0x000003e0 ++#define NV20TCL_TX_SHADER_OP_TX1_NONE 0x00000000 ++#define NV20TCL_TX_SHADER_OP_TX1_TEXTURE_2D 0x00000020 ++#define NV20TCL_TX_SHADER_OP_TX1_PASS_THROUGH 0x00000080 ++#define NV20TCL_TX_SHADER_OP_TX1_CULL_FRAGMENT 0x000000a0 ++#define NV20TCL_TX_SHADER_OP_TX1_OFFSET_TEXTURE_2D 0x000000c0 ++#define NV20TCL_TX_SHADER_OP_TX1_DOT_PRODUCT_TEXTURE_2D 0x00000120 ++#define NV20TCL_TX_SHADER_OP_TX1_DOT_PRODUCT_DEPTH_REPLACE 0x00000140 ++#define NV20TCL_TX_SHADER_OP_TX1_DEPENDANT_AR_TEXTURE_2D 0x000001e0 ++#define NV20TCL_TX_SHADER_OP_TX1_DEPENDANT_GB_TEXTURE_2D 0x00000200 ++#define NV20TCL_TX_SHADER_OP_TX1_DOT_PRODUCT 0x00000220 ++#define NV20TCL_TX_SHADER_OP_TX2_SHIFT 10 ++#define NV20TCL_TX_SHADER_OP_TX2_MASK 0x00007c00 ++#define NV20TCL_TX_SHADER_OP_TX2_NONE 0x00000000 ++#define NV20TCL_TX_SHADER_OP_TX2_TEXTURE_2D 0x00000400 ++#define NV20TCL_TX_SHADER_OP_TX2_PASS_THROUGH 0x00001000 ++#define NV20TCL_TX_SHADER_OP_TX2_CULL_FRAGMENT 0x00001400 ++#define NV20TCL_TX_SHADER_OP_TX2_OFFSET_TEXTURE_2D 0x00001800 ++#define NV20TCL_TX_SHADER_OP_TX2_DOT_PRODUCT_TEXTURE_2D 0x00002400 ++#define NV20TCL_TX_SHADER_OP_TX2_DOT_PRODUCT_DEPTH_REPLACE 0x00002800 ++#define NV20TCL_TX_SHADER_OP_TX2_DEPENDANT_AR_TEXTURE_2D 0x00003c00 ++#define NV20TCL_TX_SHADER_OP_TX2_DEPENDANT_GB_TEXTURE_2D 0x00004000 ++#define NV20TCL_TX_SHADER_OP_TX2_DOT_PRODUCT 0x00004400 ++#define NV20TCL_TX_SHADER_OP_TX3_SHIFT 15 ++#define NV20TCL_TX_SHADER_OP_TX3_MASK 0x000f8000 ++#define NV20TCL_TX_SHADER_OP_TX3_NONE 0x00000000 ++#define NV20TCL_TX_SHADER_OP_TX3_TEXTURE_2D 0x00008000 ++#define NV20TCL_TX_SHADER_OP_TX3_PASS_THROUGH 0x00020000 ++#define NV20TCL_TX_SHADER_OP_TX3_CULL_FRAGMENT 0x00028000 ++#define NV20TCL_TX_SHADER_OP_TX3_OFFSET_TEXTURE_2D 0x00030000 ++#define NV20TCL_TX_SHADER_OP_TX3_DOT_PRODUCT_TEXTURE_2D 0x00048000 ++#define NV20TCL_TX_SHADER_OP_TX3_DOT_PRODUCT_DEPTH_REPLACE 0x00050000 ++#define NV20TCL_TX_SHADER_OP_TX3_DEPENDANT_AR_TEXTURE_2D 0x00078000 ++#define NV20TCL_TX_SHADER_OP_TX3_DEPENDANT_GB_TEXTURE_2D 0x00080000 ++#define NV20TCL_TX_SHADER_OP_TX3_DOT_PRODUCT 0x00088000 ++#define NV20TCL_TX_SHADER_DOTMAPPING 0x00001e74 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX0_SHIFT 0 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX0_MASK 0x0000000f ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX1_SHIFT 4 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX1_MASK 0x000000f0 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX2_SHIFT 8 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX2_MASK 0x00000f00 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX3_SHIFT 12 ++#define NV20TCL_TX_SHADER_DOTMAPPING_TX3_MASK 0x0000f000 ++#define NV20TCL_TX_SHADER_PREVIOUS 0x00001e78 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX0_SHIFT 8 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX0_MASK 0x00000f00 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX1_SHIFT 12 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX1_MASK 0x0000f000 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX2_SHIFT 16 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX2_MASK 0x00030000 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX3_SHIFT 20 ++#define NV20TCL_TX_SHADER_PREVIOUS_TX3_MASK 0x00300000 ++#define NV20TCL_ENGINE 0x00001e94 ++#define NV20TCL_ENGINE_VP (1 << 1) ++#define NV20TCL_ENGINE_FIXED (1 << 2) ++#define NV20TCL_VP_UPLOAD_FROM_ID 0x00001e9c ++#define NV20TCL_VP_START_FROM_ID 0x00001ea0 ++#define NV20TCL_VP_UPLOAD_CONST_ID 0x00001ea4 ++ ++ ++#define NV25TCL 0x00000597 ++ ++#define NV25TCL_DMA_IN_MEMORY4 0x0000019c ++#define NV25TCL_DMA_IN_MEMORY5 0x000001a0 ++#define NV25TCL_DMA_IN_MEMORY8 0x000001ac ++#define NV25TCL_DMA_IN_MEMORY9 0x000001b0 ++ ++ ++#define NV30TCL 0x00000397 ++ ++ ++ ++#define NV35TCL 0x00000497 ++ ++ ++ ++#define NV34TCL 0x00000697 ++ ++#define NV34TCL_NOP 0x00000100 ++#define NV34TCL_NOTIFY 0x00000104 ++#define NV34TCL_DMA_NOTIFY 0x00000180 ++#define NV34TCL_DMA_TEXTURE0 0x00000184 ++#define NV34TCL_DMA_TEXTURE1 0x00000188 ++#define NV34TCL_DMA_COLOR1 0x0000018c ++#define NV34TCL_DMA_COLOR0 0x00000194 ++#define NV34TCL_DMA_ZETA 0x00000198 ++#define NV34TCL_DMA_VTXBUF0 0x0000019c ++#define NV34TCL_DMA_VTXBUF1 0x000001a0 ++#define NV34TCL_DMA_FENCE 0x000001a4 ++#define NV34TCL_DMA_QUERY 0x000001a8 ++#define NV34TCL_DMA_IN_MEMORY7 0x000001ac ++#define NV34TCL_DMA_IN_MEMORY8 0x000001b0 ++#define NV34TCL_RT_HORIZ 0x00000200 ++#define NV34TCL_RT_HORIZ_X_SHIFT 0 ++#define NV34TCL_RT_HORIZ_X_MASK 0x0000ffff ++#define NV34TCL_RT_HORIZ_W_SHIFT 16 ++#define NV34TCL_RT_HORIZ_W_MASK 0xffff0000 ++#define NV34TCL_RT_VERT 0x00000204 ++#define NV34TCL_RT_VERT_Y_SHIFT 0 ++#define NV34TCL_RT_VERT_Y_MASK 0x0000ffff ++#define NV34TCL_RT_VERT_H_SHIFT 16 ++#define NV34TCL_RT_VERT_H_MASK 0xffff0000 ++#define NV34TCL_RT_FORMAT 0x00000208 ++#define NV34TCL_RT_FORMAT_LOG2_HEIGHT_SHIFT 24 ++#define NV34TCL_RT_FORMAT_LOG2_HEIGHT_MASK 0xff000000 ++#define NV34TCL_RT_FORMAT_LOG2_WIDTH_SHIFT 16 ++#define NV34TCL_RT_FORMAT_LOG2_WIDTH_MASK 0x00ff0000 ++#define NV34TCL_RT_FORMAT_TYPE_SHIFT 8 ++#define NV34TCL_RT_FORMAT_TYPE_MASK 0x00000f00 ++#define NV34TCL_RT_FORMAT_TYPE_LINEAR 0x00000100 ++#define NV34TCL_RT_FORMAT_TYPE_SWIZZLED 0x00000200 ++#define NV34TCL_RT_FORMAT_ZETA_SHIFT 5 ++#define NV34TCL_RT_FORMAT_ZETA_MASK 0x000000e0 ++#define NV34TCL_RT_FORMAT_ZETA_Z16 0x00000020 ++#define NV34TCL_RT_FORMAT_ZETA_Z24S8 0x00000040 ++#define NV34TCL_RT_FORMAT_COLOR_SHIFT 0 ++#define NV34TCL_RT_FORMAT_COLOR_MASK 0x0000001f ++#define NV34TCL_RT_FORMAT_COLOR_R5G6B5 0x00000003 ++#define NV34TCL_RT_FORMAT_COLOR_X8R8G8B8 0x00000005 ++#define NV34TCL_RT_FORMAT_COLOR_A8R8G8B8 0x00000008 ++#define NV34TCL_RT_FORMAT_COLOR_B8 0x00000009 ++#define NV34TCL_RT_FORMAT_COLOR_UNKNOWN 0x0000000d ++#define NV34TCL_RT_FORMAT_COLOR_X8B8G8R8 0x0000000f ++#define NV34TCL_RT_FORMAT_COLOR_A8B8G8R8 0x00000010 ++#define NV34TCL_COLOR0_PITCH 0x0000020c ++#define NV34TCL_COLOR0_PITCH_COLOR0_SHIFT 0 ++#define NV34TCL_COLOR0_PITCH_COLOR0_MASK 0x0000ffff ++#define NV34TCL_COLOR0_PITCH_ZETA_SHIFT 16 ++#define NV34TCL_COLOR0_PITCH_ZETA_MASK 0xffff0000 ++#define NV34TCL_COLOR0_OFFSET 0x00000210 ++#define NV34TCL_ZETA_OFFSET 0x00000214 ++#define NV34TCL_COLOR1_OFFSET 0x00000218 ++#define NV34TCL_COLOR1_PITCH 0x0000021c ++#define NV34TCL_RT_ENABLE 0x00000220 ++#define NV34TCL_RT_ENABLE_MRT (1 << 4) ++#define NV34TCL_RT_ENABLE_COLOR1 (1 << 1) ++#define NV34TCL_RT_ENABLE_COLOR0 (1 << 0) ++#define NV34TCL_LMA_DEPTH_PITCH 0x0000022c ++#define NV34TCL_LMA_DEPTH_OFFSET 0x00000230 ++#define NV34TCL_TX_UNITS_ENABLE 0x0000023c ++#define NV34TCL_TX_UNITS_ENABLE_TX0 (1 << 0) ++#define NV34TCL_TX_UNITS_ENABLE_TX1 (1 << 1) ++#define NV34TCL_TX_UNITS_ENABLE_TX2 (1 << 2) ++#define NV34TCL_TX_UNITS_ENABLE_TX3 (1 << 3) ++#define NV34TCL_TX_UNITS_ENABLE_TX4 (1 << 4) ++#define NV34TCL_TX_UNITS_ENABLE_TX5 (1 << 5) ++#define NV34TCL_TX_UNITS_ENABLE_TX6 (1 << 6) ++#define NV34TCL_TX_UNITS_ENABLE_TX7 (1 << 7) ++#define NV34TCL_TX_MATRIX_ENABLE(x) (0x00000240+((x)*4)) ++#define NV34TCL_TX_MATRIX_ENABLE__SIZE 0x00000008 ++#define NV34TCL_VIEWPORT_TX_ORIGIN 0x000002b8 ++#define NV34TCL_VIEWPORT_TX_ORIGIN_X_SHIFT 0 ++#define NV34TCL_VIEWPORT_TX_ORIGIN_X_MASK 0x0000ffff ++#define NV34TCL_VIEWPORT_TX_ORIGIN_Y_SHIFT 16 ++#define NV34TCL_VIEWPORT_TX_ORIGIN_Y_MASK 0xffff0000 ++#define NV34TCL_VIEWPORT_CLIP_MODE 0x000002bc ++#define NV34TCL_VIEWPORT_CLIP_HORIZ(x) (0x000002c0+((x)*8)) ++#define NV34TCL_VIEWPORT_CLIP_HORIZ__SIZE 0x00000008 ++#define NV34TCL_VIEWPORT_CLIP_HORIZ_L_SHIFT 0 ++#define NV34TCL_VIEWPORT_CLIP_HORIZ_L_MASK 0x0000ffff ++#define NV34TCL_VIEWPORT_CLIP_HORIZ_R_SHIFT 16 ++#define NV34TCL_VIEWPORT_CLIP_HORIZ_R_MASK 0xffff0000 ++#define NV34TCL_VIEWPORT_CLIP_VERT(x) (0x000002c4+((x)*8)) ++#define NV34TCL_VIEWPORT_CLIP_VERT__SIZE 0x00000008 ++#define NV34TCL_VIEWPORT_CLIP_VERT_T_SHIFT 0 ++#define NV34TCL_VIEWPORT_CLIP_VERT_T_MASK 0x0000ffff ++#define NV34TCL_VIEWPORT_CLIP_VERT_D_SHIFT 16 ++#define NV34TCL_VIEWPORT_CLIP_VERT_D_MASK 0xffff0000 ++#define NV34TCL_DITHER_ENABLE 0x00000300 ++#define NV34TCL_ALPHA_FUNC_ENABLE 0x00000304 ++#define NV34TCL_ALPHA_FUNC_FUNC 0x00000308 ++#define NV34TCL_ALPHA_FUNC_FUNC_NEVER 0x00000200 ++#define NV34TCL_ALPHA_FUNC_FUNC_LESS 0x00000201 ++#define NV34TCL_ALPHA_FUNC_FUNC_EQUAL 0x00000202 ++#define NV34TCL_ALPHA_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV34TCL_ALPHA_FUNC_FUNC_GREATER 0x00000204 ++#define NV34TCL_ALPHA_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV34TCL_ALPHA_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV34TCL_ALPHA_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV34TCL_ALPHA_FUNC_REF 0x0000030c ++#define NV34TCL_BLEND_FUNC_ENABLE 0x00000310 ++#define NV34TCL_BLEND_FUNC_SRC 0x00000314 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_SHIFT 0 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_MASK 0x0000ffff ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ZERO 0x00000000 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE 0x00000001 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_SRC_COLOR 0x00000300 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA 0x00000302 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_DST_ALPHA 0x00000304 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_DST_COLOR 0x00000306 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_CONSTANT_COLOR 0x00008001 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV34TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_SHIFT 16 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_MASK 0xffff0000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ZERO 0x00000000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE 0x00010000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_SRC_COLOR 0x03000000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_COLOR 0x03010000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA 0x03020000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_ALPHA 0x03030000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_DST_ALPHA 0x03040000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_ALPHA 0x03050000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_DST_COLOR 0x03060000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_COLOR 0x03070000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA_SATURATE 0x03080000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_COLOR 0x80010000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x80020000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_ALPHA 0x80030000 ++#define NV34TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x80040000 ++#define NV34TCL_BLEND_FUNC_DST 0x00000318 ++#define NV34TCL_BLEND_FUNC_DST_RGB_SHIFT 0 ++#define NV34TCL_BLEND_FUNC_DST_RGB_MASK 0x0000ffff ++#define NV34TCL_BLEND_FUNC_DST_RGB_ZERO 0x00000000 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE 0x00000001 ++#define NV34TCL_BLEND_FUNC_DST_RGB_SRC_COLOR 0x00000300 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV34TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA 0x00000302 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV34TCL_BLEND_FUNC_DST_RGB_DST_ALPHA 0x00000304 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV34TCL_BLEND_FUNC_DST_RGB_DST_COLOR 0x00000306 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV34TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV34TCL_BLEND_FUNC_DST_RGB_CONSTANT_COLOR 0x00008001 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV34TCL_BLEND_FUNC_DST_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV34TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_SHIFT 16 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_MASK 0xffff0000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ZERO 0x00000000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE 0x00010000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_SRC_COLOR 0x03000000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_COLOR 0x03010000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA 0x03020000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_ALPHA 0x03030000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_DST_ALPHA 0x03040000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_ALPHA 0x03050000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_DST_COLOR 0x03060000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_COLOR 0x03070000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA_SATURATE 0x03080000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_COLOR 0x80010000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x80020000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_ALPHA 0x80030000 ++#define NV34TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x80040000 ++#define NV34TCL_BLEND_COLOR 0x0000031c ++#define NV34TCL_BLEND_COLOR_B_SHIFT 0 ++#define NV34TCL_BLEND_COLOR_B_MASK 0x000000ff ++#define NV34TCL_BLEND_COLOR_G_SHIFT 8 ++#define NV34TCL_BLEND_COLOR_G_MASK 0x0000ff00 ++#define NV34TCL_BLEND_COLOR_R_SHIFT 16 ++#define NV34TCL_BLEND_COLOR_R_MASK 0x00ff0000 ++#define NV34TCL_BLEND_COLOR_A_SHIFT 24 ++#define NV34TCL_BLEND_COLOR_A_MASK 0xff000000 ++#define NV34TCL_BLEND_EQUATION 0x00000320 ++#define NV34TCL_BLEND_EQUATION_FUNC_ADD 0x00008006 ++#define NV34TCL_BLEND_EQUATION_MIN 0x00008007 ++#define NV34TCL_BLEND_EQUATION_MAX 0x00008008 ++#define NV34TCL_BLEND_EQUATION_FUNC_SUBTRACT 0x0000800a ++#define NV34TCL_BLEND_EQUATION_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV34TCL_COLOR_MASK 0x00000324 ++#define NV34TCL_COLOR_MASK_B_SHIFT 0 ++#define NV34TCL_COLOR_MASK_B_MASK 0x000000ff ++#define NV34TCL_COLOR_MASK_G_SHIFT 8 ++#define NV34TCL_COLOR_MASK_G_MASK 0x0000ff00 ++#define NV34TCL_COLOR_MASK_R_SHIFT 16 ++#define NV34TCL_COLOR_MASK_R_MASK 0x00ff0000 ++#define NV34TCL_COLOR_MASK_A_SHIFT 24 ++#define NV34TCL_COLOR_MASK_A_MASK 0xff000000 ++#define NV34TCL_STENCIL_FRONT_ENABLE 0x00000328 ++#define NV34TCL_STENCIL_FRONT_MASK 0x0000032c ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC 0x00000330 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_NEVER 0x00000200 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_LESS 0x00000201 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_EQUAL 0x00000202 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_GREATER 0x00000204 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV34TCL_STENCIL_FRONT_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV34TCL_STENCIL_FRONT_FUNC_REF 0x00000334 ++#define NV34TCL_STENCIL_FRONT_FUNC_MASK 0x00000338 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL 0x0000033c ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_ZERO 0x00000000 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_INVERT 0x0000150a ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_INCR 0x00001e02 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_DECR 0x00001e03 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_FRONT_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL 0x00000340 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_ZERO 0x00000000 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_INVERT 0x0000150a ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_INCR 0x00001e02 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_DECR 0x00001e03 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_FRONT_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS 0x00000344 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_ZERO 0x00000000 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_INVERT 0x0000150a ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_INCR 0x00001e02 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_DECR 0x00001e03 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_FRONT_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV34TCL_STENCIL_BACK_ENABLE 0x00000348 ++#define NV34TCL_STENCIL_BACK_MASK 0x0000034c ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC 0x00000350 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_NEVER 0x00000200 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_LESS 0x00000201 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_EQUAL 0x00000202 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_GREATER 0x00000204 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV34TCL_STENCIL_BACK_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV34TCL_STENCIL_BACK_FUNC_REF 0x00000354 ++#define NV34TCL_STENCIL_BACK_FUNC_MASK 0x00000358 ++#define NV34TCL_STENCIL_BACK_OP_FAIL 0x0000035c ++#define NV34TCL_STENCIL_BACK_OP_FAIL_ZERO 0x00000000 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_INVERT 0x0000150a ++#define NV34TCL_STENCIL_BACK_OP_FAIL_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_INCR 0x00001e02 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_DECR 0x00001e03 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_BACK_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL 0x00000360 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_ZERO 0x00000000 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_INVERT 0x0000150a ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_INCR 0x00001e02 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_DECR 0x00001e03 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_BACK_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS 0x00000364 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_ZERO 0x00000000 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_INVERT 0x0000150a ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_KEEP 0x00001e00 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_REPLACE 0x00001e01 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_INCR 0x00001e02 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_DECR 0x00001e03 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV34TCL_STENCIL_BACK_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV34TCL_SHADE_MODEL 0x00000368 ++#define NV34TCL_SHADE_MODEL_FLAT 0x00001d00 ++#define NV34TCL_SHADE_MODEL_SMOOTH 0x00001d01 ++#define NV34TCL_FOG_ENABLE 0x0000036c ++#define NV34TCL_FOG_COLOR 0x00000370 ++#define NV34TCL_FOG_COLOR_R_SHIFT 0 ++#define NV34TCL_FOG_COLOR_R_MASK 0x000000ff ++#define NV34TCL_FOG_COLOR_G_SHIFT 8 ++#define NV34TCL_FOG_COLOR_G_MASK 0x0000ff00 ++#define NV34TCL_FOG_COLOR_B_SHIFT 16 ++#define NV34TCL_FOG_COLOR_B_MASK 0x00ff0000 ++#define NV34TCL_FOG_COLOR_A_SHIFT 24 ++#define NV34TCL_FOG_COLOR_A_MASK 0xff000000 ++#define NV34TCL_COLOR_LOGIC_OP_ENABLE 0x00000374 ++#define NV34TCL_COLOR_LOGIC_OP_OP 0x00000378 ++#define NV34TCL_COLOR_LOGIC_OP_OP_CLEAR 0x00001500 ++#define NV34TCL_COLOR_LOGIC_OP_OP_AND 0x00001501 ++#define NV34TCL_COLOR_LOGIC_OP_OP_AND_REVERSE 0x00001502 ++#define NV34TCL_COLOR_LOGIC_OP_OP_COPY 0x00001503 ++#define NV34TCL_COLOR_LOGIC_OP_OP_AND_INVERTED 0x00001504 ++#define NV34TCL_COLOR_LOGIC_OP_OP_NOOP 0x00001505 ++#define NV34TCL_COLOR_LOGIC_OP_OP_XOR 0x00001506 ++#define NV34TCL_COLOR_LOGIC_OP_OP_OR 0x00001507 ++#define NV34TCL_COLOR_LOGIC_OP_OP_NOR 0x00001508 ++#define NV34TCL_COLOR_LOGIC_OP_OP_EQUIV 0x00001509 ++#define NV34TCL_COLOR_LOGIC_OP_OP_INVERT 0x0000150a ++#define NV34TCL_COLOR_LOGIC_OP_OP_OR_REVERSE 0x0000150b ++#define NV34TCL_COLOR_LOGIC_OP_OP_COPY_INVERTED 0x0000150c ++#define NV34TCL_COLOR_LOGIC_OP_OP_OR_INVERTED 0x0000150d ++#define NV34TCL_COLOR_LOGIC_OP_OP_NAND 0x0000150e ++#define NV34TCL_COLOR_LOGIC_OP_OP_SET 0x0000150f ++#define NV34TCL_NORMALIZE_ENABLE 0x0000037c ++#define NV34TCL_COLOR_MATERIAL 0x00000390 ++#define NV34TCL_COLOR_MATERIAL_FRONT_EMISSION_ENABLE (1 << 0) ++#define NV34TCL_COLOR_MATERIAL_FRONT_AMBIENT_ENABLE (1 << 2) ++#define NV34TCL_COLOR_MATERIAL_FRONT_DIFFUSE_ENABLE (1 << 4) ++#define NV34TCL_COLOR_MATERIAL_FRONT_SPECULAR_ENABLE (1 << 6) ++#define NV34TCL_COLOR_MATERIAL_BACK_EMISSION_ENABLE (1 << 8) ++#define NV34TCL_COLOR_MATERIAL_BACK_AMBIENT_ENABLE (1 << 10) ++#define NV34TCL_COLOR_MATERIAL_BACK_DIFFUSE_ENABLE (1 << 12) ++#define NV34TCL_COLOR_MATERIAL_BACK_SPECULAR_ENABLE (1 << 14) ++#define NV34TCL_DEPTH_RANGE_NEAR 0x00000394 ++#define NV34TCL_DEPTH_RANGE_FAR 0x00000398 ++#define NV34TCL_COLOR_MATERIAL_FRONT_R 0x000003a0 ++#define NV34TCL_COLOR_MATERIAL_FRONT_G 0x000003a4 ++#define NV34TCL_COLOR_MATERIAL_FRONT_B 0x000003a8 ++#define NV34TCL_COLOR_MATERIAL_FRONT_A 0x000003b4 ++#define NV34TCL_LINE_WIDTH 0x000003b8 ++#define NV34TCL_LINE_SMOOTH_ENABLE 0x000003bc ++#define NV34TCL_TX_GEN_S(x) (0x00000400+((x)*16)) ++#define NV34TCL_TX_GEN_S__SIZE 0x00000008 ++#define NV34TCL_TX_GEN_S_FALSE 0x00000000 ++#define NV34TCL_TX_GEN_S_EYE_LINEAR 0x00002400 ++#define NV34TCL_TX_GEN_S_OBJECT_LINEAR 0x00002401 ++#define NV34TCL_TX_GEN_S_SPHERE_MAP 0x00002402 ++#define NV34TCL_TX_GEN_S_NORMAL_MAP 0x00008511 ++#define NV34TCL_TX_GEN_S_REFLECTION_MAP 0x00008512 ++#define NV34TCL_TX_GEN_T(x) (0x00000404+((x)*16)) ++#define NV34TCL_TX_GEN_T__SIZE 0x00000008 ++#define NV34TCL_TX_GEN_T_FALSE 0x00000000 ++#define NV34TCL_TX_GEN_T_EYE_LINEAR 0x00002400 ++#define NV34TCL_TX_GEN_T_OBJECT_LINEAR 0x00002401 ++#define NV34TCL_TX_GEN_T_SPHERE_MAP 0x00002402 ++#define NV34TCL_TX_GEN_T_NORMAL_MAP 0x00008511 ++#define NV34TCL_TX_GEN_T_REFLECTION_MAP 0x00008512 ++#define NV34TCL_TX_GEN_R(x) (0x00000408+((x)*16)) ++#define NV34TCL_TX_GEN_R__SIZE 0x00000008 ++#define NV34TCL_TX_GEN_R_FALSE 0x00000000 ++#define NV34TCL_TX_GEN_R_EYE_LINEAR 0x00002400 ++#define NV34TCL_TX_GEN_R_OBJECT_LINEAR 0x00002401 ++#define NV34TCL_TX_GEN_R_SPHERE_MAP 0x00002402 ++#define NV34TCL_TX_GEN_R_NORMAL_MAP 0x00008511 ++#define NV34TCL_TX_GEN_R_REFLECTION_MAP 0x00008512 ++#define NV34TCL_TX_GEN_Q(x) (0x0000040c+((x)*16)) ++#define NV34TCL_TX_GEN_Q__SIZE 0x00000008 ++#define NV34TCL_TX_GEN_Q_FALSE 0x00000000 ++#define NV34TCL_TX_GEN_Q_EYE_LINEAR 0x00002400 ++#define NV34TCL_TX_GEN_Q_OBJECT_LINEAR 0x00002401 ++#define NV34TCL_TX_GEN_Q_SPHERE_MAP 0x00002402 ++#define NV34TCL_TX_GEN_Q_NORMAL_MAP 0x00008511 ++#define NV34TCL_TX_GEN_Q_REFLECTION_MAP 0x00008512 ++#define NV34TCL_MODELVIEW_MATRIX(x) (0x00000480+((x)*4)) ++#define NV34TCL_MODELVIEW_MATRIX__SIZE 0x00000010 ++#define NV34TCL_INVERSE_MODELVIEW_MATRIX(x) (0x00000580+((x)*4)) ++#define NV34TCL_INVERSE_MODELVIEW_MATRIX__SIZE 0x0000000c ++#define NV34TCL_PROJECTION_MATRIX(x) (0x00000680+((x)*4)) ++#define NV34TCL_PROJECTION_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX0_MATRIX(x) (0x000006c0+((x)*4)) ++#define NV34TCL_TX0_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX1_MATRIX(x) (0x00000700+((x)*4)) ++#define NV34TCL_TX1_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX2_MATRIX(x) (0x00000740+((x)*4)) ++#define NV34TCL_TX2_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX3_MATRIX(x) (0x00000780+((x)*4)) ++#define NV34TCL_TX3_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX4_MATRIX(x) (0x000007c0+((x)*4)) ++#define NV34TCL_TX4_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX5_MATRIX(x) (0x00000800+((x)*4)) ++#define NV34TCL_TX5_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX6_MATRIX(x) (0x00000840+((x)*4)) ++#define NV34TCL_TX6_MATRIX__SIZE 0x00000010 ++#define NV34TCL_TX7_MATRIX(x) (0x00000880+((x)*4)) ++#define NV34TCL_TX7_MATRIX__SIZE 0x00000010 ++#define NV34TCL_SCISSOR_HORIZ 0x000008c0 ++#define NV34TCL_SCISSOR_HORIZ_X_SHIFT 0 ++#define NV34TCL_SCISSOR_HORIZ_X_MASK 0x0000ffff ++#define NV34TCL_SCISSOR_HORIZ_W_SHIFT 16 ++#define NV34TCL_SCISSOR_HORIZ_W_MASK 0xffff0000 ++#define NV34TCL_SCISSOR_VERT 0x000008c4 ++#define NV34TCL_SCISSOR_VERT_Y_SHIFT 0 ++#define NV34TCL_SCISSOR_VERT_Y_MASK 0x0000ffff ++#define NV34TCL_SCISSOR_VERT_H_SHIFT 16 ++#define NV34TCL_SCISSOR_VERT_H_MASK 0xffff0000 ++#define NV34TCL_FOG_COORD_DIST 0x000008c8 ++#define NV34TCL_FOG_MODE 0x000008cc ++#define NV34TCL_FOG_EQUATION_CONSTANT 0x000008d0 ++#define NV34TCL_FOG_EQUATION_LINEAR 0x000008d4 ++#define NV34TCL_FOG_EQUATION_QUADRATIC 0x000008d8 ++#define NV34TCL_FP_ACTIVE_PROGRAM 0x000008e4 ++#define NV34TCL_FP_ACTIVE_PROGRAM_DMA0 (1 << 0) ++#define NV34TCL_FP_ACTIVE_PROGRAM_DMA1 (1 << 1) ++#define NV34TCL_FP_ACTIVE_PROGRAM_OFFSET_SHIFT 2 ++#define NV34TCL_FP_ACTIVE_PROGRAM_OFFSET_MASK 0xfffffffc ++#define NV34TCL_RC_COLOR0 0x000008ec ++#define NV34TCL_RC_COLOR0_B_SHIFT 0 ++#define NV34TCL_RC_COLOR0_B_MASK 0x000000ff ++#define NV34TCL_RC_COLOR0_G_SHIFT 8 ++#define NV34TCL_RC_COLOR0_G_MASK 0x0000ff00 ++#define NV34TCL_RC_COLOR0_R_SHIFT 16 ++#define NV34TCL_RC_COLOR0_R_MASK 0x00ff0000 ++#define NV34TCL_RC_COLOR0_A_SHIFT 24 ++#define NV34TCL_RC_COLOR0_A_MASK 0xff000000 ++#define NV34TCL_RC_COLOR1 0x000008f0 ++#define NV34TCL_RC_COLOR1_B_SHIFT 0 ++#define NV34TCL_RC_COLOR1_B_MASK 0x000000ff ++#define NV34TCL_RC_COLOR1_G_SHIFT 8 ++#define NV34TCL_RC_COLOR1_G_MASK 0x0000ff00 ++#define NV34TCL_RC_COLOR1_R_SHIFT 16 ++#define NV34TCL_RC_COLOR1_R_MASK 0x00ff0000 ++#define NV34TCL_RC_COLOR1_A_SHIFT 24 ++#define NV34TCL_RC_COLOR1_A_MASK 0xff000000 ++#define NV34TCL_RC_FINAL0 0x000008f4 ++#define NV34TCL_RC_FINAL0_D_INPUT_SHIFT 0 ++#define NV34TCL_RC_FINAL0_D_INPUT_MASK 0x0000000f ++#define NV34TCL_RC_FINAL0_D_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV34TCL_RC_FINAL0_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV34TCL_RC_FINAL0_D_INPUT_FOG 0x00000003 ++#define NV34TCL_RC_FINAL0_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV34TCL_RC_FINAL0_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV34TCL_RC_FINAL0_D_INPUT_TEXTURE0 0x00000008 ++#define NV34TCL_RC_FINAL0_D_INPUT_TEXTURE1 0x00000009 ++#define NV34TCL_RC_FINAL0_D_INPUT_SPARE0 0x0000000c ++#define NV34TCL_RC_FINAL0_D_INPUT_SPARE1 0x0000000d ++#define NV34TCL_RC_FINAL0_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV34TCL_RC_FINAL0_D_INPUT_E_TIMES_F 0x0000000f ++#define NV34TCL_RC_FINAL0_D_INPUT_TEXTURE2 0x0000000a ++#define NV34TCL_RC_FINAL0_D_INPUT_TEXTURE3 0x0000000b ++#define NV34TCL_RC_FINAL0_D_COMPONENT_USAGE (1 << 4) ++#define NV34TCL_RC_FINAL0_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL0_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV34TCL_RC_FINAL0_D_MAPPING_SHIFT 5 ++#define NV34TCL_RC_FINAL0_D_MAPPING_MASK 0x000000e0 ++#define NV34TCL_RC_FINAL0_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL0_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV34TCL_RC_FINAL0_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV34TCL_RC_FINAL0_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV34TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV34TCL_RC_FINAL0_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV34TCL_RC_FINAL0_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV34TCL_RC_FINAL0_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV34TCL_RC_FINAL0_C_INPUT_SHIFT 8 ++#define NV34TCL_RC_FINAL0_C_INPUT_MASK 0x00000f00 ++#define NV34TCL_RC_FINAL0_C_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_FINAL0_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_FINAL0_C_INPUT_FOG 0x00000300 ++#define NV34TCL_RC_FINAL0_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_FINAL0_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_FINAL0_C_INPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_FINAL0_C_INPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_FINAL0_C_INPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_FINAL0_C_INPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_FINAL0_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_FINAL0_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_FINAL0_C_INPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_FINAL0_C_INPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_FINAL0_C_COMPONENT_USAGE (1 << 12) ++#define NV34TCL_RC_FINAL0_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL0_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_SHIFT 13 ++#define NV34TCL_RC_FINAL0_C_MAPPING_MASK 0x0000e000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV34TCL_RC_FINAL0_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV34TCL_RC_FINAL0_B_INPUT_SHIFT 16 ++#define NV34TCL_RC_FINAL0_B_INPUT_MASK 0x000f0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV34TCL_RC_FINAL0_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV34TCL_RC_FINAL0_B_INPUT_FOG 0x00030000 ++#define NV34TCL_RC_FINAL0_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV34TCL_RC_FINAL0_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV34TCL_RC_FINAL0_B_INPUT_TEXTURE0 0x00080000 ++#define NV34TCL_RC_FINAL0_B_INPUT_TEXTURE1 0x00090000 ++#define NV34TCL_RC_FINAL0_B_INPUT_SPARE0 0x000c0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_SPARE1 0x000d0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_TEXTURE2 0x000a0000 ++#define NV34TCL_RC_FINAL0_B_INPUT_TEXTURE3 0x000b0000 ++#define NV34TCL_RC_FINAL0_B_COMPONENT_USAGE (1 << 20) ++#define NV34TCL_RC_FINAL0_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL0_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_SHIFT 21 ++#define NV34TCL_RC_FINAL0_B_MAPPING_MASK 0x00e00000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV34TCL_RC_FINAL0_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV34TCL_RC_FINAL0_A_INPUT_SHIFT 24 ++#define NV34TCL_RC_FINAL0_A_INPUT_MASK 0x0f000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_FOG 0x03000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_TEXTURE0 0x08000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_TEXTURE1 0x09000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_SPARE0 0x0c000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_SPARE1 0x0d000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_TEXTURE2 0x0a000000 ++#define NV34TCL_RC_FINAL0_A_INPUT_TEXTURE3 0x0b000000 ++#define NV34TCL_RC_FINAL0_A_COMPONENT_USAGE (1 << 28) ++#define NV34TCL_RC_FINAL0_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL0_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_SHIFT 29 ++#define NV34TCL_RC_FINAL0_A_MAPPING_MASK 0xe0000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV34TCL_RC_FINAL0_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV34TCL_RC_FINAL1 0x000008f8 ++#define NV34TCL_RC_FINAL1_COLOR_SUM_CLAMP (1 << 7) ++#define NV34TCL_RC_FINAL1_G_INPUT_SHIFT 8 ++#define NV34TCL_RC_FINAL1_G_INPUT_MASK 0x00000f00 ++#define NV34TCL_RC_FINAL1_G_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_FINAL1_G_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_FINAL1_G_INPUT_FOG 0x00000300 ++#define NV34TCL_RC_FINAL1_G_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_FINAL1_G_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_FINAL1_G_INPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_FINAL1_G_INPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_FINAL1_G_INPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_FINAL1_G_INPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_FINAL1_G_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_FINAL1_G_INPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_FINAL1_G_INPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_FINAL1_G_INPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_FINAL1_G_COMPONENT_USAGE (1 << 12) ++#define NV34TCL_RC_FINAL1_G_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL1_G_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_SHIFT 13 ++#define NV34TCL_RC_FINAL1_G_MAPPING_MASK 0x0000e000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV34TCL_RC_FINAL1_G_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV34TCL_RC_FINAL1_F_INPUT_SHIFT 16 ++#define NV34TCL_RC_FINAL1_F_INPUT_MASK 0x000f0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV34TCL_RC_FINAL1_F_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV34TCL_RC_FINAL1_F_INPUT_FOG 0x00030000 ++#define NV34TCL_RC_FINAL1_F_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV34TCL_RC_FINAL1_F_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV34TCL_RC_FINAL1_F_INPUT_TEXTURE0 0x00080000 ++#define NV34TCL_RC_FINAL1_F_INPUT_TEXTURE1 0x00090000 ++#define NV34TCL_RC_FINAL1_F_INPUT_SPARE0 0x000c0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_SPARE1 0x000d0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_E_TIMES_F 0x000f0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_TEXTURE2 0x000a0000 ++#define NV34TCL_RC_FINAL1_F_INPUT_TEXTURE3 0x000b0000 ++#define NV34TCL_RC_FINAL1_F_COMPONENT_USAGE (1 << 20) ++#define NV34TCL_RC_FINAL1_F_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL1_F_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_SHIFT 21 ++#define NV34TCL_RC_FINAL1_F_MAPPING_MASK 0x00e00000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV34TCL_RC_FINAL1_F_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV34TCL_RC_FINAL1_E_INPUT_SHIFT 24 ++#define NV34TCL_RC_FINAL1_E_INPUT_MASK 0x0f000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_FOG 0x03000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_TEXTURE0 0x08000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_TEXTURE1 0x09000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_SPARE0 0x0c000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_SPARE1 0x0d000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_E_TIMES_F 0x0f000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_TEXTURE2 0x0a000000 ++#define NV34TCL_RC_FINAL1_E_INPUT_TEXTURE3 0x0b000000 ++#define NV34TCL_RC_FINAL1_E_COMPONENT_USAGE (1 << 28) ++#define NV34TCL_RC_FINAL1_E_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_FINAL1_E_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_SHIFT 29 ++#define NV34TCL_RC_FINAL1_E_MAPPING_MASK 0xe0000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV34TCL_RC_FINAL1_E_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV34TCL_RC_ENABLE 0x000008fc ++#define NV34TCL_RC_ENABLE_NUM_COMBINERS_SHIFT 0 ++#define NV34TCL_RC_ENABLE_NUM_COMBINERS_MASK 0x0000000f ++#define NV34TCL_RC_ENABLE_STAGE_CONSTANT_COLOR0_SHIFT 12 ++#define NV34TCL_RC_ENABLE_STAGE_CONSTANT_COLOR0_MASK 0x0000f000 ++#define NV34TCL_RC_ENABLE_STAGE_CONSTANT_COLOR1_SHIFT 16 ++#define NV34TCL_RC_ENABLE_STAGE_CONSTANT_COLOR1_MASK 0x000f0000 ++#define NV34TCL_RC_IN_ALPHA(x) (0x00000900+((x)*32)) ++#define NV34TCL_RC_IN_ALPHA__SIZE 0x00000008 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_SHIFT 0 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_MASK 0x0000000f ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_FOG 0x00000003 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_TEXTURE0 0x00000008 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_TEXTURE1 0x00000009 ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_SPARE0 0x0000000c ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_SPARE1 0x0000000d ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_E_TIMES_F 0x0000000f ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_TEXTURE2 0x0000000a ++#define NV34TCL_RC_IN_ALPHA_D_INPUT_TEXTURE3 0x0000000b ++#define NV34TCL_RC_IN_ALPHA_D_COMPONENT_USAGE (1 << 4) ++#define NV34TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_SHIFT 5 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_MASK 0x000000e0 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV34TCL_RC_IN_ALPHA_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_SHIFT 8 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_MASK 0x00000f00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_FOG 0x00000300 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_IN_ALPHA_C_INPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_IN_ALPHA_C_COMPONENT_USAGE (1 << 12) ++#define NV34TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_SHIFT 13 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_MASK 0x0000e000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV34TCL_RC_IN_ALPHA_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_SHIFT 16 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_MASK 0x000f0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_FOG 0x00030000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_TEXTURE0 0x00080000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_TEXTURE1 0x00090000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_SPARE0 0x000c0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_SPARE1 0x000d0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_TEXTURE2 0x000a0000 ++#define NV34TCL_RC_IN_ALPHA_B_INPUT_TEXTURE3 0x000b0000 ++#define NV34TCL_RC_IN_ALPHA_B_COMPONENT_USAGE (1 << 20) ++#define NV34TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_SHIFT 21 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_MASK 0x00e00000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV34TCL_RC_IN_ALPHA_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_SHIFT 24 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_MASK 0x0f000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_FOG 0x03000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_TEXTURE0 0x08000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_TEXTURE1 0x09000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_SPARE0 0x0c000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_SPARE1 0x0d000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_TEXTURE2 0x0a000000 ++#define NV34TCL_RC_IN_ALPHA_A_INPUT_TEXTURE3 0x0b000000 ++#define NV34TCL_RC_IN_ALPHA_A_COMPONENT_USAGE (1 << 28) ++#define NV34TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_BLUE 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_SHIFT 29 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_MASK 0xe0000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV34TCL_RC_IN_ALPHA_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV34TCL_RC_IN_RGB(x) (0x00000904+((x)*32)) ++#define NV34TCL_RC_IN_RGB__SIZE 0x00000008 ++#define NV34TCL_RC_IN_RGB_D_INPUT_SHIFT 0 ++#define NV34TCL_RC_IN_RGB_D_INPUT_MASK 0x0000000f ++#define NV34TCL_RC_IN_RGB_D_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR0 0x00000001 ++#define NV34TCL_RC_IN_RGB_D_INPUT_CONSTANT_COLOR1 0x00000002 ++#define NV34TCL_RC_IN_RGB_D_INPUT_FOG 0x00000003 ++#define NV34TCL_RC_IN_RGB_D_INPUT_PRIMARY_COLOR 0x00000004 ++#define NV34TCL_RC_IN_RGB_D_INPUT_SECONDARY_COLOR 0x00000005 ++#define NV34TCL_RC_IN_RGB_D_INPUT_TEXTURE0 0x00000008 ++#define NV34TCL_RC_IN_RGB_D_INPUT_TEXTURE1 0x00000009 ++#define NV34TCL_RC_IN_RGB_D_INPUT_SPARE0 0x0000000c ++#define NV34TCL_RC_IN_RGB_D_INPUT_SPARE1 0x0000000d ++#define NV34TCL_RC_IN_RGB_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV34TCL_RC_IN_RGB_D_INPUT_E_TIMES_F 0x0000000f ++#define NV34TCL_RC_IN_RGB_D_INPUT_TEXTURE2 0x0000000a ++#define NV34TCL_RC_IN_RGB_D_INPUT_TEXTURE3 0x0000000b ++#define NV34TCL_RC_IN_RGB_D_COMPONENT_USAGE (1 << 4) ++#define NV34TCL_RC_IN_RGB_D_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_IN_RGB_D_COMPONENT_USAGE_ALPHA 0x00000010 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_SHIFT 5 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_MASK 0x000000e0 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_UNSIGNED_INVERT 0x00000020 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_EXPAND_NORMAL 0x00000040 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_EXPAND_NEGATE 0x00000060 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NORMAL 0x00000080 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_HALF_BIAS_NEGATE 0x000000a0 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_SIGNED_IDENTITY 0x000000c0 ++#define NV34TCL_RC_IN_RGB_D_MAPPING_SIGNED_NEGATE 0x000000e0 ++#define NV34TCL_RC_IN_RGB_C_INPUT_SHIFT 8 ++#define NV34TCL_RC_IN_RGB_C_INPUT_MASK 0x00000f00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_IN_RGB_C_INPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_IN_RGB_C_INPUT_FOG 0x00000300 ++#define NV34TCL_RC_IN_RGB_C_INPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_IN_RGB_C_INPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_IN_RGB_C_INPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_IN_RGB_C_INPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_IN_RGB_C_INPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_IN_RGB_C_INPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_IN_RGB_C_COMPONENT_USAGE (1 << 12) ++#define NV34TCL_RC_IN_RGB_C_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_IN_RGB_C_COMPONENT_USAGE_ALPHA 0x00001000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_SHIFT 13 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_MASK 0x0000e000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_UNSIGNED_INVERT 0x00002000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_EXPAND_NORMAL 0x00004000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_EXPAND_NEGATE 0x00006000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NORMAL 0x00008000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_HALF_BIAS_NEGATE 0x0000a000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_SIGNED_IDENTITY 0x0000c000 ++#define NV34TCL_RC_IN_RGB_C_MAPPING_SIGNED_NEGATE 0x0000e000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_SHIFT 16 ++#define NV34TCL_RC_IN_RGB_B_INPUT_MASK 0x000f0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR0 0x00010000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_CONSTANT_COLOR1 0x00020000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_FOG 0x00030000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_PRIMARY_COLOR 0x00040000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_SECONDARY_COLOR 0x00050000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_TEXTURE0 0x00080000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_TEXTURE1 0x00090000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_SPARE0 0x000c0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_SPARE1 0x000d0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000e0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_E_TIMES_F 0x000f0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_TEXTURE2 0x000a0000 ++#define NV34TCL_RC_IN_RGB_B_INPUT_TEXTURE3 0x000b0000 ++#define NV34TCL_RC_IN_RGB_B_COMPONENT_USAGE (1 << 20) ++#define NV34TCL_RC_IN_RGB_B_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_IN_RGB_B_COMPONENT_USAGE_ALPHA 0x00100000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_SHIFT 21 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_MASK 0x00e00000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_UNSIGNED_INVERT 0x00200000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_EXPAND_NORMAL 0x00400000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_EXPAND_NEGATE 0x00600000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NORMAL 0x00800000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_HALF_BIAS_NEGATE 0x00a00000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_SIGNED_IDENTITY 0x00c00000 ++#define NV34TCL_RC_IN_RGB_B_MAPPING_SIGNED_NEGATE 0x00e00000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_SHIFT 24 ++#define NV34TCL_RC_IN_RGB_A_INPUT_MASK 0x0f000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_ZERO 0x00000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR0 0x01000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_CONSTANT_COLOR1 0x02000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_FOG 0x03000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_PRIMARY_COLOR 0x04000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_SECONDARY_COLOR 0x05000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_TEXTURE0 0x08000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_TEXTURE1 0x09000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_SPARE0 0x0c000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_SPARE1 0x0d000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0e000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_E_TIMES_F 0x0f000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_TEXTURE2 0x0a000000 ++#define NV34TCL_RC_IN_RGB_A_INPUT_TEXTURE3 0x0b000000 ++#define NV34TCL_RC_IN_RGB_A_COMPONENT_USAGE (1 << 28) ++#define NV34TCL_RC_IN_RGB_A_COMPONENT_USAGE_RGB 0x00000000 ++#define NV34TCL_RC_IN_RGB_A_COMPONENT_USAGE_ALPHA 0x10000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_SHIFT 29 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_MASK 0xe0000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_IDENTITY 0x00000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_UNSIGNED_INVERT 0x20000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_EXPAND_NORMAL 0x40000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_EXPAND_NEGATE 0x60000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NORMAL 0x80000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_HALF_BIAS_NEGATE 0xa0000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_SIGNED_IDENTITY 0xc0000000 ++#define NV34TCL_RC_IN_RGB_A_MAPPING_SIGNED_NEGATE 0xe0000000 ++#define NV34TCL_RC_CONSTANT_COLOR0(x) (0x00000908+((x)*32)) ++#define NV34TCL_RC_CONSTANT_COLOR0__SIZE 0x00000008 ++#define NV34TCL_RC_CONSTANT_COLOR0_B_SHIFT 0 ++#define NV34TCL_RC_CONSTANT_COLOR0_B_MASK 0x000000ff ++#define NV34TCL_RC_CONSTANT_COLOR0_G_SHIFT 8 ++#define NV34TCL_RC_CONSTANT_COLOR0_G_MASK 0x0000ff00 ++#define NV34TCL_RC_CONSTANT_COLOR0_R_SHIFT 16 ++#define NV34TCL_RC_CONSTANT_COLOR0_R_MASK 0x00ff0000 ++#define NV34TCL_RC_CONSTANT_COLOR0_A_SHIFT 24 ++#define NV34TCL_RC_CONSTANT_COLOR0_A_MASK 0xff000000 ++#define NV34TCL_RC_CONSTANT_COLOR1(x) (0x0000090c+((x)*32)) ++#define NV34TCL_RC_CONSTANT_COLOR1__SIZE 0x00000008 ++#define NV34TCL_RC_CONSTANT_COLOR1_B_SHIFT 0 ++#define NV34TCL_RC_CONSTANT_COLOR1_B_MASK 0x000000ff ++#define NV34TCL_RC_CONSTANT_COLOR1_G_SHIFT 8 ++#define NV34TCL_RC_CONSTANT_COLOR1_G_MASK 0x0000ff00 ++#define NV34TCL_RC_CONSTANT_COLOR1_R_SHIFT 16 ++#define NV34TCL_RC_CONSTANT_COLOR1_R_MASK 0x00ff0000 ++#define NV34TCL_RC_CONSTANT_COLOR1_A_SHIFT 24 ++#define NV34TCL_RC_CONSTANT_COLOR1_A_MASK 0xff000000 ++#define NV34TCL_RC_OUT_ALPHA(x) (0x00000910+((x)*32)) ++#define NV34TCL_RC_OUT_ALPHA__SIZE 0x00000008 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_SHIFT 0 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_MASK 0x0000000f ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_FOG 0x00000003 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0 0x0000000c ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE1 0x0000000d ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV34TCL_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_SHIFT 4 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_MASK 0x000000f0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_FOG 0x00000030 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV34TCL_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_SHIFT 8 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_MASK 0x00000f00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_FOG 0x00000300 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_OUT_ALPHA_CD_DOT_PRODUCT (1 << 12) ++#define NV34TCL_RC_OUT_ALPHA_AB_DOT_PRODUCT (1 << 13) ++#define NV34TCL_RC_OUT_ALPHA_MUX_SUM (1 << 14) ++#define NV34TCL_RC_OUT_ALPHA_BIAS (1 << 15) ++#define NV34TCL_RC_OUT_ALPHA_BIAS_NONE 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_SHIFT 17 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_MASK 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_NONE 0x00000000 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV34TCL_RC_OUT_ALPHA_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV34TCL_RC_OUT_RGB(x) (0x00000914+((x)*32)) ++#define NV34TCL_RC_OUT_RGB__SIZE 0x00000008 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_SHIFT 0 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_MASK 0x0000000f ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR0 0x00000001 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR1 0x00000002 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_FOG 0x00000003 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_PRIMARY_COLOR 0x00000004 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_SECONDARY_COLOR 0x00000005 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE0 0x00000008 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE1 0x00000009 ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0 0x0000000c ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_SPARE1 0x0000000d ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x0000000e ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_E_TIMES_F 0x0000000f ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE2 0x0000000a ++#define NV34TCL_RC_OUT_RGB_CD_OUTPUT_TEXTURE3 0x0000000b ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_SHIFT 4 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_MASK 0x000000f0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR0 0x00000010 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR1 0x00000020 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_FOG 0x00000030 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_PRIMARY_COLOR 0x00000040 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_SECONDARY_COLOR 0x00000050 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE0 0x00000080 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE1 0x00000090 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0 0x000000c0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_SPARE1 0x000000d0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x000000e0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_E_TIMES_F 0x000000f0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE2 0x000000a0 ++#define NV34TCL_RC_OUT_RGB_AB_OUTPUT_TEXTURE3 0x000000b0 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_SHIFT 8 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_MASK 0x00000f00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_ZERO 0x00000000 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR0 0x00000100 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR1 0x00000200 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_FOG 0x00000300 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_PRIMARY_COLOR 0x00000400 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_SECONDARY_COLOR 0x00000500 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE0 0x00000800 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE1 0x00000900 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0 0x00000c00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE1 0x00000d00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR 0x00000e00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_E_TIMES_F 0x00000f00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE2 0x00000a00 ++#define NV34TCL_RC_OUT_RGB_SUM_OUTPUT_TEXTURE3 0x00000b00 ++#define NV34TCL_RC_OUT_RGB_CD_DOT_PRODUCT (1 << 12) ++#define NV34TCL_RC_OUT_RGB_AB_DOT_PRODUCT (1 << 13) ++#define NV34TCL_RC_OUT_RGB_MUX_SUM (1 << 14) ++#define NV34TCL_RC_OUT_RGB_BIAS (1 << 15) ++#define NV34TCL_RC_OUT_RGB_BIAS_NONE 0x00000000 ++#define NV34TCL_RC_OUT_RGB_BIAS_BIAS_BY_NEGATIVE_ONE_HALF 0x00008000 ++#define NV34TCL_RC_OUT_RGB_SCALE_SHIFT 17 ++#define NV34TCL_RC_OUT_RGB_SCALE_MASK 0x00000000 ++#define NV34TCL_RC_OUT_RGB_SCALE_NONE 0x00000000 ++#define NV34TCL_RC_OUT_RGB_SCALE_SCALE_BY_TWO 0x00020000 ++#define NV34TCL_RC_OUT_RGB_SCALE_SCALE_BY_FOUR 0x00040000 ++#define NV34TCL_RC_OUT_RGB_SCALE_SCALE_BY_ONE_HALF 0x00060000 ++#define NV34TCL_VIEWPORT_HORIZ 0x00000a00 ++#define NV34TCL_VIEWPORT_HORIZ_X_SHIFT 0 ++#define NV34TCL_VIEWPORT_HORIZ_X_MASK 0x0000ffff ++#define NV34TCL_VIEWPORT_HORIZ_W_SHIFT 16 ++#define NV34TCL_VIEWPORT_HORIZ_W_MASK 0xffff0000 ++#define NV34TCL_VIEWPORT_VERT 0x00000a04 ++#define NV34TCL_VIEWPORT_VERT_Y_SHIFT 0 ++#define NV34TCL_VIEWPORT_VERT_Y_MASK 0x0000ffff ++#define NV34TCL_VIEWPORT_VERT_H_SHIFT 16 ++#define NV34TCL_VIEWPORT_VERT_H_MASK 0xffff0000 ++#define NV34TCL_LIGHT_MODEL_FRONT_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_R 0x00000a10 ++#define NV34TCL_LIGHT_MODEL_FRONT_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_G 0x00000a14 ++#define NV34TCL_LIGHT_MODEL_FRONT_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_B 0x00000a18 ++#define NV34TCL_VIEWPORT_TRANSLATE_X 0x00000a20 ++#define NV34TCL_VIEWPORT_TRANSLATE_Y 0x00000a24 ++#define NV34TCL_VIEWPORT_TRANSLATE_Z 0x00000a28 ++#define NV34TCL_VIEWPORT_TRANSLATE_W 0x00000a2c ++#define NV34TCL_VIEWPORT_SCALE_X 0x00000a30 ++#define NV34TCL_VIEWPORT_SCALE_Y 0x00000a34 ++#define NV34TCL_VIEWPORT_SCALE_Z 0x00000a38 ++#define NV34TCL_VIEWPORT_SCALE_W 0x00000a3c ++#define NV34TCL_POLYGON_OFFSET_POINT_ENABLE 0x00000a60 ++#define NV34TCL_POLYGON_OFFSET_LINE_ENABLE 0x00000a64 ++#define NV34TCL_POLYGON_OFFSET_FILL_ENABLE 0x00000a68 ++#define NV34TCL_DEPTH_FUNC 0x00000a6c ++#define NV34TCL_DEPTH_FUNC_NEVER 0x00000200 ++#define NV34TCL_DEPTH_FUNC_LESS 0x00000201 ++#define NV34TCL_DEPTH_FUNC_EQUAL 0x00000202 ++#define NV34TCL_DEPTH_FUNC_LEQUAL 0x00000203 ++#define NV34TCL_DEPTH_FUNC_GREATER 0x00000204 ++#define NV34TCL_DEPTH_FUNC_NOTEQUAL 0x00000205 ++#define NV34TCL_DEPTH_FUNC_GEQUAL 0x00000206 ++#define NV34TCL_DEPTH_FUNC_ALWAYS 0x00000207 ++#define NV34TCL_DEPTH_WRITE_ENABLE 0x00000a70 ++#define NV34TCL_DEPTH_TEST_ENABLE 0x00000a74 ++#define NV34TCL_POLYGON_OFFSET_FACTOR 0x00000a78 ++#define NV34TCL_POLYGON_OFFSET_UNITS 0x00000a7c ++#define NV34TCL_VTX_ATTR_3I_XY(x) (0x00000a80+((x)*8)) ++#define NV34TCL_VTX_ATTR_3I_XY__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_3I_XY_X_SHIFT 0 ++#define NV34TCL_VTX_ATTR_3I_XY_X_MASK 0x0000ffff ++#define NV34TCL_VTX_ATTR_3I_XY_Y_SHIFT 16 ++#define NV34TCL_VTX_ATTR_3I_XY_Y_MASK 0xffff0000 ++#define NV34TCL_VTX_ATTR_3I_Z(x) (0x00000a84+((x)*8)) ++#define NV34TCL_VTX_ATTR_3I_Z__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_3I_Z_Z_SHIFT 0 ++#define NV34TCL_VTX_ATTR_3I_Z_Z_MASK 0x0000ffff ++#define NV34TCL_VP_UPLOAD_INST(x) (0x00000b80+((x)*4)) ++#define NV34TCL_VP_UPLOAD_INST__SIZE 0x00000004 ++#define NV34TCL_TX0_CLIP_PLANE_A(x) (0x00000e00+((x)*16)) ++#define NV34TCL_TX0_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX0_CLIP_PLANE_B(x) (0x00000e04+((x)*16)) ++#define NV34TCL_TX0_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX0_CLIP_PLANE_C(x) (0x00000e08+((x)*16)) ++#define NV34TCL_TX0_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX0_CLIP_PLANE_D(x) (0x00000e0c+((x)*16)) ++#define NV34TCL_TX0_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX1_CLIP_PLANE_A(x) (0x00000e40+((x)*16)) ++#define NV34TCL_TX1_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX1_CLIP_PLANE_B(x) (0x00000e44+((x)*16)) ++#define NV34TCL_TX1_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX1_CLIP_PLANE_C(x) (0x00000e48+((x)*16)) ++#define NV34TCL_TX1_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX1_CLIP_PLANE_D(x) (0x00000e4c+((x)*16)) ++#define NV34TCL_TX1_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX2_CLIP_PLANE_A(x) (0x00000e80+((x)*16)) ++#define NV34TCL_TX2_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX2_CLIP_PLANE_B(x) (0x00000e84+((x)*16)) ++#define NV34TCL_TX2_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX2_CLIP_PLANE_C(x) (0x00000e88+((x)*16)) ++#define NV34TCL_TX2_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX2_CLIP_PLANE_D(x) (0x00000e8c+((x)*16)) ++#define NV34TCL_TX2_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX3_CLIP_PLANE_A(x) (0x00000ec0+((x)*16)) ++#define NV34TCL_TX3_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX3_CLIP_PLANE_B(x) (0x00000ec4+((x)*16)) ++#define NV34TCL_TX3_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX3_CLIP_PLANE_C(x) (0x00000ec8+((x)*16)) ++#define NV34TCL_TX3_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX3_CLIP_PLANE_D(x) (0x00000ecc+((x)*16)) ++#define NV34TCL_TX3_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX4_CLIP_PLANE_A(x) (0x00000f00+((x)*16)) ++#define NV34TCL_TX4_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX4_CLIP_PLANE_B(x) (0x00000f04+((x)*16)) ++#define NV34TCL_TX4_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX4_CLIP_PLANE_C(x) (0x00000f08+((x)*16)) ++#define NV34TCL_TX4_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX4_CLIP_PLANE_D(x) (0x00000f0c+((x)*16)) ++#define NV34TCL_TX4_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX5_CLIP_PLANE_A(x) (0x00000f40+((x)*16)) ++#define NV34TCL_TX5_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX5_CLIP_PLANE_B(x) (0x00000f44+((x)*16)) ++#define NV34TCL_TX5_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX5_CLIP_PLANE_C(x) (0x00000f48+((x)*16)) ++#define NV34TCL_TX5_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX5_CLIP_PLANE_D(x) (0x00000f4c+((x)*16)) ++#define NV34TCL_TX5_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX6_CLIP_PLANE_A(x) (0x00000f80+((x)*16)) ++#define NV34TCL_TX6_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX6_CLIP_PLANE_B(x) (0x00000f84+((x)*16)) ++#define NV34TCL_TX6_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX6_CLIP_PLANE_C(x) (0x00000f88+((x)*16)) ++#define NV34TCL_TX6_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX6_CLIP_PLANE_D(x) (0x00000f8c+((x)*16)) ++#define NV34TCL_TX6_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_TX7_CLIP_PLANE_A(x) (0x00000fc0+((x)*16)) ++#define NV34TCL_TX7_CLIP_PLANE_A__SIZE 0x00000004 ++#define NV34TCL_TX7_CLIP_PLANE_B(x) (0x00000fc4+((x)*16)) ++#define NV34TCL_TX7_CLIP_PLANE_B__SIZE 0x00000004 ++#define NV34TCL_TX7_CLIP_PLANE_C(x) (0x00000fc8+((x)*16)) ++#define NV34TCL_TX7_CLIP_PLANE_C__SIZE 0x00000004 ++#define NV34TCL_TX7_CLIP_PLANE_D(x) (0x00000fcc+((x)*16)) ++#define NV34TCL_TX7_CLIP_PLANE_D__SIZE 0x00000004 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_R(x) (0x00001000+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_R__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_G(x) (0x00001004+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_G__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_B(x) (0x00001008+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_AMBIENT_B__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_R(x) (0x0000100c+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_R__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_G(x) (0x00001010+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_G__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_B(x) (0x00001014+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_DIFFUSE_B__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_R(x) (0x00001018+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_R__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_G(x) (0x0000101c+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_G__SIZE 0x00000008 ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_B(x) (0x00001020+((x)*64)) ++#define NV34TCL_LIGHT_FRONT_SIDE_PRODUCT_SPECULAR_B__SIZE 0x00000008 ++#define NV34TCL_LIGHT_HALF_VECTOR_X(x) (0x00001028+((x)*64)) ++#define NV34TCL_LIGHT_HALF_VECTOR_X__SIZE 0x00000008 ++#define NV34TCL_LIGHT_HALF_VECTOR_Y(x) (0x0000102c+((x)*64)) ++#define NV34TCL_LIGHT_HALF_VECTOR_Y__SIZE 0x00000008 ++#define NV34TCL_LIGHT_HALF_VECTOR_Z(x) (0x00001030+((x)*64)) ++#define NV34TCL_LIGHT_HALF_VECTOR_Z__SIZE 0x00000008 ++#define NV34TCL_LIGHT_DIRECTION_X(x) (0x00001034+((x)*64)) ++#define NV34TCL_LIGHT_DIRECTION_X__SIZE 0x00000008 ++#define NV34TCL_LIGHT_DIRECTION_Y(x) (0x00001038+((x)*64)) ++#define NV34TCL_LIGHT_DIRECTION_Y__SIZE 0x00000008 ++#define NV34TCL_LIGHT_DIRECTION_Z(x) (0x0000103c+((x)*64)) ++#define NV34TCL_LIGHT_DIRECTION_Z__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_CUTOFF_A(x) (0x00001200+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_CUTOFF_A__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_CUTOFF_B(x) (0x00001204+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_CUTOFF_B__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_CUTOFF_C(x) (0x00001208+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_CUTOFF_C__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_DIR_X(x) (0x0000120c+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_DIR_X__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_DIR_Y(x) (0x00001210+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_DIR_Y__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_DIR_Z(x) (0x00001214+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_DIR_Z__SIZE 0x00000008 ++#define NV34TCL_LIGHT_SPOT_CUTOFF_D(x) (0x00001218+((x)*64)) ++#define NV34TCL_LIGHT_SPOT_CUTOFF_D__SIZE 0x00000008 ++#define NV34TCL_LIGHT_POSITION_X(x) (0x0000121c+((x)*64)) ++#define NV34TCL_LIGHT_POSITION_X__SIZE 0x00000008 ++#define NV34TCL_LIGHT_POSITION_Y(x) (0x00001220+((x)*64)) ++#define NV34TCL_LIGHT_POSITION_Y__SIZE 0x00000008 ++#define NV34TCL_LIGHT_POSITION_Z(x) (0x00001224+((x)*64)) ++#define NV34TCL_LIGHT_POSITION_Z__SIZE 0x00000008 ++#define NV34TCL_LIGHT_ATTENUATION_CONSTANT(x) (0x00001228+((x)*64)) ++#define NV34TCL_LIGHT_ATTENUATION_CONSTANT__SIZE 0x00000008 ++#define NV34TCL_LIGHT_ATTENUATION_LINEAR(x) (0x0000122c+((x)*64)) ++#define NV34TCL_LIGHT_ATTENUATION_LINEAR__SIZE 0x00000008 ++#define NV34TCL_LIGHT_ATTENUATION_QUADRATIC(x) (0x00001230+((x)*64)) ++#define NV34TCL_LIGHT_ATTENUATION_QUADRATIC__SIZE 0x00000008 ++#define NV34TCL_FRONT_MATERIAL_SHININESS(x) (0x00001400+((x)*4)) ++#define NV34TCL_FRONT_MATERIAL_SHININESS__SIZE 0x00000006 ++#define NV34TCL_ENABLED_LIGHTS 0x00001420 ++#define NV34TCL_VERTEX_TWO_SIDE_ENABLE 0x0000142c ++#define NV34TCL_FP_REG_CONTROL 0x00001450 ++#define NV34TCL_FP_REG_CONTROL_UNK1_SHIFT 16 ++#define NV34TCL_FP_REG_CONTROL_UNK1_MASK 0xffff0000 ++#define NV34TCL_FP_REG_CONTROL_UNK0_SHIFT 0 ++#define NV34TCL_FP_REG_CONTROL_UNK0_MASK 0x0000ffff ++#define NV34TCL_VP_CLIP_PLANES_ENABLE 0x00001478 ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE0 (1 << 1) ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE1 (1 << 5) ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE2 (1 << 9) ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE3 (1 << 13) ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE4 (1 << 17) ++#define NV34TCL_VP_CLIP_PLANES_ENABLE_PLANE5 (1 << 21) ++#define NV34TCL_POLYGON_STIPPLE_ENABLE 0x0000147c ++#define NV34TCL_POLYGON_STIPPLE_PATTERN(x) (0x00001480+((x)*4)) ++#define NV34TCL_POLYGON_STIPPLE_PATTERN__SIZE 0x00000020 ++#define NV34TCL_VTX_ATTR_3F_X(x) (0x00001500+((x)*16)) ++#define NV34TCL_VTX_ATTR_3F_X__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_3F_Y(x) (0x00001504+((x)*16)) ++#define NV34TCL_VTX_ATTR_3F_Y__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_3F_Z(x) (0x00001508+((x)*16)) ++#define NV34TCL_VTX_ATTR_3F_Z__SIZE 0x00000010 ++#define NV34TCL_VP_CLIP_PLANE_A(x) (0x00001600+((x)*16)) ++#define NV34TCL_VP_CLIP_PLANE_A__SIZE 0x00000006 ++#define NV34TCL_VP_CLIP_PLANE_B(x) (0x00001604+((x)*16)) ++#define NV34TCL_VP_CLIP_PLANE_B__SIZE 0x00000006 ++#define NV34TCL_VP_CLIP_PLANE_C(x) (0x00001608+((x)*16)) ++#define NV34TCL_VP_CLIP_PLANE_C__SIZE 0x00000006 ++#define NV34TCL_VP_CLIP_PLANE_D(x) (0x0000160c+((x)*16)) ++#define NV34TCL_VP_CLIP_PLANE_D__SIZE 0x00000006 ++#define NV34TCL_VTXBUF_ADDRESS(x) (0x00001680+((x)*4)) ++#define NV34TCL_VTXBUF_ADDRESS__SIZE 0x00000010 ++#define NV34TCL_VTXBUF_ADDRESS_DMA1 (1 << 31) ++#define NV34TCL_VTXBUF_ADDRESS_OFFSET_SHIFT 0 ++#define NV34TCL_VTXBUF_ADDRESS_OFFSET_MASK 0x0fffffff ++#define NV34TCL_VTXFMT(x) (0x00001740+((x)*4)) ++#define NV34TCL_VTXFMT__SIZE 0x00000010 ++#define NV34TCL_VTXFMT_TYPE_SHIFT 0 ++#define NV34TCL_VTXFMT_TYPE_MASK 0x0000000f ++#define NV34TCL_VTXFMT_TYPE_FLOAT 0x00000002 ++#define NV34TCL_VTXFMT_TYPE_UBYTE 0x00000004 ++#define NV34TCL_VTXFMT_TYPE_USHORT 0x00000005 ++#define NV34TCL_VTXFMT_SIZE_SHIFT 4 ++#define NV34TCL_VTXFMT_SIZE_MASK 0x000000f0 ++#define NV34TCL_VTXFMT_STRIDE_SHIFT 8 ++#define NV34TCL_VTXFMT_STRIDE_MASK 0x0000ff00 ++#define NV34TCL_LIGHT_MODEL_BACK_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_R 0x000017a0 ++#define NV34TCL_LIGHT_MODEL_BACK_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_G 0x000017a4 ++#define NV34TCL_LIGHT_MODEL_BACK_SIDE_PRODUCT_AMBIENT_PLUS_EMISSION_B 0x000017a8 ++#define NV34TCL_COLOR_MATERIAL_BACK_R 0x000017b0 ++#define NV34TCL_COLOR_MATERIAL_BACK_G 0x000017b4 ++#define NV34TCL_COLOR_MATERIAL_BACK_B 0x000017b8 ++#define NV34TCL_COLOR_MATERIAL_BACK_A 0x000017c0 ++#define NV34TCL_QUERY_RESET 0x000017c8 ++#define NV34TCL_QUERY_UNK17CC 0x000017cc ++#define NV34TCL_QUERY_GET 0x00001800 ++#define NV34TCL_QUERY_GET_UNK24_SHIFT 24 ++#define NV34TCL_QUERY_GET_UNK24_MASK 0xff000000 ++#define NV34TCL_QUERY_GET_OFFSET_SHIFT 0 ++#define NV34TCL_QUERY_GET_OFFSET_MASK 0x00ffffff ++#define NV34TCL_VERTEX_BEGIN_END 0x00001808 ++#define NV34TCL_VERTEX_BEGIN_END_STOP 0x00000000 ++#define NV34TCL_VERTEX_BEGIN_END_POINTS 0x00000001 ++#define NV34TCL_VERTEX_BEGIN_END_LINES 0x00000002 ++#define NV34TCL_VERTEX_BEGIN_END_LINE_LOOP 0x00000003 ++#define NV34TCL_VERTEX_BEGIN_END_LINE_STRIP 0x00000004 ++#define NV34TCL_VERTEX_BEGIN_END_TRIANGLES 0x00000005 ++#define NV34TCL_VERTEX_BEGIN_END_TRIANGLE_STRIP 0x00000006 ++#define NV34TCL_VERTEX_BEGIN_END_TRIANGLE_FAN 0x00000007 ++#define NV34TCL_VERTEX_BEGIN_END_QUADS 0x00000008 ++#define NV34TCL_VERTEX_BEGIN_END_QUAD_STRIP 0x00000009 ++#define NV34TCL_VERTEX_BEGIN_END_POLYGON 0x0000000a ++#define NV34TCL_VB_ELEMENT_U16 0x0000180c ++#define NV34TCL_VB_ELEMENT_U16_I0_SHIFT 0 ++#define NV34TCL_VB_ELEMENT_U16_I0_MASK 0x0000ffff ++#define NV34TCL_VB_ELEMENT_U16_I1_SHIFT 16 ++#define NV34TCL_VB_ELEMENT_U16_I1_MASK 0xffff0000 ++#define NV34TCL_VB_ELEMENT_U32 0x00001810 ++#define NV34TCL_VB_VERTEX_BATCH 0x00001814 ++#define NV34TCL_VB_VERTEX_BATCH_OFFSET_SHIFT 0 ++#define NV34TCL_VB_VERTEX_BATCH_OFFSET_MASK 0x00ffffff ++#define NV34TCL_VB_VERTEX_BATCH_COUNT_SHIFT 24 ++#define NV34TCL_VB_VERTEX_BATCH_COUNT_MASK 0xff000000 ++#define NV34TCL_VERTEX_DATA 0x00001818 ++#define NV34TCL_IDXBUF_ADDRESS 0x0000181c ++#define NV34TCL_IDXBUF_FORMAT 0x00001820 ++#define NV34TCL_IDXBUF_FORMAT_TYPE_SHIFT 4 ++#define NV34TCL_IDXBUF_FORMAT_TYPE_MASK 0x000000f0 ++#define NV34TCL_IDXBUF_FORMAT_TYPE_U32 0x00000000 ++#define NV34TCL_IDXBUF_FORMAT_TYPE_U16 0x00000010 ++#define NV34TCL_IDXBUF_FORMAT_DMA1 (1 << 0) ++#define NV34TCL_VB_INDEX_BATCH 0x00001824 ++#define NV34TCL_VB_INDEX_BATCH_COUNT_SHIFT 24 ++#define NV34TCL_VB_INDEX_BATCH_COUNT_MASK 0xff000000 ++#define NV34TCL_VB_INDEX_BATCH_START_SHIFT 0 ++#define NV34TCL_VB_INDEX_BATCH_START_MASK 0x00ffffff ++#define NV34TCL_POLYGON_MODE_FRONT 0x00001828 ++#define NV34TCL_POLYGON_MODE_FRONT_POINT 0x00001b00 ++#define NV34TCL_POLYGON_MODE_FRONT_LINE 0x00001b01 ++#define NV34TCL_POLYGON_MODE_FRONT_FILL 0x00001b02 ++#define NV34TCL_POLYGON_MODE_BACK 0x0000182c ++#define NV34TCL_POLYGON_MODE_BACK_POINT 0x00001b00 ++#define NV34TCL_POLYGON_MODE_BACK_LINE 0x00001b01 ++#define NV34TCL_POLYGON_MODE_BACK_FILL 0x00001b02 ++#define NV34TCL_CULL_FACE 0x00001830 ++#define NV34TCL_CULL_FACE_FRONT 0x00000404 ++#define NV34TCL_CULL_FACE_BACK 0x00000405 ++#define NV34TCL_CULL_FACE_FRONT_AND_BACK 0x00000408 ++#define NV34TCL_FRONT_FACE 0x00001834 ++#define NV34TCL_FRONT_FACE_CW 0x00000900 ++#define NV34TCL_FRONT_FACE_CCW 0x00000901 ++#define NV34TCL_POLYGON_SMOOTH_ENABLE 0x00001838 ++#define NV34TCL_CULL_FACE_ENABLE 0x0000183c ++#define NV34TCL_TX_PALETTE_OFFSET(x) (0x00001840+((x)*4)) ++#define NV34TCL_TX_PALETTE_OFFSET__SIZE 0x00000008 ++#define NV34TCL_VTX_ATTR_2F_X(x) (0x00001880+((x)*8)) ++#define NV34TCL_VTX_ATTR_2F_X__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_2F_Y(x) (0x00001884+((x)*8)) ++#define NV34TCL_VTX_ATTR_2F_Y__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_2I(x) (0x00001900+((x)*4)) ++#define NV34TCL_VTX_ATTR_2I__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_2I_X_SHIFT 0 ++#define NV34TCL_VTX_ATTR_2I_X_MASK 0x0000ffff ++#define NV34TCL_VTX_ATTR_2I_Y_SHIFT 16 ++#define NV34TCL_VTX_ATTR_2I_Y_MASK 0xffff0000 ++#define NV34TCL_VTX_ATTR_4UB(x) (0x00001940+((x)*4)) ++#define NV34TCL_VTX_ATTR_4UB__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4UB_X_SHIFT 0 ++#define NV34TCL_VTX_ATTR_4UB_X_MASK 0x000000ff ++#define NV34TCL_VTX_ATTR_4UB_Y_SHIFT 8 ++#define NV34TCL_VTX_ATTR_4UB_Y_MASK 0x0000ff00 ++#define NV34TCL_VTX_ATTR_4UB_Z_SHIFT 16 ++#define NV34TCL_VTX_ATTR_4UB_Z_MASK 0x00ff0000 ++#define NV34TCL_VTX_ATTR_4UB_W_SHIFT 24 ++#define NV34TCL_VTX_ATTR_4UB_W_MASK 0xff000000 ++#define NV34TCL_VTX_ATTR_4I_XY(x) (0x00001980+((x)*8)) ++#define NV34TCL_VTX_ATTR_4I_XY__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4I_XY_X_SHIFT 0 ++#define NV34TCL_VTX_ATTR_4I_XY_X_MASK 0x0000ffff ++#define NV34TCL_VTX_ATTR_4I_XY_Y_SHIFT 16 ++#define NV34TCL_VTX_ATTR_4I_XY_Y_MASK 0xffff0000 ++#define NV34TCL_VTX_ATTR_4I_ZW(x) (0x00001984+((x)*8)) ++#define NV34TCL_VTX_ATTR_4I_ZW__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4I_ZW_Z_SHIFT 0 ++#define NV34TCL_VTX_ATTR_4I_ZW_Z_MASK 0x0000ffff ++#define NV34TCL_VTX_ATTR_4I_ZW_W_SHIFT 16 ++#define NV34TCL_VTX_ATTR_4I_ZW_W_MASK 0xffff0000 ++#define NV34TCL_TX_OFFSET(x) (0x00001a00+((x)*32)) ++#define NV34TCL_TX_OFFSET__SIZE 0x00000008 ++#define NV34TCL_TX_FORMAT(x) (0x00001a04+((x)*32)) ++#define NV34TCL_TX_FORMAT__SIZE 0x00000008 ++#define NV34TCL_TX_FORMAT_DMA0 (1 << 0) ++#define NV34TCL_TX_FORMAT_DMA1 (1 << 1) ++#define NV34TCL_TX_FORMAT_CUBIC (1 << 2) ++#define NV34TCL_TX_FORMAT_NO_BORDER (1 << 3) ++#define NV34TCL_TX_FORMAT_DIMS_SHIFT 4 ++#define NV34TCL_TX_FORMAT_DIMS_MASK 0x000000f0 ++#define NV34TCL_TX_FORMAT_DIMS_1D 0x00000010 ++#define NV34TCL_TX_FORMAT_DIMS_2D 0x00000020 ++#define NV34TCL_TX_FORMAT_DIMS_3D 0x00000030 ++#define NV34TCL_TX_FORMAT_FORMAT_SHIFT 8 ++#define NV34TCL_TX_FORMAT_FORMAT_MASK 0x0000ff00 ++#define NV34TCL_TX_FORMAT_FORMAT_L8 0x00000000 ++#define NV34TCL_TX_FORMAT_FORMAT_A8 0x00000100 ++#define NV34TCL_TX_FORMAT_FORMAT_A1R5G5B5 0x00000200 ++#define NV34TCL_TX_FORMAT_FORMAT_A4R4G4B4 0x00000400 ++#define NV34TCL_TX_FORMAT_FORMAT_R5G6B5 0x00000500 ++#define NV34TCL_TX_FORMAT_FORMAT_A8R8G8B8 0x00000600 ++#define NV34TCL_TX_FORMAT_FORMAT_X8R8G8B8 0x00000700 ++#define NV34TCL_TX_FORMAT_FORMAT_INDEX8 0x00000b00 ++#define NV34TCL_TX_FORMAT_FORMAT_DXT1 0x00000c00 ++#define NV34TCL_TX_FORMAT_FORMAT_DXT3 0x00000e00 ++#define NV34TCL_TX_FORMAT_FORMAT_DXT5 0x00000f00 ++#define NV34TCL_TX_FORMAT_FORMAT_A1R5G5B5_RECT 0x00001000 ++#define NV34TCL_TX_FORMAT_FORMAT_R5G6B5_RECT 0x00001100 ++#define NV34TCL_TX_FORMAT_FORMAT_A8R8G8B8_RECT 0x00001200 ++#define NV34TCL_TX_FORMAT_FORMAT_L8_RECT 0x00001300 ++#define NV34TCL_TX_FORMAT_FORMAT_DSDT8_RECT 0x00001700 ++#define NV34TCL_TX_FORMAT_FORMAT_A8L8 0x00001a00 ++#define NV34TCL_TX_FORMAT_FORMAT_A8_RECT 0x00001b00 ++#define NV34TCL_TX_FORMAT_FORMAT_A4R4G4B4_RECT 0x00001d00 ++#define NV34TCL_TX_FORMAT_FORMAT_R8G8B8_RECT 0x00001e00 ++#define NV34TCL_TX_FORMAT_FORMAT_A8L8_RECT 0x00002000 ++#define NV34TCL_TX_FORMAT_FORMAT_DSDT8 0x00002800 ++#define NV34TCL_TX_FORMAT_FORMAT_HILO16 0x00003300 ++#define NV34TCL_TX_FORMAT_FORMAT_HILO16_RECT 0x00003600 ++#define NV34TCL_TX_FORMAT_FORMAT_HILO8 0x00004400 ++#define NV34TCL_TX_FORMAT_FORMAT_SIGNED_HILO8 0x00004500 ++#define NV34TCL_TX_FORMAT_FORMAT_HILO8_RECT 0x00004600 ++#define NV34TCL_TX_FORMAT_FORMAT_SIGNED_HILO8_RECT 0x00004700 ++#define NV34TCL_TX_FORMAT_FORMAT_A16 0x00003200 ++#define NV34TCL_TX_FORMAT_FORMAT_A16_RECT 0x00003500 ++#define NV34TCL_TX_FORMAT_FORMAT_FLOAT_RGBA16_NV 0x00004a00 ++#define NV34TCL_TX_FORMAT_FORMAT_FLOAT_RGBA32_NV 0x00004b00 ++#define NV34TCL_TX_FORMAT_FORMAT_FLOAT_R32_NV 0x00004c00 ++#define NV34TCL_TX_FORMAT_MIPMAP (1 << 19) ++#define NV34TCL_TX_FORMAT_BASE_SIZE_U_SHIFT 20 ++#define NV34TCL_TX_FORMAT_BASE_SIZE_U_MASK 0x00f00000 ++#define NV34TCL_TX_FORMAT_BASE_SIZE_V_SHIFT 24 ++#define NV34TCL_TX_FORMAT_BASE_SIZE_V_MASK 0x0f000000 ++#define NV34TCL_TX_FORMAT_BASE_SIZE_W_SHIFT 28 ++#define NV34TCL_TX_FORMAT_BASE_SIZE_W_MASK 0xf0000000 ++#define NV34TCL_TX_WRAP(x) (0x00001a08+((x)*32)) ++#define NV34TCL_TX_WRAP__SIZE 0x00000008 ++#define NV34TCL_TX_WRAP_S_SHIFT 0 ++#define NV34TCL_TX_WRAP_S_MASK 0x000000ff ++#define NV34TCL_TX_WRAP_S_REPEAT 0x00000001 ++#define NV34TCL_TX_WRAP_S_MIRRORED_REPEAT 0x00000002 ++#define NV34TCL_TX_WRAP_S_CLAMP_TO_EDGE 0x00000003 ++#define NV34TCL_TX_WRAP_S_CLAMP_TO_BORDER 0x00000004 ++#define NV34TCL_TX_WRAP_S_CLAMP 0x00000005 ++#define NV34TCL_TX_WRAP_T_SHIFT 8 ++#define NV34TCL_TX_WRAP_T_MASK 0x00000f00 ++#define NV34TCL_TX_WRAP_T_REPEAT 0x00000100 ++#define NV34TCL_TX_WRAP_T_MIRRORED_REPEAT 0x00000200 ++#define NV34TCL_TX_WRAP_T_CLAMP_TO_EDGE 0x00000300 ++#define NV34TCL_TX_WRAP_T_CLAMP_TO_BORDER 0x00000400 ++#define NV34TCL_TX_WRAP_T_CLAMP 0x00000500 ++#define NV34TCL_TX_WRAP_EXPAND_NORMAL_SHIFT 12 ++#define NV34TCL_TX_WRAP_EXPAND_NORMAL_MASK 0x0000f000 ++#define NV34TCL_TX_WRAP_R_SHIFT 16 ++#define NV34TCL_TX_WRAP_R_MASK 0x000f0000 ++#define NV34TCL_TX_WRAP_R_REPEAT 0x00010000 ++#define NV34TCL_TX_WRAP_R_MIRRORED_REPEAT 0x00020000 ++#define NV34TCL_TX_WRAP_R_CLAMP_TO_EDGE 0x00030000 ++#define NV34TCL_TX_WRAP_R_CLAMP_TO_BORDER 0x00040000 ++#define NV34TCL_TX_WRAP_R_CLAMP 0x00050000 ++#define NV34TCL_TX_WRAP_RCOMP_SHIFT 28 ++#define NV34TCL_TX_WRAP_RCOMP_MASK 0xf0000000 ++#define NV34TCL_TX_WRAP_RCOMP_NEVER 0x00000000 ++#define NV34TCL_TX_WRAP_RCOMP_GREATER 0x10000000 ++#define NV34TCL_TX_WRAP_RCOMP_EQUAL 0x20000000 ++#define NV34TCL_TX_WRAP_RCOMP_GEQUAL 0x30000000 ++#define NV34TCL_TX_WRAP_RCOMP_LESS 0x40000000 ++#define NV34TCL_TX_WRAP_RCOMP_NOTEQUAL 0x50000000 ++#define NV34TCL_TX_WRAP_RCOMP_LEQUAL 0x60000000 ++#define NV34TCL_TX_WRAP_RCOMP_ALWAYS 0x70000000 ++#define NV34TCL_TX_ENABLE(x) (0x00001a0c+((x)*32)) ++#define NV34TCL_TX_ENABLE__SIZE 0x00000008 ++#define NV34TCL_TX_ENABLE_ANISO_SHIFT 4 ++#define NV34TCL_TX_ENABLE_ANISO_MASK 0x00000030 ++#define NV34TCL_TX_ENABLE_ANISO_NONE 0x00000000 ++#define NV34TCL_TX_ENABLE_ANISO_2X 0x00000010 ++#define NV34TCL_TX_ENABLE_ANISO_4X 0x00000020 ++#define NV34TCL_TX_ENABLE_ANISO_8X 0x00000030 ++#define NV34TCL_TX_ENABLE_MIPMAP_MAX_LOD_SHIFT 14 ++#define NV34TCL_TX_ENABLE_MIPMAP_MAX_LOD_MASK 0x0003c000 ++#define NV34TCL_TX_ENABLE_MIPMAP_MIN_LOD_SHIFT 26 ++#define NV34TCL_TX_ENABLE_MIPMAP_MIN_LOD_MASK 0x3c000000 ++#define NV34TCL_TX_ENABLE_ENABLE (1 << 30) ++#define NV34TCL_TX_SWIZZLE(x) (0x00001a10+((x)*32)) ++#define NV34TCL_TX_SWIZZLE__SIZE 0x00000008 ++#define NV34TCL_TX_SWIZZLE_S0_X_SHIFT 14 ++#define NV34TCL_TX_SWIZZLE_S0_X_MASK 0x0000c000 ++#define NV34TCL_TX_SWIZZLE_S0_X_ZERO 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S0_X_ONE 0x00004000 ++#define NV34TCL_TX_SWIZZLE_S0_X_S1 0x00008000 ++#define NV34TCL_TX_SWIZZLE_S0_Y_SHIFT 12 ++#define NV34TCL_TX_SWIZZLE_S0_Y_MASK 0x00003000 ++#define NV34TCL_TX_SWIZZLE_S0_Y_ZERO 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S0_Y_ONE 0x00001000 ++#define NV34TCL_TX_SWIZZLE_S0_Y_S1 0x00002000 ++#define NV34TCL_TX_SWIZZLE_S0_Z_SHIFT 10 ++#define NV34TCL_TX_SWIZZLE_S0_Z_MASK 0x00000c00 ++#define NV34TCL_TX_SWIZZLE_S0_Z_ZERO 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S0_Z_ONE 0x00000400 ++#define NV34TCL_TX_SWIZZLE_S0_Z_S1 0x00000800 ++#define NV34TCL_TX_SWIZZLE_S0_W_SHIFT 8 ++#define NV34TCL_TX_SWIZZLE_S0_W_MASK 0x00000300 ++#define NV34TCL_TX_SWIZZLE_S0_W_ZERO 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S0_W_ONE 0x00000100 ++#define NV34TCL_TX_SWIZZLE_S0_W_S1 0x00000200 ++#define NV34TCL_TX_SWIZZLE_S1_X_SHIFT 6 ++#define NV34TCL_TX_SWIZZLE_S1_X_MASK 0x000000c0 ++#define NV34TCL_TX_SWIZZLE_S1_X_W 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S1_X_Z 0x00000040 ++#define NV34TCL_TX_SWIZZLE_S1_X_Y 0x00000080 ++#define NV34TCL_TX_SWIZZLE_S1_X_X 0x000000c0 ++#define NV34TCL_TX_SWIZZLE_S1_Y_SHIFT 4 ++#define NV34TCL_TX_SWIZZLE_S1_Y_MASK 0x00000030 ++#define NV34TCL_TX_SWIZZLE_S1_Y_W 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S1_Y_Z 0x00000010 ++#define NV34TCL_TX_SWIZZLE_S1_Y_Y 0x00000020 ++#define NV34TCL_TX_SWIZZLE_S1_Y_X 0x00000030 ++#define NV34TCL_TX_SWIZZLE_S1_Z_SHIFT 2 ++#define NV34TCL_TX_SWIZZLE_S1_Z_MASK 0x0000000c ++#define NV34TCL_TX_SWIZZLE_S1_Z_W 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S1_Z_Z 0x00000004 ++#define NV34TCL_TX_SWIZZLE_S1_Z_Y 0x00000008 ++#define NV34TCL_TX_SWIZZLE_S1_Z_X 0x0000000c ++#define NV34TCL_TX_SWIZZLE_S1_W_SHIFT 0 ++#define NV34TCL_TX_SWIZZLE_S1_W_MASK 0x00000003 ++#define NV34TCL_TX_SWIZZLE_S1_W_W 0x00000000 ++#define NV34TCL_TX_SWIZZLE_S1_W_Z 0x00000001 ++#define NV34TCL_TX_SWIZZLE_S1_W_Y 0x00000002 ++#define NV34TCL_TX_SWIZZLE_S1_W_X 0x00000003 ++#define NV34TCL_TX_SWIZZLE_RECT_PITCH_SHIFT 16 ++#define NV34TCL_TX_SWIZZLE_RECT_PITCH_MASK 0xffff0000 ++#define NV34TCL_TX_FILTER(x) (0x00001a14+((x)*32)) ++#define NV34TCL_TX_FILTER__SIZE 0x00000008 ++#define NV34TCL_TX_FILTER_LOD_BIAS_SHIFT 8 ++#define NV34TCL_TX_FILTER_LOD_BIAS_MASK 0x00000f00 ++#define NV34TCL_TX_FILTER_MINIFY_SHIFT 16 ++#define NV34TCL_TX_FILTER_MINIFY_MASK 0x000f0000 ++#define NV34TCL_TX_FILTER_MINIFY_NEAREST 0x00010000 ++#define NV34TCL_TX_FILTER_MINIFY_LINEAR 0x00020000 ++#define NV34TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_NEAREST 0x00030000 ++#define NV34TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_NEAREST 0x00040000 ++#define NV34TCL_TX_FILTER_MINIFY_NEAREST_MIPMAP_LINEAR 0x00050000 ++#define NV34TCL_TX_FILTER_MINIFY_LINEAR_MIPMAP_LINEAR 0x00060000 ++#define NV34TCL_TX_FILTER_MAGNIFY_SHIFT 24 ++#define NV34TCL_TX_FILTER_MAGNIFY_MASK 0x0f000000 ++#define NV34TCL_TX_FILTER_MAGNIFY_NEAREST 0x01000000 ++#define NV34TCL_TX_FILTER_MAGNIFY_LINEAR 0x02000000 ++#define NV34TCL_TX_FILTER_SIGNED_BLUE (1 << 28) ++#define NV34TCL_TX_FILTER_SIGNED_GREEN (1 << 29) ++#define NV34TCL_TX_FILTER_SIGNED_RED (1 << 30) ++#define NV34TCL_TX_FILTER_SIGNED_ALPHA (1 << 31) ++#define NV34TCL_TX_NPOT_SIZE(x) (0x00001a18+((x)*32)) ++#define NV34TCL_TX_NPOT_SIZE__SIZE 0x00000008 ++#define NV34TCL_TX_NPOT_SIZE_H_SHIFT 0 ++#define NV34TCL_TX_NPOT_SIZE_H_MASK 0x0000ffff ++#define NV34TCL_TX_NPOT_SIZE_W_SHIFT 16 ++#define NV34TCL_TX_NPOT_SIZE_W_MASK 0xffff0000 ++#define NV34TCL_TX_BORDER_COLOR(x) (0x00001a1c+((x)*32)) ++#define NV34TCL_TX_BORDER_COLOR__SIZE 0x00000008 ++#define NV34TCL_TX_BORDER_COLOR_B_SHIFT 0 ++#define NV34TCL_TX_BORDER_COLOR_B_MASK 0x000000ff ++#define NV34TCL_TX_BORDER_COLOR_G_SHIFT 8 ++#define NV34TCL_TX_BORDER_COLOR_G_MASK 0x0000ff00 ++#define NV34TCL_TX_BORDER_COLOR_R_SHIFT 16 ++#define NV34TCL_TX_BORDER_COLOR_R_MASK 0x00ff0000 ++#define NV34TCL_TX_BORDER_COLOR_A_SHIFT 24 ++#define NV34TCL_TX_BORDER_COLOR_A_MASK 0xff000000 ++#define NV34TCL_VTX_ATTR_4F_X(x) (0x00001c00+((x)*16)) ++#define NV34TCL_VTX_ATTR_4F_X__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4F_Y(x) (0x00001c04+((x)*16)) ++#define NV34TCL_VTX_ATTR_4F_Y__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4F_Z(x) (0x00001c08+((x)*16)) ++#define NV34TCL_VTX_ATTR_4F_Z__SIZE 0x00000010 ++#define NV34TCL_VTX_ATTR_4F_W(x) (0x00001c0c+((x)*16)) ++#define NV34TCL_VTX_ATTR_4F_W__SIZE 0x00000010 ++#define NV34TCL_FP_CONTROL 0x00001d60 ++#define NV34TCL_FP_CONTROL_USES_KIL (1 << 7) ++#define NV34TCL_FP_CONTROL_USED_REGS_MINUS1_DIV2_SHIFT 0 ++#define NV34TCL_FP_CONTROL_USED_REGS_MINUS1_DIV2_MASK 0x0000000f ++#define NV34TCL_DEPTH_UNK17D8 0x00001d78 ++#define NV34TCL_DEPTH_UNK17D8_CLAMP_SHIFT 4 ++#define NV34TCL_DEPTH_UNK17D8_CLAMP_MASK 0x000000f0 ++#define NV34TCL_MULTISAMPLE_CONTROL 0x00001d7c ++#define NV34TCL_MULTISAMPLE_CONTROL_ENABLE (1 << 0) ++#define NV34TCL_MULTISAMPLE_CONTROL_SAMPLE_ALPHA_TO_COVERAGE (1 << 4) ++#define NV34TCL_MULTISAMPLE_CONTROL_SAMPLE_ALPHA_TO_ONE (1 << 8) ++#define NV34TCL_MULTISAMPLE_CONTROL_SAMPLE_COVERAGE_SHIFT 16 ++#define NV34TCL_MULTISAMPLE_CONTROL_SAMPLE_COVERAGE_MASK 0xffff0000 ++#define NV34TCL_CLEAR_DEPTH_VALUE 0x00001d8c ++#define NV34TCL_CLEAR_COLOR_VALUE 0x00001d90 ++#define NV34TCL_CLEAR_COLOR_VALUE_B_SHIFT 0 ++#define NV34TCL_CLEAR_COLOR_VALUE_B_MASK 0x000000ff ++#define NV34TCL_CLEAR_COLOR_VALUE_G_SHIFT 8 ++#define NV34TCL_CLEAR_COLOR_VALUE_G_MASK 0x0000ff00 ++#define NV34TCL_CLEAR_COLOR_VALUE_R_SHIFT 16 ++#define NV34TCL_CLEAR_COLOR_VALUE_R_MASK 0x00ff0000 ++#define NV34TCL_CLEAR_COLOR_VALUE_A_SHIFT 24 ++#define NV34TCL_CLEAR_COLOR_VALUE_A_MASK 0xff000000 ++#define NV34TCL_CLEAR_BUFFERS 0x00001d94 ++#define NV34TCL_CLEAR_BUFFERS_COLOR_A (1 << 7) ++#define NV34TCL_CLEAR_BUFFERS_COLOR_B (1 << 6) ++#define NV34TCL_CLEAR_BUFFERS_COLOR_G (1 << 5) ++#define NV34TCL_CLEAR_BUFFERS_COLOR_R (1 << 4) ++#define NV34TCL_CLEAR_BUFFERS_STENCIL (1 << 1) ++#define NV34TCL_CLEAR_BUFFERS_DEPTH (1 << 0) ++#define NV34TCL_DO_VERTICES 0x00001dac ++#define NV34TCL_LINE_STIPPLE_ENABLE 0x00001db4 ++#define NV34TCL_LINE_STIPPLE_PATTERN 0x00001db8 ++#define NV34TCL_LINE_STIPPLE_PATTERN_FACTOR_SHIFT 0 ++#define NV34TCL_LINE_STIPPLE_PATTERN_FACTOR_MASK 0x0000ffff ++#define NV34TCL_LINE_STIPPLE_PATTERN_PATTERN_SHIFT 16 ++#define NV34TCL_LINE_STIPPLE_PATTERN_PATTERN_MASK 0xffff0000 ++#define NV34TCL_BACK_MATERIAL_SHININESS(x) (0x00001e20+((x)*4)) ++#define NV34TCL_BACK_MATERIAL_SHININESS__SIZE 0x00000006 ++#define NV34TCL_VTX_ATTR_1F(x) (0x00001e40+((x)*4)) ++#define NV34TCL_VTX_ATTR_1F__SIZE 0x00000010 ++#define NV34TCL_ENGINE 0x00001e94 ++#define NV34TCL_ENGINE_FP (1 << 0) ++#define NV34TCL_ENGINE_VP (1 << 1) ++#define NV34TCL_ENGINE_FIXED (1 << 2) ++#define NV34TCL_VP_UPLOAD_FROM_ID 0x00001e9c ++#define NV34TCL_VP_START_FROM_ID 0x00001ea0 ++#define NV34TCL_POINT_PARAMETERS(x) (0x00001ec0+((x)*4)) ++#define NV34TCL_POINT_PARAMETERS__SIZE 0x00000008 ++#define NV34TCL_POINT_SIZE 0x00001ee0 ++#define NV34TCL_POINT_PARAMETERS_ENABLE 0x00001ee4 ++#define NV34TCL_POINT_SPRITE 0x00001ee8 ++#define NV34TCL_POINT_SPRITE_ENABLE (1 << 0) ++#define NV34TCL_POINT_SPRITE_R_MODE_SHIFT 1 ++#define NV34TCL_POINT_SPRITE_R_MODE_MASK 0x00000006 ++#define NV34TCL_POINT_SPRITE_R_MODE_ZERO 0x00000000 ++#define NV34TCL_POINT_SPRITE_R_MODE_R 0x00000002 ++#define NV34TCL_POINT_SPRITE_R_MODE_S 0x00000004 ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_0 (1 << 8) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_1 (1 << 9) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_2 (1 << 10) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_3 (1 << 11) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_4 (1 << 12) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_5 (1 << 13) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_6 (1 << 14) ++#define NV34TCL_POINT_SPRITE_COORD_REPLACE_7 (1 << 15) ++#define NV34TCL_VP_UPLOAD_CONST_ID 0x00001efc ++#define NV34TCL_VP_UPLOAD_CONST_X(x) (0x00001f00+((x)*16)) ++#define NV34TCL_VP_UPLOAD_CONST_X__SIZE 0x00000004 ++#define NV34TCL_VP_UPLOAD_CONST_Y(x) (0x00001f04+((x)*16)) ++#define NV34TCL_VP_UPLOAD_CONST_Y__SIZE 0x00000004 ++#define NV34TCL_VP_UPLOAD_CONST_Z(x) (0x00001f08+((x)*16)) ++#define NV34TCL_VP_UPLOAD_CONST_Z__SIZE 0x00000004 ++#define NV34TCL_VP_UPLOAD_CONST_W(x) (0x00001f0c+((x)*16)) ++#define NV34TCL_VP_UPLOAD_CONST_W__SIZE 0x00000004 ++#define NV34TCL_UNK1f80(x) (0x00001f80+((x)*4)) ++#define NV34TCL_UNK1f80__SIZE 0x00000010 ++ ++ ++#define NV40TCL 0x00004097 ++ ++#define NV40TCL_REF_CNT 0x00000050 ++#define NV40TCL_NOP 0x00000100 ++#define NV40TCL_NOTIFY 0x00000104 ++#define NV40TCL_DMA_NOTIFY 0x00000180 ++#define NV40TCL_DMA_TEXTURE0 0x00000184 ++#define NV40TCL_DMA_TEXTURE1 0x00000188 ++#define NV40TCL_DMA_COLOR1 0x0000018c ++#define NV40TCL_DMA_COLOR0 0x00000194 ++#define NV40TCL_DMA_ZETA 0x00000198 ++#define NV40TCL_DMA_VTXBUF0 0x0000019c ++#define NV40TCL_DMA_VTXBUF1 0x000001a0 ++#define NV40TCL_DMA_FENCE 0x000001a4 ++#define NV40TCL_DMA_QUERY 0x000001a8 ++#define NV40TCL_DMA_UNK01AC 0x000001ac ++#define NV40TCL_DMA_UNK01B0 0x000001b0 ++#define NV40TCL_DMA_COLOR2 0x000001b4 ++#define NV40TCL_DMA_COLOR3 0x000001b8 ++#define NV40TCL_RT_HORIZ 0x00000200 ++#define NV40TCL_RT_HORIZ_W_SHIFT 16 ++#define NV40TCL_RT_HORIZ_W_MASK 0xffff0000 ++#define NV40TCL_RT_HORIZ_X_SHIFT 0 ++#define NV40TCL_RT_HORIZ_X_MASK 0x0000ffff ++#define NV40TCL_RT_VERT 0x00000204 ++#define NV40TCL_RT_VERT_H_SHIFT 16 ++#define NV40TCL_RT_VERT_H_MASK 0xffff0000 ++#define NV40TCL_RT_VERT_Y_SHIFT 0 ++#define NV40TCL_RT_VERT_Y_MASK 0x0000ffff ++#define NV40TCL_RT_FORMAT 0x00000208 ++#define NV40TCL_RT_FORMAT_LOG2_HEIGHT_SHIFT 24 ++#define NV40TCL_RT_FORMAT_LOG2_HEIGHT_MASK 0xff000000 ++#define NV40TCL_RT_FORMAT_LOG2_WIDTH_SHIFT 16 ++#define NV40TCL_RT_FORMAT_LOG2_WIDTH_MASK 0x00ff0000 ++#define NV40TCL_RT_FORMAT_TYPE_SHIFT 8 ++#define NV40TCL_RT_FORMAT_TYPE_MASK 0x00000f00 ++#define NV40TCL_RT_FORMAT_TYPE_LINEAR 0x00000100 ++#define NV40TCL_RT_FORMAT_TYPE_SWIZZLED 0x00000200 ++#define NV40TCL_RT_FORMAT_ZETA_SHIFT 5 ++#define NV40TCL_RT_FORMAT_ZETA_MASK 0x000000e0 ++#define NV40TCL_RT_FORMAT_ZETA_Z16 0x00000020 ++#define NV40TCL_RT_FORMAT_ZETA_Z24S8 0x00000040 ++#define NV40TCL_RT_FORMAT_COLOR_SHIFT 0 ++#define NV40TCL_RT_FORMAT_COLOR_MASK 0x0000001f ++#define NV40TCL_RT_FORMAT_COLOR_R5G6B5 0x00000003 ++#define NV40TCL_RT_FORMAT_COLOR_X8R8G8B8 0x00000005 ++#define NV40TCL_RT_FORMAT_COLOR_A8R8G8B8 0x00000008 ++#define NV40TCL_RT_FORMAT_COLOR_B8 0x00000009 ++#define NV40TCL_RT_FORMAT_COLOR_UNKNOWN 0x0000000d ++#define NV40TCL_RT_FORMAT_COLOR_X8B8G8R8 0x0000000f ++#define NV40TCL_RT_FORMAT_COLOR_A8B8G8R8 0x00000010 ++#define NV40TCL_COLOR0_PITCH 0x0000020c ++#define NV40TCL_COLOR0_OFFSET 0x00000210 ++#define NV40TCL_ZETA_OFFSET 0x00000214 ++#define NV40TCL_COLOR1_OFFSET 0x00000218 ++#define NV40TCL_COLOR1_PITCH 0x0000021c ++#define NV40TCL_RT_ENABLE 0x00000220 ++#define NV40TCL_RT_ENABLE_MRT (1 << 4) ++#define NV40TCL_RT_ENABLE_COLOR3 (1 << 3) ++#define NV40TCL_RT_ENABLE_COLOR2 (1 << 2) ++#define NV40TCL_RT_ENABLE_COLOR1 (1 << 1) ++#define NV40TCL_RT_ENABLE_COLOR0 (1 << 0) ++#define NV40TCL_ZETA_PITCH 0x0000022c ++#define NV40TCL_COLOR2_PITCH 0x00000280 ++#define NV40TCL_COLOR3_PITCH 0x00000284 ++#define NV40TCL_COLOR2_OFFSET 0x00000288 ++#define NV40TCL_COLOR3_OFFSET 0x0000028c ++#define NV40TCL_VIEWPORT_CLIP_HORIZ(x) (0x000002c0+((x)*8)) ++#define NV40TCL_VIEWPORT_CLIP_HORIZ__SIZE 0x00000008 ++#define NV40TCL_VIEWPORT_CLIP_VERT(x) (0x000002c4+((x)*8)) ++#define NV40TCL_VIEWPORT_CLIP_VERT__SIZE 0x00000008 ++#define NV40TCL_DITHER_ENABLE 0x00000300 ++#define NV40TCL_ALPHA_TEST_ENABLE 0x00000304 ++#define NV40TCL_ALPHA_TEST_FUNC 0x00000308 ++#define NV40TCL_ALPHA_TEST_FUNC_NEVER 0x00000200 ++#define NV40TCL_ALPHA_TEST_FUNC_LESS 0x00000201 ++#define NV40TCL_ALPHA_TEST_FUNC_EQUAL 0x00000202 ++#define NV40TCL_ALPHA_TEST_FUNC_LEQUAL 0x00000203 ++#define NV40TCL_ALPHA_TEST_FUNC_GREATER 0x00000204 ++#define NV40TCL_ALPHA_TEST_FUNC_NOTEQUAL 0x00000205 ++#define NV40TCL_ALPHA_TEST_FUNC_GEQUAL 0x00000206 ++#define NV40TCL_ALPHA_TEST_FUNC_ALWAYS 0x00000207 ++#define NV40TCL_ALPHA_TEST_REF 0x0000030c ++#define NV40TCL_BLEND_ENABLE 0x00000310 ++#define NV40TCL_BLEND_FUNC_SRC 0x00000314 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_SHIFT 0 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_MASK 0x0000ffff ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ZERO 0x00000000 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE 0x00000001 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_SRC_COLOR 0x00000300 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA 0x00000302 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_DST_ALPHA 0x00000304 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_DST_COLOR 0x00000306 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_CONSTANT_COLOR 0x00008001 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV40TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_SHIFT 16 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_MASK 0xffff0000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ZERO 0x00000000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE 0x00010000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_SRC_COLOR 0x03000000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_COLOR 0x03010000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA 0x03020000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_ALPHA 0x03030000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_DST_ALPHA 0x03040000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_ALPHA 0x03050000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_DST_COLOR 0x03060000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_COLOR 0x03070000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA_SATURATE 0x03080000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_COLOR 0x80010000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x80020000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_ALPHA 0x80030000 ++#define NV40TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x80040000 ++#define NV40TCL_BLEND_FUNC_DST 0x00000318 ++#define NV40TCL_BLEND_FUNC_DST_RGB_SHIFT 0 ++#define NV40TCL_BLEND_FUNC_DST_RGB_MASK 0x0000ffff ++#define NV40TCL_BLEND_FUNC_DST_RGB_ZERO 0x00000000 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE 0x00000001 ++#define NV40TCL_BLEND_FUNC_DST_RGB_SRC_COLOR 0x00000300 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV40TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA 0x00000302 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV40TCL_BLEND_FUNC_DST_RGB_DST_ALPHA 0x00000304 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV40TCL_BLEND_FUNC_DST_RGB_DST_COLOR 0x00000306 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV40TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV40TCL_BLEND_FUNC_DST_RGB_CONSTANT_COLOR 0x00008001 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV40TCL_BLEND_FUNC_DST_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV40TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_SHIFT 16 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_MASK 0xffff0000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ZERO 0x00000000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE 0x00010000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_SRC_COLOR 0x03000000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_COLOR 0x03010000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA 0x03020000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_ALPHA 0x03030000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_DST_ALPHA 0x03040000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_ALPHA 0x03050000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_DST_COLOR 0x03060000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_COLOR 0x03070000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA_SATURATE 0x03080000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_COLOR 0x80010000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x80020000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_ALPHA 0x80030000 ++#define NV40TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x80040000 ++#define NV40TCL_BLEND_COLOR 0x0000031c ++#define NV40TCL_BLEND_COLOR_B_SHIFT 0 ++#define NV40TCL_BLEND_COLOR_B_MASK 0x000000ff ++#define NV40TCL_BLEND_COLOR_G_SHIFT 8 ++#define NV40TCL_BLEND_COLOR_G_MASK 0x0000ff00 ++#define NV40TCL_BLEND_COLOR_R_SHIFT 16 ++#define NV40TCL_BLEND_COLOR_R_MASK 0x00ff0000 ++#define NV40TCL_BLEND_COLOR_A_SHIFT 24 ++#define NV40TCL_BLEND_COLOR_A_MASK 0xff000000 ++#define NV40TCL_BLEND_EQUATION 0x00000320 ++#define NV40TCL_BLEND_EQUATION_RGB_SHIFT 0 ++#define NV40TCL_BLEND_EQUATION_RGB_MASK 0x0000ffff ++#define NV40TCL_BLEND_EQUATION_RGB_FUNC_ADD 0x00008006 ++#define NV40TCL_BLEND_EQUATION_RGB_MIN 0x00008007 ++#define NV40TCL_BLEND_EQUATION_RGB_MAX 0x00008008 ++#define NV40TCL_BLEND_EQUATION_RGB_FUNC_SUBTRACT 0x0000800a ++#define NV40TCL_BLEND_EQUATION_RGB_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV40TCL_BLEND_EQUATION_ALPHA_SHIFT 16 ++#define NV40TCL_BLEND_EQUATION_ALPHA_MASK 0xffff0000 ++#define NV40TCL_BLEND_EQUATION_ALPHA_FUNC_ADD 0x80060000 ++#define NV40TCL_BLEND_EQUATION_ALPHA_MIN 0x80070000 ++#define NV40TCL_BLEND_EQUATION_ALPHA_MAX 0x80080000 ++#define NV40TCL_BLEND_EQUATION_ALPHA_FUNC_SUBTRACT 0x800a0000 ++#define NV40TCL_BLEND_EQUATION_ALPHA_FUNC_REVERSE_SUBTRACT 0x800b0000 ++#define NV40TCL_COLOR_MASK 0x00000324 ++#define NV40TCL_COLOR_MASK_BUFFER0_B_SHIFT 0 ++#define NV40TCL_COLOR_MASK_BUFFER0_B_MASK 0x000000ff ++#define NV40TCL_COLOR_MASK_BUFFER0_G_SHIFT 8 ++#define NV40TCL_COLOR_MASK_BUFFER0_G_MASK 0x0000ff00 ++#define NV40TCL_COLOR_MASK_BUFFER0_R_SHIFT 16 ++#define NV40TCL_COLOR_MASK_BUFFER0_R_MASK 0x00ff0000 ++#define NV40TCL_COLOR_MASK_BUFFER0_A_SHIFT 24 ++#define NV40TCL_COLOR_MASK_BUFFER0_A_MASK 0xff000000 ++#define NV40TCL_STENCIL_FRONT_ENABLE 0x00000328 ++#define NV40TCL_STENCIL_FRONT_MASK 0x0000032c ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC 0x00000330 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_NEVER 0x00000200 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_LESS 0x00000201 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_EQUAL 0x00000202 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_GREATER 0x00000204 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV40TCL_STENCIL_FRONT_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV40TCL_STENCIL_FRONT_FUNC_REF 0x00000334 ++#define NV40TCL_STENCIL_FRONT_FUNC_MASK 0x00000338 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL 0x0000033c ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_ZERO 0x00000000 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_INVERT 0x0000150a ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_INCR 0x00001e02 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_DECR 0x00001e03 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_FRONT_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL 0x00000340 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_ZERO 0x00000000 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_INVERT 0x0000150a ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_INCR 0x00001e02 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_DECR 0x00001e03 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_FRONT_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS 0x00000344 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_ZERO 0x00000000 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_INVERT 0x0000150a ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_INCR 0x00001e02 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_DECR 0x00001e03 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_FRONT_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV40TCL_STENCIL_BACK_ENABLE 0x00000348 ++#define NV40TCL_STENCIL_BACK_MASK 0x0000034c ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC 0x00000350 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_NEVER 0x00000200 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_LESS 0x00000201 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_EQUAL 0x00000202 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_GREATER 0x00000204 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV40TCL_STENCIL_BACK_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV40TCL_STENCIL_BACK_FUNC_REF 0x00000354 ++#define NV40TCL_STENCIL_BACK_FUNC_MASK 0x00000358 ++#define NV40TCL_STENCIL_BACK_OP_FAIL 0x0000035c ++#define NV40TCL_STENCIL_BACK_OP_FAIL_ZERO 0x00000000 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_INVERT 0x0000150a ++#define NV40TCL_STENCIL_BACK_OP_FAIL_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_INCR 0x00001e02 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_DECR 0x00001e03 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_BACK_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL 0x00000360 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_ZERO 0x00000000 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_INVERT 0x0000150a ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_INCR 0x00001e02 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_DECR 0x00001e03 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_BACK_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS 0x00000364 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_ZERO 0x00000000 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_INVERT 0x0000150a ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_KEEP 0x00001e00 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_REPLACE 0x00001e01 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_INCR 0x00001e02 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_DECR 0x00001e03 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV40TCL_STENCIL_BACK_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV40TCL_SHADE_MODEL 0x00000368 ++#define NV40TCL_SHADE_MODEL_FLAT 0x00001d00 ++#define NV40TCL_SHADE_MODEL_SMOOTH 0x00001d01 ++#define NV40TCL_MRT_COLOR_MASK 0x00000370 ++#define NV40TCL_MRT_COLOR_MASK_BUFFER1_A (1 << 4) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER1_R (1 << 5) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER1_G (1 << 6) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER1_B (1 << 7) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER2_A (1 << 8) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER2_R (1 << 9) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER2_G (1 << 10) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER2_B (1 << 11) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER3_A (1 << 12) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER3_R (1 << 13) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER3_G (1 << 14) ++#define NV40TCL_MRT_COLOR_MASK_BUFFER3_B (1 << 15) ++#define NV40TCL_COLOR_LOGIC_OP_ENABLE 0x00000374 ++#define NV40TCL_COLOR_LOGIC_OP 0x00000378 ++#define NV40TCL_COLOR_LOGIC_OP_CLEAR 0x00001500 ++#define NV40TCL_COLOR_LOGIC_OP_AND 0x00001501 ++#define NV40TCL_COLOR_LOGIC_OP_AND_REVERSE 0x00001502 ++#define NV40TCL_COLOR_LOGIC_OP_COPY 0x00001503 ++#define NV40TCL_COLOR_LOGIC_OP_AND_INVERTED 0x00001504 ++#define NV40TCL_COLOR_LOGIC_OP_NOOP 0x00001505 ++#define NV40TCL_COLOR_LOGIC_OP_XOR 0x00001506 ++#define NV40TCL_COLOR_LOGIC_OP_OR 0x00001507 ++#define NV40TCL_COLOR_LOGIC_OP_NOR 0x00001508 ++#define NV40TCL_COLOR_LOGIC_OP_EQUIV 0x00001509 ++#define NV40TCL_COLOR_LOGIC_OP_INVERT 0x0000150a ++#define NV40TCL_COLOR_LOGIC_OP_OR_REVERSE 0x0000150b ++#define NV40TCL_COLOR_LOGIC_OP_COPY_INVERTED 0x0000150c ++#define NV40TCL_COLOR_LOGIC_OP_OR_INVERTED 0x0000150d ++#define NV40TCL_COLOR_LOGIC_OP_NAND 0x0000150e ++#define NV40TCL_COLOR_LOGIC_OP_SET 0x0000150f ++#define NV40TCL_DEPTH_RANGE_NEAR 0x00000394 ++#define NV40TCL_DEPTH_RANGE_FAR 0x00000398 ++#define NV40TCL_LINE_WIDTH 0x000003b8 ++#define NV40TCL_LINE_SMOOTH_ENABLE 0x000003bc ++#define NV40TCL_UNK03C0(x) (0x000003c0+((x)*4)) ++#define NV40TCL_UNK03C0__SIZE 0x00000010 ++#define NV40TCL_UNK0400(x) (0x00000400+((x)*4)) ++#define NV40TCL_UNK0400__SIZE 0x00000010 ++#define NV40TCL_UNK0440(x) (0x00000440+((x)*4)) ++#define NV40TCL_UNK0440__SIZE 0x00000020 ++#define NV40TCL_SCISSOR_HORIZ 0x000008c0 ++#define NV40TCL_SCISSOR_HORIZ_X_SHIFT 0 ++#define NV40TCL_SCISSOR_HORIZ_X_MASK 0x0000ffff ++#define NV40TCL_SCISSOR_HORIZ_W_SHIFT 16 ++#define NV40TCL_SCISSOR_HORIZ_W_MASK 0xffff0000 ++#define NV40TCL_SCISSOR_VERT 0x000008c4 ++#define NV40TCL_SCISSOR_VERT_Y_SHIFT 0 ++#define NV40TCL_SCISSOR_VERT_Y_MASK 0x0000ffff ++#define NV40TCL_SCISSOR_VERT_H_SHIFT 16 ++#define NV40TCL_SCISSOR_VERT_H_MASK 0xffff0000 ++#define NV40TCL_FOG_MODE 0x000008cc ++#define NV40TCL_FOG_EQUATION_CONSTANT 0x000008d0 ++#define NV40TCL_FOG_EQUATION_LINEAR 0x000008d4 ++#define NV40TCL_FOG_EQUATION_QUADRATIC 0x000008d8 ++#define NV40TCL_FP_ADDRESS 0x000008e4 ++#define NV40TCL_FP_ADDRESS_OFFSET_SHIFT 8 ++#define NV40TCL_FP_ADDRESS_OFFSET_MASK 0xffffff00 ++#define NV40TCL_FP_ADDRESS_DMA1 (1 << 1) ++#define NV40TCL_FP_ADDRESS_DMA0 (1 << 0) ++#define NV40TCL_VIEWPORT_HORIZ 0x00000a00 ++#define NV40TCL_VIEWPORT_HORIZ_W_SHIFT 16 ++#define NV40TCL_VIEWPORT_HORIZ_W_MASK 0xffff0000 ++#define NV40TCL_VIEWPORT_HORIZ_X_SHIFT 0 ++#define NV40TCL_VIEWPORT_HORIZ_X_MASK 0x0000ffff ++#define NV40TCL_VIEWPORT_VERT 0x00000a04 ++#define NV40TCL_VIEWPORT_VERT_H_SHIFT 16 ++#define NV40TCL_VIEWPORT_VERT_H_MASK 0xffff0000 ++#define NV40TCL_VIEWPORT_VERT_Y_SHIFT 0 ++#define NV40TCL_VIEWPORT_VERT_Y_MASK 0x0000ffff ++#define NV40TCL_VIEWPORT_TRANSLATE_X 0x00000a20 ++#define NV40TCL_VIEWPORT_TRANSLATE_Y 0x00000a24 ++#define NV40TCL_VIEWPORT_TRANSLATE_Z 0x00000a28 ++#define NV40TCL_VIEWPORT_TRANSLATE_W 0x00000a2c ++#define NV40TCL_VIEWPORT_SCALE_X 0x00000a30 ++#define NV40TCL_VIEWPORT_SCALE_Y 0x00000a34 ++#define NV40TCL_VIEWPORT_SCALE_Z 0x00000a38 ++#define NV40TCL_VIEWPORT_SCALE_W 0x00000a3c ++#define NV40TCL_POLYGON_OFFSET_POINT_ENABLE 0x00000a60 ++#define NV40TCL_POLYGON_OFFSET_LINE_ENABLE 0x00000a64 ++#define NV40TCL_POLYGON_OFFSET_FILL_ENABLE 0x00000a68 ++#define NV40TCL_DEPTH_FUNC 0x00000a6c ++#define NV40TCL_DEPTH_FUNC_NEVER 0x00000200 ++#define NV40TCL_DEPTH_FUNC_LESS 0x00000201 ++#define NV40TCL_DEPTH_FUNC_EQUAL 0x00000202 ++#define NV40TCL_DEPTH_FUNC_LEQUAL 0x00000203 ++#define NV40TCL_DEPTH_FUNC_GREATER 0x00000204 ++#define NV40TCL_DEPTH_FUNC_NOTEQUAL 0x00000205 ++#define NV40TCL_DEPTH_FUNC_GEQUAL 0x00000206 ++#define NV40TCL_DEPTH_FUNC_ALWAYS 0x00000207 ++#define NV40TCL_DEPTH_WRITE_ENABLE 0x00000a70 ++#define NV40TCL_DEPTH_TEST_ENABLE 0x00000a74 ++#define NV40TCL_POLYGON_OFFSET_FACTOR 0x00000a78 ++#define NV40TCL_POLYGON_OFFSET_UNITS 0x00000a7c ++#define NV40TCL_VTX_ATTR_3I_XY(x) (0x00000a80+((x)*8)) ++#define NV40TCL_VTX_ATTR_3I_XY__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_3I_XY_X_SHIFT 0 ++#define NV40TCL_VTX_ATTR_3I_XY_X_MASK 0x0000ffff ++#define NV40TCL_VTX_ATTR_3I_XY_Y_SHIFT 16 ++#define NV40TCL_VTX_ATTR_3I_XY_Y_MASK 0xffff0000 ++#define NV40TCL_VTX_ATTR_3I_Z(x) (0x00000a84+((x)*8)) ++#define NV40TCL_VTX_ATTR_3I_Z__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_3I_Z_Z_SHIFT 0 ++#define NV40TCL_VTX_ATTR_3I_Z_Z_MASK 0x0000ffff ++#define NV40TCL_TEX_FILTER_OPTIMIZATION 0x00000b00 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_SHIFT 0 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_MASK 0x0000001f ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_OFF 0x00000000 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_HIGH_QUALITY 0x00000004 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_QUALITY 0x00000006 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_PERFORMANCE 0x00000008 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_TRILINEAR_HIGH_PERFORMANCE 0x00000018 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_SHIFT 6 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_MASK 0x000001c0 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_OFF 0x00000000 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_HIGH_QUALITY 0x000000c0 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_QUALITY 0x000001c0 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_ANISO_SAMPLE_PERFORMANCE 0x00000140 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_UNKNOWN_SHIFT 10 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_UNKNOWN_MASK 0x00007c00 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_UNKNOWN_OFF 0x00000000 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_UNKNOWN_PARTIAL 0x00002c00 ++#define NV40TCL_TEX_FILTER_OPTIMIZATION_UNKNOWN_FULL 0x00007c00 ++#define NV40TCL_UNK0B40(x) (0x00000b40+((x)*4)) ++#define NV40TCL_UNK0B40__SIZE 0x00000008 ++#define NV40TCL_VP_UPLOAD_INST(x) (0x00000b80+((x)*4)) ++#define NV40TCL_VP_UPLOAD_INST__SIZE 0x00000004 ++#define NV40TCL_VERTEX_TWO_SIDE_ENABLE 0x0000142c ++#define NV40TCL_CLIP_PLANE_ENABLE 0x00001478 ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE0 (1 << 1) ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE1 (1 << 5) ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE2 (1 << 9) ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE3 (1 << 13) ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE4 (1 << 17) ++#define NV40TCL_CLIP_PLANE_ENABLE_PLANE5 (1 << 21) ++#define NV40TCL_POLYGON_STIPPLE_ENABLE 0x0000147c ++#define NV40TCL_POLYGON_STIPPLE_PATTERN(x) (0x00001480+((x)*4)) ++#define NV40TCL_POLYGON_STIPPLE_PATTERN__SIZE 0x00000020 ++#define NV40TCL_VTX_ATTR_3F_X(x) (0x00001500+((x)*16)) ++#define NV40TCL_VTX_ATTR_3F_X__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_3F_Y(x) (0x00001504+((x)*16)) ++#define NV40TCL_VTX_ATTR_3F_Y__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_3F_Z(x) (0x00001508+((x)*16)) ++#define NV40TCL_VTX_ATTR_3F_Z__SIZE 0x00000010 ++#define NV40TCL_VTXBUF_ADDRESS(x) (0x00001680+((x)*4)) ++#define NV40TCL_VTXBUF_ADDRESS__SIZE 0x00000010 ++#define NV40TCL_VTXBUF_ADDRESS_DMA1 (1 << 31) ++#define NV40TCL_VTXBUF_ADDRESS_OFFSET_SHIFT 0 ++#define NV40TCL_VTXBUF_ADDRESS_OFFSET_MASK 0x0fffffff ++#define NV40TCL_VTX_CACHE_INVALIDATE 0x00001714 ++#define NV40TCL_VTXFMT(x) (0x00001740+((x)*4)) ++#define NV40TCL_VTXFMT__SIZE 0x00000010 ++#define NV40TCL_VTXFMT_TYPE_SHIFT 0 ++#define NV40TCL_VTXFMT_TYPE_MASK 0x0000000f ++#define NV40TCL_VTXFMT_TYPE_FLOAT 0x00000002 ++#define NV40TCL_VTXFMT_TYPE_UBYTE 0x00000004 ++#define NV40TCL_VTXFMT_TYPE_USHORT 0x00000005 ++#define NV40TCL_VTXFMT_SIZE_SHIFT 4 ++#define NV40TCL_VTXFMT_SIZE_MASK 0x000000f0 ++#define NV40TCL_VTXFMT_STRIDE_SHIFT 8 ++#define NV40TCL_VTXFMT_STRIDE_MASK 0x0000ff00 ++#define NV40TCL_QUERY_RESET 0x000017c8 ++#define NV40TCL_QUERY_UNK17CC 0x000017cc ++#define NV40TCL_QUERY_GET 0x00001800 ++#define NV40TCL_QUERY_GET_UNK24_SHIFT 24 ++#define NV40TCL_QUERY_GET_UNK24_MASK 0xff000000 ++#define NV40TCL_QUERY_GET_OFFSET_SHIFT 0 ++#define NV40TCL_QUERY_GET_OFFSET_MASK 0x00ffffff ++#define NV40TCL_BEGIN_END 0x00001808 ++#define NV40TCL_BEGIN_END_STOP 0x00000000 ++#define NV40TCL_BEGIN_END_POINTS 0x00000001 ++#define NV40TCL_BEGIN_END_LINES 0x00000002 ++#define NV40TCL_BEGIN_END_LINE_LOOP 0x00000003 ++#define NV40TCL_BEGIN_END_LINE_STRIP 0x00000004 ++#define NV40TCL_BEGIN_END_TRIANGLES 0x00000005 ++#define NV40TCL_BEGIN_END_TRIANGLE_STRIP 0x00000006 ++#define NV40TCL_BEGIN_END_TRIANGLE_FAN 0x00000007 ++#define NV40TCL_BEGIN_END_QUADS 0x00000008 ++#define NV40TCL_BEGIN_END_QUAD_STRIP 0x00000009 ++#define NV40TCL_BEGIN_END_POLYGON 0x0000000a ++#define NV40TCL_VB_ELEMENT_U16 0x0000180c ++#define NV40TCL_VB_ELEMENT_U16_1_SHIFT 16 ++#define NV40TCL_VB_ELEMENT_U16_1_MASK 0xffff0000 ++#define NV40TCL_VB_ELEMENT_U16_0_SHIFT 0 ++#define NV40TCL_VB_ELEMENT_U16_0_MASK 0x0000ffff ++#define NV40TCL_VB_ELEMENT_U32 0x00001810 ++#define NV40TCL_VB_VERTEX_BATCH 0x00001814 ++#define NV40TCL_VB_VERTEX_BATCH_COUNT_SHIFT 24 ++#define NV40TCL_VB_VERTEX_BATCH_COUNT_MASK 0xff000000 ++#define NV40TCL_VB_VERTEX_BATCH_START_SHIFT 0 ++#define NV40TCL_VB_VERTEX_BATCH_START_MASK 0x00ffffff ++#define NV40TCL_VERTEX_DATA 0x00001818 ++#define NV40TCL_IDXBUF_ADDRESS 0x0000181c ++#define NV40TCL_IDXBUF_FORMAT 0x00001820 ++#define NV40TCL_IDXBUF_FORMAT_TYPE_SHIFT 4 ++#define NV40TCL_IDXBUF_FORMAT_TYPE_MASK 0x000000f0 ++#define NV40TCL_IDXBUF_FORMAT_TYPE_U32 0x00000000 ++#define NV40TCL_IDXBUF_FORMAT_TYPE_U16 0x00000010 ++#define NV40TCL_IDXBUF_FORMAT_DMA1 (1 << 0) ++#define NV40TCL_VB_INDEX_BATCH 0x00001824 ++#define NV40TCL_VB_INDEX_BATCH_COUNT_SHIFT 24 ++#define NV40TCL_VB_INDEX_BATCH_COUNT_MASK 0xff000000 ++#define NV40TCL_VB_INDEX_BATCH_START_SHIFT 0 ++#define NV40TCL_VB_INDEX_BATCH_START_MASK 0x00ffffff ++#define NV40TCL_POLYGON_MODE_FRONT 0x00001828 ++#define NV40TCL_POLYGON_MODE_FRONT_POINT 0x00001b00 ++#define NV40TCL_POLYGON_MODE_FRONT_LINE 0x00001b01 ++#define NV40TCL_POLYGON_MODE_FRONT_FILL 0x00001b02 ++#define NV40TCL_POLYGON_MODE_BACK 0x0000182c ++#define NV40TCL_POLYGON_MODE_BACK_POINT 0x00001b00 ++#define NV40TCL_POLYGON_MODE_BACK_LINE 0x00001b01 ++#define NV40TCL_POLYGON_MODE_BACK_FILL 0x00001b02 ++#define NV40TCL_CULL_FACE 0x00001830 ++#define NV40TCL_CULL_FACE_FRONT 0x00000404 ++#define NV40TCL_CULL_FACE_BACK 0x00000405 ++#define NV40TCL_CULL_FACE_FRONT_AND_BACK 0x00000408 ++#define NV40TCL_FRONT_FACE 0x00001834 ++#define NV40TCL_FRONT_FACE_CW 0x00000900 ++#define NV40TCL_FRONT_FACE_CCW 0x00000901 ++#define NV40TCL_POLYGON_SMOOTH_ENABLE 0x00001838 ++#define NV40TCL_CULL_FACE_ENABLE 0x0000183c ++#define NV40TCL_TEX_SIZE1(x) (0x00001840+((x)*4)) ++#define NV40TCL_TEX_SIZE1__SIZE 0x00000008 ++#define NV40TCL_TEX_SIZE1_DEPTH_SHIFT 20 ++#define NV40TCL_TEX_SIZE1_DEPTH_MASK 0xfff00000 ++#define NV40TCL_TEX_SIZE1_PITCH_SHIFT 0 ++#define NV40TCL_TEX_SIZE1_PITCH_MASK 0x0000ffff ++#define NV40TCL_VTX_ATTR_2F_X(x) (0x00001880+((x)*8)) ++#define NV40TCL_VTX_ATTR_2F_X__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_2F_Y(x) (0x00001884+((x)*8)) ++#define NV40TCL_VTX_ATTR_2F_Y__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_2I(x) (0x00001900+((x)*4)) ++#define NV40TCL_VTX_ATTR_2I__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_2I_X_SHIFT 0 ++#define NV40TCL_VTX_ATTR_2I_X_MASK 0x0000ffff ++#define NV40TCL_VTX_ATTR_2I_Y_SHIFT 16 ++#define NV40TCL_VTX_ATTR_2I_Y_MASK 0xffff0000 ++#define NV40TCL_VTX_ATTR_4UB(x) (0x00001940+((x)*4)) ++#define NV40TCL_VTX_ATTR_4UB__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4UB_X_SHIFT 0 ++#define NV40TCL_VTX_ATTR_4UB_X_MASK 0x000000ff ++#define NV40TCL_VTX_ATTR_4UB_Y_SHIFT 8 ++#define NV40TCL_VTX_ATTR_4UB_Y_MASK 0x0000ff00 ++#define NV40TCL_VTX_ATTR_4UB_Z_SHIFT 16 ++#define NV40TCL_VTX_ATTR_4UB_Z_MASK 0x00ff0000 ++#define NV40TCL_VTX_ATTR_4UB_W_SHIFT 24 ++#define NV40TCL_VTX_ATTR_4UB_W_MASK 0xff000000 ++#define NV40TCL_VTX_ATTR_4I_XY(x) (0x00001980+((x)*8)) ++#define NV40TCL_VTX_ATTR_4I_XY__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4I_XY_X_SHIFT 0 ++#define NV40TCL_VTX_ATTR_4I_XY_X_MASK 0x0000ffff ++#define NV40TCL_VTX_ATTR_4I_XY_Y_SHIFT 16 ++#define NV40TCL_VTX_ATTR_4I_XY_Y_MASK 0xffff0000 ++#define NV40TCL_VTX_ATTR_4I_ZW(x) (0x00001984+((x)*8)) ++#define NV40TCL_VTX_ATTR_4I_ZW__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4I_ZW_Z_SHIFT 0 ++#define NV40TCL_VTX_ATTR_4I_ZW_Z_MASK 0x0000ffff ++#define NV40TCL_VTX_ATTR_4I_ZW_W_SHIFT 16 ++#define NV40TCL_VTX_ATTR_4I_ZW_W_MASK 0xffff0000 ++#define NV40TCL_TEX_OFFSET(x) (0x00001a00+((x)*32)) ++#define NV40TCL_TEX_OFFSET__SIZE 0x00000010 ++#define NV40TCL_TEX_FORMAT(x) (0x00001a04+((x)*32)) ++#define NV40TCL_TEX_FORMAT__SIZE 0x00000010 ++#define NV40TCL_TEX_FORMAT_MIPMAP_COUNT_SHIFT 16 ++#define NV40TCL_TEX_FORMAT_MIPMAP_COUNT_MASK 0x000f0000 ++#define NV40TCL_TEX_FORMAT_RECT (1 << 14) ++#define NV40TCL_TEX_FORMAT_LINEAR (1 << 13) ++#define NV40TCL_TEX_FORMAT_FORMAT_SHIFT 8 ++#define NV40TCL_TEX_FORMAT_FORMAT_MASK 0x00001f00 ++#define NV40TCL_TEX_FORMAT_FORMAT_L8 0x00000100 ++#define NV40TCL_TEX_FORMAT_FORMAT_A1R5G5B5 0x00000200 ++#define NV40TCL_TEX_FORMAT_FORMAT_A4R4G4B4 0x00000300 ++#define NV40TCL_TEX_FORMAT_FORMAT_R5G6B5 0x00000400 ++#define NV40TCL_TEX_FORMAT_FORMAT_A8R8G8B8 0x00000500 ++#define NV40TCL_TEX_FORMAT_FORMAT_DXT1 0x00000600 ++#define NV40TCL_TEX_FORMAT_FORMAT_DXT3 0x00000700 ++#define NV40TCL_TEX_FORMAT_FORMAT_DXT5 0x00000800 ++#define NV40TCL_TEX_FORMAT_FORMAT_A8L8 0x00000b00 ++#define NV40TCL_TEX_FORMAT_FORMAT_Z24 0x00001000 ++#define NV40TCL_TEX_FORMAT_FORMAT_Z16 0x00001200 ++#define NV40TCL_TEX_FORMAT_FORMAT_A16 0x00001400 ++#define NV40TCL_TEX_FORMAT_FORMAT_A16L16 0x00001500 ++#define NV40TCL_TEX_FORMAT_FORMAT_HILO8 0x00001800 ++#define NV40TCL_TEX_FORMAT_FORMAT_RGBA16F 0x00001a00 ++#define NV40TCL_TEX_FORMAT_FORMAT_RGBA32F 0x00001b00 ++#define NV40TCL_TEX_FORMAT_DIMS_SHIFT 4 ++#define NV40TCL_TEX_FORMAT_DIMS_MASK 0x000000f0 ++#define NV40TCL_TEX_FORMAT_DIMS_1D 0x00000010 ++#define NV40TCL_TEX_FORMAT_DIMS_2D 0x00000020 ++#define NV40TCL_TEX_FORMAT_DIMS_3D 0x00000030 ++#define NV40TCL_TEX_FORMAT_NO_BORDER (1 << 3) ++#define NV40TCL_TEX_FORMAT_CUBIC (1 << 2) ++#define NV40TCL_TEX_FORMAT_DMA1 (1 << 1) ++#define NV40TCL_TEX_FORMAT_DMA0 (1 << 0) ++#define NV40TCL_TEX_WRAP(x) (0x00001a08+((x)*32)) ++#define NV40TCL_TEX_WRAP__SIZE 0x00000010 ++#define NV40TCL_TEX_WRAP_S_SHIFT 0 ++#define NV40TCL_TEX_WRAP_S_MASK 0x0000000f ++#define NV40TCL_TEX_WRAP_S_REPEAT 0x00000001 ++#define NV40TCL_TEX_WRAP_S_MIRRORED_REPEAT 0x00000002 ++#define NV40TCL_TEX_WRAP_S_CLAMP_TO_EDGE 0x00000003 ++#define NV40TCL_TEX_WRAP_S_CLAMP_TO_BORDER 0x00000004 ++#define NV40TCL_TEX_WRAP_S_CLAMP 0x00000005 ++#define NV40TCL_TEX_WRAP_S_MIRROR_CLAMP_TO_EDGE 0x00000006 ++#define NV40TCL_TEX_WRAP_S_MIRROR_CLAMP_TO_BORDER 0x00000007 ++#define NV40TCL_TEX_WRAP_S_MIRROR_CLAMP 0x00000008 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_SHIFT 4 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_MASK 0x00000070 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_OFF 0x00000000 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_QUALITY 0x00000020 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_PERFORMANCE 0x00000030 ++#define NV40TCL_TEX_WRAP_ANISO_MIP_FILTER_OPTIMIZATION_HIGH_PERFORMANCE 0x00000070 ++#define NV40TCL_TEX_WRAP_T_SHIFT 8 ++#define NV40TCL_TEX_WRAP_T_MASK 0x00000f00 ++#define NV40TCL_TEX_WRAP_T_REPEAT 0x00000100 ++#define NV40TCL_TEX_WRAP_T_MIRRORED_REPEAT 0x00000200 ++#define NV40TCL_TEX_WRAP_T_CLAMP_TO_EDGE 0x00000300 ++#define NV40TCL_TEX_WRAP_T_CLAMP_TO_BORDER 0x00000400 ++#define NV40TCL_TEX_WRAP_T_CLAMP 0x00000500 ++#define NV40TCL_TEX_WRAP_T_MIRROR_CLAMP_TO_EDGE 0x00000600 ++#define NV40TCL_TEX_WRAP_T_MIRROR_CLAMP_TO_BORDER 0x00000700 ++#define NV40TCL_TEX_WRAP_T_MIRROR_CLAMP 0x00000800 ++#define NV40TCL_TEX_WRAP_EXPAND_NORMAL_SHIFT 12 ++#define NV40TCL_TEX_WRAP_EXPAND_NORMAL_MASK 0x0000f000 ++#define NV40TCL_TEX_WRAP_R_SHIFT 16 ++#define NV40TCL_TEX_WRAP_R_MASK 0x000f0000 ++#define NV40TCL_TEX_WRAP_R_REPEAT 0x00010000 ++#define NV40TCL_TEX_WRAP_R_MIRRORED_REPEAT 0x00020000 ++#define NV40TCL_TEX_WRAP_R_CLAMP_TO_EDGE 0x00030000 ++#define NV40TCL_TEX_WRAP_R_CLAMP_TO_BORDER 0x00040000 ++#define NV40TCL_TEX_WRAP_R_CLAMP 0x00050000 ++#define NV40TCL_TEX_WRAP_R_MIRROR_CLAMP_TO_EDGE 0x00060000 ++#define NV40TCL_TEX_WRAP_R_MIRROR_CLAMP_TO_BORDER 0x00070000 ++#define NV40TCL_TEX_WRAP_R_MIRROR_CLAMP 0x00080000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_SHIFT 20 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_MASK 0x00f00000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_NONE 0x00000000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_RED 0x00100000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_GREEN 0x00200000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_BLUE 0x00400000 ++#define NV40TCL_TEX_WRAP_GAMMA_DECREASE_FILTER_ALL 0x00f00000 ++#define NV40TCL_TEX_WRAP_RCOMP_SHIFT 28 ++#define NV40TCL_TEX_WRAP_RCOMP_MASK 0xf0000000 ++#define NV40TCL_TEX_WRAP_RCOMP_NEVER 0x00000000 ++#define NV40TCL_TEX_WRAP_RCOMP_GREATER 0x10000000 ++#define NV40TCL_TEX_WRAP_RCOMP_EQUAL 0x20000000 ++#define NV40TCL_TEX_WRAP_RCOMP_GEQUAL 0x30000000 ++#define NV40TCL_TEX_WRAP_RCOMP_LESS 0x40000000 ++#define NV40TCL_TEX_WRAP_RCOMP_NOTEQUAL 0x50000000 ++#define NV40TCL_TEX_WRAP_RCOMP_LEQUAL 0x60000000 ++#define NV40TCL_TEX_WRAP_RCOMP_ALWAYS 0x70000000 ++#define NV40TCL_TEX_ENABLE(x) (0x00001a0c+((x)*32)) ++#define NV40TCL_TEX_ENABLE__SIZE 0x00000010 ++#define NV40TCL_TEX_ENABLE_ENABLE (1 << 31) ++#define NV40TCL_TEX_ENABLE_MIPMAP_MIN_LOD_SHIFT 27 ++#define NV40TCL_TEX_ENABLE_MIPMAP_MIN_LOD_MASK 0x38000000 ++#define NV40TCL_TEX_ENABLE_MIPMAP_MAX_LOD_SHIFT 15 ++#define NV40TCL_TEX_ENABLE_MIPMAP_MAX_LOD_MASK 0x00038000 ++#define NV40TCL_TEX_ENABLE_ANISO_SHIFT 4 ++#define NV40TCL_TEX_ENABLE_ANISO_MASK 0x000000f0 ++#define NV40TCL_TEX_ENABLE_ANISO_NONE 0x00000000 ++#define NV40TCL_TEX_ENABLE_ANISO_2X 0x00000010 ++#define NV40TCL_TEX_ENABLE_ANISO_4X 0x00000020 ++#define NV40TCL_TEX_ENABLE_ANISO_6X 0x00000030 ++#define NV40TCL_TEX_ENABLE_ANISO_8X 0x00000040 ++#define NV40TCL_TEX_ENABLE_ANISO_10X 0x00000050 ++#define NV40TCL_TEX_ENABLE_ANISO_12X 0x00000060 ++#define NV40TCL_TEX_ENABLE_ANISO_16X 0x00000070 ++#define NV40TCL_TEX_SWIZZLE(x) (0x00001a10+((x)*32)) ++#define NV40TCL_TEX_SWIZZLE__SIZE 0x00000010 ++#define NV40TCL_TEX_SWIZZLE_S0_X_SHIFT 14 ++#define NV40TCL_TEX_SWIZZLE_S0_X_MASK 0x0000c000 ++#define NV40TCL_TEX_SWIZZLE_S0_X_ZERO 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S0_X_ONE 0x00004000 ++#define NV40TCL_TEX_SWIZZLE_S0_X_S1 0x00008000 ++#define NV40TCL_TEX_SWIZZLE_S0_Y_SHIFT 12 ++#define NV40TCL_TEX_SWIZZLE_S0_Y_MASK 0x00003000 ++#define NV40TCL_TEX_SWIZZLE_S0_Y_ZERO 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S0_Y_ONE 0x00001000 ++#define NV40TCL_TEX_SWIZZLE_S0_Y_S1 0x00002000 ++#define NV40TCL_TEX_SWIZZLE_S0_Z_SHIFT 10 ++#define NV40TCL_TEX_SWIZZLE_S0_Z_MASK 0x00000c00 ++#define NV40TCL_TEX_SWIZZLE_S0_Z_ZERO 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S0_Z_ONE 0x00000400 ++#define NV40TCL_TEX_SWIZZLE_S0_Z_S1 0x00000800 ++#define NV40TCL_TEX_SWIZZLE_S0_W_SHIFT 8 ++#define NV40TCL_TEX_SWIZZLE_S0_W_MASK 0x00000300 ++#define NV40TCL_TEX_SWIZZLE_S0_W_ZERO 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S0_W_ONE 0x00000100 ++#define NV40TCL_TEX_SWIZZLE_S0_W_S1 0x00000200 ++#define NV40TCL_TEX_SWIZZLE_S1_X_SHIFT 6 ++#define NV40TCL_TEX_SWIZZLE_S1_X_MASK 0x000000c0 ++#define NV40TCL_TEX_SWIZZLE_S1_X_W 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S1_X_Z 0x00000040 ++#define NV40TCL_TEX_SWIZZLE_S1_X_Y 0x00000080 ++#define NV40TCL_TEX_SWIZZLE_S1_X_X 0x000000c0 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_SHIFT 4 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_MASK 0x00000030 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_W 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_Z 0x00000010 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_Y 0x00000020 ++#define NV40TCL_TEX_SWIZZLE_S1_Y_X 0x00000030 ++#define NV40TCL_TEX_SWIZZLE_S1_Z_SHIFT 2 ++#define NV40TCL_TEX_SWIZZLE_S1_Z_MASK 0x0000000c ++#define NV40TCL_TEX_SWIZZLE_S1_Z_W 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S1_Z_Z 0x00000004 ++#define NV40TCL_TEX_SWIZZLE_S1_Z_Y 0x00000008 ++#define NV40TCL_TEX_SWIZZLE_S1_Z_X 0x0000000c ++#define NV40TCL_TEX_SWIZZLE_S1_W_SHIFT 0 ++#define NV40TCL_TEX_SWIZZLE_S1_W_MASK 0x00000003 ++#define NV40TCL_TEX_SWIZZLE_S1_W_W 0x00000000 ++#define NV40TCL_TEX_SWIZZLE_S1_W_Z 0x00000001 ++#define NV40TCL_TEX_SWIZZLE_S1_W_Y 0x00000002 ++#define NV40TCL_TEX_SWIZZLE_S1_W_X 0x00000003 ++#define NV40TCL_TEX_FILTER(x) (0x00001a14+((x)*32)) ++#define NV40TCL_TEX_FILTER__SIZE 0x00000010 ++#define NV40TCL_TEX_FILTER_SIGNED_ALPHA (1 << 31) ++#define NV40TCL_TEX_FILTER_SIGNED_RED (1 << 30) ++#define NV40TCL_TEX_FILTER_SIGNED_GREEN (1 << 29) ++#define NV40TCL_TEX_FILTER_SIGNED_BLUE (1 << 28) ++#define NV40TCL_TEX_FILTER_MIN_SHIFT 16 ++#define NV40TCL_TEX_FILTER_MIN_MASK 0x000f0000 ++#define NV40TCL_TEX_FILTER_MIN_NEAREST 0x00010000 ++#define NV40TCL_TEX_FILTER_MIN_LINEAR 0x00020000 ++#define NV40TCL_TEX_FILTER_MIN_NEAREST_MIPMAP_NEAREST 0x00030000 ++#define NV40TCL_TEX_FILTER_MIN_LINEAR_MIPMAP_NEAREST 0x00040000 ++#define NV40TCL_TEX_FILTER_MIN_NEAREST_MIPMAP_LINEAR 0x00050000 ++#define NV40TCL_TEX_FILTER_MIN_LINEAR_MIPMAP_LINEAR 0x00060000 ++#define NV40TCL_TEX_FILTER_MAG_SHIFT 24 ++#define NV40TCL_TEX_FILTER_MAG_MASK 0x0f000000 ++#define NV40TCL_TEX_FILTER_MAG_NEAREST 0x01000000 ++#define NV40TCL_TEX_FILTER_MAG_LINEAR 0x02000000 ++#define NV40TCL_TEX_SIZE0(x) (0x00001a18+((x)*32)) ++#define NV40TCL_TEX_SIZE0__SIZE 0x00000010 ++#define NV40TCL_TEX_SIZE0_H_SHIFT 0 ++#define NV40TCL_TEX_SIZE0_H_MASK 0x0000ffff ++#define NV40TCL_TEX_SIZE0_W_SHIFT 16 ++#define NV40TCL_TEX_SIZE0_W_MASK 0xffff0000 ++#define NV40TCL_TEX_BORDER_COLOR(x) (0x00001a1c+((x)*32)) ++#define NV40TCL_TEX_BORDER_COLOR__SIZE 0x00000010 ++#define NV40TCL_TEX_BORDER_COLOR_B_SHIFT 0 ++#define NV40TCL_TEX_BORDER_COLOR_B_MASK 0x000000ff ++#define NV40TCL_TEX_BORDER_COLOR_G_SHIFT 8 ++#define NV40TCL_TEX_BORDER_COLOR_G_MASK 0x0000ff00 ++#define NV40TCL_TEX_BORDER_COLOR_R_SHIFT 16 ++#define NV40TCL_TEX_BORDER_COLOR_R_MASK 0x00ff0000 ++#define NV40TCL_TEX_BORDER_COLOR_A_SHIFT 24 ++#define NV40TCL_TEX_BORDER_COLOR_A_MASK 0xff000000 ++#define NV40TCL_VTX_ATTR_4F_X(x) (0x00001c00+((x)*16)) ++#define NV40TCL_VTX_ATTR_4F_X__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4F_Y(x) (0x00001c04+((x)*16)) ++#define NV40TCL_VTX_ATTR_4F_Y__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4F_Z(x) (0x00001c08+((x)*16)) ++#define NV40TCL_VTX_ATTR_4F_Z__SIZE 0x00000010 ++#define NV40TCL_VTX_ATTR_4F_W(x) (0x00001c0c+((x)*16)) ++#define NV40TCL_VTX_ATTR_4F_W__SIZE 0x00000010 ++#define NV40TCL_FP_CONTROL 0x00001d60 ++#define NV40TCL_FP_CONTROL_TEMP_COUNT_SHIFT 24 ++#define NV40TCL_FP_CONTROL_TEMP_COUNT_MASK 0xff000000 ++#define NV40TCL_FP_CONTROL_KIL (1 << 7) ++#define NV40TCL_MULTISAMPLE_CONTROL 0x00001d7c ++#define NV40TCL_CLEAR_VALUE_DEPTH 0x00001d8c ++#define NV40TCL_CLEAR_VALUE_COLOR 0x00001d90 ++#define NV40TCL_CLEAR_VALUE_COLOR_B_SHIFT 0 ++#define NV40TCL_CLEAR_VALUE_COLOR_B_MASK 0x000000ff ++#define NV40TCL_CLEAR_VALUE_COLOR_G_SHIFT 8 ++#define NV40TCL_CLEAR_VALUE_COLOR_G_MASK 0x0000ff00 ++#define NV40TCL_CLEAR_VALUE_COLOR_R_SHIFT 16 ++#define NV40TCL_CLEAR_VALUE_COLOR_R_MASK 0x00ff0000 ++#define NV40TCL_CLEAR_VALUE_COLOR_A_SHIFT 24 ++#define NV40TCL_CLEAR_VALUE_COLOR_A_MASK 0xff000000 ++#define NV40TCL_CLEAR_BUFFERS 0x00001d94 ++#define NV40TCL_CLEAR_BUFFERS_COLOR_A (1 << 7) ++#define NV40TCL_CLEAR_BUFFERS_COLOR_B (1 << 6) ++#define NV40TCL_CLEAR_BUFFERS_COLOR_G (1 << 5) ++#define NV40TCL_CLEAR_BUFFERS_COLOR_R (1 << 4) ++#define NV40TCL_CLEAR_BUFFERS_STENCIL (1 << 1) ++#define NV40TCL_CLEAR_BUFFERS_DEPTH (1 << 0) ++#define NV40TCL_LINE_STIPPLE_ENABLE 0x00001db4 ++#define NV40TCL_LINE_STIPPLE_PATTERN 0x00001db8 ++#define NV40TCL_LINE_STIPPLE_PATTERN_FACTOR_SHIFT 0 ++#define NV40TCL_LINE_STIPPLE_PATTERN_FACTOR_MASK 0x0000ffff ++#define NV40TCL_LINE_STIPPLE_PATTERN_PATTERN_SHIFT 16 ++#define NV40TCL_LINE_STIPPLE_PATTERN_PATTERN_MASK 0xffff0000 ++#define NV40TCL_VTX_ATTR_1F(x) (0x00001e40+((x)*4)) ++#define NV40TCL_VTX_ATTR_1F__SIZE 0x00000010 ++#define NV40TCL_VP_UPLOAD_FROM_ID 0x00001e9c ++#define NV40TCL_VP_START_FROM_ID 0x00001ea0 ++#define NV40TCL_POINT_SIZE 0x00001ee0 ++#define NV40TCL_POINT_SPRITE 0x00001ee8 ++#define NV40TCL_POINT_SPRITE_ENABLE (1 << 0) ++#define NV40TCL_POINT_SPRITE_R_MODE_SHIFT 1 ++#define NV40TCL_POINT_SPRITE_R_MODE_MASK 0x00000006 ++#define NV40TCL_POINT_SPRITE_R_MODE_ZERO 0x00000000 ++#define NV40TCL_POINT_SPRITE_R_MODE_R 0x00000002 ++#define NV40TCL_POINT_SPRITE_R_MODE_S 0x00000004 ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_0 (1 << 8) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_1 (1 << 9) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_2 (1 << 10) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_3 (1 << 11) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_4 (1 << 12) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_5 (1 << 13) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_6 (1 << 14) ++#define NV40TCL_POINT_SPRITE_COORD_REPLACE_7 (1 << 15) ++#define NV40TCL_VP_UPLOAD_CONST_ID 0x00001efc ++#define NV40TCL_VP_UPLOAD_CONST_X(x) (0x00001f00+((x)*16)) ++#define NV40TCL_VP_UPLOAD_CONST_X__SIZE 0x00000004 ++#define NV40TCL_VP_UPLOAD_CONST_Y(x) (0x00001f04+((x)*16)) ++#define NV40TCL_VP_UPLOAD_CONST_Y__SIZE 0x00000004 ++#define NV40TCL_VP_UPLOAD_CONST_Z(x) (0x00001f08+((x)*16)) ++#define NV40TCL_VP_UPLOAD_CONST_Z__SIZE 0x00000004 ++#define NV40TCL_VP_UPLOAD_CONST_W(x) (0x00001f0c+((x)*16)) ++#define NV40TCL_VP_UPLOAD_CONST_W__SIZE 0x00000004 ++#define NV40TCL_TEX_CACHE_CTL 0x00001fd8 ++#define NV40TCL_VP_ATTRIB_EN 0x00001ff0 ++#define NV40TCL_VP_RESULT_EN 0x00001ff4 ++ ++ ++#define NV44TCL 0x00004497 ++ ++ ++ ++#define NV50_2D 0x0000502d ++ ++#define NV50_2D_NOP 0x00000100 ++#define NV50_2D_NOTIFY 0x00000104 ++#define NV50_2D_SERIALIZE 0x00000110 ++#define NV50_2D_DMA_NOTIFY 0x00000180 ++#define NV50_2D_DMA_DST 0x00000184 ++#define NV50_2D_DMA_SRC 0x00000188 ++#define NV50_2D_DMA_COND 0x0000018c ++#define NV50_2D_DST_FORMAT 0x00000200 ++#define NV50_2D_DST_FORMAT_R32G32B32A32_FLOAT 0x000000c0 ++#define NV50_2D_DST_FORMAT_R32G32B32A32_SINT 0x000000c1 ++#define NV50_2D_DST_FORMAT_R32G32B32A32_UINT 0x000000c2 ++#define NV50_2D_DST_FORMAT_R32G32B32X32_FLOAT 0x000000c3 ++#define NV50_2D_DST_FORMAT_R16G16B16A16_UNORM 0x000000c6 ++#define NV50_2D_DST_FORMAT_R16G16B16A16_SNORM 0x000000c7 ++#define NV50_2D_DST_FORMAT_R16G16B16A16_SINT 0x000000c8 ++#define NV50_2D_DST_FORMAT_R16G16B16A16_UINT 0x000000c9 ++#define NV50_2D_DST_FORMAT_R16G16B16A16_FLOAT 0x000000ca ++#define NV50_2D_DST_FORMAT_R32G32_FLOAT 0x000000cb ++#define NV50_2D_DST_FORMAT_R32G32_SINT 0x000000cc ++#define NV50_2D_DST_FORMAT_R32G32_UINT 0x000000cd ++#define NV50_2D_DST_FORMAT_R16G16B16X16_FLOAT 0x000000ce ++#define NV50_2D_DST_FORMAT_A8R8G8B8_UNORM 0x000000cf ++#define NV50_2D_DST_FORMAT_A8R8G8B8_SRGB 0x000000d0 ++#define NV50_2D_DST_FORMAT_A2B10G10R10_UNORM 0x000000d1 ++#define NV50_2D_DST_FORMAT_A2B10G10R10_UINT 0x000000d2 ++#define NV50_2D_DST_FORMAT_A8B8G8R8_UNORM 0x000000d5 ++#define NV50_2D_DST_FORMAT_A8B8G8R8_SRGB 0x000000d6 ++#define NV50_2D_DST_FORMAT_A8B8G8R8_SNORM 0x000000d7 ++#define NV50_2D_DST_FORMAT_A8B8G8R8_SINT 0x000000d8 ++#define NV50_2D_DST_FORMAT_A8B8G8R8_UINT 0x000000d9 ++#define NV50_2D_DST_FORMAT_R16G16_UNORM 0x000000da ++#define NV50_2D_DST_FORMAT_R16G16_SNORM 0x000000db ++#define NV50_2D_DST_FORMAT_R16G16_SINT 0x000000dc ++#define NV50_2D_DST_FORMAT_R16G16_UINT 0x000000dd ++#define NV50_2D_DST_FORMAT_R16G16_FLOAT 0x000000de ++#define NV50_2D_DST_FORMAT_A2R10G10B10_UNORM 0x000000df ++#define NV50_2D_DST_FORMAT_B10G11R11_FLOAT 0x000000e0 ++#define NV50_2D_DST_FORMAT_R32_FLOAT 0x000000e5 ++#define NV50_2D_DST_FORMAT_X8R8G8B8_UNORM 0x000000e6 ++#define NV50_2D_DST_FORMAT_X8R8G8B8_SRGB 0x000000e7 ++#define NV50_2D_DST_FORMAT_R5G6B5_UNORM 0x000000e8 ++#define NV50_2D_DST_FORMAT_A1R5G5B5_UNORM 0x000000e9 ++#define NV50_2D_DST_FORMAT_R8G8_UNORM 0x000000ea ++#define NV50_2D_DST_FORMAT_R8G8_SNORM 0x000000eb ++#define NV50_2D_DST_FORMAT_R8G8_SINT 0x000000ec ++#define NV50_2D_DST_FORMAT_R8G8_UINT 0x000000ed ++#define NV50_2D_DST_FORMAT_R16_UNORM 0x000000ee ++#define NV50_2D_DST_FORMAT_R16_SNORM 0x000000ef ++#define NV50_2D_DST_FORMAT_R16_SINT 0x000000f0 ++#define NV50_2D_DST_FORMAT_R16_UINT 0x000000f1 ++#define NV50_2D_DST_FORMAT_R16_FLOAT 0x000000f2 ++#define NV50_2D_DST_FORMAT_R8_UNORM 0x000000f3 ++#define NV50_2D_DST_FORMAT_R8_SNORM 0x000000f4 ++#define NV50_2D_DST_FORMAT_R8_SINT 0x000000f5 ++#define NV50_2D_DST_FORMAT_R8_UINT 0x000000f6 ++#define NV50_2D_DST_FORMAT_A8_UNORM 0x000000f7 ++#define NV50_2D_DST_FORMAT_X1R5G5B5_UNORM 0x000000f8 ++#define NV50_2D_DST_FORMAT_X8B8G8R8_UNORM 0x000000f9 ++#define NV50_2D_DST_FORMAT_X8B8G8R8_SRGB 0x000000fa ++#define NV50_2D_DST_LINEAR 0x00000204 ++#define NV50_2D_DST_TILE_MODE 0x00000208 ++#define NV50_2D_DST_DEPTH 0x0000020c ++#define NV50_2D_DST_LAYER 0x00000210 ++#define NV50_2D_DST_PITCH 0x00000214 ++#define NV50_2D_DST_WIDTH 0x00000218 ++#define NV50_2D_DST_HEIGHT 0x0000021c ++#define NV50_2D_DST_ADDRESS_HIGH 0x00000220 ++#define NV50_2D_DST_ADDRESS_LOW 0x00000224 ++#define NV50_2D_SRC_FORMAT 0x00000230 ++#define NV50_2D_SRC_FORMAT_R32G32B32A32_FLOAT 0x000000c0 ++#define NV50_2D_SRC_FORMAT_R32G32B32A32_SINT 0x000000c1 ++#define NV50_2D_SRC_FORMAT_R32G32B32A32_UINT 0x000000c2 ++#define NV50_2D_SRC_FORMAT_R32G32B32X32_FLOAT 0x000000c3 ++#define NV50_2D_SRC_FORMAT_R16G16B16A16_UNORM 0x000000c6 ++#define NV50_2D_SRC_FORMAT_R16G16B16A16_SNORM 0x000000c7 ++#define NV50_2D_SRC_FORMAT_R16G16B16A16_SINT 0x000000c8 ++#define NV50_2D_SRC_FORMAT_R16G16B16A16_UINT 0x000000c9 ++#define NV50_2D_SRC_FORMAT_R16G16B16A16_FLOAT 0x000000ca ++#define NV50_2D_SRC_FORMAT_R32G32_FLOAT 0x000000cb ++#define NV50_2D_SRC_FORMAT_R32G32_SINT 0x000000cc ++#define NV50_2D_SRC_FORMAT_R32G32_UINT 0x000000cd ++#define NV50_2D_SRC_FORMAT_R16G16B16X16_FLOAT 0x000000ce ++#define NV50_2D_SRC_FORMAT_A8R8G8B8_UNORM 0x000000cf ++#define NV50_2D_SRC_FORMAT_A8R8G8B8_SRGB 0x000000d0 ++#define NV50_2D_SRC_FORMAT_A2B10G10R10_UNORM 0x000000d1 ++#define NV50_2D_SRC_FORMAT_A2B10G10R10_UINT 0x000000d2 ++#define NV50_2D_SRC_FORMAT_A8B8G8R8_UNORM 0x000000d5 ++#define NV50_2D_SRC_FORMAT_A8B8G8R8_SRGB 0x000000d6 ++#define NV50_2D_SRC_FORMAT_A8B8G8R8_SNORM 0x000000d7 ++#define NV50_2D_SRC_FORMAT_A8B8G8R8_SINT 0x000000d8 ++#define NV50_2D_SRC_FORMAT_A8B8G8R8_UINT 0x000000d9 ++#define NV50_2D_SRC_FORMAT_R16G16_UNORM 0x000000da ++#define NV50_2D_SRC_FORMAT_R16G16_SNORM 0x000000db ++#define NV50_2D_SRC_FORMAT_R16G16_SINT 0x000000dc ++#define NV50_2D_SRC_FORMAT_R16G16_UINT 0x000000dd ++#define NV50_2D_SRC_FORMAT_R16G16_FLOAT 0x000000de ++#define NV50_2D_SRC_FORMAT_A2R10G10B10_UNORM 0x000000df ++#define NV50_2D_SRC_FORMAT_B10G11R11_FLOAT 0x000000e0 ++#define NV50_2D_SRC_FORMAT_R32_FLOAT 0x000000e5 ++#define NV50_2D_SRC_FORMAT_X8R8G8B8_UNORM 0x000000e6 ++#define NV50_2D_SRC_FORMAT_X8R8G8B8_SRGB 0x000000e7 ++#define NV50_2D_SRC_FORMAT_R5G6B5_UNORM 0x000000e8 ++#define NV50_2D_SRC_FORMAT_A1R5G5B5_UNORM 0x000000e9 ++#define NV50_2D_SRC_FORMAT_R8G8_UNORM 0x000000ea ++#define NV50_2D_SRC_FORMAT_R8G8_SNORM 0x000000eb ++#define NV50_2D_SRC_FORMAT_R8G8_SINT 0x000000ec ++#define NV50_2D_SRC_FORMAT_R8G8_UINT 0x000000ed ++#define NV50_2D_SRC_FORMAT_R16_UNORM 0x000000ee ++#define NV50_2D_SRC_FORMAT_R16_SNORM 0x000000ef ++#define NV50_2D_SRC_FORMAT_R16_SINT 0x000000f0 ++#define NV50_2D_SRC_FORMAT_R16_UINT 0x000000f1 ++#define NV50_2D_SRC_FORMAT_R16_FLOAT 0x000000f2 ++#define NV50_2D_SRC_FORMAT_R8_UNORM 0x000000f3 ++#define NV50_2D_SRC_FORMAT_R8_SNORM 0x000000f4 ++#define NV50_2D_SRC_FORMAT_R8_SINT 0x000000f5 ++#define NV50_2D_SRC_FORMAT_R8_UINT 0x000000f6 ++#define NV50_2D_SRC_FORMAT_A8_UNORM 0x000000f7 ++#define NV50_2D_SRC_FORMAT_X1R5G5B5_UNORM 0x000000f8 ++#define NV50_2D_SRC_FORMAT_X8B8G8R8_UNORM 0x000000f9 ++#define NV50_2D_SRC_FORMAT_X8B8G8R8_SRGB 0x000000fa ++#define NV50_2D_SRC_LINEAR 0x00000234 ++#define NV50_2D_SRC_TILE_MODE 0x00000238 ++#define NV50_2D_SRC_DEPTH 0x0000023c ++#define NV50_2D_SRC_LAYER 0x00000240 ++#define NV50_2D_SRC_PITCH 0x00000244 ++#define NV50_2D_SRC_WIDTH 0x00000248 ++#define NV50_2D_SRC_HEIGHT 0x0000024c ++#define NV50_2D_SRC_ADDRESS_HIGH 0x00000250 ++#define NV50_2D_SRC_ADDRESS_LOW 0x00000254 ++#define NV50_2D_COND_ADDRESS_HIGH 0x00000264 ++#define NV50_2D_COND_ADDRESS_LOW 0x00000268 ++#define NV50_2D_COND_MODE 0x0000026c ++#define NV50_2D_COND_MODE_NEVER 0x00000000 ++#define NV50_2D_COND_MODE_ALWAYS 0x00000001 ++#define NV50_2D_COND_MODE_RES 0x00000002 ++#define NV50_2D_COND_MODE_NOT_RES_AND_NOT_ID 0x00000003 ++#define NV50_2D_COND_MODE_RES_OR_ID 0x00000004 ++#define NV50_2D_CLIP_X 0x00000280 ++#define NV50_2D_CLIP_Y 0x00000284 ++#define NV50_2D_CLIP_W 0x00000288 ++#define NV50_2D_CLIP_H 0x0000028c ++#define NV50_2D_CLIP_ENABLE 0x00000290 ++#define NV50_2D_COLOR_KEY_FORMAT 0x00000294 ++#define NV50_2D_COLOR_KEY_FORMAT_16BPP 0x00000000 ++#define NV50_2D_COLOR_KEY_FORMAT_15BPP 0x00000001 ++#define NV50_2D_COLOR_KEY_FORMAT_24BPP 0x00000002 ++#define NV50_2D_COLOR_KEY_FORMAT_30BPP 0x00000003 ++#define NV50_2D_COLOR_KEY_FORMAT_8BPP 0x00000004 ++#define NV50_2D_COLOR_KEY_FORMAT_16BPP2 0x00000005 ++#define NV50_2D_COLOR_KEY_FORMAT_32BPP 0x00000006 ++#define NV50_2D_COLOR_KEY 0x00000298 ++#define NV50_2D_COLOR_KEY_ENABLE 0x0000029c ++#define NV50_2D_ROP 0x000002a0 ++#define NV50_2D_OPERATION 0x000002ac ++#define NV50_2D_OPERATION_SRCCOPY_AND 0x00000000 ++#define NV50_2D_OPERATION_ROP_AND 0x00000001 ++#define NV50_2D_OPERATION_BLEND_AND 0x00000002 ++#define NV50_2D_OPERATION_SRCCOPY 0x00000003 ++#define NV50_2D_OPERATION_SRCCOPY_PREMULT 0x00000004 ++#define NV50_2D_OPERATION_BLEND_PREMULT 0x00000005 ++#define NV50_2D_PATTERN_FORMAT 0x000002e8 ++#define NV50_2D_PATTERN_FORMAT_16BPP 0x00000000 ++#define NV50_2D_PATTERN_FORMAT_15BPP 0x00000001 ++#define NV50_2D_PATTERN_FORMAT_32BPP 0x00000002 ++#define NV50_2D_PATTERN_FORMAT_8BPP 0x00000003 ++#define NV50_2D_PATTERN_COLOR(x) (0x000002f0+((x)*4)) ++#define NV50_2D_PATTERN_COLOR__SIZE 0x00000002 ++#define NV50_2D_PATTERN_BITMAP(x) (0x000002f8+((x)*4)) ++#define NV50_2D_PATTERN_BITMAP__SIZE 0x00000002 ++#define NV50_2D_DRAW_SHAPE 0x00000580 ++#define NV50_2D_DRAW_SHAPE_POINTS 0x00000000 ++#define NV50_2D_DRAW_SHAPE_LINES 0x00000001 ++#define NV50_2D_DRAW_SHAPE_LINE_STRIP 0x00000002 ++#define NV50_2D_DRAW_SHAPE_TRIANGLES 0x00000003 ++#define NV50_2D_DRAW_SHAPE_RECTANGLES 0x00000004 ++#define NV50_2D_DRAW_COLOR_FORMAT 0x00000584 ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32B32A32_FLOAT 0x000000c0 ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32B32A32_SINT 0x000000c1 ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32B32A32_UINT 0x000000c2 ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32B32X32_FLOAT 0x000000c3 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16A16_UNORM 0x000000c6 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16A16_SNORM 0x000000c7 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16A16_SINT 0x000000c8 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16A16_UINT 0x000000c9 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16A16_FLOAT 0x000000ca ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32_FLOAT 0x000000cb ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32_SINT 0x000000cc ++#define NV50_2D_DRAW_COLOR_FORMAT_R32G32_UINT 0x000000cd ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16B16X16_FLOAT 0x000000ce ++#define NV50_2D_DRAW_COLOR_FORMAT_A8R8G8B8_UNORM 0x000000cf ++#define NV50_2D_DRAW_COLOR_FORMAT_A8R8G8B8_SRGB 0x000000d0 ++#define NV50_2D_DRAW_COLOR_FORMAT_A2B10G10R10_UNORM 0x000000d1 ++#define NV50_2D_DRAW_COLOR_FORMAT_A2B10G10R10_UINT 0x000000d2 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8B8G8R8_UNORM 0x000000d5 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8B8G8R8_SRGB 0x000000d6 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8B8G8R8_SNORM 0x000000d7 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8B8G8R8_SINT 0x000000d8 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8B8G8R8_UINT 0x000000d9 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16_UNORM 0x000000da ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16_SNORM 0x000000db ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16_SINT 0x000000dc ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16_UINT 0x000000dd ++#define NV50_2D_DRAW_COLOR_FORMAT_R16G16_FLOAT 0x000000de ++#define NV50_2D_DRAW_COLOR_FORMAT_A2R10G10B10_UNORM 0x000000df ++#define NV50_2D_DRAW_COLOR_FORMAT_B10G11R11_FLOAT 0x000000e0 ++#define NV50_2D_DRAW_COLOR_FORMAT_R32_FLOAT 0x000000e5 ++#define NV50_2D_DRAW_COLOR_FORMAT_X8R8G8B8_UNORM 0x000000e6 ++#define NV50_2D_DRAW_COLOR_FORMAT_X8R8G8B8_SRGB 0x000000e7 ++#define NV50_2D_DRAW_COLOR_FORMAT_R5G6B5_UNORM 0x000000e8 ++#define NV50_2D_DRAW_COLOR_FORMAT_A1R5G5B5_UNORM 0x000000e9 ++#define NV50_2D_DRAW_COLOR_FORMAT_R8G8_UNORM 0x000000ea ++#define NV50_2D_DRAW_COLOR_FORMAT_R8G8_SNORM 0x000000eb ++#define NV50_2D_DRAW_COLOR_FORMAT_R8G8_SINT 0x000000ec ++#define NV50_2D_DRAW_COLOR_FORMAT_R8G8_UINT 0x000000ed ++#define NV50_2D_DRAW_COLOR_FORMAT_R16_UNORM 0x000000ee ++#define NV50_2D_DRAW_COLOR_FORMAT_R16_SNORM 0x000000ef ++#define NV50_2D_DRAW_COLOR_FORMAT_R16_SINT 0x000000f0 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16_UINT 0x000000f1 ++#define NV50_2D_DRAW_COLOR_FORMAT_R16_FLOAT 0x000000f2 ++#define NV50_2D_DRAW_COLOR_FORMAT_R8_UNORM 0x000000f3 ++#define NV50_2D_DRAW_COLOR_FORMAT_R8_SNORM 0x000000f4 ++#define NV50_2D_DRAW_COLOR_FORMAT_R8_SINT 0x000000f5 ++#define NV50_2D_DRAW_COLOR_FORMAT_R8_UINT 0x000000f6 ++#define NV50_2D_DRAW_COLOR_FORMAT_A8_UNORM 0x000000f7 ++#define NV50_2D_DRAW_COLOR_FORMAT_X1R5G5B5_UNORM 0x000000f8 ++#define NV50_2D_DRAW_COLOR_FORMAT_X8B8G8R8_UNORM 0x000000f9 ++#define NV50_2D_DRAW_COLOR_FORMAT_X8B8G8R8_SRGB 0x000000fa ++#define NV50_2D_DRAW_COLOR 0x00000588 ++#define NV50_2D_DRAW_POINT16 0x000005e0 ++#define NV50_2D_DRAW_POINT16_X_SHIFT 0 ++#define NV50_2D_DRAW_POINT16_X_MASK 0x0000ffff ++#define NV50_2D_DRAW_POINT16_Y_SHIFT 16 ++#define NV50_2D_DRAW_POINT16_Y_MASK 0xffff0000 ++#define NV50_2D_DRAW_POINT32_X(x) (0x00000600+((x)*8)) ++#define NV50_2D_DRAW_POINT32_X__SIZE 0x00000040 ++#define NV50_2D_DRAW_POINT32_Y(x) (0x00000604+((x)*8)) ++#define NV50_2D_DRAW_POINT32_Y__SIZE 0x00000040 ++#define NV50_2D_SIFC_BITMAP_ENABLE 0x00000800 ++#define NV50_2D_SIFC_FORMAT 0x00000804 ++#define NV50_2D_SIFC_FORMAT_R32G32B32A32_FLOAT 0x000000c0 ++#define NV50_2D_SIFC_FORMAT_R32G32B32A32_SINT 0x000000c1 ++#define NV50_2D_SIFC_FORMAT_R32G32B32A32_UINT 0x000000c2 ++#define NV50_2D_SIFC_FORMAT_R32G32B32X32_FLOAT 0x000000c3 ++#define NV50_2D_SIFC_FORMAT_R16G16B16A16_UNORM 0x000000c6 ++#define NV50_2D_SIFC_FORMAT_R16G16B16A16_SNORM 0x000000c7 ++#define NV50_2D_SIFC_FORMAT_R16G16B16A16_SINT 0x000000c8 ++#define NV50_2D_SIFC_FORMAT_R16G16B16A16_UINT 0x000000c9 ++#define NV50_2D_SIFC_FORMAT_R16G16B16A16_FLOAT 0x000000ca ++#define NV50_2D_SIFC_FORMAT_R32G32_FLOAT 0x000000cb ++#define NV50_2D_SIFC_FORMAT_R32G32_SINT 0x000000cc ++#define NV50_2D_SIFC_FORMAT_R32G32_UINT 0x000000cd ++#define NV50_2D_SIFC_FORMAT_R16G16B16X16_FLOAT 0x000000ce ++#define NV50_2D_SIFC_FORMAT_A8R8G8B8_UNORM 0x000000cf ++#define NV50_2D_SIFC_FORMAT_A8R8G8B8_SRGB 0x000000d0 ++#define NV50_2D_SIFC_FORMAT_A2B10G10R10_UNORM 0x000000d1 ++#define NV50_2D_SIFC_FORMAT_A2B10G10R10_UINT 0x000000d2 ++#define NV50_2D_SIFC_FORMAT_A8B8G8R8_UNORM 0x000000d5 ++#define NV50_2D_SIFC_FORMAT_A8B8G8R8_SRGB 0x000000d6 ++#define NV50_2D_SIFC_FORMAT_A8B8G8R8_SNORM 0x000000d7 ++#define NV50_2D_SIFC_FORMAT_A8B8G8R8_SINT 0x000000d8 ++#define NV50_2D_SIFC_FORMAT_A8B8G8R8_UINT 0x000000d9 ++#define NV50_2D_SIFC_FORMAT_R16G16_UNORM 0x000000da ++#define NV50_2D_SIFC_FORMAT_R16G16_SNORM 0x000000db ++#define NV50_2D_SIFC_FORMAT_R16G16_SINT 0x000000dc ++#define NV50_2D_SIFC_FORMAT_R16G16_UINT 0x000000dd ++#define NV50_2D_SIFC_FORMAT_R16G16_FLOAT 0x000000de ++#define NV50_2D_SIFC_FORMAT_A2R10G10B10_UNORM 0x000000df ++#define NV50_2D_SIFC_FORMAT_B10G11R11_FLOAT 0x000000e0 ++#define NV50_2D_SIFC_FORMAT_R32_FLOAT 0x000000e5 ++#define NV50_2D_SIFC_FORMAT_X8R8G8B8_UNORM 0x000000e6 ++#define NV50_2D_SIFC_FORMAT_X8R8G8B8_SRGB 0x000000e7 ++#define NV50_2D_SIFC_FORMAT_R5G6B5_UNORM 0x000000e8 ++#define NV50_2D_SIFC_FORMAT_A1R5G5B5_UNORM 0x000000e9 ++#define NV50_2D_SIFC_FORMAT_R8G8_UNORM 0x000000ea ++#define NV50_2D_SIFC_FORMAT_R8G8_SNORM 0x000000eb ++#define NV50_2D_SIFC_FORMAT_R8G8_SINT 0x000000ec ++#define NV50_2D_SIFC_FORMAT_R8G8_UINT 0x000000ed ++#define NV50_2D_SIFC_FORMAT_R16_UNORM 0x000000ee ++#define NV50_2D_SIFC_FORMAT_R16_SNORM 0x000000ef ++#define NV50_2D_SIFC_FORMAT_R16_SINT 0x000000f0 ++#define NV50_2D_SIFC_FORMAT_R16_UINT 0x000000f1 ++#define NV50_2D_SIFC_FORMAT_R16_FLOAT 0x000000f2 ++#define NV50_2D_SIFC_FORMAT_R8_UNORM 0x000000f3 ++#define NV50_2D_SIFC_FORMAT_R8_SNORM 0x000000f4 ++#define NV50_2D_SIFC_FORMAT_R8_SINT 0x000000f5 ++#define NV50_2D_SIFC_FORMAT_R8_UINT 0x000000f6 ++#define NV50_2D_SIFC_FORMAT_A8_UNORM 0x000000f7 ++#define NV50_2D_SIFC_FORMAT_X1R5G5B5_UNORM 0x000000f8 ++#define NV50_2D_SIFC_FORMAT_X8B8G8R8_UNORM 0x000000f9 ++#define NV50_2D_SIFC_FORMAT_X8B8G8R8_SRGB 0x000000fa ++#define NV50_2D_SIFC_BITMAP_UNK808 0x00000808 ++#define NV50_2D_SIFC_BITMAP_LSB_FIRST 0x0000080c ++#define NV50_2D_SIFC_BITMAP_LINE_PACK_MODE 0x00000810 ++#define NV50_2D_SIFC_BITMAP_LINE_PACK_MODE_PACKED 0x00000000 ++#define NV50_2D_SIFC_BITMAP_LINE_PACK_MODE_ALIGN_BYTE 0x00000001 ++#define NV50_2D_SIFC_BITMAP_LINE_PACK_MODE_ALIGN_WORD 0x00000002 ++#define NV50_2D_SIFC_BITMAP_COLOR_BIT0 0x00000814 ++#define NV50_2D_SIFC_BITMAP_COLOR_BIT1 0x00000818 ++#define NV50_2D_SIFC_BITMAP_WRITE_BIT0_ENABLE 0x0000081c ++#define NV50_2D_SIFC_WIDTH 0x00000838 ++#define NV50_2D_SIFC_HEIGHT 0x0000083c ++#define NV50_2D_SIFC_DX_DU_FRACT 0x00000840 ++#define NV50_2D_SIFC_DX_DU_INT 0x00000844 ++#define NV50_2D_SIFC_DY_DV_FRACT 0x00000848 ++#define NV50_2D_SIFC_DY_DV_INT 0x0000084c ++#define NV50_2D_SIFC_DST_X_FRACT 0x00000850 ++#define NV50_2D_SIFC_DST_X_INT 0x00000854 ++#define NV50_2D_SIFC_DST_Y_FRACT 0x00000858 ++#define NV50_2D_SIFC_DST_Y_INT 0x0000085c ++#define NV50_2D_SIFC_DATA 0x00000860 ++#define NV50_2D_BLIT_DST_X 0x000008b0 ++#define NV50_2D_BLIT_DST_Y 0x000008b4 ++#define NV50_2D_BLIT_DST_W 0x000008b8 ++#define NV50_2D_BLIT_DST_H 0x000008bc ++#define NV50_2D_BLIT_DU_DX_FRACT 0x000008c0 ++#define NV50_2D_BLIT_DU_DX_INT 0x000008c4 ++#define NV50_2D_BLIT_DV_DY_FRACT 0x000008c8 ++#define NV50_2D_BLIT_DV_DY_INT 0x000008cc ++#define NV50_2D_BLIT_SRC_X_FRACT 0x000008d0 ++#define NV50_2D_BLIT_SRC_X_INT 0x000008d4 ++#define NV50_2D_BLIT_SRC_Y_FRACT 0x000008d8 ++#define NV50_2D_BLIT_SRC_Y_INT 0x000008dc ++ ++ ++#define NV50TCL 0x00005097 ++ ++#define NV50TCL_NOP 0x00000100 ++#define NV50TCL_NOTIFY 0x00000104 ++#define NV50TCL_SERIALIZE 0x00000110 ++#define NV50TCL_DMA_NOTIFY 0x00000180 ++#define NV50TCL_DMA_ZETA 0x00000184 ++#define NV50TCL_DMA_QUERY 0x00000188 ++#define NV50TCL_DMA_VTXBUF0 0x0000018c ++#define NV50TCL_DMA_LOCAL 0x00000190 ++#define NV50TCL_DMA_STACK 0x00000194 ++#define NV50TCL_DMA_CODE_CB 0x00000198 ++#define NV50TCL_DMA_TSC 0x0000019c ++#define NV50TCL_DMA_TIC 0x000001a0 ++#define NV50TCL_DMA_TEXTURE 0x000001a4 ++#define NV50TCL_DMA_STRMOUT 0x000001a8 ++#define NV50TCL_DMA_UNK01AC 0x000001ac ++#define NV50TCL_DMA_COLOR(x) (0x000001c0+((x)*4)) ++#define NV50TCL_DMA_COLOR__SIZE 0x00000008 ++#define NV50TCL_RT_ADDRESS_HIGH(x) (0x00000200+((x)*32)) ++#define NV50TCL_RT_ADDRESS_HIGH__SIZE 0x00000008 ++#define NV50TCL_RT_ADDRESS_LOW(x) (0x00000204+((x)*32)) ++#define NV50TCL_RT_ADDRESS_LOW__SIZE 0x00000008 ++#define NV50TCL_RT_FORMAT(x) (0x00000208+((x)*32)) ++#define NV50TCL_RT_FORMAT__SIZE 0x00000008 ++#define NV50TCL_RT_FORMAT_R32G32B32A32_FLOAT 0x000000c0 ++#define NV50TCL_RT_FORMAT_R32G32B32A32_SINT 0x000000c1 ++#define NV50TCL_RT_FORMAT_R32G32B32A32_UINT 0x000000c2 ++#define NV50TCL_RT_FORMAT_R32G32B32X32_FLOAT 0x000000c3 ++#define NV50TCL_RT_FORMAT_R16G16B16A16_UNORM 0x000000c6 ++#define NV50TCL_RT_FORMAT_R16G16B16A16_SNORM 0x000000c7 ++#define NV50TCL_RT_FORMAT_R16G16B16A16_SINT 0x000000c8 ++#define NV50TCL_RT_FORMAT_R16G16B16A16_UINT 0x000000c9 ++#define NV50TCL_RT_FORMAT_R16G16B16A16_FLOAT 0x000000ca ++#define NV50TCL_RT_FORMAT_R32G32_FLOAT 0x000000cb ++#define NV50TCL_RT_FORMAT_R32G32_SINT 0x000000cc ++#define NV50TCL_RT_FORMAT_R32G32_UINT 0x000000cd ++#define NV50TCL_RT_FORMAT_R16G16B16X16_FLOAT 0x000000ce ++#define NV50TCL_RT_FORMAT_A8R8G8B8_UNORM 0x000000cf ++#define NV50TCL_RT_FORMAT_A8R8G8B8_SRGB 0x000000d0 ++#define NV50TCL_RT_FORMAT_A2B10G10R10_UNORM 0x000000d1 ++#define NV50TCL_RT_FORMAT_A2B10G10R10_UINT 0x000000d2 ++#define NV50TCL_RT_FORMAT_A8B8G8R8_UNORM 0x000000d5 ++#define NV50TCL_RT_FORMAT_A8B8G8R8_SRGB 0x000000d6 ++#define NV50TCL_RT_FORMAT_A8B8G8R8_SNORM 0x000000d7 ++#define NV50TCL_RT_FORMAT_A8B8G8R8_SINT 0x000000d8 ++#define NV50TCL_RT_FORMAT_A8B8G8R8_UINT 0x000000d9 ++#define NV50TCL_RT_FORMAT_R16G16_UNORM 0x000000da ++#define NV50TCL_RT_FORMAT_R16G16_SNORM 0x000000db ++#define NV50TCL_RT_FORMAT_R16G16_SINT 0x000000dc ++#define NV50TCL_RT_FORMAT_R16G16_UINT 0x000000dd ++#define NV50TCL_RT_FORMAT_R16G16_FLOAT 0x000000de ++#define NV50TCL_RT_FORMAT_A2R10G10B10_UNORM 0x000000df ++#define NV50TCL_RT_FORMAT_B10G11R11_FLOAT 0x000000e0 ++#define NV50TCL_RT_FORMAT_R32_FLOAT 0x000000e5 ++#define NV50TCL_RT_FORMAT_X8R8G8B8_UNORM 0x000000e6 ++#define NV50TCL_RT_FORMAT_X8R8G8B8_SRGB 0x000000e7 ++#define NV50TCL_RT_FORMAT_R5G6B5_UNORM 0x000000e8 ++#define NV50TCL_RT_FORMAT_A1R5G5B5_UNORM 0x000000e9 ++#define NV50TCL_RT_FORMAT_R8G8_UNORM 0x000000ea ++#define NV50TCL_RT_FORMAT_R8G8_SNORM 0x000000eb ++#define NV50TCL_RT_FORMAT_R8G8_SINT 0x000000ec ++#define NV50TCL_RT_FORMAT_R8G8_UINT 0x000000ed ++#define NV50TCL_RT_FORMAT_R16_UNORM 0x000000ee ++#define NV50TCL_RT_FORMAT_R16_SNORM 0x000000ef ++#define NV50TCL_RT_FORMAT_R16_SINT 0x000000f0 ++#define NV50TCL_RT_FORMAT_R16_UINT 0x000000f1 ++#define NV50TCL_RT_FORMAT_R16_FLOAT 0x000000f2 ++#define NV50TCL_RT_FORMAT_R8_UNORM 0x000000f3 ++#define NV50TCL_RT_FORMAT_R8_SNORM 0x000000f4 ++#define NV50TCL_RT_FORMAT_R8_SINT 0x000000f5 ++#define NV50TCL_RT_FORMAT_R8_UINT 0x000000f6 ++#define NV50TCL_RT_FORMAT_A8_UNORM 0x000000f7 ++#define NV50TCL_RT_FORMAT_X1R5G5B5_UNORM 0x000000f8 ++#define NV50TCL_RT_FORMAT_X8B8G8R8_UNORM 0x000000f9 ++#define NV50TCL_RT_FORMAT_X8B8G8R8_SRGB 0x000000fa ++#define NV50TCL_RT_TILE_MODE(x) (0x0000020c+((x)*32)) ++#define NV50TCL_RT_TILE_MODE__SIZE 0x00000008 ++#define NV50TCL_RT_LAYER_STRIDE(x) (0x00000210+((x)*32)) ++#define NV50TCL_RT_LAYER_STRIDE__SIZE 0x00000008 ++#define NV50TCL_VTX_ATTR_1F(x) (0x00000300+((x)*4)) ++#define NV50TCL_VTX_ATTR_1F__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_2H(x) (0x00000340+((x)*4)) ++#define NV50TCL_VTX_ATTR_2H__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_2H_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_2H_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_2H_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_2H_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_2F_X(x) (0x00000380+((x)*8)) ++#define NV50TCL_VTX_ATTR_2F_X__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_2F_Y(x) (0x00000384+((x)*8)) ++#define NV50TCL_VTX_ATTR_2F_Y__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_3F_X(x) (0x00000400+((x)*16)) ++#define NV50TCL_VTX_ATTR_3F_X__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_3F_Y(x) (0x00000404+((x)*16)) ++#define NV50TCL_VTX_ATTR_3F_Y__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_3F_Z(x) (0x00000408+((x)*16)) ++#define NV50TCL_VTX_ATTR_3F_Z__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4F_X(x) (0x00000500+((x)*16)) ++#define NV50TCL_VTX_ATTR_4F_X__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4F_Y(x) (0x00000504+((x)*16)) ++#define NV50TCL_VTX_ATTR_4F_Y__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4F_Z(x) (0x00000508+((x)*16)) ++#define NV50TCL_VTX_ATTR_4F_Z__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4F_W(x) (0x0000050c+((x)*16)) ++#define NV50TCL_VTX_ATTR_4F_W__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4H_0(x) (0x00000600+((x)*8)) ++#define NV50TCL_VTX_ATTR_4H_0__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4H_0_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4H_0_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4H_0_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4H_0_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4H_1(x) (0x00000604+((x)*8)) ++#define NV50TCL_VTX_ATTR_4H_1__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4H_1_Z_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4H_1_Z_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4H_1_W_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4H_1_W_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_2I(x) (0x00000680+((x)*4)) ++#define NV50TCL_VTX_ATTR_2I__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_2I_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_2I_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_2I_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_2I_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_2NI(x) (0x000006c0+((x)*4)) ++#define NV50TCL_VTX_ATTR_2NI__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_2NI_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_2NI_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_2NI_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_2NI_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4I_0(x) (0x00000700+((x)*8)) ++#define NV50TCL_VTX_ATTR_4I_0__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4I_0_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4I_0_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4I_0_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4I_0_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4I_1(x) (0x00000704+((x)*8)) ++#define NV50TCL_VTX_ATTR_4I_1__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4I_1_Z_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4I_1_Z_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4I_1_W_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4I_1_W_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4NI_0(x) (0x00000780+((x)*8)) ++#define NV50TCL_VTX_ATTR_4NI_0__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4NI_0_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4NI_0_X_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4NI_0_Y_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4NI_0_Y_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4NI_1(x) (0x00000784+((x)*8)) ++#define NV50TCL_VTX_ATTR_4NI_1__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4NI_1_Z_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4NI_1_Z_MASK 0x0000ffff ++#define NV50TCL_VTX_ATTR_4NI_1_W_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4NI_1_W_MASK 0xffff0000 ++#define NV50TCL_VTX_ATTR_4UB(x) (0x00000800+((x)*4)) ++#define NV50TCL_VTX_ATTR_4UB__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4UB_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4UB_X_MASK 0x000000ff ++#define NV50TCL_VTX_ATTR_4UB_Y_SHIFT 8 ++#define NV50TCL_VTX_ATTR_4UB_Y_MASK 0x0000ff00 ++#define NV50TCL_VTX_ATTR_4UB_Z_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4UB_Z_MASK 0x00ff0000 ++#define NV50TCL_VTX_ATTR_4UB_W_SHIFT 24 ++#define NV50TCL_VTX_ATTR_4UB_W_MASK 0xff000000 ++#define NV50TCL_VTX_ATTR_4B(x) (0x00000840+((x)*4)) ++#define NV50TCL_VTX_ATTR_4B__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4B_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4B_X_MASK 0x000000ff ++#define NV50TCL_VTX_ATTR_4B_Y_SHIFT 8 ++#define NV50TCL_VTX_ATTR_4B_Y_MASK 0x0000ff00 ++#define NV50TCL_VTX_ATTR_4B_Z_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4B_Z_MASK 0x00ff0000 ++#define NV50TCL_VTX_ATTR_4B_W_SHIFT 24 ++#define NV50TCL_VTX_ATTR_4B_W_MASK 0xff000000 ++#define NV50TCL_VTX_ATTR_4NUB(x) (0x00000880+((x)*4)) ++#define NV50TCL_VTX_ATTR_4NUB__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4NUB_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4NUB_X_MASK 0x000000ff ++#define NV50TCL_VTX_ATTR_4NUB_Y_SHIFT 8 ++#define NV50TCL_VTX_ATTR_4NUB_Y_MASK 0x0000ff00 ++#define NV50TCL_VTX_ATTR_4NUB_Z_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4NUB_Z_MASK 0x00ff0000 ++#define NV50TCL_VTX_ATTR_4NUB_W_SHIFT 24 ++#define NV50TCL_VTX_ATTR_4NUB_W_MASK 0xff000000 ++#define NV50TCL_VTX_ATTR_4NB(x) (0x000008c0+((x)*4)) ++#define NV50TCL_VTX_ATTR_4NB__SIZE 0x00000010 ++#define NV50TCL_VTX_ATTR_4NB_X_SHIFT 0 ++#define NV50TCL_VTX_ATTR_4NB_X_MASK 0x000000ff ++#define NV50TCL_VTX_ATTR_4NB_Y_SHIFT 8 ++#define NV50TCL_VTX_ATTR_4NB_Y_MASK 0x0000ff00 ++#define NV50TCL_VTX_ATTR_4NB_Z_SHIFT 16 ++#define NV50TCL_VTX_ATTR_4NB_Z_MASK 0x00ff0000 ++#define NV50TCL_VTX_ATTR_4NB_W_SHIFT 24 ++#define NV50TCL_VTX_ATTR_4NB_W_MASK 0xff000000 ++#define NV50TCL_VERTEX_ARRAY_FORMAT(x) (0x00000900+((x)*16)) ++#define NV50TCL_VERTEX_ARRAY_FORMAT__SIZE 0x00000010 ++#define NV50TCL_VERTEX_ARRAY_FORMAT_STRIDE_SHIFT 0 ++#define NV50TCL_VERTEX_ARRAY_FORMAT_STRIDE_MASK 0x00000fff ++#define NV50TCL_VERTEX_ARRAY_FORMAT_ENABLE (1 << 29) ++#define NV50TCL_VERTEX_ARRAY_START_HIGH(x) (0x00000904+((x)*16)) ++#define NV50TCL_VERTEX_ARRAY_START_HIGH__SIZE 0x00000010 ++#define NV50TCL_VERTEX_ARRAY_START_LOW(x) (0x00000908+((x)*16)) ++#define NV50TCL_VERTEX_ARRAY_START_LOW__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_SCALE_X(x) (0x00000a00+((x)*32)) ++#define NV50TCL_VIEWPORT_SCALE_X__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_SCALE_Y(x) (0x00000a04+((x)*32)) ++#define NV50TCL_VIEWPORT_SCALE_Y__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_SCALE_Z(x) (0x00000a08+((x)*32)) ++#define NV50TCL_VIEWPORT_SCALE_Z__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_TRANSLATE_X(x) (0x00000a0c+((x)*32)) ++#define NV50TCL_VIEWPORT_TRANSLATE_X__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_TRANSLATE_Y(x) (0x00000a10+((x)*32)) ++#define NV50TCL_VIEWPORT_TRANSLATE_Y__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_TRANSLATE_Z(x) (0x00000a14+((x)*32)) ++#define NV50TCL_VIEWPORT_TRANSLATE_Z__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_HORIZ(x) (0x00000c00+((x)*16)) ++#define NV50TCL_VIEWPORT_HORIZ__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_HORIZ_X_SHIFT 0 ++#define NV50TCL_VIEWPORT_HORIZ_X_MASK 0x0000ffff ++#define NV50TCL_VIEWPORT_HORIZ_W_SHIFT 16 ++#define NV50TCL_VIEWPORT_HORIZ_W_MASK 0xffff0000 ++#define NV50TCL_VIEWPORT_VERT(x) (0x00000c04+((x)*16)) ++#define NV50TCL_VIEWPORT_VERT__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_VERT_Y_SHIFT 0 ++#define NV50TCL_VIEWPORT_VERT_Y_MASK 0x0000ffff ++#define NV50TCL_VIEWPORT_VERT_H_SHIFT 16 ++#define NV50TCL_VIEWPORT_VERT_H_MASK 0xffff0000 ++#define NV50TCL_DEPTH_RANGE_NEAR(x) (0x00000c08+((x)*16)) ++#define NV50TCL_DEPTH_RANGE_NEAR__SIZE 0x00000010 ++#define NV50TCL_DEPTH_RANGE_FAR(x) (0x00000c0c+((x)*16)) ++#define NV50TCL_DEPTH_RANGE_FAR__SIZE 0x00000010 ++#define NV50TCL_VIEWPORT_CLIP_HORIZ(x) (0x00000d00+((x)*8)) ++#define NV50TCL_VIEWPORT_CLIP_HORIZ__SIZE 0x00000008 ++#define NV50TCL_VIEWPORT_CLIP_VERT(x) (0x00000d04+((x)*8)) ++#define NV50TCL_VIEWPORT_CLIP_VERT__SIZE 0x00000008 ++#define NV50TCL_VERTEX_BUFFER_FIRST 0x00000d74 ++#define NV50TCL_VERTEX_BUFFER_COUNT 0x00000d78 ++#define NV50TCL_CLEAR_COLOR(x) (0x00000d80+((x)*4)) ++#define NV50TCL_CLEAR_COLOR__SIZE 0x00000004 ++#define NV50TCL_CLEAR_DEPTH 0x00000d90 ++#define NV50TCL_STACK_ADDRESS_HIGH 0x00000d94 ++#define NV50TCL_STACK_ADDRESS_LOW 0x00000d98 ++#define NV50TCL_STACK_SIZE_LOG 0x00000d9c ++#define NV50TCL_CLEAR_STENCIL 0x00000da0 ++#define NV50TCL_STRMOUT_PRIMITIVE_COUNT 0x00000da8 ++#define NV50TCL_POLYGON_MODE_FRONT 0x00000dac ++#define NV50TCL_POLYGON_MODE_FRONT_POINT 0x00001b00 ++#define NV50TCL_POLYGON_MODE_FRONT_LINE 0x00001b01 ++#define NV50TCL_POLYGON_MODE_FRONT_FILL 0x00001b02 ++#define NV50TCL_POLYGON_MODE_BACK 0x00000db0 ++#define NV50TCL_POLYGON_MODE_BACK_POINT 0x00001b00 ++#define NV50TCL_POLYGON_MODE_BACK_LINE 0x00001b01 ++#define NV50TCL_POLYGON_MODE_BACK_FILL 0x00001b02 ++#define NV50TCL_POLYGON_SMOOTH_ENABLE 0x00000db4 ++#define NV50TCL_POLYGON_OFFSET_POINT_ENABLE 0x00000dc0 ++#define NV50TCL_POLYGON_OFFSET_LINE_ENABLE 0x00000dc4 ++#define NV50TCL_POLYGON_OFFSET_FILL_ENABLE 0x00000dc8 ++#define NV50TCL_WATCHDOG_TIMER 0x00000de4 ++#define NV50TCL_WINDOW_OFFSET_X 0x00000df8 ++#define NV50TCL_WINDOW_OFFSET_Y 0x00000dfc ++#define NV50TCL_SCISSOR_ENABLE(x) (0x00000e00+((x)*16)) ++#define NV50TCL_SCISSOR_ENABLE__SIZE 0x00000010 ++#define NV50TCL_SCISSOR_HORIZ(x) (0x00000e04+((x)*16)) ++#define NV50TCL_SCISSOR_HORIZ__SIZE 0x00000010 ++#define NV50TCL_SCISSOR_HORIZ_MIN_SHIFT 0 ++#define NV50TCL_SCISSOR_HORIZ_MIN_MASK 0x0000ffff ++#define NV50TCL_SCISSOR_HORIZ_MAX_SHIFT 16 ++#define NV50TCL_SCISSOR_HORIZ_MAX_MASK 0xffff0000 ++#define NV50TCL_SCISSOR_VERT(x) (0x00000e08+((x)*16)) ++#define NV50TCL_SCISSOR_VERT__SIZE 0x00000010 ++#define NV50TCL_SCISSOR_VERT_MIN_SHIFT 0 ++#define NV50TCL_SCISSOR_VERT_MIN_MASK 0x0000ffff ++#define NV50TCL_SCISSOR_VERT_MAX_SHIFT 16 ++#define NV50TCL_SCISSOR_VERT_MAX_MASK 0xffff0000 ++#define NV50TCL_CB_ADDR 0x00000f00 ++#define NV50TCL_CB_ADDR_ID_SHIFT 8 ++#define NV50TCL_CB_ADDR_ID_MASK 0x003fff00 ++#define NV50TCL_CB_ADDR_BUFFER_SHIFT 0 ++#define NV50TCL_CB_ADDR_BUFFER_MASK 0x0000007f ++#define NV50TCL_CB_DATA(x) (0x00000f04+((x)*4)) ++#define NV50TCL_CB_DATA__SIZE 0x00000010 ++#define NV50TCL_LOCAL_WARPS_LOG_ALLOC 0x00000f44 ++#define NV50TCL_LOCAL_WARPS_NO_CLAMP 0x00000f48 ++#define NV50TCL_STACK_WARPS_LOG_ALLOC 0x00000f4c ++#define NV50TCL_STACK_WARPS_NO_CLAMP 0x00000f50 ++#define NV50TCL_STENCIL_BACK_FUNC_REF 0x00000f54 ++#define NV50TCL_STENCIL_BACK_MASK 0x00000f58 ++#define NV50TCL_STENCIL_BACK_FUNC_MASK 0x00000f5c ++#define NV50TCL_GP_ADDRESS_HIGH 0x00000f70 ++#define NV50TCL_GP_ADDRESS_LOW 0x00000f74 ++#define NV50TCL_VP_ADDRESS_HIGH 0x00000f7c ++#define NV50TCL_VP_ADDRESS_LOW 0x00000f80 ++#define NV50TCL_UNK0F84_ADDRESS_HIGH 0x00000f84 ++#define NV50TCL_UNK0F84_ADDRESS_LOW 0x00000f88 ++#define NV50TCL_DEPTH_BOUNDS(x) (0x00000f9c+((x)*4)) ++#define NV50TCL_DEPTH_BOUNDS__SIZE 0x00000002 ++#define NV50TCL_FP_ADDRESS_HIGH 0x00000fa4 ++#define NV50TCL_FP_ADDRESS_LOW 0x00000fa8 ++#define NV50TCL_MSAA_MASK(x) (0x00000fbc+((x)*4)) ++#define NV50TCL_MSAA_MASK__SIZE 0x00000004 ++#define NV50TCL_ZETA_ADDRESS_HIGH 0x00000fe0 ++#define NV50TCL_ZETA_ADDRESS_LOW 0x00000fe4 ++#define NV50TCL_ZETA_FORMAT 0x00000fe8 ++#define NV50TCL_ZETA_FORMAT_Z32_FLOAT 0x0000000a ++#define NV50TCL_ZETA_FORMAT_Z16_UNORM 0x00000013 ++#define NV50TCL_ZETA_FORMAT_Z24S8_UNORM 0x00000014 ++#define NV50TCL_ZETA_FORMAT_X8Z24_UNORM 0x00000015 ++#define NV50TCL_ZETA_FORMAT_S8Z24_UNORM 0x00000016 ++#define NV50TCL_ZETA_FORMAT_Z32_FLOAT_X24S8_UNORM 0x00000019 ++#define NV50TCL_ZETA_TILE_MODE 0x00000fec ++#define NV50TCL_ZETA_LAYER_STRIDE 0x00000ff0 ++#define NV50TCL_SCREEN_SCISSOR_HORIZ 0x00000ff4 ++#define NV50TCL_SCREEN_SCISSOR_HORIZ_W_SHIFT 16 ++#define NV50TCL_SCREEN_SCISSOR_HORIZ_W_MASK 0xffff0000 ++#define NV50TCL_SCREEN_SCISSOR_HORIZ_X_SHIFT 0 ++#define NV50TCL_SCREEN_SCISSOR_HORIZ_X_MASK 0x0000ffff ++#define NV50TCL_SCREEN_SCISSOR_VERT 0x00000ff8 ++#define NV50TCL_SCREEN_SCISSOR_VERT_H_SHIFT 16 ++#define NV50TCL_SCREEN_SCISSOR_VERT_H_MASK 0xffff0000 ++#define NV50TCL_SCREEN_SCISSOR_VERT_Y_SHIFT 0 ++#define NV50TCL_SCREEN_SCISSOR_VERT_Y_MASK 0x0000ffff ++#define NV50TCL_VERTEX_ARRAY_LIMIT_HIGH(x) (0x00001080+((x)*8)) ++#define NV50TCL_VERTEX_ARRAY_LIMIT_HIGH__SIZE 0x00000010 ++#define NV50TCL_VERTEX_ARRAY_LIMIT_LOW(x) (0x00001084+((x)*8)) ++#define NV50TCL_VERTEX_ARRAY_LIMIT_LOW__SIZE 0x00000010 ++#define NV50TCL_RT_CONTROL 0x0000121c ++#define NV50TCL_RT_CONTROL_COUNT_SHIFT 0 ++#define NV50TCL_RT_CONTROL_COUNT_MASK 0x0000000f ++#define NV50TCL_RT_CONTROL_MAP0_SHIFT 4 ++#define NV50TCL_RT_CONTROL_MAP0_MASK 0x00000070 ++#define NV50TCL_RT_CONTROL_MAP1_SHIFT 7 ++#define NV50TCL_RT_CONTROL_MAP1_MASK 0x00000380 ++#define NV50TCL_RT_CONTROL_MAP2_SHIFT 10 ++#define NV50TCL_RT_CONTROL_MAP2_MASK 0x00001c00 ++#define NV50TCL_RT_CONTROL_MAP3_SHIFT 13 ++#define NV50TCL_RT_CONTROL_MAP3_MASK 0x0000e000 ++#define NV50TCL_RT_CONTROL_MAP4_SHIFT 16 ++#define NV50TCL_RT_CONTROL_MAP4_MASK 0x00070000 ++#define NV50TCL_RT_CONTROL_MAP5_SHIFT 19 ++#define NV50TCL_RT_CONTROL_MAP5_MASK 0x00380000 ++#define NV50TCL_RT_CONTROL_MAP6_SHIFT 22 ++#define NV50TCL_RT_CONTROL_MAP6_MASK 0x01c00000 ++#define NV50TCL_RT_CONTROL_MAP7_SHIFT 25 ++#define NV50TCL_RT_CONTROL_MAP7_MASK 0x0e000000 ++#define NV50TCL_RT_ARRAY_MODE 0x00001224 ++#define NV50TCL_RT_ARRAY_MODE_LAYERS_SHIFT 0 ++#define NV50TCL_RT_ARRAY_MODE_LAYERS_MASK 0x0000ffff ++#define NV50TCL_RT_ARRAY_MODE_VOLUME (1 << 16) ++#define NV50TCL_ZETA_HORIZ 0x00001228 ++#define NV50TCL_ZETA_VERT 0x0000122c ++#define NV50TCL_ZETA_ARRAY_MODE 0x00001230 ++#define NV50TCL_ZETA_ARRAY_MODE_LAYERS_SHIFT 0 ++#define NV50TCL_ZETA_ARRAY_MODE_LAYERS_MASK 0x0000ffff ++#define NV50TCL_ZETA_ARRAY_MODE_UNK (1 << 16) ++#define NV50TCL_LINKED_TSC 0x00001234 ++#define NV50TCL_RT_HORIZ(x) (0x00001240+((x)*8)) ++#define NV50TCL_RT_HORIZ__SIZE 0x00000008 ++#define NV50TCL_RT_VERT(x) (0x00001244+((x)*8)) ++#define NV50TCL_RT_VERT__SIZE 0x00000008 ++#define NV50TCL_CB_DEF_ADDRESS_HIGH 0x00001280 ++#define NV50TCL_CB_DEF_ADDRESS_LOW 0x00001284 ++#define NV50TCL_CB_DEF_SET 0x00001288 ++#define NV50TCL_CB_DEF_SET_SIZE_SHIFT 0 ++#define NV50TCL_CB_DEF_SET_SIZE_MASK 0x0000ffff ++#define NV50TCL_CB_DEF_SET_BUFFER_SHIFT 16 ++#define NV50TCL_CB_DEF_SET_BUFFER_MASK 0x007f0000 ++#define NV50TCL_STRMOUT_BUFFERS_CTRL 0x00001294 ++#define NV50TCL_STRMOUT_BUFFERS_CTRL_INTERLEAVED (1 << 0) ++#define NV50TCL_STRMOUT_BUFFERS_CTRL_SEPARATE_SHIFT 4 ++#define NV50TCL_STRMOUT_BUFFERS_CTRL_SEPARATE_MASK 0x000000f0 ++#define NV50TCL_STRMOUT_BUFFERS_CTRL_STRIDE_SHIFT 8 ++#define NV50TCL_STRMOUT_BUFFERS_CTRL_STRIDE_MASK 0x0000ff00 ++#define NV50TCL_FP_RESULT_COUNT 0x00001298 ++#define NV50TCL_DEPTH_TEST_ENABLE 0x000012cc ++#define NV50TCL_SHADE_MODEL 0x000012d4 ++#define NV50TCL_SHADE_MODEL_FLAT 0x00001d00 ++#define NV50TCL_SHADE_MODEL_SMOOTH 0x00001d01 ++#define NV50TCL_LOCAL_ADDRESS_HIGH 0x000012d8 ++#define NV50TCL_LOCAL_ADDRESS_LOW 0x000012dc ++#define NV50TCL_LOCAL_SIZE_LOG 0x000012e0 ++#define NV50TCL_DEPTH_WRITE_ENABLE 0x000012e8 ++#define NV50TCL_ALPHA_TEST_ENABLE 0x000012ec ++#define NV50TCL_PM_SET(x) (0x000012f0+((x)*4)) ++#define NV50TCL_PM_SET__SIZE 0x00000004 ++#define NV50TCL_VB_ELEMENT_U8_SETUP 0x00001300 ++#define NV50TCL_VB_ELEMENT_U8_SETUP_OFFSET_SHIFT 30 ++#define NV50TCL_VB_ELEMENT_U8_SETUP_OFFSET_MASK 0xc0000000 ++#define NV50TCL_VB_ELEMENT_U8_SETUP_COUNT_SHIFT 0 ++#define NV50TCL_VB_ELEMENT_U8_SETUP_COUNT_MASK 0x3fffffff ++#define NV50TCL_VB_ELEMENT_U8 0x00001304 ++#define NV50TCL_VB_ELEMENT_U8_I0_SHIFT 0 ++#define NV50TCL_VB_ELEMENT_U8_I0_MASK 0x000000ff ++#define NV50TCL_VB_ELEMENT_U8_I1_SHIFT 8 ++#define NV50TCL_VB_ELEMENT_U8_I1_MASK 0x0000ff00 ++#define NV50TCL_VB_ELEMENT_U8_I2_SHIFT 16 ++#define NV50TCL_VB_ELEMENT_U8_I2_MASK 0x00ff0000 ++#define NV50TCL_VB_ELEMENT_U8_I3_SHIFT 24 ++#define NV50TCL_VB_ELEMENT_U8_I3_MASK 0xff000000 ++#define NV50TCL_DEPTH_TEST_FUNC 0x0000130c ++#define NV50TCL_DEPTH_TEST_FUNC_NEVER 0x00000200 ++#define NV50TCL_DEPTH_TEST_FUNC_LESS 0x00000201 ++#define NV50TCL_DEPTH_TEST_FUNC_EQUAL 0x00000202 ++#define NV50TCL_DEPTH_TEST_FUNC_LEQUAL 0x00000203 ++#define NV50TCL_DEPTH_TEST_FUNC_GREATER 0x00000204 ++#define NV50TCL_DEPTH_TEST_FUNC_NOTEQUAL 0x00000205 ++#define NV50TCL_DEPTH_TEST_FUNC_GEQUAL 0x00000206 ++#define NV50TCL_DEPTH_TEST_FUNC_ALWAYS 0x00000207 ++#define NV50TCL_ALPHA_TEST_REF 0x00001310 ++#define NV50TCL_ALPHA_TEST_FUNC 0x00001314 ++#define NV50TCL_ALPHA_TEST_FUNC_NEVER 0x00000200 ++#define NV50TCL_ALPHA_TEST_FUNC_LESS 0x00000201 ++#define NV50TCL_ALPHA_TEST_FUNC_EQUAL 0x00000202 ++#define NV50TCL_ALPHA_TEST_FUNC_LEQUAL 0x00000203 ++#define NV50TCL_ALPHA_TEST_FUNC_GREATER 0x00000204 ++#define NV50TCL_ALPHA_TEST_FUNC_NOTEQUAL 0x00000205 ++#define NV50TCL_ALPHA_TEST_FUNC_GEQUAL 0x00000206 ++#define NV50TCL_ALPHA_TEST_FUNC_ALWAYS 0x00000207 ++#define NV50TCL_BLEND_COLOR(x) (0x0000131c+((x)*4)) ++#define NV50TCL_BLEND_COLOR__SIZE 0x00000004 ++#define NV50TCL_TIC_FLUSH 0x00001330 ++#define NV50TCL_TSC_FLUSH 0x00001334 ++#define NV50TCL_TEX_CACHE_CTL 0x00001338 ++#define NV50TCL_BLEND_EQUATION_RGB 0x00001340 ++#define NV50TCL_BLEND_EQUATION_RGB_FUNC_ADD 0x00008006 ++#define NV50TCL_BLEND_EQUATION_RGB_MIN 0x00008007 ++#define NV50TCL_BLEND_EQUATION_RGB_MAX 0x00008008 ++#define NV50TCL_BLEND_EQUATION_RGB_FUNC_SUBTRACT 0x0000800a ++#define NV50TCL_BLEND_EQUATION_RGB_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV50TCL_BLEND_FUNC_SRC_RGB 0x00001344 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ZERO 0x00000000 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE 0x00000001 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_SRC_COLOR 0x00000300 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA 0x00000302 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_DST_ALPHA 0x00000304 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_DST_COLOR 0x00000306 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_CONSTANT_COLOR 0x00008001 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV50TCL_BLEND_FUNC_SRC_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV50TCL_BLEND_FUNC_DST_RGB 0x00001348 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ZERO 0x00000000 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE 0x00000001 ++#define NV50TCL_BLEND_FUNC_DST_RGB_SRC_COLOR 0x00000300 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV50TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA 0x00000302 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV50TCL_BLEND_FUNC_DST_RGB_DST_ALPHA 0x00000304 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV50TCL_BLEND_FUNC_DST_RGB_DST_COLOR 0x00000306 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV50TCL_BLEND_FUNC_DST_RGB_SRC_ALPHA_SATURATE 0x00000308 ++#define NV50TCL_BLEND_FUNC_DST_RGB_CONSTANT_COLOR 0x00008001 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV50TCL_BLEND_FUNC_DST_RGB_CONSTANT_ALPHA 0x00008003 ++#define NV50TCL_BLEND_FUNC_DST_RGB_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV50TCL_BLEND_EQUATION_ALPHA 0x0000134c ++#define NV50TCL_BLEND_EQUATION_ALPHA_FUNC_ADD 0x00008006 ++#define NV50TCL_BLEND_EQUATION_ALPHA_MIN 0x00008007 ++#define NV50TCL_BLEND_EQUATION_ALPHA_MAX 0x00008008 ++#define NV50TCL_BLEND_EQUATION_ALPHA_FUNC_SUBTRACT 0x0000800a ++#define NV50TCL_BLEND_EQUATION_ALPHA_FUNC_REVERSE_SUBTRACT 0x0000800b ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA 0x00001350 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ZERO 0x00000000 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE 0x00000001 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_SRC_COLOR 0x00000300 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA 0x00000302 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_DST_ALPHA 0x00000304 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_DST_COLOR 0x00000306 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_SRC_ALPHA_SATURATE 0x00000308 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_COLOR 0x00008001 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_CONSTANT_ALPHA 0x00008003 ++#define NV50TCL_BLEND_FUNC_SRC_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA 0x00001358 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ZERO 0x00000000 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE 0x00000001 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_SRC_COLOR 0x00000300 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_COLOR 0x00000301 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA 0x00000302 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_SRC_ALPHA 0x00000303 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_DST_ALPHA 0x00000304 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_ALPHA 0x00000305 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_DST_COLOR 0x00000306 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_DST_COLOR 0x00000307 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_SRC_ALPHA_SATURATE 0x00000308 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_COLOR 0x00008001 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_COLOR 0x00008002 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_CONSTANT_ALPHA 0x00008003 ++#define NV50TCL_BLEND_FUNC_DST_ALPHA_ONE_MINUS_CONSTANT_ALPHA 0x00008004 ++#define NV50TCL_BLEND_ENABLE(x) (0x00001360+((x)*4)) ++#define NV50TCL_BLEND_ENABLE__SIZE 0x00000008 ++#define NV50TCL_STENCIL_FRONT_ENABLE 0x00001380 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL 0x00001384 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_ZERO 0x00000000 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_INVERT 0x0000150a ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_INCR 0x00001e02 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_DECR 0x00001e03 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_FRONT_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL 0x00001388 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_ZERO 0x00000000 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_INVERT 0x0000150a ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_INCR 0x00001e02 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_DECR 0x00001e03 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_FRONT_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS 0x0000138c ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_ZERO 0x00000000 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_INVERT 0x0000150a ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_INCR 0x00001e02 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_DECR 0x00001e03 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_FRONT_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC 0x00001390 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_NEVER 0x00000200 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_LESS 0x00000201 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_EQUAL 0x00000202 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_GREATER 0x00000204 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV50TCL_STENCIL_FRONT_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV50TCL_STENCIL_FRONT_FUNC_REF 0x00001394 ++#define NV50TCL_STENCIL_FRONT_MASK 0x00001398 ++#define NV50TCL_STENCIL_FRONT_FUNC_MASK 0x0000139c ++#define NV50TCL_FRAG_COLOR_CLAMP_EN 0x000013a8 ++#define NV50TCL_Y_ORIGIN_BOTTOM 0x000013ac ++#define NV50TCL_LINE_WIDTH 0x000013b0 ++#define NV50TCL_TEX_LIMITS(x) (0x000013b4+((x)*4)) ++#define NV50TCL_TEX_LIMITS__SIZE 0x00000003 ++#define NV50TCL_TEX_LIMITS_SAMPLERS_LOG2_SHIFT 0 ++#define NV50TCL_TEX_LIMITS_SAMPLERS_LOG2_MASK 0x0000000f ++#define NV50TCL_TEX_LIMITS_TEXTURES_LOG2_SHIFT 4 ++#define NV50TCL_TEX_LIMITS_TEXTURES_LOG2_MASK 0x000000f0 ++#define NV50TCL_POINT_COORD_REPLACE_MAP(x) (0x000013c0+((x)*4)) ++#define NV50TCL_POINT_COORD_REPLACE_MAP__SIZE 0x00000008 ++#define NV50TCL_VP_START_ID 0x0000140c ++#define NV50TCL_GP_START_ID 0x00001410 ++#define NV50TCL_FP_START_ID 0x00001414 ++#define NV50TCL_GP_VERTEX_OUTPUT_COUNT 0x00001420 ++#define NV50TCL_VB_ELEMENT_BASE 0x00001434 ++#define NV50TCL_CODE_CB_FLUSH 0x00001440 ++#define NV50TCL_BIND_TSC(x) (0x00001444+((x)*8)) ++#define NV50TCL_BIND_TSC__SIZE 0x00000003 ++#define NV50TCL_BIND_TSC_VALID (1 << 0) ++#define NV50TCL_BIND_TSC_SAMPLER_SHIFT 4 ++#define NV50TCL_BIND_TSC_SAMPLER_MASK 0x000000f0 ++#define NV50TCL_BIND_TSC_TSC_SHIFT 12 ++#define NV50TCL_BIND_TSC_TSC_MASK 0x001ff000 ++#define NV50TCL_BIND_TIC(x) (0x00001448+((x)*8)) ++#define NV50TCL_BIND_TIC__SIZE 0x00000003 ++#define NV50TCL_BIND_TIC_VALID (1 << 0) ++#define NV50TCL_BIND_TIC_TEXTURE_SHIFT 1 ++#define NV50TCL_BIND_TIC_TEXTURE_MASK 0x000001fe ++#define NV50TCL_BIND_TIC_TIC_SHIFT 9 ++#define NV50TCL_BIND_TIC_TIC_MASK 0x7ffffe00 ++#define NV50TCL_STRMOUT_MAP(x) (0x00001480+((x)*4)) ++#define NV50TCL_STRMOUT_MAP__SIZE 0x00000020 ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE 0x00001510 ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_0 (1 << 0) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_1 (1 << 1) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_2 (1 << 2) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_3 (1 << 3) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_4 (1 << 4) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_5 (1 << 5) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_6 (1 << 6) ++#define NV50TCL_VP_CLIP_DISTANCE_ENABLE_7 (1 << 7) ++#define NV50TCL_SAMPLECNT_ENABLE 0x00001514 ++#define NV50TCL_POINT_SIZE 0x00001518 ++#define NV50TCL_POINT_SPRITE_ENABLE 0x00001520 ++#define NV50TCL_SAMPLECNT_RESET 0x00001530 ++#define NV50TCL_ZETA_ENABLE 0x00001538 ++#define NV50TCL_MULTISAMPLE_CTRL 0x0000153c ++#define NV50TCL_MULTISAMPLE_CTRL_ALPHA_TO_COVERAGE (1 << 0) ++#define NV50TCL_MULTISAMPLE_CTRL_ALPHA_TO_ONE (1 << 4) ++#define NV50TCL_NOPERSPECTIVE_BITMAP(x) (0x00001540+((x)*4)) ++#define NV50TCL_NOPERSPECTIVE_BITMAP__SIZE 0x00000004 ++#define NV50TCL_COND_ADDRESS_HIGH 0x00001550 ++#define NV50TCL_COND_ADDRESS_LOW 0x00001554 ++#define NV50TCL_COND_MODE 0x00001558 ++#define NV50TCL_COND_MODE_NEVER 0x00000000 ++#define NV50TCL_COND_MODE_ALWAYS 0x00000001 ++#define NV50TCL_COND_MODE_RES 0x00000002 ++#define NV50TCL_COND_MODE_NOT_RES_AND_NOT_ID 0x00000003 ++#define NV50TCL_COND_MODE_RES_OR_ID 0x00000004 ++#define NV50TCL_TSC_ADDRESS_HIGH 0x0000155c ++#define NV50TCL_TSC_ADDRESS_LOW 0x00001560 ++#define NV50TCL_TSC_LIMIT 0x00001564 ++#define NV50TCL_POLYGON_OFFSET_FACTOR 0x0000156c ++#define NV50TCL_LINE_SMOOTH_ENABLE 0x00001570 ++#define NV50TCL_TIC_ADDRESS_HIGH 0x00001574 ++#define NV50TCL_TIC_ADDRESS_LOW 0x00001578 ++#define NV50TCL_TIC_LIMIT 0x0000157c ++#define NV50TCL_PM_CONTROL(x) (0x00001580+((x)*4)) ++#define NV50TCL_PM_CONTROL__SIZE 0x00000004 ++#define NV50TCL_PM_CONTROL_UNK0 (1 << 0) ++#define NV50TCL_PM_CONTROL_UNK1_SHIFT 4 ++#define NV50TCL_PM_CONTROL_UNK1_MASK 0x00000070 ++#define NV50TCL_PM_CONTROL_UNK2_SHIFT 8 ++#define NV50TCL_PM_CONTROL_UNK2_MASK 0xffffff00 ++#define NV50TCL_STENCIL_BACK_ENABLE 0x00001594 ++#define NV50TCL_STENCIL_BACK_OP_FAIL 0x00001598 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_ZERO 0x00000000 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_INVERT 0x0000150a ++#define NV50TCL_STENCIL_BACK_OP_FAIL_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_INCR 0x00001e02 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_DECR 0x00001e03 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_BACK_OP_FAIL_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL 0x0000159c ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_ZERO 0x00000000 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_INVERT 0x0000150a ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_INCR 0x00001e02 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_DECR 0x00001e03 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_BACK_OP_ZFAIL_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS 0x000015a0 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_ZERO 0x00000000 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_INVERT 0x0000150a ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_KEEP 0x00001e00 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_REPLACE 0x00001e01 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_INCR 0x00001e02 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_DECR 0x00001e03 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_INCR_WRAP 0x00008507 ++#define NV50TCL_STENCIL_BACK_OP_ZPASS_DECR_WRAP 0x00008508 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC 0x000015a4 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_NEVER 0x00000200 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_LESS 0x00000201 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_EQUAL 0x00000202 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_LEQUAL 0x00000203 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_GREATER 0x00000204 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_NOTEQUAL 0x00000205 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_GEQUAL 0x00000206 ++#define NV50TCL_STENCIL_BACK_FUNC_FUNC_ALWAYS 0x00000207 ++#define NV50TCL_FRAMEBUFFER_SRGB 0x000015b8 ++#define NV50TCL_POLYGON_OFFSET_UNITS 0x000015bc ++#define NV50TCL_GP_BUILTIN_RESULT_EN 0x000015cc ++#define NV50TCL_GP_BUILTIN_RESULT_EN_VPORT_IDX (1 << 0) ++#define NV50TCL_GP_BUILTIN_RESULT_EN_LAYER_IDX (1 << 16) ++#define NV50TCL_MULTISAMPLE_SAMPLES_LOG2 0x000015d0 ++#define NV50TCL_VERTEX_BEGIN 0x000015dc ++#define NV50TCL_VERTEX_BEGIN_POINTS 0x00000000 ++#define NV50TCL_VERTEX_BEGIN_LINES 0x00000001 ++#define NV50TCL_VERTEX_BEGIN_LINE_LOOP 0x00000002 ++#define NV50TCL_VERTEX_BEGIN_LINE_STRIP 0x00000003 ++#define NV50TCL_VERTEX_BEGIN_TRIANGLES 0x00000004 ++#define NV50TCL_VERTEX_BEGIN_TRIANGLE_STRIP 0x00000005 ++#define NV50TCL_VERTEX_BEGIN_TRIANGLE_FAN 0x00000006 ++#define NV50TCL_VERTEX_BEGIN_QUADS 0x00000007 ++#define NV50TCL_VERTEX_BEGIN_QUAD_STRIP 0x00000008 ++#define NV50TCL_VERTEX_BEGIN_POLYGON 0x00000009 ++#define NV50TCL_VERTEX_BEGIN_LINES_ADJACENCY 0x0000000a ++#define NV50TCL_VERTEX_BEGIN_LINE_STRIP_ADJACENCY 0x0000000b ++#define NV50TCL_VERTEX_BEGIN_TRIANGLES_ADJACENCY 0x0000000c ++#define NV50TCL_VERTEX_BEGIN_TRIANGLE_STRIP_ADJACENCY 0x0000000d ++#define NV50TCL_VERTEX_END 0x000015e0 ++#define NV50TCL_EDGEFLAG_ENABLE 0x000015e4 ++#define NV50TCL_VB_ELEMENT_U32 0x000015e8 ++#define NV50TCL_VB_ELEMENT_U16_SETUP 0x000015ec ++#define NV50TCL_VB_ELEMENT_U16_SETUP_OFFSET_SHIFT 30 ++#define NV50TCL_VB_ELEMENT_U16_SETUP_OFFSET_MASK 0xc0000000 ++#define NV50TCL_VB_ELEMENT_U16_SETUP_COUNT_SHIFT 0 ++#define NV50TCL_VB_ELEMENT_U16_SETUP_COUNT_MASK 0x3fffffff ++#define NV50TCL_VB_ELEMENT_U16 0x000015f0 ++#define NV50TCL_VB_ELEMENT_U16_I0_SHIFT 0 ++#define NV50TCL_VB_ELEMENT_U16_I0_MASK 0x0000ffff ++#define NV50TCL_VB_ELEMENT_U16_I1_SHIFT 16 ++#define NV50TCL_VB_ELEMENT_U16_I1_MASK 0xffff0000 ++#define NV50TCL_VERTEX_DATA 0x00001640 ++#define NV50TCL_PRIM_RESTART_ENABLE 0x00001644 ++#define NV50TCL_PRIM_RESTART_INDEX 0x00001648 ++#define NV50TCL_VP_GP_BUILTIN_ATTR_EN 0x0000164c ++#define NV50TCL_VP_GP_BUILTIN_ATTR_EN_VERTEX_ID (1 << 0) ++#define NV50TCL_VP_GP_BUILTIN_ATTR_EN_INSTANCE_ID (1 << 4) ++#define NV50TCL_VP_GP_BUILTIN_ATTR_EN_PRIMITIVE_ID (1 << 8) ++#define NV50TCL_VP_GP_BUILTIN_ATTR_EN_UNK12 (1 << 12) ++#define NV50TCL_VP_ATTR_EN_0 0x00001650 ++#define NV50TCL_VP_ATTR_EN_0_7_SHIFT 28 ++#define NV50TCL_VP_ATTR_EN_0_7_MASK 0xf0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XNNN 0x10000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NYNN 0x20000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XYNN 0x30000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NNZN 0x40000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XNZN 0x50000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NYZN 0x60000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XYZN 0x70000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NNNW 0x80000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XNNW 0x90000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NYNW 0xa0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XYNW 0xb0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NNZW 0xc0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XNZW 0xd0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_NYZW 0xe0000000 ++#define NV50TCL_VP_ATTR_EN_0_7_XYZW 0xf0000000 ++#define NV50TCL_VP_ATTR_EN_0_6_SHIFT 24 ++#define NV50TCL_VP_ATTR_EN_0_6_MASK 0x0f000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XNNN 0x01000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NYNN 0x02000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XYNN 0x03000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NNZN 0x04000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XNZN 0x05000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NYZN 0x06000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XYZN 0x07000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NNNW 0x08000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XNNW 0x09000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NYNW 0x0a000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XYNW 0x0b000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NNZW 0x0c000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XNZW 0x0d000000 ++#define NV50TCL_VP_ATTR_EN_0_6_NYZW 0x0e000000 ++#define NV50TCL_VP_ATTR_EN_0_6_XYZW 0x0f000000 ++#define NV50TCL_VP_ATTR_EN_0_5_SHIFT 20 ++#define NV50TCL_VP_ATTR_EN_0_5_MASK 0x00f00000 ++#define NV50TCL_VP_ATTR_EN_0_5_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_5_XNNN 0x00100000 ++#define NV50TCL_VP_ATTR_EN_0_5_NYNN 0x00200000 ++#define NV50TCL_VP_ATTR_EN_0_5_XYNN 0x00300000 ++#define NV50TCL_VP_ATTR_EN_0_5_NNZN 0x00400000 ++#define NV50TCL_VP_ATTR_EN_0_5_XNZN 0x00500000 ++#define NV50TCL_VP_ATTR_EN_0_5_NYZN 0x00600000 ++#define NV50TCL_VP_ATTR_EN_0_5_XYZN 0x00700000 ++#define NV50TCL_VP_ATTR_EN_0_5_NNNW 0x00800000 ++#define NV50TCL_VP_ATTR_EN_0_5_XNNW 0x00900000 ++#define NV50TCL_VP_ATTR_EN_0_5_NYNW 0x00a00000 ++#define NV50TCL_VP_ATTR_EN_0_5_XYNW 0x00b00000 ++#define NV50TCL_VP_ATTR_EN_0_5_NNZW 0x00c00000 ++#define NV50TCL_VP_ATTR_EN_0_5_XNZW 0x00d00000 ++#define NV50TCL_VP_ATTR_EN_0_5_NYZW 0x00e00000 ++#define NV50TCL_VP_ATTR_EN_0_5_XYZW 0x00f00000 ++#define NV50TCL_VP_ATTR_EN_0_4_SHIFT 16 ++#define NV50TCL_VP_ATTR_EN_0_4_MASK 0x000f0000 ++#define NV50TCL_VP_ATTR_EN_0_4_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_4_XNNN 0x00010000 ++#define NV50TCL_VP_ATTR_EN_0_4_NYNN 0x00020000 ++#define NV50TCL_VP_ATTR_EN_0_4_XYNN 0x00030000 ++#define NV50TCL_VP_ATTR_EN_0_4_NNZN 0x00040000 ++#define NV50TCL_VP_ATTR_EN_0_4_XNZN 0x00050000 ++#define NV50TCL_VP_ATTR_EN_0_4_NYZN 0x00060000 ++#define NV50TCL_VP_ATTR_EN_0_4_XYZN 0x00070000 ++#define NV50TCL_VP_ATTR_EN_0_4_NNNW 0x00080000 ++#define NV50TCL_VP_ATTR_EN_0_4_XNNW 0x00090000 ++#define NV50TCL_VP_ATTR_EN_0_4_NYNW 0x000a0000 ++#define NV50TCL_VP_ATTR_EN_0_4_XYNW 0x000b0000 ++#define NV50TCL_VP_ATTR_EN_0_4_NNZW 0x000c0000 ++#define NV50TCL_VP_ATTR_EN_0_4_XNZW 0x000d0000 ++#define NV50TCL_VP_ATTR_EN_0_4_NYZW 0x000e0000 ++#define NV50TCL_VP_ATTR_EN_0_4_XYZW 0x000f0000 ++#define NV50TCL_VP_ATTR_EN_0_3_SHIFT 12 ++#define NV50TCL_VP_ATTR_EN_0_3_MASK 0x0000f000 ++#define NV50TCL_VP_ATTR_EN_0_3_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_3_XNNN 0x00001000 ++#define NV50TCL_VP_ATTR_EN_0_3_NYNN 0x00002000 ++#define NV50TCL_VP_ATTR_EN_0_3_XYNN 0x00003000 ++#define NV50TCL_VP_ATTR_EN_0_3_NNZN 0x00004000 ++#define NV50TCL_VP_ATTR_EN_0_3_XNZN 0x00005000 ++#define NV50TCL_VP_ATTR_EN_0_3_NYZN 0x00006000 ++#define NV50TCL_VP_ATTR_EN_0_3_XYZN 0x00007000 ++#define NV50TCL_VP_ATTR_EN_0_3_NNNW 0x00008000 ++#define NV50TCL_VP_ATTR_EN_0_3_XNNW 0x00009000 ++#define NV50TCL_VP_ATTR_EN_0_3_NYNW 0x0000a000 ++#define NV50TCL_VP_ATTR_EN_0_3_XYNW 0x0000b000 ++#define NV50TCL_VP_ATTR_EN_0_3_NNZW 0x0000c000 ++#define NV50TCL_VP_ATTR_EN_0_3_XNZW 0x0000d000 ++#define NV50TCL_VP_ATTR_EN_0_3_NYZW 0x0000e000 ++#define NV50TCL_VP_ATTR_EN_0_3_XYZW 0x0000f000 ++#define NV50TCL_VP_ATTR_EN_0_2_SHIFT 8 ++#define NV50TCL_VP_ATTR_EN_0_2_MASK 0x00000f00 ++#define NV50TCL_VP_ATTR_EN_0_2_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_2_XNNN 0x00000100 ++#define NV50TCL_VP_ATTR_EN_0_2_NYNN 0x00000200 ++#define NV50TCL_VP_ATTR_EN_0_2_XYNN 0x00000300 ++#define NV50TCL_VP_ATTR_EN_0_2_NNZN 0x00000400 ++#define NV50TCL_VP_ATTR_EN_0_2_XNZN 0x00000500 ++#define NV50TCL_VP_ATTR_EN_0_2_NYZN 0x00000600 ++#define NV50TCL_VP_ATTR_EN_0_2_XYZN 0x00000700 ++#define NV50TCL_VP_ATTR_EN_0_2_NNNW 0x00000800 ++#define NV50TCL_VP_ATTR_EN_0_2_XNNW 0x00000900 ++#define NV50TCL_VP_ATTR_EN_0_2_NYNW 0x00000a00 ++#define NV50TCL_VP_ATTR_EN_0_2_XYNW 0x00000b00 ++#define NV50TCL_VP_ATTR_EN_0_2_NNZW 0x00000c00 ++#define NV50TCL_VP_ATTR_EN_0_2_XNZW 0x00000d00 ++#define NV50TCL_VP_ATTR_EN_0_2_NYZW 0x00000e00 ++#define NV50TCL_VP_ATTR_EN_0_2_XYZW 0x00000f00 ++#define NV50TCL_VP_ATTR_EN_0_1_SHIFT 4 ++#define NV50TCL_VP_ATTR_EN_0_1_MASK 0x000000f0 ++#define NV50TCL_VP_ATTR_EN_0_1_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_1_XNNN 0x00000010 ++#define NV50TCL_VP_ATTR_EN_0_1_NYNN 0x00000020 ++#define NV50TCL_VP_ATTR_EN_0_1_XYNN 0x00000030 ++#define NV50TCL_VP_ATTR_EN_0_1_NNZN 0x00000040 ++#define NV50TCL_VP_ATTR_EN_0_1_XNZN 0x00000050 ++#define NV50TCL_VP_ATTR_EN_0_1_NYZN 0x00000060 ++#define NV50TCL_VP_ATTR_EN_0_1_XYZN 0x00000070 ++#define NV50TCL_VP_ATTR_EN_0_1_NNNW 0x00000080 ++#define NV50TCL_VP_ATTR_EN_0_1_XNNW 0x00000090 ++#define NV50TCL_VP_ATTR_EN_0_1_NYNW 0x000000a0 ++#define NV50TCL_VP_ATTR_EN_0_1_XYNW 0x000000b0 ++#define NV50TCL_VP_ATTR_EN_0_1_NNZW 0x000000c0 ++#define NV50TCL_VP_ATTR_EN_0_1_XNZW 0x000000d0 ++#define NV50TCL_VP_ATTR_EN_0_1_NYZW 0x000000e0 ++#define NV50TCL_VP_ATTR_EN_0_1_XYZW 0x000000f0 ++#define NV50TCL_VP_ATTR_EN_0_0_SHIFT 0 ++#define NV50TCL_VP_ATTR_EN_0_0_MASK 0x0000000f ++#define NV50TCL_VP_ATTR_EN_0_0_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_0_0_XNNN 0x00000001 ++#define NV50TCL_VP_ATTR_EN_0_0_NYNN 0x00000002 ++#define NV50TCL_VP_ATTR_EN_0_0_XYNN 0x00000003 ++#define NV50TCL_VP_ATTR_EN_0_0_NNZN 0x00000004 ++#define NV50TCL_VP_ATTR_EN_0_0_XNZN 0x00000005 ++#define NV50TCL_VP_ATTR_EN_0_0_NYZN 0x00000006 ++#define NV50TCL_VP_ATTR_EN_0_0_XYZN 0x00000007 ++#define NV50TCL_VP_ATTR_EN_0_0_NNNW 0x00000008 ++#define NV50TCL_VP_ATTR_EN_0_0_XNNW 0x00000009 ++#define NV50TCL_VP_ATTR_EN_0_0_NYNW 0x0000000a ++#define NV50TCL_VP_ATTR_EN_0_0_XYNW 0x0000000b ++#define NV50TCL_VP_ATTR_EN_0_0_NNZW 0x0000000c ++#define NV50TCL_VP_ATTR_EN_0_0_XNZW 0x0000000d ++#define NV50TCL_VP_ATTR_EN_0_0_NYZW 0x0000000e ++#define NV50TCL_VP_ATTR_EN_0_0_XYZW 0x0000000f ++#define NV50TCL_VP_ATTR_EN_1 0x00001654 ++#define NV50TCL_VP_ATTR_EN_1_15_SHIFT 28 ++#define NV50TCL_VP_ATTR_EN_1_15_MASK 0xf0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XNNN 0x10000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NYNN 0x20000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XYNN 0x30000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NNZN 0x40000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XNZN 0x50000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NYZN 0x60000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XYZN 0x70000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NNNW 0x80000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XNNW 0x90000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NYNW 0xa0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XYNW 0xb0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NNZW 0xc0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XNZW 0xd0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_NYZW 0xe0000000 ++#define NV50TCL_VP_ATTR_EN_1_15_XYZW 0xf0000000 ++#define NV50TCL_VP_ATTR_EN_1_14_SHIFT 24 ++#define NV50TCL_VP_ATTR_EN_1_14_MASK 0x0f000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XNNN 0x01000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NYNN 0x02000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XYNN 0x03000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NNZN 0x04000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XNZN 0x05000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NYZN 0x06000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XYZN 0x07000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NNNW 0x08000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XNNW 0x09000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NYNW 0x0a000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XYNW 0x0b000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NNZW 0x0c000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XNZW 0x0d000000 ++#define NV50TCL_VP_ATTR_EN_1_14_NYZW 0x0e000000 ++#define NV50TCL_VP_ATTR_EN_1_14_XYZW 0x0f000000 ++#define NV50TCL_VP_ATTR_EN_1_13_SHIFT 20 ++#define NV50TCL_VP_ATTR_EN_1_13_MASK 0x00f00000 ++#define NV50TCL_VP_ATTR_EN_1_13_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_13_XNNN 0x00100000 ++#define NV50TCL_VP_ATTR_EN_1_13_NYNN 0x00200000 ++#define NV50TCL_VP_ATTR_EN_1_13_XYNN 0x00300000 ++#define NV50TCL_VP_ATTR_EN_1_13_NNZN 0x00400000 ++#define NV50TCL_VP_ATTR_EN_1_13_XNZN 0x00500000 ++#define NV50TCL_VP_ATTR_EN_1_13_NYZN 0x00600000 ++#define NV50TCL_VP_ATTR_EN_1_13_XYZN 0x00700000 ++#define NV50TCL_VP_ATTR_EN_1_13_NNNW 0x00800000 ++#define NV50TCL_VP_ATTR_EN_1_13_XNNW 0x00900000 ++#define NV50TCL_VP_ATTR_EN_1_13_NYNW 0x00a00000 ++#define NV50TCL_VP_ATTR_EN_1_13_XYNW 0x00b00000 ++#define NV50TCL_VP_ATTR_EN_1_13_NNZW 0x00c00000 ++#define NV50TCL_VP_ATTR_EN_1_13_XNZW 0x00d00000 ++#define NV50TCL_VP_ATTR_EN_1_13_NYZW 0x00e00000 ++#define NV50TCL_VP_ATTR_EN_1_13_XYZW 0x00f00000 ++#define NV50TCL_VP_ATTR_EN_1_12_SHIFT 16 ++#define NV50TCL_VP_ATTR_EN_1_12_MASK 0x000f0000 ++#define NV50TCL_VP_ATTR_EN_1_12_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_12_XNNN 0x00010000 ++#define NV50TCL_VP_ATTR_EN_1_12_NYNN 0x00020000 ++#define NV50TCL_VP_ATTR_EN_1_12_XYNN 0x00030000 ++#define NV50TCL_VP_ATTR_EN_1_12_NNZN 0x00040000 ++#define NV50TCL_VP_ATTR_EN_1_12_XNZN 0x00050000 ++#define NV50TCL_VP_ATTR_EN_1_12_NYZN 0x00060000 ++#define NV50TCL_VP_ATTR_EN_1_12_XYZN 0x00070000 ++#define NV50TCL_VP_ATTR_EN_1_12_NNNW 0x00080000 ++#define NV50TCL_VP_ATTR_EN_1_12_XNNW 0x00090000 ++#define NV50TCL_VP_ATTR_EN_1_12_NYNW 0x000a0000 ++#define NV50TCL_VP_ATTR_EN_1_12_XYNW 0x000b0000 ++#define NV50TCL_VP_ATTR_EN_1_12_NNZW 0x000c0000 ++#define NV50TCL_VP_ATTR_EN_1_12_XNZW 0x000d0000 ++#define NV50TCL_VP_ATTR_EN_1_12_NYZW 0x000e0000 ++#define NV50TCL_VP_ATTR_EN_1_12_XYZW 0x000f0000 ++#define NV50TCL_VP_ATTR_EN_1_11_SHIFT 12 ++#define NV50TCL_VP_ATTR_EN_1_11_MASK 0x0000f000 ++#define NV50TCL_VP_ATTR_EN_1_11_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_11_XNNN 0x00001000 ++#define NV50TCL_VP_ATTR_EN_1_11_NYNN 0x00002000 ++#define NV50TCL_VP_ATTR_EN_1_11_XYNN 0x00003000 ++#define NV50TCL_VP_ATTR_EN_1_11_NNZN 0x00004000 ++#define NV50TCL_VP_ATTR_EN_1_11_XNZN 0x00005000 ++#define NV50TCL_VP_ATTR_EN_1_11_NYZN 0x00006000 ++#define NV50TCL_VP_ATTR_EN_1_11_XYZN 0x00007000 ++#define NV50TCL_VP_ATTR_EN_1_11_NNNW 0x00008000 ++#define NV50TCL_VP_ATTR_EN_1_11_XNNW 0x00009000 ++#define NV50TCL_VP_ATTR_EN_1_11_NYNW 0x0000a000 ++#define NV50TCL_VP_ATTR_EN_1_11_XYNW 0x0000b000 ++#define NV50TCL_VP_ATTR_EN_1_11_NNZW 0x0000c000 ++#define NV50TCL_VP_ATTR_EN_1_11_XNZW 0x0000d000 ++#define NV50TCL_VP_ATTR_EN_1_11_NYZW 0x0000e000 ++#define NV50TCL_VP_ATTR_EN_1_11_XYZW 0x0000f000 ++#define NV50TCL_VP_ATTR_EN_1_10_SHIFT 8 ++#define NV50TCL_VP_ATTR_EN_1_10_MASK 0x00000f00 ++#define NV50TCL_VP_ATTR_EN_1_10_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_10_XNNN 0x00000100 ++#define NV50TCL_VP_ATTR_EN_1_10_NYNN 0x00000200 ++#define NV50TCL_VP_ATTR_EN_1_10_XYNN 0x00000300 ++#define NV50TCL_VP_ATTR_EN_1_10_NNZN 0x00000400 ++#define NV50TCL_VP_ATTR_EN_1_10_XNZN 0x00000500 ++#define NV50TCL_VP_ATTR_EN_1_10_NYZN 0x00000600 ++#define NV50TCL_VP_ATTR_EN_1_10_XYZN 0x00000700 ++#define NV50TCL_VP_ATTR_EN_1_10_NNNW 0x00000800 ++#define NV50TCL_VP_ATTR_EN_1_10_XNNW 0x00000900 ++#define NV50TCL_VP_ATTR_EN_1_10_NYNW 0x00000a00 ++#define NV50TCL_VP_ATTR_EN_1_10_XYNW 0x00000b00 ++#define NV50TCL_VP_ATTR_EN_1_10_NNZW 0x00000c00 ++#define NV50TCL_VP_ATTR_EN_1_10_XNZW 0x00000d00 ++#define NV50TCL_VP_ATTR_EN_1_10_NYZW 0x00000e00 ++#define NV50TCL_VP_ATTR_EN_1_10_XYZW 0x00000f00 ++#define NV50TCL_VP_ATTR_EN_1_9_SHIFT 4 ++#define NV50TCL_VP_ATTR_EN_1_9_MASK 0x000000f0 ++#define NV50TCL_VP_ATTR_EN_1_9_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_9_XNNN 0x00000010 ++#define NV50TCL_VP_ATTR_EN_1_9_NYNN 0x00000020 ++#define NV50TCL_VP_ATTR_EN_1_9_XYNN 0x00000030 ++#define NV50TCL_VP_ATTR_EN_1_9_NNZN 0x00000040 ++#define NV50TCL_VP_ATTR_EN_1_9_XNZN 0x00000050 ++#define NV50TCL_VP_ATTR_EN_1_9_NYZN 0x00000060 ++#define NV50TCL_VP_ATTR_EN_1_9_XYZN 0x00000070 ++#define NV50TCL_VP_ATTR_EN_1_9_NNNW 0x00000080 ++#define NV50TCL_VP_ATTR_EN_1_9_XNNW 0x00000090 ++#define NV50TCL_VP_ATTR_EN_1_9_NYNW 0x000000a0 ++#define NV50TCL_VP_ATTR_EN_1_9_XYNW 0x000000b0 ++#define NV50TCL_VP_ATTR_EN_1_9_NNZW 0x000000c0 ++#define NV50TCL_VP_ATTR_EN_1_9_XNZW 0x000000d0 ++#define NV50TCL_VP_ATTR_EN_1_9_NYZW 0x000000e0 ++#define NV50TCL_VP_ATTR_EN_1_9_XYZW 0x000000f0 ++#define NV50TCL_VP_ATTR_EN_1_8_SHIFT 0 ++#define NV50TCL_VP_ATTR_EN_1_8_MASK 0x0000000f ++#define NV50TCL_VP_ATTR_EN_1_8_NONE 0x00000000 ++#define NV50TCL_VP_ATTR_EN_1_8_XNNN 0x00000001 ++#define NV50TCL_VP_ATTR_EN_1_8_NYNN 0x00000002 ++#define NV50TCL_VP_ATTR_EN_1_8_XYNN 0x00000003 ++#define NV50TCL_VP_ATTR_EN_1_8_NNZN 0x00000004 ++#define NV50TCL_VP_ATTR_EN_1_8_XNZN 0x00000005 ++#define NV50TCL_VP_ATTR_EN_1_8_NYZN 0x00000006 ++#define NV50TCL_VP_ATTR_EN_1_8_XYZN 0x00000007 ++#define NV50TCL_VP_ATTR_EN_1_8_NNNW 0x00000008 ++#define NV50TCL_VP_ATTR_EN_1_8_XNNW 0x00000009 ++#define NV50TCL_VP_ATTR_EN_1_8_NYNW 0x0000000a ++#define NV50TCL_VP_ATTR_EN_1_8_XYNW 0x0000000b ++#define NV50TCL_VP_ATTR_EN_1_8_NNZW 0x0000000c ++#define NV50TCL_VP_ATTR_EN_1_8_XNZW 0x0000000d ++#define NV50TCL_VP_ATTR_EN_1_8_NYZW 0x0000000e ++#define NV50TCL_VP_ATTR_EN_1_8_XYZW 0x0000000f ++#define NV50TCL_POINT_SPRITE_CTRL 0x00001660 ++#define NV50TCL_LINE_STIPPLE_ENABLE 0x0000166c ++#define NV50TCL_LINE_STIPPLE_PATTERN 0x00001680 ++#define NV50TCL_PROVOKING_VERTEX_LAST 0x00001684 ++#define NV50TCL_VERTEX_TWO_SIDE_ENABLE 0x00001688 ++#define NV50TCL_POLYGON_STIPPLE_ENABLE 0x0000168c ++#define NV50TCL_SET_PROGRAM_CB 0x00001694 ++#define NV50TCL_SET_PROGRAM_CB_PROGRAM_SHIFT 4 ++#define NV50TCL_SET_PROGRAM_CB_PROGRAM_MASK 0x000000f0 ++#define NV50TCL_SET_PROGRAM_CB_PROGRAM_VERTEX 0x00000000 ++#define NV50TCL_SET_PROGRAM_CB_PROGRAM_GEOMETRY 0x00000020 ++#define NV50TCL_SET_PROGRAM_CB_PROGRAM_FRAGMENT 0x00000030 ++#define NV50TCL_SET_PROGRAM_CB_INDEX_SHIFT 8 ++#define NV50TCL_SET_PROGRAM_CB_INDEX_MASK 0x00000f00 ++#define NV50TCL_SET_PROGRAM_CB_BUFFER_SHIFT 12 ++#define NV50TCL_SET_PROGRAM_CB_BUFFER_MASK 0x0007f000 ++#define NV50TCL_SET_PROGRAM_CB_VALID (1 << 0) ++#define NV50TCL_VP_RESULT_MAP_SIZE 0x000016ac ++#define NV50TCL_VP_REG_ALLOC_TEMP 0x000016b0 ++#define NV50TCL_VP_REG_ALLOC_RESULT 0x000016b8 ++#define NV50TCL_VP_RESULT_MAP(x) (0x000016bc+((x)*4)) ++#define NV50TCL_VP_RESULT_MAP__SIZE 0x00000010 ++#define NV50TCL_VP_RESULT_MAP_0_SHIFT 0 ++#define NV50TCL_VP_RESULT_MAP_0_MASK 0x000000ff ++#define NV50TCL_VP_RESULT_MAP_1_SHIFT 8 ++#define NV50TCL_VP_RESULT_MAP_1_MASK 0x0000ff00 ++#define NV50TCL_VP_RESULT_MAP_2_SHIFT 16 ++#define NV50TCL_VP_RESULT_MAP_2_MASK 0x00ff0000 ++#define NV50TCL_VP_RESULT_MAP_3_SHIFT 24 ++#define NV50TCL_VP_RESULT_MAP_3_MASK 0xff000000 ++#define NV50TCL_POLYGON_STIPPLE_PATTERN(x) (0x00001700+((x)*4)) ++#define NV50TCL_POLYGON_STIPPLE_PATTERN__SIZE 0x00000020 ++#define NV50TCL_GP_ENABLE 0x00001798 ++#define NV50TCL_GP_REG_ALLOC_TEMP 0x000017a0 ++#define NV50TCL_GP_REG_ALLOC_RESULT 0x000017a8 ++#define NV50TCL_GP_RESULT_MAP_SIZE 0x000017ac ++#define NV50TCL_GP_OUTPUT_PRIMITIVE_TYPE 0x000017b0 ++#define NV50TCL_GP_OUTPUT_PRIMITIVE_TYPE_POINTS 0x00000001 ++#define NV50TCL_GP_OUTPUT_PRIMITIVE_TYPE_LINE_STRIP 0x00000002 ++#define NV50TCL_GP_OUTPUT_PRIMITIVE_TYPE_TRIANGLE_STRIP 0x00000003 ++#define NV50TCL_RASTERIZE_ENABLE 0x000017b4 ++#define NV50TCL_STRMOUT_ENABLE 0x000017b8 ++#define NV50TCL_GP_RESULT_MAP(x) (0x000017fc+((x)*4)) ++#define NV50TCL_GP_RESULT_MAP__SIZE 0x00000020 ++#define NV50TCL_GP_RESULT_MAP_0_SHIFT 0 ++#define NV50TCL_GP_RESULT_MAP_0_MASK 0x000000ff ++#define NV50TCL_GP_RESULT_MAP_1_SHIFT 8 ++#define NV50TCL_GP_RESULT_MAP_1_MASK 0x0000ff00 ++#define NV50TCL_GP_RESULT_MAP_2_SHIFT 16 ++#define NV50TCL_GP_RESULT_MAP_2_MASK 0x00ff0000 ++#define NV50TCL_GP_RESULT_MAP_3_SHIFT 24 ++#define NV50TCL_GP_RESULT_MAP_3_MASK 0xff000000 ++#define NV50TCL_MAP_SEMANTIC_0 0x00001904 ++#define NV50TCL_MAP_SEMANTIC_0_FFC0_ID_SHIFT 0 ++#define NV50TCL_MAP_SEMANTIC_0_FFC0_ID_MASK 0x000000ff ++#define NV50TCL_MAP_SEMANTIC_0_BFC0_ID_SHIFT 8 ++#define NV50TCL_MAP_SEMANTIC_0_BFC0_ID_MASK 0x0000ff00 ++#define NV50TCL_MAP_SEMANTIC_0_COLR_NR_SHIFT 16 ++#define NV50TCL_MAP_SEMANTIC_0_COLR_NR_MASK 0x00ff0000 ++#define NV50TCL_MAP_SEMANTIC_0_CLMP_EN_SHIFT 24 ++#define NV50TCL_MAP_SEMANTIC_0_CLMP_EN_MASK 0xff000000 ++#define NV50TCL_MAP_SEMANTIC_1 0x00001908 ++#define NV50TCL_MAP_SEMANTIC_1_CLIP_LO_SHIFT 0 ++#define NV50TCL_MAP_SEMANTIC_1_CLIP_LO_MASK 0x000000ff ++#define NV50TCL_MAP_SEMANTIC_1_CLIP_HI_SHIFT 8 ++#define NV50TCL_MAP_SEMANTIC_1_CLIP_HI_MASK 0x0000ff00 ++#define NV50TCL_MAP_SEMANTIC_2 0x0000190c ++#define NV50TCL_MAP_SEMANTIC_2_LAYER_ID_SHIFT 0 ++#define NV50TCL_MAP_SEMANTIC_2_LAYER_ID_MASK 0x000000ff ++#define NV50TCL_MAP_SEMANTIC_3 0x00001910 ++#define NV50TCL_MAP_SEMANTIC_3_PTSZ_EN (1 << 0) ++#define NV50TCL_MAP_SEMANTIC_3_PTSZ_ID_SHIFT 4 ++#define NV50TCL_MAP_SEMANTIC_3_PTSZ_ID_MASK 0x00000ff0 ++#define NV50TCL_MAP_SEMANTIC_4 0x00001914 ++#define NV50TCL_MAP_SEMANTIC_4_PRIM_ID_SHIFT 0 ++#define NV50TCL_MAP_SEMANTIC_4_PRIM_ID_MASK 0x000000ff ++#define NV50TCL_CULL_FACE_ENABLE 0x00001918 ++#define NV50TCL_FRONT_FACE 0x0000191c ++#define NV50TCL_FRONT_FACE_CW 0x00000900 ++#define NV50TCL_FRONT_FACE_CCW 0x00000901 ++#define NV50TCL_CULL_FACE 0x00001920 ++#define NV50TCL_CULL_FACE_FRONT 0x00000404 ++#define NV50TCL_CULL_FACE_BACK 0x00000405 ++#define NV50TCL_CULL_FACE_FRONT_AND_BACK 0x00000408 ++#define NV50TCL_VIEWPORT_TRANSFORM_EN 0x0000192c ++#define NV50TCL_VIEW_VOLUME_CLIP_CTRL 0x0000193c ++#define NV50TCL_VIEWPORT_CLIP_RECTS_EN 0x0000194c ++#define NV50TCL_FP_CTRL_UNK196C 0x0000196c ++#define NV50TCL_FP_INTERPOLANT_CTRL 0x00001988 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_SHIFT 24 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_MASK 0xff000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NONE 0x00000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XNNN 0x01000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NYNN 0x02000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XYNN 0x03000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NNZN 0x04000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XNZN 0x05000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NYZN 0x06000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XYZN 0x07000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NNNW 0x08000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XNNW 0x09000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NYNW 0x0a000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XYNW 0x0b000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NNZW 0x0c000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XNZW 0x0d000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_NYZW 0x0e000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_UMASK_XYZW 0x0f000000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_COUNT_NONFLAT_SHIFT 16 ++#define NV50TCL_FP_INTERPOLANT_CTRL_COUNT_NONFLAT_MASK 0x00ff0000 ++#define NV50TCL_FP_INTERPOLANT_CTRL_OFFSET_SHIFT 8 ++#define NV50TCL_FP_INTERPOLANT_CTRL_OFFSET_MASK 0x0000ff00 ++#define NV50TCL_FP_INTERPOLANT_CTRL_COUNT_SHIFT 0 ++#define NV50TCL_FP_INTERPOLANT_CTRL_COUNT_MASK 0x000000ff ++#define NV50TCL_FP_REG_ALLOC_TEMP 0x0000198c ++#define NV50TCL_REG_MODE 0x000019a0 ++#define NV50TCL_REG_MODE_PACKED 0x00000001 ++#define NV50TCL_REG_MODE_STRIPED 0x00000002 ++#define NV50TCL_FP_CONTROL 0x000019a8 ++#define NV50TCL_FP_CONTROL_MULTIPLE_RESULTS (1 << 0) ++#define NV50TCL_FP_CONTROL_EXPORTS_Z (1 << 8) ++#define NV50TCL_FP_CONTROL_USES_KIL (1 << 20) ++#define NV50TCL_DEPTH_BOUNDS_EN 0x000019bc ++#define NV50TCL_LOGIC_OP_ENABLE 0x000019c4 ++#define NV50TCL_LOGIC_OP 0x000019c8 ++#define NV50TCL_LOGIC_OP_CLEAR 0x00001500 ++#define NV50TCL_LOGIC_OP_AND 0x00001501 ++#define NV50TCL_LOGIC_OP_AND_REVERSE 0x00001502 ++#define NV50TCL_LOGIC_OP_COPY 0x00001503 ++#define NV50TCL_LOGIC_OP_AND_INVERTED 0x00001504 ++#define NV50TCL_LOGIC_OP_NOOP 0x00001505 ++#define NV50TCL_LOGIC_OP_XOR 0x00001506 ++#define NV50TCL_LOGIC_OP_OR 0x00001507 ++#define NV50TCL_LOGIC_OP_NOR 0x00001508 ++#define NV50TCL_LOGIC_OP_EQUIV 0x00001509 ++#define NV50TCL_LOGIC_OP_INVERT 0x0000150a ++#define NV50TCL_LOGIC_OP_OR_REVERSE 0x0000150b ++#define NV50TCL_LOGIC_OP_COPY_INVERTED 0x0000150c ++#define NV50TCL_LOGIC_OP_OR_INVERTED 0x0000150d ++#define NV50TCL_LOGIC_OP_NAND 0x0000150e ++#define NV50TCL_LOGIC_OP_SET 0x0000150f ++#define NV50TCL_CLEAR_BUFFERS 0x000019d0 ++#define NV50TCL_CLEAR_BUFFERS_Z (1 << 0) ++#define NV50TCL_CLEAR_BUFFERS_S (1 << 1) ++#define NV50TCL_CLEAR_BUFFERS_R (1 << 2) ++#define NV50TCL_CLEAR_BUFFERS_G (1 << 3) ++#define NV50TCL_CLEAR_BUFFERS_B (1 << 4) ++#define NV50TCL_CLEAR_BUFFERS_A (1 << 5) ++#define NV50TCL_CLEAR_BUFFERS_RT_SHIFT 6 ++#define NV50TCL_CLEAR_BUFFERS_RT_MASK 0x000003c0 ++#define NV50TCL_CLEAR_BUFFERS_LAYER_SHIFT 10 ++#define NV50TCL_CLEAR_BUFFERS_LAYER_MASK 0x0007fc00 ++#define NV50TCL_COLOR_MASK(x) (0x00001a00+((x)*4)) ++#define NV50TCL_COLOR_MASK__SIZE 0x00000008 ++#define NV50TCL_COLOR_MASK_R_SHIFT 0 ++#define NV50TCL_COLOR_MASK_R_MASK 0x0000000f ++#define NV50TCL_COLOR_MASK_G_SHIFT 4 ++#define NV50TCL_COLOR_MASK_G_MASK 0x000000f0 ++#define NV50TCL_COLOR_MASK_B_SHIFT 8 ++#define NV50TCL_COLOR_MASK_B_MASK 0x00000f00 ++#define NV50TCL_COLOR_MASK_A_SHIFT 12 ++#define NV50TCL_COLOR_MASK_A_MASK 0x0000f000 ++#define NV50TCL_STRMOUT_ADDRESS_HIGH(x) (0x00001a80+((x)*16)) ++#define NV50TCL_STRMOUT_ADDRESS_HIGH__SIZE 0x00000004 ++#define NV50TCL_STRMOUT_ADDRESS_LOW(x) (0x00001a84+((x)*16)) ++#define NV50TCL_STRMOUT_ADDRESS_LOW__SIZE 0x00000004 ++#define NV50TCL_STRMOUT_NUM_ATTRIBS(x) (0x00001a88+((x)*16)) ++#define NV50TCL_STRMOUT_NUM_ATTRIBS__SIZE 0x00000004 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB(x) (0x00001ac0+((x)*4)) ++#define NV50TCL_VERTEX_ARRAY_ATTRIB__SIZE 0x00000010 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_BUFFER_SHIFT 0 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_BUFFER_MASK 0x0000000f ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_CONST (1 << 4) ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_OFFSET_SHIFT 5 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_OFFSET_MASK 0x0007ffe0 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_SHIFT 19 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_MASK 0x01f80000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_32_32_32_32 0x00080000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_32_32_32 0x00100000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_16_16_16_16 0x00180000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_32_32 0x00200000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_16_16_16 0x00280000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_8_8_8_8 0x00500000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_16_16 0x00780000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_32 0x00900000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_8_8_8 0x00980000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_8_8 0x00c00000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_16 0x00d80000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_FORMAT_8 0x00e80000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_SHIFT 25 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_MASK 0x7e000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_FLOAT 0x7e000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_UNORM 0x24000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_SNORM 0x12000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_USCALED 0x5a000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_SSCALED 0x6c000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_UINT 0x48000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_TYPE_SINT 0x36000000 ++#define NV50TCL_VERTEX_ARRAY_ATTRIB_BGRA (1 << 31) ++#define NV50TCL_QUERY_ADDRESS_HIGH 0x00001b00 ++#define NV50TCL_QUERY_ADDRESS_LOW 0x00001b04 ++#define NV50TCL_QUERY_COUNTER 0x00001b08 ++#define NV50TCL_QUERY_GET 0x00001b0c ++ ++ ++#define NV84TCL 0x00008297 ++ ++ ++ ++#define NVA0TCL 0x00008397 ++ ++ ++ ++#define NVA8TCL 0x00008597 ++ ++ ++ ++#define NV50_COMPUTE 0x000050c0 ++ ++#define NV50_COMPUTE_NOP 0x00000100 ++#define NV50_COMPUTE_NOTIFY 0x00000104 ++#define NV50_COMPUTE_SERIALIZE 0x00000110 ++#define NV50_COMPUTE_DMA_NOTIFY 0x00000180 ++#define NV50_COMPUTE_DMA_GLOBAL 0x000001a0 ++#define NV50_COMPUTE_DMA_QUERY 0x000001a4 ++#define NV50_COMPUTE_DMA_LOCAL 0x000001b8 ++#define NV50_COMPUTE_DMA_STACK 0x000001bc ++#define NV50_COMPUTE_DMA_CODE_CB 0x000001c0 ++#define NV50_COMPUTE_DMA_TSC 0x000001c4 ++#define NV50_COMPUTE_DMA_TIC 0x000001c8 ++#define NV50_COMPUTE_DMA_TEXTURE 0x000001cc ++#define NV50_COMPUTE_CP_ADDRESS_HIGH 0x00000210 ++#define NV50_COMPUTE_CP_ADDRESS_LOW 0x00000214 ++#define NV50_COMPUTE_STACK_ADDRESS_HIGH 0x00000218 ++#define NV50_COMPUTE_STACK_ADDRESS_LOW 0x0000021c ++#define NV50_COMPUTE_STACK_SIZE_LOG 0x00000220 ++#define NV50_COMPUTE_TSC_ADDRESS_HIGH 0x0000022c ++#define NV50_COMPUTE_TSC_ADDRESS_LOW 0x00000230 ++#define NV50_COMPUTE_TSC_LIMIT 0x00000234 ++#define NV50_COMPUTE_CB_ADDR 0x00000238 ++#define NV50_COMPUTE_CB_ADDR_ID_SHIFT 8 ++#define NV50_COMPUTE_CB_ADDR_ID_MASK 0x003fff00 ++#define NV50_COMPUTE_CB_ADDR_BUFFER_SHIFT 0 ++#define NV50_COMPUTE_CB_ADDR_BUFFER_MASK 0x0000007f ++#define NV50_COMPUTE_CB_DATA(x) (0x0000023c+((x)*4)) ++#define NV50_COMPUTE_CB_DATA__SIZE 0x00000010 ++#define NV50_COMPUTE_DELAY1 0x00000284 ++#define NV50_COMPUTE_WATCHDOG_TIMER 0x00000288 ++#define NV50_COMPUTE_DELAY2 0x0000028c ++#define NV50_COMPUTE_LOCAL_ADDRESS_HIGH 0x00000294 ++#define NV50_COMPUTE_LOCAL_ADDRESS_LOW 0x00000298 ++#define NV50_COMPUTE_LOCAL_SIZE_LOG 0x0000029c ++#define NV50_COMPUTE_CB_DEF_ADDRESS_HIGH 0x000002a4 ++#define NV50_COMPUTE_CB_DEF_ADDRESS_LOW 0x000002a8 ++#define NV50_COMPUTE_CB_DEF_SET 0x000002ac ++#define NV50_COMPUTE_CB_DEF_SET_SIZE_SHIFT 0 ++#define NV50_COMPUTE_CB_DEF_SET_SIZE_MASK 0x0000ffff ++#define NV50_COMPUTE_CB_DEF_SET_BUFFER_SHIFT 16 ++#define NV50_COMPUTE_CB_DEF_SET_BUFFER_MASK 0x007f0000 ++#define NV50_COMPUTE_BLOCK_ALLOC 0x000002b4 ++#define NV50_COMPUTE_BLOCK_ALLOC_THREADS_SHIFT 0 ++#define NV50_COMPUTE_BLOCK_ALLOC_THREADS_MASK 0x0000ffff ++#define NV50_COMPUTE_BLOCK_ALLOC_BARRIERS_SHIFT 16 ++#define NV50_COMPUTE_BLOCK_ALLOC_BARRIERS_MASK 0xffff0000 ++#define NV50_COMPUTE_LANES32_ENABLE 0x000002b8 ++#define NV50_COMPUTE_CP_REG_ALLOC_TEMP 0x000002c0 ++#define NV50_COMPUTE_TIC_ADDRESS_HIGH 0x000002c4 ++#define NV50_COMPUTE_TIC_ADDRESS_LOW 0x000002c8 ++#define NV50_COMPUTE_TIC_LIMIT 0x000002cc ++#define NV50_COMPUTE_PM_SET(x) (0x000002d0+((x)*4)) ++#define NV50_COMPUTE_PM_SET__SIZE 0x00000004 ++#define NV50_COMPUTE_PM_CONTROL(x) (0x000002e0+((x)*4)) ++#define NV50_COMPUTE_PM_CONTROL__SIZE 0x00000004 ++#define NV50_COMPUTE_PM_CONTROL_UNK0 (1 << 0) ++#define NV50_COMPUTE_PM_CONTROL_UNK1_SHIFT 4 ++#define NV50_COMPUTE_PM_CONTROL_UNK1_MASK 0x00000070 ++#define NV50_COMPUTE_PM_CONTROL_UNK2_SHIFT 8 ++#define NV50_COMPUTE_PM_CONTROL_UNK2_MASK 0xffffff00 ++#define NV50_COMPUTE_LOCAL_WARPS_LOG_ALLOC 0x000002fc ++#define NV50_COMPUTE_LOCAL_WARPS_NO_CLAMP 0x00000300 ++#define NV50_COMPUTE_STACK_WARPS_LOG_ALLOC 0x00000304 ++#define NV50_COMPUTE_STACK_WARPS_NO_CLAMP 0x00000308 ++#define NV50_COMPUTE_QUERY_ADDRESS_HIGH 0x00000310 ++#define NV50_COMPUTE_QUERY_ADDRESS_LOW 0x00000314 ++#define NV50_COMPUTE_QUERY_COUNTER 0x00000318 ++#define NV50_COMPUTE_QUERY_GET 0x0000031c ++#define NV50_COMPUTE_COND_ADDRESS_HIGH 0x00000320 ++#define NV50_COMPUTE_COND_ADDRESS_LOW 0x00000324 ++#define NV50_COMPUTE_COND_MODE 0x00000328 ++#define NV50_COMPUTE_COND_MODE_NEVER 0x00000000 ++#define NV50_COMPUTE_COND_MODE_ALWAYS 0x00000001 ++#define NV50_COMPUTE_COND_MODE_RES 0x00000002 ++#define NV50_COMPUTE_COND_MODE_NOT_RES_AND_NOT_ID 0x00000003 ++#define NV50_COMPUTE_COND_MODE_RES_OR_ID 0x00000004 ++#define NV50_COMPUTE_LAUNCH 0x00000368 ++#define NV50_COMPUTE_USER_PARAM_COUNT 0x00000374 ++#define NV50_COMPUTE_USER_PARAM_COUNT_COUNT_SHIFT 8 ++#define NV50_COMPUTE_USER_PARAM_COUNT_COUNT_MASK 0x0000ff00 ++#define NV50_COMPUTE_LINKED_TSC 0x00000378 ++#define NV50_COMPUTE_CODE_CB_FLUSH 0x00000380 ++#define NV50_COMPUTE_GRIDDIM 0x000003a4 ++#define NV50_COMPUTE_GRIDDIM_X_SHIFT 0 ++#define NV50_COMPUTE_GRIDDIM_X_MASK 0x0000ffff ++#define NV50_COMPUTE_GRIDDIM_Y_SHIFT 16 ++#define NV50_COMPUTE_GRIDDIM_Y_MASK 0xffff0000 ++#define NV50_COMPUTE_SHARED_SIZE 0x000003a8 ++#define NV50_COMPUTE_BLOCKDIM_YX 0x000003ac ++#define NV50_COMPUTE_BLOCKDIM_YX_X_SHIFT 0 ++#define NV50_COMPUTE_BLOCKDIM_YX_X_MASK 0x0000ffff ++#define NV50_COMPUTE_BLOCKDIM_YX_Y_SHIFT 16 ++#define NV50_COMPUTE_BLOCKDIM_YX_Y_MASK 0xffff0000 ++#define NV50_COMPUTE_BLOCKDIM_Z 0x000003b0 ++#define NV50_COMPUTE_CP_START_ID 0x000003b4 ++#define NV50_COMPUTE_REG_MODE 0x000003b8 ++#define NV50_COMPUTE_REG_MODE_PACKED 0x00000001 ++#define NV50_COMPUTE_REG_MODE_STRIPED 0x00000002 ++#define NV50_COMPUTE_TEX_LIMITS 0x000003bc ++#define NV50_COMPUTE_TEX_LIMITS_SAMPLERS_LOG2_SHIFT 0 ++#define NV50_COMPUTE_TEX_LIMITS_SAMPLERS_LOG2_MASK 0x0000000f ++#define NV50_COMPUTE_TEX_LIMITS_TEXTURES_LOG2_SHIFT 4 ++#define NV50_COMPUTE_TEX_LIMITS_TEXTURES_LOG2_MASK 0x000000f0 ++#define NV50_COMPUTE_BIND_TSC 0x000003c0 ++#define NV50_COMPUTE_BIND_TSC_VALID (1 << 0) ++#define NV50_COMPUTE_BIND_TSC_SAMPLER_SHIFT 4 ++#define NV50_COMPUTE_BIND_TSC_SAMPLER_MASK 0x000000f0 ++#define NV50_COMPUTE_BIND_TSC_TSC_SHIFT 12 ++#define NV50_COMPUTE_BIND_TSC_TSC_MASK 0x001ff000 ++#define NV50_COMPUTE_BIND_TIC 0x000003c4 ++#define NV50_COMPUTE_BIND_TIC_VALID (1 << 0) ++#define NV50_COMPUTE_BIND_TIC_TEXTURE_SHIFT 1 ++#define NV50_COMPUTE_BIND_TIC_TEXTURE_MASK 0x000001fe ++#define NV50_COMPUTE_BIND_TIC_TIC_SHIFT 9 ++#define NV50_COMPUTE_BIND_TIC_TIC_MASK 0x7ffffe00 ++#define NV50_COMPUTE_SET_PROGRAM_CB 0x000003c8 ++#define NV50_COMPUTE_SET_PROGRAM_CB_INDEX_SHIFT 8 ++#define NV50_COMPUTE_SET_PROGRAM_CB_INDEX_MASK 0x00000f00 ++#define NV50_COMPUTE_SET_PROGRAM_CB_BUFFER_SHIFT 12 ++#define NV50_COMPUTE_SET_PROGRAM_CB_BUFFER_MASK 0x0007f000 ++#define NV50_COMPUTE_SET_PROGRAM_CB_VALID (1 << 0) ++#define NV50_COMPUTE_GLOBAL_ADDRESS_HIGH(x) (0x00000400+((x)*32)) ++#define NV50_COMPUTE_GLOBAL_ADDRESS_HIGH__SIZE 0x00000010 ++#define NV50_COMPUTE_GLOBAL_ADDRESS_LOW(x) (0x00000404+((x)*32)) ++#define NV50_COMPUTE_GLOBAL_ADDRESS_LOW__SIZE 0x00000010 ++#define NV50_COMPUTE_GLOBAL_PITCH(x) (0x00000408+((x)*32)) ++#define NV50_COMPUTE_GLOBAL_PITCH__SIZE 0x00000010 ++#define NV50_COMPUTE_GLOBAL_LIMIT(x) (0x0000040c+((x)*32)) ++#define NV50_COMPUTE_GLOBAL_LIMIT__SIZE 0x00000010 ++#define NV50_COMPUTE_GLOBAL_MODE(x) (0x00000410+((x)*32)) ++#define NV50_COMPUTE_GLOBAL_MODE__SIZE 0x00000010 ++#define NV50_COMPUTE_GLOBAL_MODE_LINEAR (1 << 0) ++#define NV50_COMPUTE_GLOBAL_MODE_TILE_MODE_SHIFT 8 ++#define NV50_COMPUTE_GLOBAL_MODE_TILE_MODE_MASK 0x00000f00 ++#define NV50_COMPUTE_USER_PARAM(x) (0x00000600+((x)*4)) ++#define NV50_COMPUTE_USER_PARAM__SIZE 0x00000040 ++ ++ ++#endif /* NOUVEAU_REG_H */ +Index: mesa/src/gallium/drivers/nv50/nv50_screen.c +=================================================================== +--- mesa.orig/src/gallium/drivers/nv50/nv50_screen.c ++++ mesa/src/gallium/drivers/nv50/nv50_screen.c +@@ -360,8 +360,8 @@ + so_data (so, 1); + + /* activate all 32 lanes (threads) in a warp */ +- so_method(so, screen->tesla, NV50TCL_WARP_HALVES, 1); +- so_data (so, 0x2); ++ so_method(so, screen->tesla, NV50TCL_REG_MODE, 1); ++ so_data (so, NV50TCL_REG_MODE_STRIPED); + so_method(so, screen->tesla, 0x1400, 1); + so_data (so, 0xf); + +Index: mesa/src/mesa/drivers/dri/nouveau/nouveau_class.h +=================================================================== +--- /dev/null ++++ mesa/src/mesa/drivers/dri/nouveau/nouveau_class.h +@@ -0,0 +1 @@ ++../../../../gallium/drivers/nouveau/nouveau_class.h +\ No newline at end of file --- mesa-7.8.2.orig/debian/patches/08-kfreebsd-gallium.diff +++ mesa-7.8.2/debian/patches/08-kfreebsd-gallium.diff @@ -0,0 +1,26 @@ +Index: mesa/src/gallium/auxiliary/rtasm/rtasm_execmem.c +=================================================================== +--- mesa.orig/src/gallium/auxiliary/rtasm/rtasm_execmem.c ++++ mesa/src/gallium/auxiliary/rtasm/rtasm_execmem.c +@@ -37,7 +37,7 @@ + + #include "rtasm_execmem.h" + +-#if defined(PIPE_OS_BSD) ++#ifndef MAP_ANONYMOUS + #define MAP_ANONYMOUS MAP_ANON + #endif + +Index: mesa/src/gallium/include/pipe/p_config.h +=================================================================== +--- mesa.orig/src/gallium/include/pipe/p_config.h ++++ mesa/src/gallium/include/pipe/p_config.h +@@ -128,7 +128,7 @@ + #define PIPE_OS_UNIX + #endif + +-#if defined(__FreeBSD__) ++#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) + #define PIPE_OS_FREEBSD + #define PIPE_OS_BSD + #define PIPE_OS_UNIX --- mesa-7.8.2.orig/debian/patches/09-intel-fix-invalidate-before-initialisation.diff +++ mesa-7.8.2/debian/patches/09-intel-fix-invalidate-before-initialisation.diff @@ -0,0 +1,73 @@ +From dd7853f327ad7a286a59c9c5956d4989c31a58fa Mon Sep 17 00:00:00 2001 +From: Chris Wilson +Date: Fri, 16 Jul 2010 12:24:53 +0100 +Subject: [PATCH] intel: Fix invalidate before initialisation + +Fixes: + + Bug 29091 - 1.9RC5 server crash when starting GLX 1.3 app with mesa 7.8 + Intel dri2 driver. + https://bugs.freedesktop.org/show_bug.cgi?id=29091 + +Signed-off-by: Chris Wilson +--- + src/mesa/drivers/dri/common/dri_util.c | 2 +- + src/mesa/drivers/dri/intel/intel_screen.c | 19 +++++++++++++++---- + 2 files changed, 16 insertions(+), 5 deletions(-) + +diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c +index 75c9882..9a9bfed 100644 +--- a/src/mesa/drivers/dri/common/dri_util.c ++++ b/src/mesa/drivers/dri/common/dri_util.c +@@ -432,7 +432,7 @@ driCreateNewDrawable(__DRIscreen *psp, const __DRIconfig *config, + */ + (void) attrs; + +- pdp = malloc(sizeof *pdp); ++ pdp = calloc(1, sizeof *pdp); + if (!pdp) { + return NULL; + } +diff --git a/src/mesa/drivers/dri/intel/intel_screen.c b/src/mesa/drivers/dri/intel/intel_screen.c +index 6e4bb64..083b7bb 100644 +--- a/src/mesa/drivers/dri/intel/intel_screen.c ++++ b/src/mesa/drivers/dri/intel/intel_screen.c +@@ -102,10 +102,21 @@ static const __DRItexBufferExtension intelTexBufferExtension = { + intelSetTexBuffer2, + }; + ++static inline struct intel_context * ++to_intel_context(__DRIdrawable *drawable) ++{ ++ if (drawable->driContextPriv == NULL) ++ return NULL; ++ ++ return drawable->driContextPriv->driverPrivate; ++} ++ + static void + intelDRI2Flush(__DRIdrawable *drawable) + { +- struct intel_context *intel = drawable->driContextPriv->driverPrivate; ++ struct intel_context *intel = to_intel_context(drawable); ++ if (!intel) ++ return; + + if (intel->gen < 4) + INTEL_FIREVERTICES(intel); +@@ -117,9 +128,9 @@ intelDRI2Flush(__DRIdrawable *drawable) + static void + intelDRI2Invalidate(__DRIdrawable *drawable) + { +- struct intel_context *intel = drawable->driContextPriv->driverPrivate; +- +- intel->using_dri2_swapbuffers = GL_TRUE; ++ struct intel_context *intel = to_intel_context(drawable); ++ if (intel) ++ intel->using_dri2_swapbuffers = GL_TRUE; + dri2InvalidateDrawable(drawable); + } + +-- +1.7.1 + --- mesa-7.8.2.orig/debian/patches/series +++ mesa-7.8.2/debian/patches/series @@ -0,0 +1,12 @@ +02_use-ieee-fp-on-s390-and-m68k.patch +03_optional-progs-and-install.patch +04_osmesa_version.diff +05_hurd-ftbfs.diff +06_kfreebsd-ftbfs.diff +07-nouveau-update.diff +08-kfreebsd-gallium.diff +09-intel-fix-invalidate-before-initialisation.diff +100_no_abi_tag.patch +101_ubuntu_hidden_glname.patch +103_savage-expose_fbmodes_with_nonzero_alpha.patch +107_glxgears_is_not_a_benchmark.patch --- mesa-7.8.2.orig/debian/scripts/choose-configs +++ mesa-7.8.2/debian/scripts/choose-configs @@ -0,0 +1,47 @@ +# Script to choose which configurations are to be built depending on the value +# of the DEB_BUILD_ARCH variable. +# +# Copyright © 2006 Thierry Reding + +############################################################################## +## architecture-specific configurations ###################################### + +# choose an architecture-specific build of swx11 and GLU if a matching +# configuration exists +#ifneq ($(wildcard configs/debian-swx11+glu-$(DEB_BUILD_ARCH)),) +# SWX11_GLU_CONFIGS := debian-swx11+glu-$(DEB_BUILD_ARCH) +#else +# SWX11_GLU_CONFIGS := debian-swx11+glu-any +#endif + +# same for static builds +#ifneq ($(wildcard configs/debian-swx11+glu-static-$(DEB_BUILD_ARCH)),) +# SWX11_GLU_CONFIGS += debian-swx11+glu-static-$(DEB_BUILD_ARCH) +#else +# SWX11_GLU_CONFIGS += debian-swx11+glu-static-any +#endif + +SWX11_GLU_CONFIGS := swx11+glu swx11+glu-static + +############################################################################## +## CPU-optimized configurations ############################################## + +#ifneq (,$(filter $(DEB_BUILD_ARCH), i386 kfreebsd-i386 hurd-i386)) +# SWX11_GLU_CONFIGS += swx11+glu-i386-i686 +# DRI_CONFIGS += debian-dri-i386-i686 +#endif + +#ifeq ($(DEB_BUILD_ARCH), alpha) +# SWX11_GLU_CONFIGS += debian-swx11+glu-alpha-ev5 +#endif + +#ifeq ($(DEB_BUILD_ARCH), powerpc) +# SWX11_GLU_CONFIGS += debian-swx11+glu-powerpc-603 +#endif + +#ifeq ($(DEB_BUILD_ARCH), sparc) +# SWX11_GLU_CONFIGS += debian-swx11+glu-sparc-ultrasparc +#endif + +# vim: ft=make + --- mesa-7.8.2.orig/progs/SConscript +++ mesa-7.8.2/progs/SConscript @@ -0,0 +1,59 @@ +Import('*') + +if env['platform'] == 'embedded': + Return() + +SConscript([ + 'util/SConscript', +]) + +Import('util') + +progs_env = env.Clone() + +if progs_env['platform'] == 'windows': + progs_env.Append(CPPDEFINES = ['NOMINMAX']) + progs_env.Prepend(LIBS = [ + 'winmm', + 'kernel32', + 'user32', + 'gdi32', + ]) + +# OpenGL +if progs_env['platform'] == 'windows': + progs_env.Prepend(LIBS = ['glu32', 'opengl32']) +else: + progs_env.Prepend(LIBS = ['GLU', 'GL']) + +# Glut +progs_env.Prepend(LIBPATH = [glut.dir]) +progs_env.Prepend(LIBS = [glut.name]) + +# GLEW +progs_env.Prepend(LIBS = [glew]) + +progs_env.Prepend(CPPPATH = [ + '#progs/util', +]) + +progs_env.Prepend(LIBS = [ + util, +]) + +Export('progs_env') + +SConscript([ + 'demos/SConscript', + 'glsl/SConscript', + 'redbook/SConscript', + 'samples/SConscript', + 'tests/SConscript', + 'trivial/SConscript', + 'vp/SConscript', + 'vpglsl/SConscript', + 'fp/SConscript', + 'wgl/SConscript', + 'perf/SConscript', + 'gallium/unit/SConscript', +]) --- mesa-7.8.2.orig/progs/demos/SConscript +++ mesa-7.8.2/progs/demos/SConscript @@ -0,0 +1,71 @@ +Import('*') + +progs = [ + 'arbfplight', + 'arbfslight', + 'arbocclude', + 'arbocclude2', + 'bounce', + 'clearspd', + 'copypix', + 'cubemap', + 'dinoshade', + 'dissolve', + 'drawpix', + 'engine', + 'fbo_firecube', + 'fbotexture', + 'fire', + 'fogcoord', + 'fplight', + 'fslight', + 'gamma', + 'gearbox', + 'gears', + 'geartrain', + 'glinfo', + 'gloss', + 'gltestperf', + 'ipers', + 'isosurf', + 'lodbias', + 'morph3d', + 'multiarb', + 'paltex', + 'pointblast', + 'projtex', + 'ray', + 'readpix', + 'reflect', + 'renormal', + 'shadowtex', + 'singlebuffer', + 'spectex', + 'spriteblast', + 'stex3d', + 'teapot', + 'terrain', + 'tessdemo', + 'texcyl', + 'texenv', + 'textures', + 'trispd', + 'tunnel', + 'tunnel2', + 'vao_demo', + 'winpos', +] + +for prog in progs: + progs_env.Program( + target = prog, + source = prog + '.c', + ) + +progs_env.Program( + target = 'rain', + source = [ + 'rain.cxx', + 'particles.cxx', + ] +) --- mesa-7.8.2.orig/progs/samples/SConscript +++ mesa-7.8.2/progs/samples/SConscript @@ -0,0 +1,40 @@ +Import('*') + +progs = [ + 'accum', + 'bitmap1', + 'bitmap2', + 'blendeq', + 'blendxor', + 'copy', + 'cursor', + 'depth', + 'eval', + 'fog', + 'font', + 'line', + 'logo', + 'nurb', + #'oglinfo', + 'olympic', + 'overlay', + 'point', + 'prim', + 'quad', + 'rgbtoppm', + 'select', + 'shape', + 'sphere', + 'star', + 'stencil', + 'stretch', + 'texture', + 'tri', + 'wave', +] + +for prog in progs: + progs_env.Program( + target = prog, + source = prog + '.c', + ) --- mesa-7.8.2.orig/progs/util/SConscript +++ mesa-7.8.2/progs/util/SConscript @@ -0,0 +1,15 @@ +Import('env') + +env = env.Clone() + +util = env.StaticLibrary( + target = ['util'], + source = [ + 'readtex.c', + 'trackball.c', + 'showbuffer.c', + 'shaderutil.c', + ], +) + +Export('util') --- mesa-7.8.2.orig/progs/util/imagesgi.cpp +++ mesa-7.8.2/progs/util/imagesgi.cpp @@ -0,0 +1,369 @@ +/****************************************************************************** +** Filename : imageSgi.cpp +** UNCLASSIFIED +** +** Description : Utility to read SGI image format files. This code was +** originally a SGI image loading utility provided with the +** Mesa 3D library @ http://www.mesa3d.org by Brain Paul. +** This has been extended to read all SGI image formats +** (e.g. INT, INTA, RGB, RGBA). +** +** Revision History: +** Date Name Description +** 06/07/99 BRC Initial Release +** +** Note: +** +** The SGI Image Data (if not RLE) +** +** If the image is stored verbatim (without RLE), then image data directly +** follows the 512 byte header. The data for each scanline of the first +** channel is written first. If the image has more than 1 channel, all +** the data for the first channel is written, followed by the remaining +** channels. If the BPC value is 1, then each scanline is written as XSIZE +** bytes. If the BPC value is 2, then each scanline is written as XSIZE +** shorts. These shorts are stored in the byte order described above. +** +******************************************************************************/ +#define __IMAGESGI_CPP + +#include "imagesgi.h" + +#include +#include +#include +#include +#include + +struct sImageSgiRaw +{ + struct sImageSgiHeader header; + unsigned char *chan0; + unsigned char *chan1; + unsigned char *chan2; + unsigned char *chan3; + unsigned int *rowStart; + int *rowSize; +}; + +// Static routines +static struct sImageSgiRaw *ImageSgiRawOpen(char const * const fileName); +static void ImageSgiRawClose(struct sImageSgiRaw *raw); +static void ImageSgiRawGetRow(struct sImageSgiRaw *raw, unsigned char *buf, + int y, int z); +static void ImageSgiRawGetData(struct sImageSgiRaw *raw, struct sImageSgi +*final); +static void *SwitchEndian16(void *value); +static void *SwitchEndian32(void *value); + +// Static variables +FILE *mFp = NULL; +unsigned char *mChanTmp = NULL; + + +/*****************************************************************************/ +struct sImageSgi *ImageSgiOpen(char const * const fileName) +{ + struct sImageSgiRaw *raw = NULL; + struct sImageSgi *final = NULL; + + raw = ImageSgiRawOpen(fileName); + final = new struct sImageSgi; + + assert(final); + if(final) + { + final->header = raw->header; + final->data = NULL; + ImageSgiRawGetData(raw, final); + ImageSgiRawClose(raw); + } + + return final; +} // ImageSgiRawOpen + + +/*****************************************************************************/ +void ImageSgiClose(struct sImageSgi *image) +{ + + if(image) + { + if(image->data) + delete[] image->data; + image->data = NULL; + delete image; + } + image = NULL; + + return; +} // ImageSgiClose + + +/*****************************************************************************/ +static struct sImageSgiRaw *ImageSgiRawOpen(char const * const fileName) +{ + struct sImageSgiRaw *raw = NULL; + int x; + int i; + bool swapFlag = false; + union + { + int testWord; + char testByte[4]; + } endianTest; + endianTest.testWord = 1; + + // Determine endianess of platform. + if(endianTest.testByte[0] == 1) + swapFlag = true; + else + swapFlag = false; + + raw = new struct sImageSgiRaw; + + assert(raw); + if(raw) + { + raw->chan0 = NULL; + raw->chan1 = NULL; + raw->chan2 = NULL; + raw->chan3 = NULL; + raw->rowStart = NULL; + raw->rowSize = NULL; + mFp = fopen(fileName, "rb"); + assert(mFp); + + fread(&raw->header, sizeof(struct sImageSgiHeader), 1, mFp); + if(swapFlag == true) + { + SwitchEndian16(&raw->header.magic); + SwitchEndian16(&raw->header.type); + SwitchEndian16(&raw->header.dim); + SwitchEndian16(&raw->header.xsize); + SwitchEndian16(&raw->header.ysize); + SwitchEndian16(&raw->header.zsize); + } + + mChanTmp = new unsigned char[raw->header.xsize * raw->header.ysize]; + assert(mChanTmp); + switch(raw->header.zsize) + { + case 4: + raw->chan3 = new unsigned char[raw->header.xsize * +raw->header.ysize]; + assert(raw->chan3); + case 3: + raw->chan2 = new unsigned char[raw->header.xsize * +raw->header.ysize]; + assert(raw->chan2); + case 2: + raw->chan1 = new unsigned char[raw->header.xsize * +raw->header.ysize]; + assert(raw->chan1); + case 1: + raw->chan0 = new unsigned char[raw->header.xsize * +raw->header.ysize]; + assert(raw->chan0); + } + + if(raw->header.type == IMAGE_SGI_TYPE_RLE) + { + x = raw->header.ysize * raw->header.zsize * sizeof(unsigned int); + raw->rowStart = new unsigned int[x]; + raw->rowSize = new int[x]; + + fseek(mFp, sizeof(struct sImageSgiHeader), SEEK_SET); + fread(raw->rowStart, 1, x, mFp); + fread(raw->rowSize, 1, x, mFp); + + if(swapFlag == true) + { + for(i=0; irowStart[i]); + for(i=0; irowSize[i]); + } + + } + + } + + return raw; +} // ImageSgiRawOpen + + +/*****************************************************************************/ +static void ImageSgiRawClose(struct sImageSgiRaw *raw) +{ + + fclose(mFp); + mFp = NULL; + + if(mChanTmp) + delete[] mChanTmp; + mChanTmp = NULL; + + if(raw->chan0) + delete[] raw->chan0; + raw->chan0 = NULL; + + if(raw->chan1) + delete[] raw->chan1; + raw->chan1 = NULL; + + if(raw->chan2) + delete[] raw->chan2; + raw->chan2 = NULL; + + if(raw->chan3) + delete[] raw->chan3; + raw->chan3 = NULL; + + if(raw) + delete raw; + raw = NULL; + + return; +} // ImageSgiRawClose + + +/*****************************************************************************/ +static void ImageSgiRawGetRow(struct sImageSgiRaw *raw, unsigned char *buf, + int y, int z) +{ + unsigned char *iPtr = NULL; + unsigned char *oPtr = NULL; + unsigned char pixel; + int count; + + if((raw->header.type & 0xFF00) == 0x0100) + { + fseek(mFp, raw->rowStart[y+z*raw->header.ysize], SEEK_SET); + fread(mChanTmp, 1, (unsigned int)raw->rowSize[y+z*raw->header.ysize], +mFp); + iPtr = mChanTmp; + oPtr = buf; + while(1) + { + pixel = *iPtr++; + count = (int)(pixel & 0x7F); + if(!count) + { + return; + } + if (pixel & 0x80) + { + while (count--) + { + *oPtr++ = *iPtr++; + } + } + else + { + pixel = *iPtr++; + while (count--) + { + *oPtr++ = pixel; + } + } + } + } + else + { + fseek(mFp, + sizeof(struct sImageSgiHeader)+(y*raw->header.xsize) + + (z*raw->header.xsize*raw->header.ysize), + SEEK_SET); + fread(buf, 1, raw->header.xsize, mFp); + } + + return; +} // ImageSgiRawGetRow + + +/*****************************************************************************/ +static void ImageSgiRawGetData(struct sImageSgiRaw *raw, struct sImageSgi +*final) +{ + unsigned char *ptr = NULL; + int i, j; + + final->data = + new unsigned +char[raw->header.xsize*raw->header.ysize*raw->header.zsize]; + assert(final->data); + + ptr = final->data; + for(i=0; iheader.ysize; i++) + { + switch(raw->header.zsize) + { + case 1: + ImageSgiRawGetRow(raw, raw->chan0, i, 0); + for(j=0; jheader.xsize; j++) + *(ptr++) = raw->chan0[j]; + break; + case 2: + ImageSgiRawGetRow(raw, raw->chan0, i, 0); + ImageSgiRawGetRow(raw, raw->chan1, i, 1); + for(j=0; jheader.xsize; j++) + { + *(ptr++) = raw->chan0[j]; + *(ptr++) = raw->chan1[j]; + } + break; + case 3: + ImageSgiRawGetRow(raw, raw->chan0, i, 0); + ImageSgiRawGetRow(raw, raw->chan1, i, 1); + ImageSgiRawGetRow(raw, raw->chan2, i, 2); + for(j=0; jheader.xsize; j++) + { + *(ptr++) = raw->chan0[j]; + *(ptr++) = raw->chan1[j]; + *(ptr++) = raw->chan2[j]; + } + break; + case 4: + ImageSgiRawGetRow(raw, raw->chan0, i, 0); + ImageSgiRawGetRow(raw, raw->chan1, i, 1); + ImageSgiRawGetRow(raw, raw->chan2, i, 2); + ImageSgiRawGetRow(raw, raw->chan3, i, 3); + for(j=0; jheader.xsize; j++) + { + *(ptr++) = raw->chan0[j]; + *(ptr++) = raw->chan1[j]; + *(ptr++) = raw->chan2[j]; + *(ptr++) = raw->chan3[j]; + } + break; + } + } + + return; +} // ImageSgiRawGetData + + +/*****************************************************************************/ +static void *SwitchEndian16(void *value) +{ + short value16 = *(short *) value; + value16 = ((value16 & 0xff00) >> 8L) + + ((value16 & 0x00ff) << 8L); + *(short *)value = value16; + return value; +} // SwitchEndian16 + + +/*****************************************************************************/ +static void *SwitchEndian32(void *value) +{ + int value32 = *(int *) value; + value32 = ((value32 & 0xff000000) >> 24L) + + ((value32 & 0x00ff0000) >> 8) + + ((value32 & 0x0000ff00) << 8) + + ((value32 & 0x000000ff) << 24L); + *(int *)value = value32; + return value; +} // SwitchEndian32 + --- mesa-7.8.2.orig/progs/glsl/SConscript +++ mesa-7.8.2/progs/glsl/SConscript @@ -0,0 +1,37 @@ +Import('*') + +progs = [ + 'array', + 'bitmap', + 'brick', + 'bump', + 'convolutions', + 'deriv', + 'fragcoord', + 'identity', + 'linktest', + 'mandelbrot', + 'multinoise', + 'multitex', + 'noise', + 'noise2', + 'pointcoord', + 'points', + 'samplers', + 'shadow_sampler', + 'skinning', + 'texaaline', + 'texdemo1', + 'toyball', + 'trirast', + 'twoside', + 'vert-or-frag-only', + 'vert-tex', +] + +for prog in progs: + progs_env.Program( + target = prog, + source = prog + '.c', + ) + --- mesa-7.8.2.orig/progs/redbook/SConscript +++ mesa-7.8.2/progs/redbook/SConscript @@ -0,0 +1,86 @@ +Import('*') + +progs = [ + 'aaindex', + 'aapoly', + 'aargb', + 'accanti', + 'accpersp', + 'alpha3D', + 'alpha', + 'anti', + 'bezcurve', + 'bezmesh', + 'checker', + 'clip', + 'colormat', + 'combiner', + 'convolution', + 'cube', + 'cubemap', + 'depthcue', + 'dof', + 'double', + 'drawf', + 'feedback', + 'fog', + 'fogcoord', + 'fogindex', + 'font', + 'hello', + 'histogram', + 'image', + 'light', + 'lines', + 'list', + 'material', + 'minmax', + 'mipmap', + 'model', + 'movelight', + 'multisamp', + 'multitex', + 'mvarray', + 'nurbs', + 'pickdepth', + 'picksquare', + 'plane', + 'planet', + 'pointp', + 'polyoff', + 'polys', + 'quadric', + 'robot', + 'sccolorlight', + 'scenebamb', + 'scene', + 'sceneflat', + 'select', + 'shadowmap', + 'smooth', + 'stencil', + 'stroke', + 'surface', + 'surfpoints', + 'teaambient', + 'teapots', + 'tess', + 'tesswind', + 'texbind', + 'texgen', + 'texprox', + 'texsub', + 'texturesurf', + 'texture3d', + 'torus', + 'trim', + 'unproject', + 'varray', + 'wrap', +] + +for prog in progs: + progs_env.Program( + target = prog, + source = prog + '.c', + )