mesa: add _mesa_get_version, a ctx-independent variant of _mesa_compute_version
[mesa.git] / src / mesa / main / vtxfmt.c
index 3a0e7d357ee315fdf8f663402ac5df732a17db7c..fc0a01edf8682040cef204e2d7deb9076b69116f 100644 (file)
@@ -1,6 +1,5 @@
 /*
  * Mesa 3-D graphics library
- * Version:  6.3
  *
  * Copyright (C) 1999-2004  Brian Paul   All Rights Reserved.
  *
@@ -23,7 +22,7 @@
  * OTHER DEALINGS IN THE SOFTWARE.
  *
  * Authors:
- *    Keith Whitwell <keith@tungstengraphics.com> Gareth Hughes
+ *    Keith Whitwell <keithw@vmware.com> Gareth Hughes
  */
 
 #include "glheader.h"
 
 
 /**
- * Use the per-vertex functions found in <vfmt> to initialize the given
- * API dispatch table.
- * If beginend is true, only plug in the functions which are legal
- * between glBegin/glEnd.
+ * Copy the functions found in the GLvertexformat object into the
+ * dispatch table.
  */
 static void
 install_vtxfmt(struct gl_context *ctx, struct _glapi_table *tab,
-               const GLvertexformat *vfmt, bool beginend)
+               const GLvertexformat *vfmt)
 {
    assert(ctx->Version > 0);
 
@@ -63,7 +60,7 @@ install_vtxfmt(struct gl_context *ctx, struct _glapi_table *tab,
    }
 
    if (ctx->API == API_OPENGL_COMPAT) {
-      _mesa_install_eval_vtxfmt(tab, vfmt, beginend);
+      _mesa_install_eval_vtxfmt(tab, vfmt);
    }
 
    if (ctx->API != API_OPENGL_CORE && ctx->API != API_OPENGLES2) {
@@ -218,9 +215,9 @@ install_vtxfmt(struct gl_context *ctx, struct _glapi_table *tab,
 void
 _mesa_install_exec_vtxfmt(struct gl_context *ctx, const GLvertexformat *vfmt)
 {
-   install_vtxfmt(ctx, ctx->Exec, vfmt, false);
+   install_vtxfmt(ctx, ctx->Exec, vfmt);
    if (ctx->BeginEnd)
-      install_vtxfmt(ctx, ctx->BeginEnd, vfmt, true);
+      install_vtxfmt(ctx, ctx->BeginEnd, vfmt);
 }
 
 
@@ -232,7 +229,7 @@ void
 _mesa_install_save_vtxfmt(struct gl_context *ctx, const GLvertexformat *vfmt)
 {
    if (_mesa_is_desktop_gl(ctx))
-      install_vtxfmt(ctx, ctx->Save, vfmt, false);
+      install_vtxfmt(ctx, ctx->Save, vfmt);
 }