summaryrefslogtreecommitdiff
path: root/src/radeon_textured_videofuncs.c
diff options
context:
space:
mode:
authorAlex Deucher <alexdeucher@gmail.com>2008-12-02 22:26:21 -0500
committerAlex Deucher <alexdeucher@gmail.com>2008-12-02 22:26:21 -0500
commitca74ebf8813b7fab8d08465ef9600f001c948e94 (patch)
treef3eb4ee04a1ac0f48621dcd4d8c40905da8500e5 /src/radeon_textured_videofuncs.c
parentfc079c5267baf431bbecee7744e484783d393152 (diff)
move 3d state init after RADEON_SWITCH_TO_3D()
Diffstat (limited to 'src/radeon_textured_videofuncs.c')
-rw-r--r--src/radeon_textured_videofuncs.c34
1 files changed, 20 insertions, 14 deletions
diff --git a/src/radeon_textured_videofuncs.c b/src/radeon_textured_videofuncs.c
index 8a4a31d7..7a4ffc2e 100644
--- a/src/radeon_textured_videofuncs.c
+++ b/src/radeon_textured_videofuncs.c
@@ -124,23 +124,29 @@ FUNC_NAME(RADEONDisplayTexturedVideo)(ScrnInfoPtr pScrn, RADEONPortPrivPtr pPriv
dstyoff = 0;
#endif
+#ifdef USE_EXA
+ if (info->useEXA) {
+ RADEON_SWITCH_TO_3D();
+ } else
+#endif
+ {
+ BEGIN_ACCEL(2);
+ if (IS_R300_3D || IS_R500_3D)
+ OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D);
+ else
+ OUT_ACCEL_REG(RADEON_RB3D_DSTCACHE_CTLSTAT, RADEON_RB3D_DC_FLUSH);
+ /* We must wait for 3d to idle, in case source was just written as a dest. */
+ OUT_ACCEL_REG(RADEON_WAIT_UNTIL,
+ RADEON_WAIT_HOST_IDLECLEAN |
+ RADEON_WAIT_2D_IDLECLEAN |
+ RADEON_WAIT_3D_IDLECLEAN |
+ RADEON_WAIT_DMA_GUI_IDLE);
+ FINISH_ACCEL();
+ }
+
if (!info->accel_state->XInited3D)
RADEONInit3DEngine(pScrn);
- /* we can probably improve this */
- BEGIN_ACCEL(2);
- if (IS_R300_3D || IS_R500_3D)
- OUT_ACCEL_REG(R300_RB3D_DSTCACHE_CTLSTAT, R300_DC_FLUSH_3D);
- else
- OUT_ACCEL_REG(RADEON_RB3D_DSTCACHE_CTLSTAT, RADEON_RB3D_DC_FLUSH);
- /* We must wait for 3d to idle, in case source was just written as a dest. */
- OUT_ACCEL_REG(RADEON_WAIT_UNTIL,
- RADEON_WAIT_HOST_IDLECLEAN |
- RADEON_WAIT_2D_IDLECLEAN |
- RADEON_WAIT_3D_IDLECLEAN |
- RADEON_WAIT_DMA_GUI_IDLE);
- FINISH_ACCEL();
-
if (pPriv->bicubic_enabled)
vtx_count = 6;
else