Properly let radeon_cs_flush_indirect() re-emit 2D state if necessary.

Also remove a superfluous assignment.
This commit is contained in:
Michel Dänzer
2009-08-07 11:56:50 +02:00
parent 577ff3ce92
commit cd99d9f0d7
2 changed files with 2 additions and 5 deletions

View File

@@ -222,7 +222,6 @@ FUNC_NAME(RADEONSolid)(PixmapPtr pPix, int x1, int y1, int x2, int y2)
if (info->cs && CS_FULL(info->cs)) {
FUNC_NAME(RADEONDone2D)(info->accel_state->dst_pix);
radeon_cs_flush_indirect(pScrn);
FUNC_NAME(Emit2DState)(pScrn, RADEON_2D_EXA_SOLID);
}
#endif
@@ -333,7 +332,6 @@ FUNC_NAME(RADEONCopy)(PixmapPtr pDst,
if (info->cs && CS_FULL(info->cs)) {
FUNC_NAME(RADEONDone2D)(info->accel_state->dst_pix);
radeon_cs_flush_indirect(pScrn);
FUNC_NAME(Emit2DState)(pScrn, RADEON_2D_EXA_COPY);
}
#endif

View File

@@ -84,8 +84,8 @@ void radeon_cs_flush_indirect(ScrnInfoPtr pScrn)
if (ret)
ErrorF("space check failed in flush\n");
if (info->reemit_current2d)
info->reemit_current2d(pScrn, 0);
if (info->reemit_current2d && info->state_2d.op)
info->reemit_current2d(pScrn, info->state_2d.op);
if (info->dri2.enabled) {
info->accel_state->XInited3D = FALSE;
info->accel_state->engineMode = EXA_ENGINEMODE_UNKNOWN;
@@ -169,7 +169,6 @@ static void RADEONBlockHandler_KMS(int i, pointer blockData,
if (info->VideoTimerCallback)
(*info->VideoTimerCallback)(pScrn, currentTime.milliseconds);
info->accel_state->engineMode = EXA_ENGINEMODE_UNKNOWN;
radeon_cs_flush_indirect(pScrn);
}