summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/radeon_dri2.c12
-rw-r--r--src/radeon_video.c4
2 files changed, 7 insertions, 9 deletions
diff --git a/src/radeon_dri2.c b/src/radeon_dri2.c
index 0e6292e3..7d5205e9 100644
--- a/src/radeon_dri2.c
+++ b/src/radeon_dri2.c
@@ -399,16 +399,14 @@ static int radeon_dri2_drawable_crtc(DrawablePtr pDraw)
{
ScreenPtr pScreen = pDraw->pScreen;
ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
- BoxRec box, crtcbox;
xf86CrtcPtr crtc;
int crtc_id = -1;
- box.x1 = pDraw->x;
- box.y1 = pDraw->y;
- box.x2 = box.x1 + pDraw->width;
- box.y2 = box.y1 + pDraw->height;
-
- crtc = radeon_covering_crtc(pScrn, &box, NULL, &crtcbox);
+ crtc = radeon_pick_best_crtc(pScrn,
+ pDraw->x,
+ pDraw->x + pDraw->width,
+ pDraw->y,
+ pDraw->y + pDraw->height);
/* Make sure the CRTC is valid and this is the real front buffer */
if (crtc != NULL && !crtc->rotatedData) {
diff --git a/src/radeon_video.c b/src/radeon_video.c
index 7b5f6dec..5e2a7238 100644
--- a/src/radeon_video.c
+++ b/src/radeon_video.c
@@ -162,7 +162,8 @@ radeon_pick_best_crtc(ScrnInfoPtr pScrn,
return best_crtc;
}
-xf86CrtcPtr
+#ifndef HAVE_XF86CRTCCLIPVIDEOHELPER
+static xf86CrtcPtr
radeon_covering_crtc(ScrnInfoPtr pScrn,
BoxPtr box,
xf86CrtcPtr desired,
@@ -197,7 +198,6 @@ radeon_covering_crtc(ScrnInfoPtr pScrn,
return best_crtc;
}
-#ifndef HAVE_XF86CRTCCLIPVIDEOHELPER
static Bool
radeon_crtc_clip_video_helper(ScrnInfoPtr pScrn,
xf86CrtcPtr *crtc_ret,