mesa: handle GL_UNSIGNED_INT64_ARB properly (v2)
authorMarek Olšák <marek.olsak@amd.com>
Fri, 25 May 2018 20:37:29 +0000 (16:37 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Wed, 30 May 2018 00:09:00 +0000 (20:09 -0400)
Bindless texture handles can be passed via vertex attribs using this type.
This fixes a bunch of bindless piglit tests on radeonsi.

Cc: 18.0 18.1 <mesa-stable@lists.freedesktop.org>
Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
src/mesa/main/glformats.c
src/mesa/vbo/vbo_private.h

index cba5e670db01546a56c63d547b4162d63add2108..667020c193c92f5ca0e21ca1257d953d294a67e2 100644 (file)
@@ -563,6 +563,8 @@ _mesa_bytes_per_vertex_attrib(GLint comps, GLenum type)
          return sizeof(GLuint);
       else
          return -1;
+   case GL_UNSIGNED_INT64_ARB:
+      return comps * 8;
    default:
       return -1;
    }
index b69f836aa0b210fc3c598e22c76c491c724b9015..3f7d0dc60824ebfc666e5626f0a317ee49222262 100644 (file)
@@ -104,8 +104,8 @@ vbo_attrtype_to_double_flag(GLenum format)
    case GL_FLOAT:
    case GL_INT:
    case GL_UNSIGNED_INT:
-   case GL_UNSIGNED_INT64_ARB:
       return GL_FALSE;
+   case GL_UNSIGNED_INT64_ARB:
    case GL_DOUBLE:
       return GL_TRUE;
    default: