Commit 439909a8 authored by Brian Paul's avatar Brian Paul

docs: document the MESA_GLSL env var, other misc GLSL updates

parent 4069447f
...@@ -22,6 +22,7 @@ Last updated on 15 December 2008. ...@@ -22,6 +22,7 @@ Last updated on 15 December 2008.
Contents Contents
</p> </p>
<ul> <ul>
<li><a href="#envvars">Environment variables</a>
<li><a href="#120">GLSL 1.20 support</a> <li><a href="#120">GLSL 1.20 support</a>
<li><a href="#unsup">Unsupported Features</a> <li><a href="#unsup">Unsupported Features</a>
<li><a href="#notes">Implementation Notes</a> <li><a href="#notes">Implementation Notes</a>
...@@ -33,11 +34,32 @@ Contents ...@@ -33,11 +34,32 @@ Contents
<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:
</p>
<ul>
<li>dump - print GLSL shader code to stdout at link time
<li>log - log all GLSL shaders to files.
The filenames will be "shader_X.vert" or "shader_X.frag" where X
the shader ID.
<li>nopt - disable compiler optimizations
<li>opt - force compiler optimizations
<li>uniform - print message to stdout when glUniform is called
</ul>
<p>
Example: export MESA_GLSL=dump,nopt
</p>
<a name="120"> <a name="120">
<h2>GLSL 1.20 support</h2> <h2>GLSL 1.20 support</h2>
<p> <p>
GLSL version 1.20 is supported in Mesa 7.3. GLSL version 1.20 is supported in Mesa 7.3 and later.
Among the features/differences of GLSL 1.20 are: Among the features/differences of GLSL 1.20 are:
<ul> <ul>
<li><code>mat2x3, mat2x4</code>, etc. types and functions <li><code>mat2x3, mat2x4</code>, etc. types and functions
...@@ -59,12 +81,14 @@ Among the features/differences of GLSL 1.20 are: ...@@ -59,12 +81,14 @@ Among the features/differences of GLSL 1.20 are:
<h2>Unsupported Features</h2> <h2>Unsupported Features</h2>
<p> <p>
The following features of the shading language are not yet supported The following features of the shading language are not yet fully supported
in Mesa: in Mesa:
</p> </p>
<ul> <ul>
<li>Linking of multiple shaders is not supported <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>gl_ClipVertex
<li>The gl_Color and gl_SecondaryColor varying vars are interpolated <li>The gl_Color and gl_SecondaryColor varying vars are interpolated
without perspective correction without perspective correction
...@@ -177,6 +201,8 @@ This tool is useful for: ...@@ -177,6 +201,8 @@ This tool is useful for:
After building Mesa, the glslcompiler can be built by manually running: After building Mesa, the glslcompiler can be built by manually running:
</p> </p>
<pre> <pre>
make realclean
make linux
cd src/mesa/drivers/glslcompiler cd src/mesa/drivers/glslcompiler
make make
</pre> </pre>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment