Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[xsrc/trunk]: xsrc/external/mit/MesaLib/dist/src Import mesa 19.1.7



details:   https://anonhg.NetBSD.org/xsrc/rev/833d1d91f105
branches:  trunk
changeset: 10393:833d1d91f105
user:      maya <maya%NetBSD.org@localhost>
date:      Tue Sep 24 18:21:09 2019 +0000

description:
Import mesa 19.1.7

New features in mesa 19.1.0:

    GL_ARB_parallel_shader_compile on all drivers.
    GL_EXT_gpu_shader4 on all GL 3.1 drivers.
    GL_EXT_shader_image_load_formatted on radeonsi.
    GL_EXT_texture_buffer_object on all GL 3.1 drivers.
    GL_EXT_texture_compression_s3tc_srgb on Gallium drivers and i965 (ES extension).
    GL_NV_compute_shader_derivatives on iris and i965.
    GL_KHR_parallel_shader_compile on all drivers.
    VK_EXT_buffer_device_address on Intel and RADV.
    VK_EXT_depth_clip_enable on Intel and RADV.
    VK_KHR_ycbcr_image_arrays on Intel.
    VK_EXT_inline_uniform_block on Intel and RADV.
    VK_EXT_external_memory_host on Intel.
    VK_EXT_host_query_reset on Intel and RADV.
    VK_KHR_surface_protected_capabilities on Intel and RADV.
    VK_EXT_pipeline_creation_feedback on Intel and RADV.
    VK_KHR_8bit_storage on RADV.
    VK_AMD_gpu_shader_int16 on RADV.
    VK_AMD_gpu_shader_half_float on RADV.
    VK_NV_compute_shader_derivatives on Intel.
    VK_KHR_shader_float16_int8 on Intel and RADV (RADV only supports int8).
    VK_KHR_shader_atomic_int64 on Intel.
    VK_EXT_descriptor_indexing on Intel.
    VK_KHR_shader_float16_int8 on Intel and RADV.
    GL_INTEL_conservative_rasterization on iris.
    VK_EXT_memory_budget on Intel.

New features in mesa 19.0.0:

    GL_AMD_texture_texture4 on all GL 4.0 drivers.
    GL_EXT_shader_implicit_conversions on all drivers (ES extension).
    GL_EXT_texture_compression_bptc on all GL 4.0 drivers (ES extension).
    GL_EXT_texture_compression_rgtc on all GL 3.0 drivers (ES extension).
    GL_EXT_render_snorm on gallium drivers (ES extension).
    GL_EXT_texture_view on drivers supporting texture views (ES extension).
    GL_OES_texture_view on drivers supporting texture views (ES extension).
    GL_NV_shader_atomic_float on nvc0 (Fermi/Kepler only).
    Shader-based software implementations of GL_ARB_gpu_shader_fp64, GL_ARB_gpu_shader_int64, GL_ARB_vertex_attrib_64bit, and GL_ARB_shader_ballot on i965.
    VK_ANDROID_external_memory_android_hardware_buffer on Intel
    Fixed and re-exposed VK_EXT_pci_bus_info on Intel and RADV
    VK_EXT_scalar_block_layout on Intel and RADV
    VK_KHR_depth_stencil_resolve on Intel
    VK_KHR_draw_indirect_count on Intel
    VK_EXT_conditional_rendering on Intel
    VK_EXT_memory_budget on RADV

Also, bug fixes.

