diff options
author | Aapo Tahkola <aet@rasterburn.org> | 2005-02-02 13:29:11 +0000 |
---|---|---|
committer | Aapo Tahkola <aet@rasterburn.org> | 2005-02-02 13:29:11 +0000 |
commit | 1a1c49f8a6b0e46c1b551409534b3e2ebbbb401d (patch) | |
tree | 6304b515ff42399f2324951f2028996bf3a46b39 /src/mesa/drivers | |
parent | 3fec8c24ec14a5e07953828beba7e03d6367ae34 (diff) |
Changed parts of r300_setup_routing to use WARN_ONCE.
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r-- | src/mesa/drivers/dri/r300/r300_render.c | 14 | ||||
-rw-r--r-- | src/mesa/drivers/dri/r300/r300_state.c | 12 |
2 files changed, 15 insertions, 11 deletions
diff --git a/src/mesa/drivers/dri/r300/r300_render.c b/src/mesa/drivers/dri/r300/r300_render.c index 1e4db5e1d3..dac7006e57 100644 --- a/src/mesa/drivers/dri/r300/r300_render.c +++ b/src/mesa/drivers/dri/r300/r300_render.c @@ -411,7 +411,7 @@ static void upload_vertex_buffer(r300ContextPtr rmesa, GLcontext *ctx) offset+=v->size*4*VB->Count; \ idx++; \ } - + UPLOAD_VECTOR(VB->ObjPtr); UPLOAD_VECTOR(VB->ColorPtr[0]); /* texture coordinates */ @@ -518,8 +518,8 @@ static GLboolean r300_run_render(GLcontext *ctx, if (RADEON_DEBUG == DEBUG_PRIMS) fprintf(stderr, "%s\n", __FUNCTION__); - - + + #if 1 #if 1 @@ -597,7 +597,13 @@ static void r300_check_render(GLcontext *ctx, struct tnl_pipeline_stage *stage) stage->active = GL_FALSE; return; } - + +#if 0 // selecting VERT_BIT_NORMAL still doesnt give us normals but why? + stage->inputs |= VERT_BIT_POS; + stage->inputs |= VERT_BIT_NORMAL; + stage->inputs |= VERT_BIT_COLOR0; +#endif + // I failed to figure out how dither works in hardware, // let's just ignore it for now //FALLBACK_IF(ctx->Color.DitherFlag); diff --git a/src/mesa/drivers/dri/r300/r300_state.c b/src/mesa/drivers/dri/r300/r300_state.c index e17cb8fe4d..306a921b9b 100644 --- a/src/mesa/drivers/dri/r300/r300_state.c +++ b/src/mesa/drivers/dri/r300/r300_state.c @@ -853,31 +853,31 @@ void r300_setup_routing(GLcontext *ctx, GLboolean immediate) if(tnl->render_inputs & _TNL_BIT_POS){ reg=r300->current_vp->inputs[VERT_ATTRIB_POS]; CONFIGURE_AOS(VB->ObjPtr, 0, i_coords, AOS_FORMAT_FLOAT); - }else fprintf(stderr, "vp expects pos but none was given\n"); + }else WARN_ONCE("vp expects pos but none was given\n"); } if(r300->current_vp->inputs[VERT_ATTRIB_NORMAL] != -1){ if(tnl->render_inputs & _TNL_BIT_NORMAL){ reg=r300->current_vp->inputs[VERT_ATTRIB_NORMAL]; CONFIGURE_AOS(VB->NormalPtr, 0, i_normal, AOS_FORMAT_FLOAT); - }else fprintf(stderr, "vp expects normal but none was given\n"); + }else WARN_ONCE("vp expects normal but none was given\n"); } if(r300->current_vp->inputs[VERT_ATTRIB_COLOR0] != -1){ if(tnl->render_inputs & _TNL_BIT_COLOR0){ reg=r300->current_vp->inputs[VERT_ATTRIB_COLOR0]; CONFIGURE_AOS(VB->ColorPtr[0], 0, i_color[0], AOS_FORMAT_FLOAT_COLOR); - }else fprintf(stderr, "vp expects primary color but none was given\n"); + }else WARN_ONCE("vp expects primary color but none was given\n"); } if(r300->current_vp->inputs[VERT_ATTRIB_COLOR1] != -1){ if(tnl->render_inputs & _TNL_BIT_COLOR1){ reg=r300->current_vp->inputs[VERT_ATTRIB_COLOR1]; CONFIGURE_AOS(VB->SecondaryColorPtr[0], 0, i_color[1], AOS_FORMAT_FLOAT_COLOR); - }else fprintf(stderr, "vp expects secondary color but none was given\n"); + }else WARN_ONCE("vp expects secondary color but none was given\n"); } if(r300->current_vp->inputs[VERT_ATTRIB_FOG] != -1){ if(tnl->render_inputs & _TNL_BIT_FOG){ reg=r300->current_vp->inputs[VERT_ATTRIB_FOG]; CONFIGURE_AOS(VB->FogCoordPtr, 0, i_fog, AOS_FORMAT_FLOAT); - }else fprintf(stderr, "vp expects fog but none was given\n"); + }else WARN_ONCE("vp expects fog but none was given\n"); } for(i=0;i < ctx->Const.MaxTextureUnits;i++) // tex 7 is last if(r300->current_vp->inputs[VERT_ATTRIB_TEX0+i] != -1){ @@ -1807,7 +1807,6 @@ void r300InitState(r300ContextPtr r300) } - /** * Initialize driver's state callback functions */ @@ -1838,4 +1837,3 @@ void r300InitStateFuncs(struct dd_function_table* functions) functions->DepthRange = r300DepthRange; functions->PointSize = r300PointSize; } - |