diff options
author | marha <marha@users.sourceforge.net> | 2011-02-20 14:23:37 +0000 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2011-02-20 14:23:37 +0000 |
commit | 684eb992146cad24b690073f33b909f47150b841 (patch) | |
tree | 7bc62d6f06c5e8a8114b56fa78485cb7ec08f26b /mesalib/docs | |
parent | 53810445215dc45ae303bc89feb6e0aaf04aa6fa (diff) | |
parent | 8a191c08ddda2e66fa26f148d6c21959bb08f923 (diff) | |
download | vcxsrv-684eb992146cad24b690073f33b909f47150b841.tar.gz vcxsrv-684eb992146cad24b690073f33b909f47150b841.tar.bz2 vcxsrv-684eb992146cad24b690073f33b909f47150b841.zip |
svn merge ^/branches/released .
Diffstat (limited to 'mesalib/docs')
-rw-r--r-- | mesalib/docs/envvars.html | 233 | ||||
-rw-r--r-- | mesalib/docs/shading.html | 536 | ||||
-rw-r--r-- | mesalib/docs/sourcetree.html | 331 |
3 files changed, 589 insertions, 511 deletions
diff --git a/mesalib/docs/envvars.html b/mesalib/docs/envvars.html index fd1700a02..5240c803f 100644 --- a/mesalib/docs/envvars.html +++ b/mesalib/docs/envvars.html @@ -1,78 +1,155 @@ -<HTML> - -<TITLE>Environment Variables</TITLE> - -<link rel="stylesheet" type="text/css" href="mesa.css"></head> - -<BODY> - -<H1>Environment Variables</H1> - -<p> -Mesa supports the following environment variables: -</p> -<ul> -<li>MESA_NO_ASM - if set, disables all assembly language optimizations -<li>MESA_NO_MMX - if set, disables Intel MMX optimizations -<li>MESA_NO_3DNOW - if set, disables AMD 3DNow! optimizations -<li>MESA_NO_SSE - if set, disables Intel SSE optimizations -<li>MESA_DEBUG - if set, error messages are printed to stderr. -If the value of MESA_DEBUG is "FP" floating point arithmetic errors will -generate exceptions. -<li>MESA_NO_DITHER - if set, disables dithering, overriding glEnable(GL_DITHER) -<li>MESA_TEX_PROG - if set, implement conventional texture env modes with -fragment programs (intended for developers only) -<li>MESA_TNL_PROG - if set, implement conventional vertex transformation -operations with vertex programs (intended for developers only). -Setting this variable automatically sets the MESA_TEX_PROG variable as well. -<li>MESA_EXTENSION_OVERRIDE - can be used to enable/disable extensions. -A value such as "GL_EXT_foo -GL_EXT_bar" will enable the GL_EXT_foo extension -and disable the GL_EXT_bar extension. -<li>MESA_GLSL - <a href="shading.html#envvars">shading language options</a> -</ul> - -<p> -The following are only applicable to the Xlib software driver. -See the <A HREF="xlibdriver.html">Xlib software driver page</A> for details. -</p> -<ul> -<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode -<li>MESA_CI_VISUAL - specifies the X visual and depth for CI mode -<li>MESA_BACK_BUFFER - specifies how to implement the back color buffer, - either "pixmap" or "ximage" -<li>MESA_GAMMA - gamma correction coefficients for red, green, blue channels -<li>MESA_XSYNC - enable synchronous X behavior (for debugging only) -<li>MESA_GLX_FORCE_CI - if set, force GLX to treat 8bpp visuals as CI visuals -<li>MESA_GLX_FX - set to either "fullscreen" for full-screen rendering, - "window" to render into a window, or "disable" to disable the Glide driver. -<li>MESA_GLX_FORCE_ALPHA - if set, forces RGB windows to have an alpha channel. -<li>MESA_GLX_DEPTH_BITS - specifies default number of bits for depth buffer. -<li>MESA_GLX_ALPHA_BITS - specifies default number of bits for alpha channel. -</ul> - - -<p> -These environment variables are for the Intel i945/i965 drivers: -</p> -<ul> -<li>INTEL_STRICT_CONFORMANCE - if set to 1, enable sw fallbacks to improve - OpenGL conformance. If set to 2, always use software rendering. -<li>INTEL_NO_BLIT - if set, disable hardware-accelerated glBitmap, - glCopyPixels, glDrawPixels. -</ul> - - -<p> -These environment variables are for the Radeon R300 driver: -</p> -<ul> -<li>R300_NO_TCL - if set, disable hardware-accelerated Transform/Clip/Lighting. -</ul> - -<p> -Mesa EGL supports different sets of environment variables. See the -<a href="egl.html">Mesa EGL</a> page for the details. -</p> - -</BODY> -</HTML> +<HTML>
+
+<TITLE>Environment Variables</TITLE>
+
+<link rel="stylesheet" type="text/css" href="mesa.css"></head>
+
+<BODY>
+
+<H1>Environment Variables</H1>
+
+<p>
+Normally, no environment variables need to be set. Most of the environment
+variables used by Mesa/Gallium are for debugging purposes, but they can
+sometimes be useful for debugging end-user issues.
+</p>
+
+
+<H2>LibGL environment variables</H2>
+
+<ul>
+<li>LIBGL_DEBUG - If defined debug information will be printed to stderr.
+ If set to 'verbose' additional information will be printed.
+<li>LIBGL_DRIVERS_PATH - colon-separated list of paths to search for DRI drivers
+<li>LIBGL_ALWAYS_INDIRECT - forces an indirect rendering context/connection.
+<li>LIBGL_ALWAYS_SOFTWARE - if set, always use software rendering
+<li>LIBGL_NO_DRAWARRAYS - if set do not use DrawArrays GLX protocol (for debugging)
+</ul>
+
+
+
+<H2>Core Mesa environment variables</H2>
+
+<ul>
+<li>MESA_NO_ASM - if set, disables all assembly language optimizations
+<li>MESA_NO_MMX - if set, disables Intel MMX optimizations
+<li>MESA_NO_3DNOW - if set, disables AMD 3DNow! optimizations
+<li>MESA_NO_SSE - if set, disables Intel SSE optimizations
+<li>MESA_DEBUG - if set, error messages are printed to stderr. For example,
+ if the application generates a GL_INVALID_ENUM error, a corresponding error
+ message indicating where the error occured, and possibly why, will be
+ printed to stderr.<br>
+ If the value of MESA_DEBUG is 'FP' floating point arithmetic errors will
+ generate exceptions.
+<li>MESA_TEX_PROG - if set, implement conventional texture env modes with
+fragment programs (intended for developers only)
+<li>MESA_TNL_PROG - if set, implement conventional vertex transformation
+operations with vertex programs (intended for developers only).
+Setting this variable automatically sets the MESA_TEX_PROG variable as well.
+<li>MESA_EXTENSION_OVERRIDE - can be used to enable/disable extensions.
+A value such as "GL_EXT_foo -GL_EXT_bar" will enable the GL_EXT_foo extension
+and disable the GL_EXT_bar extension.
+<li>MESA_GLSL - <a href="shading.html#envvars">shading language compiler options</a>
+</ul>
+
+
+<H2>Mesa Xlib driver environment variables</H2>
+
+<p>
+The following are only applicable to the Mesa Xlib software driver.
+See the <A HREF="xlibdriver.html">Xlib software driver page</A> for details.
+</p>
+<ul>
+<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode
+<li>MESA_CI_VISUAL - specifies the X visual and depth for CI mode
+<li>MESA_BACK_BUFFER - specifies how to implement the back color buffer,
+ either "pixmap" or "ximage"
+<li>MESA_GAMMA - gamma correction coefficients for red, green, blue channels
+<li>MESA_XSYNC - enable synchronous X behavior (for debugging only)
+<li>MESA_GLX_FORCE_CI - if set, force GLX to treat 8bpp visuals as CI visuals
+<li>MESA_GLX_FX - set to either "fullscreen" for full-screen rendering,
+ "window" to render into a window, or "disable" to disable the Glide driver.
+<li>MESA_GLX_FORCE_ALPHA - if set, forces RGB windows to have an alpha channel.
+<li>MESA_GLX_DEPTH_BITS - specifies default number of bits for depth buffer.
+<li>MESA_GLX_ALPHA_BITS - specifies default number of bits for alpha channel.
+</ul>
+
+
+<h2>i945/i965 driver environment variables (non-Gallium)</h2>
+
+<ul>
+<li>INTEL_STRICT_CONFORMANCE - if set to 1, enable sw fallbacks to improve
+ OpenGL conformance. If set to 2, always use software rendering.
+<li>INTEL_NO_BLIT - if set, disable hardware-accelerated glBitmap,
+ glCopyPixels, glDrawPixels.
+</ul>
+
+
+<h2>Radeon R300 driver environment variables (non-Gallium)</h2>
+
+<ul>
+<li>R300_NO_TCL - if set, disable hardware-accelerated Transform/Clip/Lighting.
+</ul>
+
+
+<h2>EGL environment variables</h2>
+
+<p>
+Mesa EGL supports different sets of environment variables. See the
+<a href="egl.html">Mesa EGL</a> page for the details.
+</p>
+
+
+<h2>Gallium environment variables</h2>
+
+<ul>
+<li>GALLIUM_PRINT_OPTIONS - if non-zero, print all the Gallium environment
+ variables which are used, and their current values.
+<li>GALLIUM_NOSSE - if non-zero, do not use SSE runtime code generation for
+ shader execution
+<li>GALLIUM_NOPPC - if non-zero, do not use PPC runtime code generation for
+ shader execution
+<li>GALLIUM_DUMP_CPU - if non-zero, print information about the CPU on start-up
+<li>TGSI_PRINT_SANITY - if set, do extra sanity checking on TGSI shaders and
+ print any errors to stderr.
+<LI>DRAW_FSE - ???
+<LI>DRAW_NO_FSE - ???
+<li>DRAW_USE_LLVM - if set to zero, the draw module will not use LLVM to execute
+ shaders, vertex fetch, etc.
+</ul>
+
+<h3>Softpipe driver environment variables</h3>
+<ul>
+<li>SOFTPIPE_DUMP_FS - if set, the softpipe driver will print fragment shaders
+ to stderr
+<li>SOFTPIPE_DUMP_GS - if set, the softpipe driver will print geometry shaders
+ to stderr
+<li>SOFTPIPE_NO_RAST - if set, rasterization is no-op'd. For profiling purposes.
+</ul>
+
+
+<h3>LLVMpipe driver environment variables</h3>
+<ul>
+<li>LP_NO_RAST - if set LLVMpipe will no-op rasterization
+<li>LP_DEBUG - a comma-separated list of debug options is acceptec. See the
+ source code for details.
+<li>LP_PERF - a comma-separated list of options to selectively no-op various
+ parts of the driver. See the source code for details.
+<li>LP_NUM_THREADS - an integer indicating how many threads to use for rendering.
+ Zero turns of threading completely. The default value is the number of CPU
+ cores present.
+</ul>
+
+
+<p>
+Other Gallium drivers have their own environment variables. These may change
+frequently so the source code should be consulted for details.
+</p>
+
+
+<br>
+<br>
+
+
+</BODY>
+</HTML>
diff --git a/mesalib/docs/shading.html b/mesalib/docs/shading.html index c41d4a9be..cc1f9f1ec 100644 --- a/mesalib/docs/shading.html +++ b/mesalib/docs/shading.html @@ -1,268 +1,268 @@ -<HTML> - -<TITLE>Shading Language Support</TITLE> - -<link rel="stylesheet" type="text/css" href="mesa.css"></head> - -<BODY> - -<H1>Shading Language Support</H1> - -<p> -This page describes the features and status of Mesa's support for the -<a href="http://opengl.org/documentation/glsl/" target="_parent"> -OpenGL Shading Language</a>. -</p> - -<p> -Contents -</p> -<ul> -<li><a href="#envvars">Environment variables</a> -<li><a href="#120">GLSL 1.20 support</a> -<li><a href="#unsup">Unsupported Features</a> -<li><a href="#notes">Implementation Notes</a> -<li><a href="#hints">Programming Hints</a> -<li><a href="#standalone">Stand-alone GLSL Compiler</a> -<li><a href="#implementation">Compiler Implementation</a> -<li><a href="#validation">Compiler Validation</a> -</ul> - - - -<a name="envvars"> -<h2>Environment Variables</h2> - -<p> -The <b>MESA_GLSL</b> environment variable can be set to a comma-separated -list of keywords to control some aspects of the GLSL compiler and shader -execution. These are generally used for debugging. -</p> -<ul> -<li><b>dump</b> - print GLSL shader code to stdout at link time -<li><b>log</b> - log all GLSL shaders to files. - The filenames will be "shader_X.vert" or "shader_X.frag" where X - the shader ID. -<li><b>nopt</b> - disable compiler optimizations -<li><b>opt</b> - force compiler optimizations -<li><b>uniform</b> - print message to stdout when glUniform is called -<li><b>nopvert</b> - force vertex shaders to be a simple shader that just transforms - the vertex position with ftransform() and passes through the color and - texcoord[0] attributes. -<li><b>nopfrag</b> - force fragment shader to be a simple shader that passes - through the color attribute. -<li><b>useprog</b> - log glUseProgram calls to stderr -</ul> -<p> -Example: export MESA_GLSL=dump,nopt -</p> - - -<a name="120"> -<h2>GLSL Version</h2> - -<p> -The GLSL compiler currently supports version 1.20 of the shading language. -</p> - -<p> -Several GLSL extensions are also supported: -</p> -<ul> -<li>GL_ARB_draw_buffers -<li>GL_ARB_texture_rectangle -<li>GL_ARB_fragment_coord_conventions -<li>GL_EXT_texture_array -</ul> - - -<a name="unsup"> -<h2>Unsupported Features</h2> - -<p>XXX update this section</p> - -<p> -The following features of the shading language are not yet fully supported -in Mesa: -</p> - -<ul> -<li>Linking of multiple shaders does not always work. Currently, linking - is implemented through shader concatenation and re-compiling. This - doesn't always work because of some #pragma and preprocessor issues. -<li>gl_ClipVertex -<li>The gl_Color and gl_SecondaryColor varying vars are interpolated - without perspective correction -</ul> - -<p> -All other major features of the shading language should function. -</p> - - -<a name="notes"> -<h2>Implementation Notes</h2> - -<ul> -<li>Shading language programs are compiled into low-level programs - very similar to those of GL_ARB_vertex/fragment_program. -<li>All vector types (vec2, vec3, vec4, bvec2, etc) currently occupy full - float[4] registers. -<li>Float constants and variables are packed so that up to four floats - can occupy one program parameter/register. -<li>All function calls are inlined. -<li>Shaders which use too many registers will not compile. -<li>The quality of generated code is pretty good, register usage is fair. -<li>Shader error detection and reporting of errors (InfoLog) is not - very good yet. -<li>The ftransform() function doesn't necessarily match the results of - fixed-function transformation. -</ul> - -<p> -These issues will be addressed/resolved in the future. -</p> - - -<a name="hints"> -<h2>Programming Hints</h2> - -<ul> -<li>Use the built-in library functions whenever possible. - For example, instead of writing this: -<pre> - float x = 1.0 / sqrt(y); -</pre> - Write this: -<pre> - float x = inversesqrt(y); -</pre> -</li> -</ul> - - -<a name="standalone"> -<h2>Stand-alone GLSL Compiler</h2> - -<p> -The stand-alone GLSL compiler program can be used to compile GLSL shaders -into low-level GPU code. -</p> - -<p> -This tool is useful for: -<p> -<ul> -<li>Inspecting GPU code to gain insight into compilation -<li>Generating initial GPU code for subsequent hand-tuning -<li>Debugging the GLSL compiler itself -</ul> - -<p> -After building Mesa, the compiler can be found at src/glsl/glsl_compiler -</p> - -<p> -Here's an example of using the compiler to compile a vertex shader and -emit GL_ARB_vertex_program-style instructions: -</p> -<pre> - src/glsl/glslcompiler --dump-ast myshader.vert -</pre> - -Options include -<ul> -<li><b>--dump-ast</b> - dump GPU code -<li><b>--dump-hir</b> - dump high-level IR code -<li><b>--dump-lir</b> - dump low-level IR code -<li><b>--link</b> - ??? -</ul> - - - - -<a name="implementation"> -<h2>Compiler Implementation</h2> - -<p> -The source code for Mesa's shading language compiler is in the -<code>src/glsl/</code> directory. -</p> - -<p> -XXX provide some info about the compiler.... -</p> - -<p> -The final vertex and fragment programs may be interpreted in software -(see prog_execute.c) or translated into a specific hardware architecture -(see drivers/dri/i915/i915_fragprog.c for example). -</p> - -<h3>Code Generation Options</h3> - -<p> -Internally, there are several options that control the compiler's code -generation and instruction selection. -These options are seen in the gl_shader_state struct and may be set -by the device driver to indicate its preferences: - -<pre> -struct gl_shader_state -{ - ... - /** Driver-selectable options: */ - GLboolean EmitHighLevelInstructions; - GLboolean EmitCondCodes; - GLboolean EmitComments; -}; -</pre> - -<ul> -<li>EmitHighLevelInstructions -<br> -This option controls instruction selection for loops and conditionals. -If the option is set high-level IF/ELSE/ENDIF, LOOP/ENDLOOP, CONT/BRK -instructions will be emitted. -Otherwise, those constructs will be implemented with BRA instructions. -</li> - -<li>EmitCondCodes -<br> -If set, condition codes (ala GL_NV_fragment_program) will be used for -branching and looping. -Otherwise, ordinary registers will be used (the IF instruction will -examine the first operand's X component and do the if-part if non-zero). -This option is only relevant if EmitHighLevelInstructions is set. -</li> - -<li>EmitComments -<br> -If set, instructions will be annoted with comments to help with debugging. -Extra NOP instructions will also be inserted. -</br> - -</ul> - - -<a name="validation"> -<h2>Compiler Validation</h2> - -<p> -Developers working on the GLSL compiler should test frequently to avoid -regressions. -</p> - -<p> -The <a href="http://people.freedesktop.org/~nh/piglit/">Piglit</a> project -has many GLSL tests and the -<a href="http://glean.sf.net" target="_parent">Glean</a> glsl1 test -tests GLSL features. -</p> - -<p> -The Mesa demos repository also has some good GLSL tests. -</p> - -</BODY> -</HTML> +<HTML>
+
+<TITLE>Shading Language Support</TITLE>
+
+<link rel="stylesheet" type="text/css" href="mesa.css"></head>
+
+<BODY>
+
+<H1>Shading Language Support</H1>
+
+<p>
+This page describes the features and status of Mesa's support for the
+<a href="http://opengl.org/documentation/glsl/" target="_parent">
+OpenGL Shading Language</a>.
+</p>
+
+<p>
+Contents
+</p>
+<ul>
+<li><a href="#envvars">Environment variables</a>
+<li><a href="#120">GLSL 1.20 support</a>
+<li><a href="#unsup">Unsupported Features</a>
+<li><a href="#notes">Implementation Notes</a>
+<li><a href="#hints">Programming Hints</a>
+<li><a href="#standalone">Stand-alone GLSL Compiler</a>
+<li><a href="#implementation">Compiler Implementation</a>
+<li><a href="#validation">Compiler Validation</a>
+</ul>
+
+
+
+<a name="envvars">
+<h2>Environment Variables</h2>
+
+<p>
+The <b>MESA_GLSL</b> environment variable can be set to a comma-separated
+list of keywords to control some aspects of the GLSL compiler and shader
+execution. These are generally used for debugging.
+</p>
+<ul>
+<li><b>dump</b> - print GLSL shader code to stdout at link time
+<li><b>log</b> - log all GLSL shaders to files.
+ The filenames will be "shader_X.vert" or "shader_X.frag" where X
+ the shader ID.
+<li><b>nopt</b> - disable compiler optimizations
+<li><b>opt</b> - force compiler optimizations
+<li><b>uniform</b> - print message to stdout when glUniform is called
+<li><b>nopvert</b> - force vertex shaders to be a simple shader that just transforms
+ the vertex position with ftransform() and passes through the color and
+ texcoord[0] attributes.
+<li><b>nopfrag</b> - force fragment shader to be a simple shader that passes
+ through the color attribute.
+<li><b>useprog</b> - log glUseProgram calls to stderr
+</ul>
+<p>
+Example: export MESA_GLSL=dump,nopt
+</p>
+
+
+<a name="120">
+<h2>GLSL Version</h2>
+
+<p>
+The GLSL compiler currently supports version 1.20 of the shading language.
+</p>
+
+<p>
+Several GLSL extensions are also supported:
+</p>
+<ul>
+<li>GL_ARB_draw_buffers
+<li>GL_ARB_texture_rectangle
+<li>GL_ARB_fragment_coord_conventions
+<li>GL_EXT_texture_array
+</ul>
+
+
+<a name="unsup">
+<h2>Unsupported Features</h2>
+
+<p>XXX update this section</p>
+
+<p>
+The following features of the shading language are not yet fully supported
+in Mesa:
+</p>
+
+<ul>
+<li>Linking of multiple shaders does not always work. Currently, linking
+ is implemented through shader concatenation and re-compiling. This
+ doesn't always work because of some #pragma and preprocessor issues.
+<li>gl_ClipVertex
+<li>The gl_Color and gl_SecondaryColor varying vars are interpolated
+ without perspective correction
+</ul>
+
+<p>
+All other major features of the shading language should function.
+</p>
+
+
+<a name="notes">
+<h2>Implementation Notes</h2>
+
+<ul>
+<li>Shading language programs are compiled into low-level programs
+ very similar to those of GL_ARB_vertex/fragment_program.
+<li>All vector types (vec2, vec3, vec4, bvec2, etc) currently occupy full
+ float[4] registers.
+<li>Float constants and variables are packed so that up to four floats
+ can occupy one program parameter/register.
+<li>All function calls are inlined.
+<li>Shaders which use too many registers will not compile.
+<li>The quality of generated code is pretty good, register usage is fair.
+<li>Shader error detection and reporting of errors (InfoLog) is not
+ very good yet.
+<li>The ftransform() function doesn't necessarily match the results of
+ fixed-function transformation.
+</ul>
+
+<p>
+These issues will be addressed/resolved in the future.
+</p>
+
+
+<a name="hints">
+<h2>Programming Hints</h2>
+
+<ul>
+<li>Use the built-in library functions whenever possible.
+ For example, instead of writing this:
+<pre>
+ float x = 1.0 / sqrt(y);
+</pre>
+ Write this:
+<pre>
+ float x = inversesqrt(y);
+</pre>
+</li>
+</ul>
+
+
+<a name="standalone">
+<h2>Stand-alone GLSL Compiler</h2>
+
+<p>
+The stand-alone GLSL compiler program can be used to compile GLSL shaders
+into low-level GPU code.
+</p>
+
+<p>
+This tool is useful for:
+<p>
+<ul>
+<li>Inspecting GPU code to gain insight into compilation
+<li>Generating initial GPU code for subsequent hand-tuning
+<li>Debugging the GLSL compiler itself
+</ul>
+
+<p>
+After building Mesa, the compiler can be found at src/glsl/glsl_compiler
+</p>
+
+<p>
+Here's an example of using the compiler to compile a vertex shader and
+emit GL_ARB_vertex_program-style instructions:
+</p>
+<pre>
+ src/glsl/glsl_compiler --dump-ast myshader.vert
+</pre>
+
+Options include
+<ul>
+<li><b>--dump-ast</b> - dump GPU code
+<li><b>--dump-hir</b> - dump high-level IR code
+<li><b>--dump-lir</b> - dump low-level IR code
+<li><b>--link</b> - ???
+</ul>
+
+
+
+
+<a name="implementation">
+<h2>Compiler Implementation</h2>
+
+<p>
+The source code for Mesa's shading language compiler is in the
+<code>src/glsl/</code> directory.
+</p>
+
+<p>
+XXX provide some info about the compiler....
+</p>
+
+<p>
+The final vertex and fragment programs may be interpreted in software
+(see prog_execute.c) or translated into a specific hardware architecture
+(see drivers/dri/i915/i915_fragprog.c for example).
+</p>
+
+<h3>Code Generation Options</h3>
+
+<p>
+Internally, there are several options that control the compiler's code
+generation and instruction selection.
+These options are seen in the gl_shader_state struct and may be set
+by the device driver to indicate its preferences:
+
+<pre>
+struct gl_shader_state
+{
+ ...
+ /** Driver-selectable options: */
+ GLboolean EmitHighLevelInstructions;
+ GLboolean EmitCondCodes;
+ GLboolean EmitComments;
+};
+</pre>
+
+<ul>
+<li>EmitHighLevelInstructions
+<br>
+This option controls instruction selection for loops and conditionals.
+If the option is set high-level IF/ELSE/ENDIF, LOOP/ENDLOOP, CONT/BRK
+instructions will be emitted.
+Otherwise, those constructs will be implemented with BRA instructions.
+</li>
+
+<li>EmitCondCodes
+<br>
+If set, condition codes (ala GL_NV_fragment_program) will be used for
+branching and looping.
+Otherwise, ordinary registers will be used (the IF instruction will
+examine the first operand's X component and do the if-part if non-zero).
+This option is only relevant if EmitHighLevelInstructions is set.
+</li>
+
+<li>EmitComments
+<br>
+If set, instructions will be annoted with comments to help with debugging.
+Extra NOP instructions will also be inserted.
+</br>
+
+</ul>
+
+
+<a name="validation">
+<h2>Compiler Validation</h2>
+
+<p>
+Developers working on the GLSL compiler should test frequently to avoid
+regressions.
+</p>
+
+<p>
+The <a href="http://people.freedesktop.org/~nh/piglit/">Piglit</a> project
+has many GLSL tests and the
+<a href="http://glean.sf.net" target="_parent">Glean</a> glsl1 test
+tests GLSL features.
+</p>
+
+<p>
+The Mesa demos repository also has some good GLSL tests.
+</p>
+
+</BODY>
+</HTML>
diff --git a/mesalib/docs/sourcetree.html b/mesalib/docs/sourcetree.html index 00dc4e7c9..67e0494b1 100644 --- a/mesalib/docs/sourcetree.html +++ b/mesalib/docs/sourcetree.html @@ -1,165 +1,166 @@ -<HTML> - -<TITLE>Mesa Source Tree</TITLE> - -<link rel="stylesheet" type="text/css" href="mesa.css"></head> - -<BODY> - -<h1>Mesa source code tree overview</h1> - -<p> -This is a brief summary of Mesa's directory tree and what's contained in -each directory. -</p> - - -<ul> -<li><b>docs</b> - Documentation -<li><b>include</b> - Public OpenGL header files -<li><b>src</b> - <ul> - <li><b>egl</b> - EGL library sources - <ul> - <li><b>docs</b> - EGL documentation - <li><b>drivers</b> - EGL drivers - <li><b>main</b> - main EGL library implementation. This is where all - the EGL API functions are implemented, like eglCreateContext(). - </ul> - <li><b>mesa</b> - Main Mesa sources - <ul> - <li><b>glapi</b> - OpenGL API dispatch layer. This is where all the - GL entrypoints like glClear, glBegin, etc. are generated, as well as - the GL dispatch table. All GL function calls jump through the - dispatch table to functions found in main/. - <li><b>main</b> - The core Mesa code (mainly state management) - <li><b>drivers</b> - Mesa drivers (not used with Gallium) - <ul> - <li><b>common</b> - code which may be shared by all drivers - <li><b>dri</b> - Direct Rendering Infrastructure drivers - <ul> - <li><b>common</b> - code shared by all DRI drivers - <li><b>i915</b> - driver for Intel i915/i945 - <li><b>i965</b> - driver for Intel i965 - <li>XXX more - </ul> - <li><b>x11</b> - Xlib-based software driver - <li><b>osmesa</b> - off-screen software driver - <li><b>glslcompiler</b> - a stand-alone GLSL compiler driver - <li>XXX more - </ul> - <li><b>es</b> - OpenGL ES overlay, parallelly buildable with the core Mesa - <li><b>math</b> - vertex array translation and transformation code - (not used with Gallium) - <li><b>ppc</b> - Assembly code/optimizations for PPC systems - (not used with Gallium) - <li><b>shader</b> - Vertex/fragment shader and GLSL compiler code - <li><b>sparc</b> - Assembly code/optimizations for SPARC systems - (not used with Gallium) - <li><b>state_tracker</b> - State tracker / driver for Gallium. This - is basically a Mesa device driver that speaks to Gallium. This - directory may be moved to src/mesa/drivers/gallium at some point. - <li><b>swrast</b> - Software rasterization module. For drawing points, - lines, triangles, bitmaps, images, etc. in software. - (not used with Gallium) - <li><b>swrast_setup</b> - Software primitive setup. Does things like - polygon culling, glPolygonMode, polygon offset, etc. - (not used with Gallium) - <li><b>tnl</b> - Software vertex Transformation 'n Lighting. - (not used with Gallium) - <li><b>tnl_dd</b> - TNL code for device drivers. - (not used with Gallium) - <li><b>vbo</b> - Vertex Buffer Object code. All drawing with - glBegin/glEnd, glDrawArrays, display lists, etc. goes through this - module. The results is a well-defined set of vertex arrays which - are passed to the device driver (or tnl module) for rendering. - <li><b>vf</b> - vertex format conversion (currently unused) - <li><b>x86</b> - Assembly code/optimizations for 32-bit x86 systems - (not used with Gallium) - <li><b>x86-64</b> - Assembly code/optimizations for 64-bit x86 systems - (not used with Gallium) - </ul> - <li><b>gallium</b> - Gallium3D source code - <ul> - <li><b>include</b> - Gallium3D header files which define the Gallium3D - interfaces - <li><b>drivers</b> - Gallium3D device drivers - <ul> - <li><b>cell</b> - Driver for Cell processor. - <li><b>i915</b> - Driver for Intel i915/i945. - <li><b>i965</b> - Driver for Intel i965. - <li><b>llvmpipe</b> - Software driver using LLVM for runtime code generation. - <li><b>nv*</b> - Drivers for NVIDIA GPUs. - <li><b>r300</b> - Driver for ATI/AMD R300. - <li><b>softpipe</b> - Software reference driver. - <li><b>svga</b> - Driver for VMware's SVGA virtual GPU. - <li><b>trace</b> - Driver for tracing Gallium calls. - <li>XXX more - </ul> - <li><b>auxiliary</b> - Gallium support code - <ul> - <li><b>draw</b> - Software vertex processing and primitive assembly - module. This includes vertex program execution, clipping, culling - and optional stages for drawing wide lines, stippled lines, - polygon stippling, two-sided lighting, etc. - Intended for use by drivers for hardware that does not have - vertex shaders. - Geometry shaders will also be implemented in this module. - <li><b>cso_cache</b> - Constant State Objects Cache. Used to filter out - redundant state changes between state trackers and drivers. - <li><b>gallivm</b> - LLVM module for Gallium. For LLVM-based - compilation, optimization and code generation for TGSI shaders. - Incomplete. - <li><b>pipebuffer</b> - utility module for managing buffers - <li><b>rbug</b> - Gallium remote debug utility - <li><b>rtasm</b> - run-time assembly/machine code generation. - Currently there's run-time code generation for x86/SSE, PowerPC - and Cell SPU. - <li><b>tgsi</b> - TG Shader Infrastructure. Code for encoding, - manipulating and interpretting GPU programs. - <li><b>translate</b> - module for translating vertex data from one format - to another. - <li><b>util</b> - assorted utilities for arithmetic, hashing, surface - creation, memory management, 2D blitting, simple rendering, etc. - </ul> - <li><b>state_trackers</b> - - <ul> - <li><b>dri</b> - Meta state tracker for DRI drivers - <li><b>egl</b> - Meta state tracker for EGL drivers - <li><b>es</b> - OpenGL ES 1.x and 2.x state trackers - <li><b>g3dvl</b> - - <li><b>glx</b> - Meta state tracker for GLX - <li><b>python</b> - - <li><b>vega</b> - OpenVG 1.x state tracker - <li><b>wgl</b> - - <li><b>xorg</b> - Meta state tracker for Xorg video drivers - </ul> - <li><b>winsys</b> - - <ul> - <li><b>drm</b> - - <li><b>g3dvl</b> - - <li><b>gdi</b> - - <li><b>xlib</b> - - </ul> - </ul> - </ul> - <ul> - <li><b>glu</b> - The OpenGL Utility library - <ul> - <li><b>sgi</b> - GLU from SGI - <li><b>mesa</b> - Mesa version of GLU (deprecated) - </ul> - <li><b>glut</b> - Mark Kilgard's OpenGL OpenGL Utility Toolkit library - <li><b>glx</b> - The GLX library code for building libGL. This is used for - direct rendering drivers. It will dynamically load one of the - xxx_dri.so drivers. - <li><b>glw</b> - Widgets for Xt/Motif. - <li><b>glew</b> - OpenGL Extension Wrangler library (used by demo programs) - </ul> -<li><b>progs</b> - OpenGL test and demonstration programs -<li><b>lib</b> - where the GL libraries are placed -</ul> - - -</BODY> -</HTML> +<HTML>
+
+<TITLE>Mesa Source Tree</TITLE>
+
+<link rel="stylesheet" type="text/css" href="mesa.css"></head>
+
+<BODY>
+
+<h1>Mesa source code tree overview</h1>
+
+<p>
+This is a brief summary of Mesa's directory tree and what's contained in
+each directory.
+</p>
+
+
+<ul>
+<li><b>docs</b> - Documentation
+<li><b>include</b> - Public OpenGL header files
+<li><b>src</b>
+ <ul>
+ <li><b>egl</b> - EGL library sources
+ <ul>
+ <li><b>docs</b> - EGL documentation
+ <li><b>drivers</b> - EGL drivers
+ <li><b>glsl</b> - the GLSL compiler
+ <li><b>main</b> - main EGL library implementation. This is where all
+ the EGL API functions are implemented, like eglCreateContext().
+ </ul>
+ <li><b>mesa</b> - Main Mesa sources
+ <ul>
+ <li><b>glapi</b> - OpenGL API dispatch layer. This is where all the
+ GL entrypoints like glClear, glBegin, etc. are generated, as well as
+ the GL dispatch table. All GL function calls jump through the
+ dispatch table to functions found in main/.
+ <li><b>main</b> - The core Mesa code (mainly state management)
+ <li><b>drivers</b> - Mesa drivers (not used with Gallium)
+ <ul>
+ <li><b>common</b> - code which may be shared by all drivers
+ <li><b>dri</b> - Direct Rendering Infrastructure drivers
+ <ul>
+ <li><b>common</b> - code shared by all DRI drivers
+ <li><b>i915</b> - driver for Intel i915/i945
+ <li><b>i965</b> - driver for Intel i965
+ <li>XXX more
+ </ul>
+ <li><b>x11</b> - Xlib-based software driver
+ <li><b>osmesa</b> - off-screen software driver
+ <li><b>glslcompiler</b> - a stand-alone GLSL compiler driver
+ <li>XXX more
+ </ul>
+ <li><b>es</b> - OpenGL ES overlay, parallelly buildable with the core Mesa
+ <li><b>math</b> - vertex array translation and transformation code
+ (not used with Gallium)
+ <li><b>ppc</b> - Assembly code/optimizations for PPC systems
+ (not used with Gallium)
+ <li><b>shader</b> - Vertex/fragment shader and GLSL compiler code
+ <li><b>sparc</b> - Assembly code/optimizations for SPARC systems
+ (not used with Gallium)
+ <li><b>state_tracker</b> - State tracker / driver for Gallium. This
+ is basically a Mesa device driver that speaks to Gallium. This
+ directory may be moved to src/mesa/drivers/gallium at some point.
+ <li><b>swrast</b> - Software rasterization module. For drawing points,
+ lines, triangles, bitmaps, images, etc. in software.
+ (not used with Gallium)
+ <li><b>swrast_setup</b> - Software primitive setup. Does things like
+ polygon culling, glPolygonMode, polygon offset, etc.
+ (not used with Gallium)
+ <li><b>tnl</b> - Software vertex Transformation 'n Lighting.
+ (not used with Gallium)
+ <li><b>tnl_dd</b> - TNL code for device drivers.
+ (not used with Gallium)
+ <li><b>vbo</b> - Vertex Buffer Object code. All drawing with
+ glBegin/glEnd, glDrawArrays, display lists, etc. goes through this
+ module. The results is a well-defined set of vertex arrays which
+ are passed to the device driver (or tnl module) for rendering.
+ <li><b>vf</b> - vertex format conversion (currently unused)
+ <li><b>x86</b> - Assembly code/optimizations for 32-bit x86 systems
+ (not used with Gallium)
+ <li><b>x86-64</b> - Assembly code/optimizations for 64-bit x86 systems
+ (not used with Gallium)
+ </ul>
+ <li><b>gallium</b> - Gallium3D source code
+ <ul>
+ <li><b>include</b> - Gallium3D header files which define the Gallium3D
+ interfaces
+ <li><b>drivers</b> - Gallium3D device drivers
+ <ul>
+ <li><b>cell</b> - Driver for Cell processor.
+ <li><b>i915</b> - Driver for Intel i915/i945.
+ <li><b>i965</b> - Driver for Intel i965.
+ <li><b>llvmpipe</b> - Software driver using LLVM for runtime code generation.
+ <li><b>nv*</b> - Drivers for NVIDIA GPUs.
+ <li><b>r300</b> - Driver for ATI/AMD R300.
+ <li><b>softpipe</b> - Software reference driver.
+ <li><b>svga</b> - Driver for VMware's SVGA virtual GPU.
+ <li><b>trace</b> - Driver for tracing Gallium calls.
+ <li>XXX more
+ </ul>
+ <li><b>auxiliary</b> - Gallium support code
+ <ul>
+ <li><b>draw</b> - Software vertex processing and primitive assembly
+ module. This includes vertex program execution, clipping, culling
+ and optional stages for drawing wide lines, stippled lines,
+ polygon stippling, two-sided lighting, etc.
+ Intended for use by drivers for hardware that does not have
+ vertex shaders.
+ Geometry shaders will also be implemented in this module.
+ <li><b>cso_cache</b> - Constant State Objects Cache. Used to filter out
+ redundant state changes between state trackers and drivers.
+ <li><b>gallivm</b> - LLVM module for Gallium. For LLVM-based
+ compilation, optimization and code generation for TGSI shaders.
+ Incomplete.
+ <li><b>pipebuffer</b> - utility module for managing buffers
+ <li><b>rbug</b> - Gallium remote debug utility
+ <li><b>rtasm</b> - run-time assembly/machine code generation.
+ Currently there's run-time code generation for x86/SSE, PowerPC
+ and Cell SPU.
+ <li><b>tgsi</b> - TG Shader Infrastructure. Code for encoding,
+ manipulating and interpretting GPU programs.
+ <li><b>translate</b> - module for translating vertex data from one format
+ to another.
+ <li><b>util</b> - assorted utilities for arithmetic, hashing, surface
+ creation, memory management, 2D blitting, simple rendering, etc.
+ </ul>
+ <li><b>state_trackers</b> -
+ <ul>
+ <li><b>dri</b> - Meta state tracker for DRI drivers
+ <li><b>egl</b> - Meta state tracker for EGL drivers
+ <li><b>es</b> - OpenGL ES 1.x and 2.x state trackers
+ <li><b>g3dvl</b> -
+ <li><b>glx</b> - Meta state tracker for GLX
+ <li><b>python</b> -
+ <li><b>vega</b> - OpenVG 1.x state tracker
+ <li><b>wgl</b> -
+ <li><b>xorg</b> - Meta state tracker for Xorg video drivers
+ </ul>
+ <li><b>winsys</b> -
+ <ul>
+ <li><b>drm</b> -
+ <li><b>g3dvl</b> -
+ <li><b>gdi</b> -
+ <li><b>xlib</b> -
+ </ul>
+ </ul>
+ </ul>
+ <ul>
+ <li><b>glu</b> - The OpenGL Utility library
+ <ul>
+ <li><b>sgi</b> - GLU from SGI
+ <li><b>mesa</b> - Mesa version of GLU (deprecated)
+ </ul>
+ <li><b>glut</b> - Mark Kilgard's OpenGL OpenGL Utility Toolkit library
+ <li><b>glx</b> - The GLX library code for building libGL. This is used for
+ direct rendering drivers. It will dynamically load one of the
+ xxx_dri.so drivers.
+ <li><b>glw</b> - Widgets for Xt/Motif.
+ <li><b>glew</b> - OpenGL Extension Wrangler library (used by demo programs)
+ </ul>
+<li><b>progs</b> - OpenGL test and demonstration programs
+<li><b>lib</b> - where the GL libraries are placed
+</ul>
+
+
+</BODY>
+</HTML>
|