diffstat:

 external/mit/MesaLib/dist/src/mesa/vbo/vbo_attrib_tmp.h                                 |    14 -
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_context.c                                    |    20 +-
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec.c                                       |    11 -
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec_api.c                                   |    41 +-
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_private.h                                    |    12 +-
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_api.c                                   |    78 +-
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_draw.c                                  |    16 +-
 external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_loopback.c                              |    10 +-
 external/mit/MesaLib/dist/src/util/00-mesa-defaults.conf                                |   137 +
 external/mit/MesaLib/dist/src/util/Makefile.sources                                     |     9 +
 external/mit/MesaLib/dist/src/util/bitset.h                                             |     8 +-
 external/mit/MesaLib/dist/src/util/bitset_test.cpp                                      |   129 +
 external/mit/MesaLib/dist/src/util/dag.c                                                |   154 +
 external/mit/MesaLib/dist/src/util/dag.h                                                |    65 +
 external/mit/MesaLib/dist/src/util/debug.c                                              |    34 +
 external/mit/MesaLib/dist/src/util/debug.h                                              |     4 +
 external/mit/MesaLib/dist/src/util/futex.h                                              |    34 +
 external/mit/MesaLib/dist/src/util/hash_table.c                                         |    49 +-
 external/mit/MesaLib/dist/src/util/hash_table.h                                         |    11 +
 external/mit/MesaLib/dist/src/util/macros.h                                             |    18 +
 external/mit/MesaLib/dist/src/util/merge_driinfo.py                                     |    58 +-
 external/mit/MesaLib/dist/src/util/meson.build                                          |    39 +-
 external/mit/MesaLib/dist/src/util/os_file.c                                            |   119 +
 external/mit/MesaLib/dist/src/util/os_file.h                                            |    26 +
 external/mit/MesaLib/dist/src/util/os_memory.h                                          |    80 +
 external/mit/MesaLib/dist/src/util/os_memory_aligned.h                                  |    98 +
 external/mit/MesaLib/dist/src/util/os_memory_debug.h                                    |    92 +
 external/mit/MesaLib/dist/src/util/os_memory_stdc.h                                     |    76 +
 external/mit/MesaLib/dist/src/util/os_misc.c                                            |     4 +-
 external/mit/MesaLib/dist/src/util/ralloc.h                                             |     2 +-
 external/mit/MesaLib/dist/src/util/rounding.h                                           |    18 +-
 external/mit/MesaLib/dist/src/util/set.c                                                |    11 +
 external/mit/MesaLib/dist/src/util/set.h                                                |     3 +
 external/mit/MesaLib/dist/src/util/slab.c                                               |    20 +-
 external/mit/MesaLib/dist/src/util/slab.h                                               |     8 +-
 external/mit/MesaLib/dist/src/util/tests/fast_idiv_by_const/fast_idiv_by_const_test.cpp |     2 +
 external/mit/MesaLib/dist/src/util/tests/fast_idiv_by_const/meson.build                 |     3 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/clear.c                             |    15 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/collision.c                         |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/delete_and_lookup.c                 |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/delete_management.c                 |    15 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/destroy_callback.c                  |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/insert_and_lookup.c                 |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/insert_many.c                       |    13 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/meson.build                         |     4 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/random_entry.c                      |     9 +-
 external/mit/MesaLib/dist/src/util/tests/hash_table/remove_key.c                        |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/remove_null.c                       |     2 +
 external/mit/MesaLib/dist/src/util/tests/hash_table/replacement.c                       |     2 +
 external/mit/MesaLib/dist/src/util/tests/set/meson.build                                |     3 +-
 external/mit/MesaLib/dist/src/util/tests/string_buffer/meson.build                      |     3 +-
 external/mit/MesaLib/dist/src/util/tests/vma/meson.build                                |     3 +-
 external/mit/MesaLib/dist/src/util/tests/vma/vma_random_test.cpp                        |     8 +
 external/mit/MesaLib/dist/src/util/u_cpu_detect.c                                       |    15 +-
 external/mit/MesaLib/dist/src/util/u_drm.h                                              |    55 +
 external/mit/MesaLib/dist/src/util/u_dynarray.h                                         |    23 +-
 external/mit/MesaLib/dist/src/util/u_memory.h                                           |    99 +
 external/mit/MesaLib/dist/src/util/u_queue.h                                            |    13 +-
 external/mit/MesaLib/dist/src/util/u_thread.h                                           |     3 +-
 external/mit/MesaLib/dist/src/util/u_vector.h                                           |     4 +
 external/mit/MesaLib/dist/src/util/xmlconfig.c                                          |     4 +
 external/mit/MesaLib/dist/src/util/xmlpool.h                                            |    20 +-
 external/mit/MesaLib/dist/src/util/xmlpool/ca.po                                        |   178 +-
 external/mit/MesaLib/dist/src/util/xmlpool/de.po                                        |   186 +-
 external/mit/MesaLib/dist/src/util/xmlpool/es.po                                        |   178 +-
 external/mit/MesaLib/dist/src/util/xmlpool/fr.po                                        |   186 +-
 external/mit/MesaLib/dist/src/util/xmlpool/nl.po                                        |   205 +-
 external/mit/MesaLib/dist/src/util/xmlpool/sv.po                                        |   212 +-
 external/mit/MesaLib/dist/src/util/xmlpool/t_options.h                                  |    34 +-
 external/mit/MesaLib/dist/src/vulkan/Android.mk                                         |    73 +
 external/mit/MesaLib/dist/src/vulkan/meson.build                                        |    38 +-
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/README                               |    17 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/TODO                                 |     3 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/VkLayer_MESA_overlay.json            |    11 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/meson.build                          |    54 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/overlay.cpp                          |  2330 ++++++++++
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/overlay.frag                         |    14 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/overlay.vert                         |    25 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/overlay_params.c                     |   174 +
 external/mit/MesaLib/dist/src/vulkan/overlay-layer/overlay_params.h                     |   109 +
 external/mit/MesaLib/dist/src/vulkan/registry/vk.xml                                    |  1478 ++++-
 external/mit/MesaLib/dist/src/vulkan/util/gen_enum_to_str.py                            |   200 +-
 external/mit/MesaLib/dist/src/vulkan/util/meson.build                                   |    30 +-
 external/mit/MesaLib/dist/src/vulkan/util/vk_util.c                                     |     6 +-
 external/mit/MesaLib/dist/src/vulkan/util/vk_util.h                                     |    31 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/meson.build                                    |    26 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common.c                                   |   131 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common.h                                   |    21 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common_display.c                           |    90 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common_display.h                           |     2 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common_private.h                           |     8 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common_wayland.c                           |   380 +-
 external/mit/MesaLib/dist/src/vulkan/wsi/wsi_common_x11.c                               |   119 +-
 93 files changed, 7340 insertions(+), 1045 deletions(-)

