summaryrefslogtreecommitdiff
path: root/src/mesa/vbo
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/vbo')
-rw-r--r--src/mesa/vbo/vbo_exec_api.c6
-rw-r--r--src/mesa/vbo/vbo_exec_array.c70
-rw-r--r--src/mesa/vbo/vbo_exec_draw.c32
-rw-r--r--src/mesa/vbo/vbo_rebase.c2
-rw-r--r--src/mesa/vbo/vbo_save_api.c8
-rw-r--r--src/mesa/vbo/vbo_save_draw.c2
-rw-r--r--src/mesa/vbo/vbo_save_loopback.c12
-rw-r--r--src/mesa/vbo/vbo_split_copy.c36
8 files changed, 84 insertions, 84 deletions
diff --git a/src/mesa/vbo/vbo_exec_api.c b/src/mesa/vbo/vbo_exec_api.c
index b10ee2105a..aa7f1c40b1 100644
--- a/src/mesa/vbo/vbo_exec_api.c
+++ b/src/mesa/vbo/vbo_exec_api.c
@@ -857,7 +857,7 @@ void vbo_exec_vtx_destroy( struct vbo_exec_context *exec )
void vbo_exec_BeginVertices( GLcontext *ctx )
{
struct vbo_exec_context *exec = &vbo_context(ctx)->exec;
- if (0) _mesa_printf("%s\n", __FUNCTION__);
+ if (0) printf("%s\n", __FUNCTION__);
vbo_exec_vtx_map( exec );
assert((exec->ctx->Driver.NeedFlush & FLUSH_UPDATE_CURRENT) == 0);
@@ -892,10 +892,10 @@ void vbo_exec_FlushVertices( GLcontext *ctx, GLuint flags )
assert(exec->flush_call_depth == 1);
#endif
- if (0) _mesa_printf("%s\n", __FUNCTION__);
+ if (0) printf("%s\n", __FUNCTION__);
if (exec->ctx->Driver.CurrentExecPrimitive != PRIM_OUTSIDE_BEGIN_END) {
- if (0) _mesa_printf("%s - inside begin/end\n", __FUNCTION__);
+ if (0) printf("%s - inside begin/end\n", __FUNCTION__);
#ifdef DEBUG
exec->flush_call_depth--;
assert(exec->flush_call_depth == 0);
diff --git a/src/mesa/vbo/vbo_exec_array.c b/src/mesa/vbo/vbo_exec_array.c
index f2f1674b6a..90474da7c0 100644
--- a/src/mesa/vbo/vbo_exec_array.c
+++ b/src/mesa/vbo/vbo_exec_array.c
@@ -136,13 +136,13 @@ check_array_data(GLcontext *ctx, struct gl_client_array *array,
for (k = 0; k < array->Size; k++) {
if (IS_INF_OR_NAN(f[k]) ||
f[k] >= 1.0e20 || f[k] <= -1.0e10) {
- _mesa_printf("Bad array data:\n");
- _mesa_printf(" Element[%u].%u = %f\n", j, k, f[k]);
- _mesa_printf(" Array %u at %p\n", attrib, (void* ) array);
- _mesa_printf(" Type 0x%x, Size %d, Stride %d\n",
- array->Type, array->Size, array->Stride);
- _mesa_printf(" Address/offset %p in Buffer Object %u\n",
- array->Ptr, array->BufferObj->Name);
+ 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, array->Stride);
+ printf(" Address/offset %p in Buffer Object %u\n",
+ array->Ptr, array->BufferObj->Name);
f[k] = 1.0; /* XXX replace the bad value! */
}
/*assert(!IS_INF_OR_NAN(f[k]));*/
@@ -257,21 +257,21 @@ print_draw_arrays(GLcontext *ctx, struct vbo_exec_context *exec,
{
int i;
- _mesa_printf("vbo_exec_DrawArrays(mode 0x%x, start %d, count %d):\n",
- mode, start, count);
+ printf("vbo_exec_DrawArrays(mode 0x%x, start %d, count %d):\n",
+ mode, start, count);
for (i = 0; i < 32; i++) {
GLuint bufName = exec->array.inputs[i]->BufferObj->Name;
GLint stride = exec->array.inputs[i]->Stride;
- _mesa_printf("attr %2d: size %d stride %d enabled %d "
- "ptr %p Bufobj %u\n",
- i,
- exec->array.inputs[i]->Size,
- stride,
- /*exec->array.inputs[i]->Enabled,*/
- exec->array.legacy_array[i]->Enabled,
- exec->array.inputs[i]->Ptr,
- bufName);
+ printf("attr %2d: size %d stride %d enabled %d "
+ "ptr %p Bufobj %u\n",
+ i,
+ exec->array.inputs[i]->Size,
+ stride,
+ /*exec->array.inputs[i]->Enabled,*/
+ exec->array.legacy_array[i]->Enabled,
+ exec->array.inputs[i]->Ptr,
+ bufName);
if (bufName) {
struct gl_buffer_object *buf = _mesa_lookup_bufferobj(ctx, bufName);
@@ -284,9 +284,9 @@ print_draw_arrays(GLcontext *ctx, struct vbo_exec_context *exec,
int n = (count * stride) / 4;
if (n > 32)
n = 32;
- _mesa_printf(" Data at offset %d:\n", offset);
+ printf(" Data at offset %d:\n", offset);
for (i = 0; i < n; i++) {
- _mesa_printf(" float[%d] = 0x%08x %f\n", i, k[i], f[i]);
+ printf(" float[%d] = 0x%08x %f\n", i, k[i], f[i]);
}
ctx->Driver.UnmapBuffer(ctx, GL_ARRAY_BUFFER_ARB, buf);
}
@@ -548,11 +548,11 @@ dump_element_buffer(GLcontext *ctx, GLenum type)
const GLubyte *us = (const GLubyte *) map;
GLint i;
for (i = 0; i < ctx->Array.ElementArrayBufferObj->Size; i++) {
- _mesa_printf("%02x ", us[i]);
+ printf("%02x ", us[i]);
if (i % 32 == 31)
- _mesa_printf("\n");
+ printf("\n");
}
- _mesa_printf("\n");
+ printf("\n");
}
break;
case GL_UNSIGNED_SHORT:
@@ -560,11 +560,11 @@ dump_element_buffer(GLcontext *ctx, GLenum type)
const GLushort *us = (const GLushort *) map;
GLint i;
for (i = 0; i < ctx->Array.ElementArrayBufferObj->Size / 2; i++) {
- _mesa_printf("%04x ", us[i]);
+ printf("%04x ", us[i]);
if (i % 16 == 15)
- _mesa_printf("\n");
+ printf("\n");
}
- _mesa_printf("\n");
+ printf("\n");
}
break;
case GL_UNSIGNED_INT:
@@ -572,11 +572,11 @@ dump_element_buffer(GLcontext *ctx, GLenum type)
const GLuint *us = (const GLuint *) map;
GLint i;
for (i = 0; i < ctx->Array.ElementArrayBufferObj->Size / 4; i++) {
- _mesa_printf("%08x ", us[i]);
+ printf("%08x ", us[i]);
if (i % 8 == 7)
- _mesa_printf("\n");
+ printf("\n");
}
- _mesa_printf("\n");
+ printf("\n");
}
break;
default:
@@ -754,12 +754,12 @@ vbo_exec_DrawRangeElementsBaseVertex(GLenum mode,
end = ctx->Array.ArrayObj->_MaxElement - 1;
}
else if (0) {
- _mesa_printf("glDraw[Range]Elements{,BaseVertex}"
- "(start %u, end %u, type 0x%x, count %d) ElemBuf %u, "
- "base %d\n",
- start, end, type, count,
- ctx->Array.ElementArrayBufferObj->Name,
- basevertex);
+ printf("glDraw[Range]Elements{,BaseVertex}"
+ "(start %u, end %u, type 0x%x, count %d) ElemBuf %u, "
+ "base %d\n",
+ start, end, type, count,
+ ctx->Array.ElementArrayBufferObj->Name,
+ basevertex);
}
#if 0
diff --git a/src/mesa/vbo/vbo_exec_draw.c b/src/mesa/vbo/vbo_exec_draw.c
index 526bf7ae79..045af46da8 100644
--- a/src/mesa/vbo/vbo_exec_draw.c
+++ b/src/mesa/vbo/vbo_exec_draw.c
@@ -43,22 +43,22 @@ vbo_exec_debug_verts( struct vbo_exec_context *exec )
GLuint count = exec->vtx.vert_count;
GLuint i;
- _mesa_printf("%s: %u vertices %d primitives, %d vertsize\n",
- __FUNCTION__,
- count,
- exec->vtx.prim_count,
- exec->vtx.vertex_size);
+ printf("%s: %u vertices %d primitives, %d vertsize\n",
+ __FUNCTION__,
+ count,
+ exec->vtx.prim_count,
+ exec->vtx.vertex_size);
for (i = 0 ; i < exec->vtx.prim_count ; i++) {
struct _mesa_prim *prim = &exec->vtx.prim[i];
- _mesa_printf(" prim %d: %s%s %d..%d %s %s\n",
- i,
- _mesa_lookup_prim_by_nr(prim->mode),
- prim->weak ? " (weak)" : "",
- prim->start,
- prim->start + prim->count,
- prim->begin ? "BEGIN" : "(wrap)",
- prim->end ? "END" : "(wrap)");
+ printf(" prim %d: %s%s %d..%d %s %s\n",
+ i,
+ _mesa_lookup_prim_by_nr(prim->mode),
+ prim->weak ? " (weak)" : "",
+ prim->start,
+ prim->start + prim->count,
+ prim->begin ? "BEGIN" : "(wrap)",
+ prim->end ? "END" : "(wrap)");
}
}
@@ -343,7 +343,7 @@ vbo_exec_vtx_map( struct vbo_exec_context *exec )
}
if (0)
- _mesa_printf("map %d..\n", exec->vtx.buffer_used);
+ printf("map %d..\n", exec->vtx.buffer_used);
}
@@ -378,8 +378,8 @@ vbo_exec_vtx_flush( struct vbo_exec_context *exec, GLboolean unmap )
}
if (0)
- _mesa_printf("%s %d %d\n", __FUNCTION__, exec->vtx.prim_count,
- exec->vtx.vert_count);
+ printf("%s %d %d\n", __FUNCTION__, exec->vtx.prim_count,
+ exec->vtx.vert_count);
vbo_context(ctx)->draw_prims( ctx,
exec->vtx.inputs,
diff --git a/src/mesa/vbo/vbo_rebase.c b/src/mesa/vbo/vbo_rebase.c
index 1db36de3de..ff7c7a6b0d 100644
--- a/src/mesa/vbo/vbo_rebase.c
+++ b/src/mesa/vbo/vbo_rebase.c
@@ -124,7 +124,7 @@ void vbo_rebase_prims( GLcontext *ctx,
assert(min_index != 0);
if (0)
- _mesa_printf("%s %d..%d\n", __FUNCTION__, min_index, max_index);
+ printf("%s %d..%d\n", __FUNCTION__, min_index, max_index);
/* XXX this path is disabled for now.
diff --git a/src/mesa/vbo/vbo_save_api.c b/src/mesa/vbo/vbo_save_api.c
index e1caa6f8c5..3a64c0cf01 100644
--- a/src/mesa/vbo/vbo_save_api.c
+++ b/src/mesa/vbo/vbo_save_api.c
@@ -1185,10 +1185,10 @@ static void vbo_print_vertex_list( GLcontext *ctx, void *data )
GLuint i;
(void) ctx;
- _mesa_printf("VBO-VERTEX-LIST, %u vertices %d primitives, %d vertsize\n",
- node->count,
- node->prim_count,
- node->vertex_size);
+ printf("VBO-VERTEX-LIST, %u vertices %d primitives, %d vertsize\n",
+ node->count,
+ node->prim_count,
+ node->vertex_size);
for (i = 0 ; i < node->prim_count ; i++) {
struct _mesa_prim *prim = &node->prim[i];
diff --git a/src/mesa/vbo/vbo_save_draw.c b/src/mesa/vbo/vbo_save_draw.c
index d834fa1f2e..a7cf29acd4 100644
--- a/src/mesa/vbo/vbo_save_draw.c
+++ b/src/mesa/vbo/vbo_save_draw.c
@@ -243,7 +243,7 @@ void vbo_save_playback_vertex_list( GLcontext *ctx, void *data )
* includes operations such as glBegin or glDrawArrays.
*/
if (0)
- _mesa_printf("displaylist recursive begin");
+ printf("displaylist recursive begin");
vbo_save_loopback_vertex_list( ctx, node );
return;
diff --git a/src/mesa/vbo/vbo_save_loopback.c b/src/mesa/vbo/vbo_save_loopback.c
index f13a16e3b5..8d9ae307d6 100644
--- a/src/mesa/vbo/vbo_save_loopback.c
+++ b/src/mesa/vbo/vbo_save_loopback.c
@@ -95,12 +95,12 @@ static void loopback_prim( GLcontext *ctx,
GLuint k;
if (0)
- _mesa_printf("loopback prim %s(%s,%s) verts %d..%d\n",
- _mesa_lookup_prim_by_nr(prim->mode),
- prim->begin ? "begin" : "..",
- prim->end ? "end" : "..",
- start,
- end);
+ printf("loopback prim %s(%s,%s) verts %d..%d\n",
+ _mesa_lookup_prim_by_nr(prim->mode),
+ prim->begin ? "begin" : "..",
+ prim->end ? "end" : "..",
+ start,
+ end);
if (prim->begin) {
CALL_Begin(GET_DISPATCH(), ( prim->mode ));
diff --git a/src/mesa/vbo/vbo_split_copy.c b/src/mesa/vbo/vbo_split_copy.c
index 2fae267ff5..bce401744d 100644
--- a/src/mesa/vbo/vbo_split_copy.c
+++ b/src/mesa/vbo/vbo_split_copy.c
@@ -147,21 +147,21 @@ dump_draw_info(GLcontext *ctx,
{
GLuint i, j;
- _mesa_printf("VBO Draw:\n");
+ printf("VBO Draw:\n");
for (i = 0; i < nr_prims; i++) {
- _mesa_printf("Prim %u of %u\n", i, nr_prims);
- _mesa_printf(" Prim mode 0x%x\n", prims[i].mode);
- _mesa_printf(" IB: %p\n", (void*) ib);
+ printf("Prim %u of %u\n", i, nr_prims);
+ printf(" Prim mode 0x%x\n", prims[i].mode);
+ printf(" IB: %p\n", (void*) ib);
for (j = 0; j < VERT_ATTRIB_MAX; j++) {
- _mesa_printf(" array %d at %p:\n", j, (void*) arrays[j]);
- _mesa_printf(" enabled %d, ptr %p, size %d, type 0x%x, stride %d\n",
- arrays[j]->Enabled, arrays[j]->Ptr,
- arrays[j]->Size, arrays[j]->Type, arrays[j]->StrideB);
+ printf(" array %d at %p:\n", j, (void*) arrays[j]);
+ printf(" enabled %d, ptr %p, size %d, type 0x%x, stride %d\n",
+ arrays[j]->Enabled, arrays[j]->Ptr,
+ arrays[j]->Size, arrays[j]->Type, arrays[j]->StrideB);
if (0) {
GLint k = prims[i].start + prims[i].count - 1;
GLfloat *last = (GLfloat *) (arrays[j]->Ptr + arrays[j]->Stride * k);
- _mesa_printf(" last: %f %f %f\n",
- last[0], last[1], last[2]);
+ printf(" last: %f %f %f\n",
+ last[0], last[1], last[2]);
}
}
}
@@ -235,7 +235,7 @@ elt(struct copy_context *copy, GLuint elt_idx)
GLuint elt = copy->srcelt[elt_idx];
GLuint slot = elt & (ELT_TABLE_SIZE-1);
-/* _mesa_printf("elt %d\n", elt); */
+/* printf("elt %d\n", elt); */
/* Look up the incoming element in the vertex cache. Re-emit if
* necessary.
@@ -244,7 +244,7 @@ elt(struct copy_context *copy, GLuint elt_idx)
GLubyte *csr = copy->dstptr;
GLuint i;
-/* _mesa_printf(" --> emit to dstelt %d\n", copy->dstbuf_nr); */
+/* printf(" --> emit to dstelt %d\n", copy->dstbuf_nr); */
for (i = 0; i < copy->nr_varying; i++) {
const struct gl_client_array *srcarray = copy->varying[i].array;
@@ -268,10 +268,10 @@ elt(struct copy_context *copy, GLuint elt_idx)
{
const GLuint *f = (const GLuint *)srcptr;
GLuint j;
- _mesa_printf(" varying %d: ", i);
+ printf(" varying %d: ", i);
for(j = 0; j < copy->varying[i].size / 4; j++)
- _mesa_printf("%x ", f[j]);
- _mesa_printf("\n");
+ printf("%x ", f[j]);
+ printf("\n");
}
}
@@ -284,9 +284,9 @@ elt(struct copy_context *copy, GLuint elt_idx)
copy->dstbuf_nr * copy->vertex_size));
}
/* else */
-/* _mesa_printf(" --> reuse vertex\n"); */
+/* printf(" --> reuse vertex\n"); */
-/* _mesa_printf(" --> emit %d\n", copy->vert_cache[slot].out); */
+/* printf(" --> emit %d\n", copy->vert_cache[slot].out); */
copy->dstelt[copy->dstelt_nr++] = copy->vert_cache[slot].out;
return check_flush(copy);
}
@@ -300,7 +300,7 @@ end( struct copy_context *copy, GLboolean end_flag )
{
struct _mesa_prim *prim = &copy->dstprim[copy->dstprim_nr];
-/* _mesa_printf("end (%d)\n", end_flag); */
+/* printf("end (%d)\n", end_flag); */
prim->end = end_flag;
prim->count = copy->dstelt_nr - prim->start;