From: Vladimir Dergachev Date: Mon, 10 Jan 2005 03:42:50 +0000 (+0000) Subject: For some reason we need r300Flush when using textures. Perhaps the problem is X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6867117b589d46e496886b7cca99c37e6ec5b36b;p=mesa.git For some reason we need r300Flush when using textures. Perhaps the problem is with BITBLT_MULTI call ? --- diff --git a/src/mesa/drivers/dri/r300/r300_render.c b/src/mesa/drivers/dri/r300/r300_render.c index 198ced12a4a..d7ce53ed38f 100644 --- a/src/mesa/drivers/dri/r300/r300_render.c +++ b/src/mesa/drivers/dri/r300/r300_render.c @@ -257,13 +257,20 @@ static GLboolean r300_run_immediate_render(GLcontext *ctx, /* Update texture state - needs to be done only when actually changed.. All the time for now.. */ - /* Flush state - make sure command buffer is nice and large */ - //r300Flush(ctx); if (RADEON_DEBUG == DEBUG_PRIMS) fprintf(stderr, "%s\n", __FUNCTION__); + #if 1 /* we need this, somehow */ + /* Flush state - make sure command buffer is nice and large */ + r300Flush(ctx); + /* Make sure we have enough space */ + #else 0 + /* Count is very imprecize, but should be good upper bound */ + r300EnsureCmdBufSpace(rmesa, rmesa->hw.max_state_size + 4+2+30 + +VB->PrimitiveCount*(1+8)+VB->Count*4*rmesa->state.texture.tc_count+4, __FUNCTION__); + #endif /* needed before starting 3d operation .. */ reg_start(R300_RB3D_DSTCACHE_CTLSTAT,0); @@ -285,6 +292,7 @@ static GLboolean r300_run_immediate_render(GLcontext *ctx, /* Magic register - note it is right after 20b0 */ + if(rmesa->state.texture.tc_count>0){ reg_start(0x20b4,0); e32(0x0000000c);