diffs (truncated from 11977 to 300 lines):

diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_attrib_tmp.h
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_attrib_tmp.h   Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_attrib_tmp.h   Tue Sep 24 18:21:09 2019 +0000
@@ -522,20 +522,6 @@
 }
 
 
-/**
- * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
- * It depends on a few things, including whether we're inside or outside
- * of glBegin/glEnd.
- */
-static inline bool
-is_vertex_position(const struct gl_context *ctx, GLuint index)
-{
-   return (index == 0 &&
-           _mesa_attr_zero_aliases_vertex(ctx) &&
-           _mesa_inside_begin_end(ctx));
-}
-
-
 static void GLAPIENTRY
 TAG(VertexAttrib1fARB)(GLuint index, GLfloat x)
 {
diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_context.c
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_context.c      Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_context.c      Tue Sep 24 18:21:09 2019 +0000
@@ -58,11 +58,8 @@
 {
    memset(attrib, 0, sizeof(*attrib));
 
-   attrib->Size = size;
-   attrib->Type = GL_FLOAT;
-   attrib->Format = GL_RGBA;
+   vbo_set_vertex_format(&attrib->Format, size, GL_FLOAT);
    attrib->Stride = 0;
-   attrib->_ElementSize = size * sizeof(GLfloat);
    attrib->Ptr = pointer;
 }
 
@@ -156,9 +153,6 @@
    struct vbo_context *vbo = vbo_context(ctx);
    struct vbo_exec_context *exec = &vbo->exec;
 
-   if (ctx->NewState & _NEW_ARRAY) {
-      _ae_invalidate_state(ctx);
-   }
    if (ctx->NewState & _NEW_EVAL)
       exec->eval.recalculate_maps = GL_TRUE;
 }
@@ -171,13 +165,6 @@
 
    ctx->vbo_context = vbo;
 
-   /* Initialize the arrayelt helper
-    */
-   if (!ctx->aelt_context &&
-       !_ae_create_context(ctx)) {
-      return GL_FALSE;
-   }
-
    vbo->binding.Offset = 0;
    vbo->binding.Stride = 0;
    vbo->binding.InstanceDivisor = 0;
@@ -214,11 +201,6 @@
 {
    struct vbo_context *vbo = vbo_context(ctx);
 
-   if (ctx->aelt_context) {
-      _ae_destroy_context(ctx);
-      ctx->aelt_context = NULL;
-   }
-
    if (vbo) {
 
       _mesa_reference_buffer_object(ctx, &vbo->binding.BufferObj, NULL);
diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec.c
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec.c Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec.c Tue Sep 24 18:21:09 2019 +0000
@@ -115,17 +115,11 @@
 
    exec->ctx = ctx;
 
-   /* aelt_context should have been created by the caller */
-   assert(ctx->aelt_context);
-
    vbo_exec_vtx_init(exec);
 
    ctx->Driver.NeedFlush = 0;
    ctx->Driver.CurrentExecPrimitive = PRIM_OUTSIDE_BEGIN_END;
 
-   /* The aelt_context state should still be dirty from its creation */
-   assert(_ae_is_state_dirty(ctx));
-
    exec->eval.recalculate_maps = GL_TRUE;
 }
 
@@ -134,11 +128,6 @@
 {
    struct vbo_exec_context *exec = &vbo_context(ctx)->exec;
 
-   if (ctx->aelt_context) {
-      _ae_destroy_context( ctx );
-      ctx->aelt_context = NULL;
-   }
-
    vbo_exec_vtx_destroy( exec );
 }
 
diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec_api.c
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec_api.c     Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_exec_api.c     Tue Sep 24 18:21:09 2019 +0000
@@ -195,7 +195,7 @@
                                      exec->vtx.attrtype[i]);
       }
 
-      if (exec->vtx.attrtype[i] != vbo->current[i].Type ||
+      if (exec->vtx.attrtype[i] != vbo->current[i].Format.Type ||
           memcmp(current, tmp, 4 * sizeof(GLfloat) * dmul) != 0) {
          memcpy(current, tmp, 4 * sizeof(GLfloat) * dmul);
 
@@ -205,14 +205,9 @@
           * directly.
           */
          /* Size here is in components - not bytes */
-         vbo->current[i].Size = exec->vtx.attrsz[i] / dmul;
-         vbo->current[i]._ElementSize =
-            vbo->current[i].Size * sizeof(GLfloat) * dmul;
-         vbo->current[i].Type = exec->vtx.attrtype[i];
-         vbo->current[i].Integer =
-            vbo_attrtype_to_integer_flag(exec->vtx.attrtype[i]);
-         vbo->current[i].Doubles =
-            vbo_attrtype_to_double_flag(exec->vtx.attrtype[i]);
+         vbo_set_vertex_format(&vbo->current[i].Format,
+                               exec->vtx.attrsz[i] / dmul,
+                               exec->vtx.attrtype[i]);
 
          /* This triggers rather too much recalculation of Mesa state
           * that doesn't get used (eg light positions).
@@ -463,6 +458,20 @@
 
 
 /**
+ * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
+ * It depends on a few things, including whether we're inside or outside
+ * of glBegin/glEnd.
+ */
+static inline bool
+is_vertex_position(const struct gl_context *ctx, GLuint index)
+{
+   return (index == 0 &&
+           _mesa_attr_zero_aliases_vertex(ctx) &&
+           _mesa_inside_begin_end(ctx));
+}
+
+
+/**
  * This macro is used to implement all the glVertex, glColor, glTexCoord,
  * glVertexAttrib, etc functions.
  * \param A  VBO_ATTRIB_x attribute index
@@ -803,11 +812,14 @@
    ctx->Driver.CurrentExecPrimitive = mode;
 
    ctx->Exec = ctx->BeginEnd;
+
    /* We may have been called from a display list, in which case we should
     * leave dlist.c's dispatch table in place.
     */
-   if (ctx->CurrentClientDispatch == ctx->OutsideBeginEnd) {
-      ctx->CurrentClientDispatch = ctx->BeginEnd;
+   if (ctx->CurrentClientDispatch == ctx->MarshalExec) {
+      ctx->CurrentServerDispatch = ctx->Exec;
+   } else if (ctx->CurrentClientDispatch == ctx->OutsideBeginEnd) {
+      ctx->CurrentClientDispatch = ctx->Exec;
       _glapi_set_dispatch(ctx->CurrentClientDispatch);
    } else {
       assert(ctx->CurrentClientDispatch == ctx->Save);
@@ -858,8 +870,11 @@
    }
 
    ctx->Exec = ctx->OutsideBeginEnd;
-   if (ctx->CurrentClientDispatch == ctx->BeginEnd) {
-      ctx->CurrentClientDispatch = ctx->OutsideBeginEnd;
+
+   if (ctx->CurrentClientDispatch == ctx->MarshalExec) {
+      ctx->CurrentServerDispatch = ctx->Exec;
+   } else if (ctx->CurrentClientDispatch == ctx->BeginEnd) {
+      ctx->CurrentClientDispatch = ctx->Exec;
       _glapi_set_dispatch(ctx->CurrentClientDispatch);
    }
 
diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_private.h
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_private.h      Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_private.h      Tue Sep 24 18:21:09 2019 +0000
@@ -115,6 +115,16 @@
 }
 
 
+static inline void
+vbo_set_vertex_format(struct gl_vertex_format* vertex_format,
+                      GLubyte size, GLenum16 type)
+{
+   _mesa_set_vertex_format(vertex_format, size, type, GL_RGBA, GL_FALSE,
+                           vbo_attrtype_to_integer_flag(type),
+                           vbo_attrtype_to_double_flag(type));
+}
+
+
 /**
  * Return default component values for the given format.
  * The return type is an array of fi_types, because that's how we declare
@@ -224,7 +234,7 @@
     * to the VAO. But but that is done already unconditionally in
     * _mesa_update_array_format called above.
     */
-   assert((vao->NewArrays | ~vao->_Enabled) & VERT_BIT(attr));
+   assert((vao->NewArrays | ~vao->Enabled) & VERT_BIT(attr));
    vao->VertexAttrib[attr].Ptr = ADD_POINTERS(buffer_offset, offset);
 }
 
diff -r 783992e5b20f -r 833d1d91f105 external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_api.c
--- a/external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_api.c     Tue Sep 24 18:11:06 2019 +0000
+++ b/external/mit/MesaLib/dist/src/mesa/vbo/vbo_save_api.c     Tue Sep 24 18:21:09 2019 +0000
@@ -426,7 +426,7 @@
       return false;
 
    /* If the enabled arrays are not the same we are not equal. */
-   if (vao_enabled != vao->_Enabled)
+   if (vao_enabled != vao->Enabled)
       return false;
 
    /* Check the buffer binding at 0 */
@@ -450,15 +450,14 @@
       const struct gl_array_attributes *attrib = &vao->VertexAttrib[attr];
       if (attrib->RelativeOffset + vao->BufferBinding[0].Offset != off)
          return false;
-      if (attrib->Type != tp)
+      if (attrib->Format.Type != tp)
          return false;
-      if (attrib->Size != size[vbo_attr])
+      if (attrib->Format.Size != size[vbo_attr])
          return false;
-      assert(attrib->Format == GL_RGBA);
-      assert(attrib->Enabled == GL_TRUE);
-      assert(attrib->Normalized == GL_FALSE);
-      assert(attrib->Integer == vbo_attrtype_to_integer_flag(tp));
-      assert(attrib->Doubles == vbo_attrtype_to_double_flag(tp));
+      assert(attrib->Format.Format == GL_RGBA);
+      assert(attrib->Format.Normalized == GL_FALSE);
+      assert(attrib->Format.Integer == vbo_attrtype_to_integer_flag(tp));
+      assert(attrib->Format.Doubles == vbo_attrtype_to_double_flag(tp));
       assert(attrib->BufferBindingIndex == 0);
    }
 
@@ -515,9 +514,9 @@
       _vbo_set_attrib_format(ctx, *vao, vao_attr, buffer_offset,
                              size[vbo_attr], type[vbo_attr], offset[vbo_attr]);
       _mesa_vertex_attrib_binding(ctx, *vao, vao_attr, 0);
-      _mesa_enable_vertex_array_attrib(ctx, *vao, vao_attr);
    }
-   assert(vao_enabled == (*vao)->_Enabled);
+   _mesa_enable_vertex_array_attribs(ctx, *vao, vao_enabled);
+   assert(vao_enabled == (*vao)->Enabled);
    assert((vao_enabled & ~(*vao)->VertexAttribBufferMask) == 0);
 
    /* Finalize and freeze the VAO */
@@ -980,6 +979,20 @@
 }
 
 
+/**
+ * If index=0, does glVertexAttrib*() alias glVertex() to emit a vertex?
+ * It depends on a few things, including whether we're inside or outside
+ * of glBegin/glEnd.
+ */
+static inline bool
+is_vertex_position(const struct gl_context *ctx, GLuint index)
+{
+   return (index == 0 &&
+           _mesa_attr_zero_aliases_vertex(ctx) &&
+           _mesa_inside_dlist_begin_end(ctx));
+}
+
+
 
 #define ERROR(err)   _mesa_compile_error(ctx, err, __func__);
 
@@ -1199,6 +1212,8 @@
    struct vbo_save_context *save = &vbo_context(ctx)->save;
    const GLuint i = save->prim_count++;
 
+   ctx->Driver.CurrentSavePrimitive = mode;
+
    assert(i < save->prim_max);
    save->prims[i].mode = mode & VBO_SAVE_PRIM_MODE_MASK;
    save->prims[i].begin = 1;
@@ -1308,6 +1323,7 @@
 _save_OBE_DrawArrays(GLenum mode, GLint start, GLsizei count)
 {
    GET_CURRENT_CONTEXT(ctx);



Home | Main Index | Thread Index | Old Index