summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/draw.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/draw.c')
-rw-r--r--src/mesa/main/draw.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/mesa/main/draw.c b/src/mesa/main/draw.c
index 313df6aa8bc..bfc4b9c9373 100644
--- a/src/mesa/main/draw.c
+++ b/src/mesa/main/draw.c
@@ -82,18 +82,19 @@ check_array_data(struct gl_context *ctx, struct gl_vertex_array_object *vao,
data = ADD_POINTERS(_mesa_vertex_attrib_address(array, binding),
bo->Mappings[MAP_INTERNAL].Pointer);
}
- switch (array->Type) {
+ switch (array->Format.Type) {
case GL_FLOAT:
{
GLfloat *f = (GLfloat *) ((GLubyte *) data + binding->Stride * j);
GLint k;
- for (k = 0; k < array->Size; k++) {
+ for (k = 0; k < array->Format.Size; k++) {
if (IS_INF_OR_NAN(f[k]) || f[k] >= 1.0e20F || f[k] <= -1.0e10F) {
printf("Bad array data:\n");
printf(" Element[%u].%u = %f\n", j, k, f[k]);
printf(" Array %u at %p\n", attrib, (void *) array);
printf(" Type 0x%x, Size %d, Stride %d\n",
- array->Type, array->Size, binding->Stride);
+ array->Format.Type, array->Format.Size,
+ binding->Stride);
printf(" Address/offset %p in Buffer Object %u\n",
array->Ptr, bo->Name);
f[k] = 1.0F; /* XXX replace the bad value! */
@@ -288,7 +289,7 @@ print_draw_arrays(struct gl_context *ctx,
printf("attr %s: size %d stride %d "
"ptr %p Bufobj %u\n",
gl_vert_attrib_name((gl_vert_attrib) i),
- array->Size, binding->Stride,
+ array->Format.Size, binding->Stride,
array->Ptr, bufObj->Name);
if (_mesa_is_bufferobj(bufObj)) {
@@ -299,7 +300,7 @@ print_draw_arrays(struct gl_context *ctx,
_mesa_vertex_attrib_address(array, binding);
unsigned multiplier;
- switch (array->Type) {
+ switch (array->Format.Type) {
case GL_DOUBLE:
case GL_INT64_ARB:
case GL_UNSIGNED_INT64_ARB:
@@ -313,7 +314,7 @@ print_draw_arrays(struct gl_context *ctx,
int *k = (int *) f;
int i = 0;
int n = (count - 1) * (binding->Stride / (4 * multiplier))
- + array->Size;
+ + array->Format.Size;
if (n > 32)
n = 32;
printf(" Data at offset %d:\n", offset);