eglmesaext: add forward declaration for struct wl_buffers
[mesa.git] / docs / dispatch.html
index e80a480659b31292d19e12d6951f9c8842c304aa..c96ec2de302b522776473c42d10364aee2b8abf1 100644 (file)
@@ -6,6 +6,14 @@
   <link rel="stylesheet" type="text/css" href="mesa.css">
 </head>
 <body>
+
+<div class="header">
+  <h1>The Mesa 3D Graphics Library</h1>
+</div>
+
+<iframe src="contents.html"></iframe>
+<div class="content">
+
 <h1>GL Dispatch in Mesa</h1>
 
 <p>Several factors combine to make efficient dispatch of OpenGL functions
@@ -17,7 +25,7 @@ href="#overview">overview of Mesa's implementation</a>.</p>
 <h2>1. Complexity of GL Dispatch</h2>
 
 <p>Every GL application has at least one object called a GL <em>context</em>.
-This object, which is an implicit parameter to ever GL function, stores all
+This object, which is an implicit parameter to every GL function, stores all
 of the GL related state for the application.  Every texture, every buffer
 object, every enable, and much, much more is stored in the context.  Since
 an application can have more than one context, the context to be used is
@@ -43,7 +51,7 @@ example, <tt>glFogCoordf</tt> may operate differently depending on whether
 or not fog is enabled.</p>
 
 <p>In multi-threaded environments, it is possible for each thread to have a
-differnt GL context current.  This means that poor old <tt>glVertex3fv</tt>
+different GL context current.  This means that poor old <tt>glVertex3fv</tt>
 has to know which GL context is current in the thread where it is being
 called.</p>
 
@@ -75,7 +83,7 @@ table.</li>
 void glVertex3f(GLfloat x, GLfloat y, GLfloat z)
 {
     const struct _glapi_table * const dispatch = GET_DISPATCH();
-    
+
     (*dispatch-&gt;Vertex3f)(x, y, z);
 }</pre></td></tr>
 <tr><td>Sample dispatch function</td></tr></table>
@@ -196,16 +204,15 @@ terribly relevant.</p>
 few preprocessor defines.</p>
 
 <ul>
-<li>If <tt>GLX_USE_TLS</tt> is defined, method #4 is used.</li>
-<li>If <tt>PTHREADS</tt> is defined, method #3 is used.</li>
-<li>If <tt>WIN32_THREADS</tt> is defined, method #2 is used.</li>
-<li>If none of the preceeding are defined, method #1 is used.</li>
+<li>If <tt>GLX_USE_TLS</tt> is defined, method #3 is used.</li>
+<li>If <tt>HAVE_PTHREAD</tt> is defined, method #2 is used.</li>
+<li>If none of the preceding are defined, method #1 is used.</li>
 </ul>
 
 <p>Two different techniques are used to handle the various different cases.
 On x86 and SPARC, a macro called <tt>GL_STUB</tt> is used.  In the preamble
 of the assembly source file different implementations of the macro are
-selected based on the defined preprocessor variables.  The assmebly code
+selected based on the defined preprocessor variables.  The assembly code
 then consists of a series of invocations of the macros such as:
 
 <blockquote>
@@ -234,7 +241,7 @@ first technique, is to insert <tt>#ifdef</tt> within the assembly
 implementation of each function.  This makes the assembly file considerably
 larger (e.g., 29,332 lines for <tt>glapi_x86-64.S</tt> versus 1,155 lines for
 <tt>glapi_x86.S</tt>) and causes simple changes to the function
-implementation to generate many lines of diffs.  Since the assmebly files
+implementation to generate many lines of diffs.  Since the assembly files
 are typically generated by scripts (see <a href="#autogen">below</a>), this
 isn't a significant problem.</p>
 
@@ -266,5 +273,6 @@ included.</p>
 
 <h2 id="autogen">4. Automatic Generation of Dispatch Stubs</h2>
 
+</div>
 </body>
 </html>