xf86-video-intel: Branch 'modesetting' - 4 commits - src/i830_cursor.c src/i830_lvds.c src/i830_render.c src/i830_xf86Rotate.c

Eric Anholt anholt at kemper.freedesktop.org
Tue Feb 13 23:21:53 EET 2007


 src/i830_cursor.c     |    2 +-
 src/i830_lvds.c       |    1 -
 src/i830_render.c     |   12 ++++++------
 src/i830_xf86Rotate.c |    2 +-
 4 files changed, 8 insertions(+), 9 deletions(-)

New commits:
diff-tree 0ec4ffcb4e8e5e707e68bef1b13a324677f19f8f (from 699fa88d2570de6173e2d866e11b7437f4842d74)
Author: Eric Anholt <eric at anholt.net>
Date:   Tue Feb 13 13:18:15 2007 -0800

    Fix double free in the case of LVDS disabled through quirks.

diff --git a/src/i830_lvds.c b/src/i830_lvds.c
index 4c1afb0..642dd8a 100644
--- a/src/i830_lvds.c
+++ b/src/i830_lvds.c
@@ -527,6 +527,5 @@ i830_lvds_init(ScrnInfoPtr pScrn)
 
 disable_exit:
     xf86DestroyI2CBusRec(intel_output->pDDCBus, TRUE, TRUE);
-    xfree(intel_output);
     xf86OutputDestroy(output);
 }
diff-tree 699fa88d2570de6173e2d866e11b7437f4842d74 (from parents)
Merge: 681b91924c364a1c00732f548539f2767929ba0e 6641aec0a1cbc869fba1956c556cdd204631545a
Author: Eric Anholt <eric at anholt.net>
Date:   Tue Feb 13 13:10:08 2007 -0800

    Merge branch 'modesetting-origin' into modesetting

diff-tree 681b91924c364a1c00732f548539f2767929ba0e (from 76a4f2eea826036e2ac16b7e8c61ab946038c120)
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 2 17:40:34 2007 -0800

    Add subpixel offsets to fix accelerated rotated rendering on i915.
    
    This fixes the rendercheck "transformed src/mask coords 2" tests. Previously,
    the source pixels chosen would be off by one in some cases.
    
    The particular values were taken from Mesa, which uses .125 offsets (except
    apparently broken for y), but the signs are changed.  I would be happier if
    I had better justification for why this worked.

diff --git a/src/i830_render.c b/src/i830_render.c
index 9933843..96aeb3f 100644
--- a/src/i830_render.c
+++ b/src/i830_render.c
@@ -557,8 +557,8 @@ i830_composite(PixmapPtr pDst, int srcX,
 
 	OUT_RING(PRIM3D_INLINE | PRIM3D_RECTLIST | (vertex_count-1));
 
-	OUT_RING_F(dstX);
-	OUT_RING_F(dstY);
+	OUT_RING_F(-0.125 + dstX);
+	OUT_RING_F(-0.125 + dstY);
 	OUT_RING_F(src_x[0] / pI830->scale_units[0][0]);
 	OUT_RING_F(src_y[0] / pI830->scale_units[0][1]);
 	if (has_mask) {
@@ -566,8 +566,8 @@ i830_composite(PixmapPtr pDst, int srcX,
 	    OUT_RING_F(mask_y[0] / pI830->scale_units[1][1]);
 	}
 
-	OUT_RING_F(dstX);
-	OUT_RING_F(dstY + h);
+	OUT_RING_F(-0.125 + dstX);
+	OUT_RING_F(-0.125 + dstY + h);
 	OUT_RING_F(src_x[1] / pI830->scale_units[0][0]);
 	OUT_RING_F(src_y[1] / pI830->scale_units[0][1]);
 	if (has_mask) {
@@ -575,8 +575,8 @@ i830_composite(PixmapPtr pDst, int srcX,
 	    OUT_RING_F(mask_y[1] / pI830->scale_units[1][1]);
 	}
 
-	OUT_RING_F(dstX + w);
-	OUT_RING_F(dstY + h);
+	OUT_RING_F(-0.125 + dstX + w);
+	OUT_RING_F(-0.125 + dstY + h);
 	OUT_RING_F(src_x[2] / pI830->scale_units[0][0]);
 	OUT_RING_F(src_y[2] / pI830->scale_units[0][1]);
 	if (has_mask) {
diff-tree 76a4f2eea826036e2ac16b7e8c61ab946038c120 (from 1ba45a3fcd40aaf4d373447fb9f252ca053f9105)
Author: Eric Anholt <eric at anholt.net>
Date:   Fri Feb 2 17:34:41 2007 -0800

    Fix bad offsets in "right" rotation of the CRTC in cursor and update handling.

diff --git a/src/i830_cursor.c b/src/i830_cursor.c
index 464eb6d..70a8d52 100644
--- a/src/i830_cursor.c
+++ b/src/i830_cursor.c
@@ -510,7 +510,7 @@ I830SetCursorPosition(ScrnInfoPtr pScrn,
 	    hotspoty = I810_CURSOR_Y;
 	    break;
 	case RR_Rotate_270:
-	    thisx = mode->VDisplay - (root_y - crtc->y);
+	    thisx = mode->HDisplay - (root_y - crtc->y);
 	    thisy = (root_x - crtc->x);
 	    hotspotx = I810_CURSOR_Y;
 	    break;
diff --git a/src/i830_xf86Rotate.c b/src/i830_xf86Rotate.c
index bd4d5a6..2491e7b 100644
--- a/src/i830_xf86Rotate.c
+++ b/src/i830_xf86Rotate.c
@@ -196,7 +196,7 @@ xf86RotateCrtcRedisplay (xf86CrtcPtr crt
     case RR_Rotate_270:
 	transform.matrix[0][1] = IntToxFixed(1);
 	transform.matrix[1][0] = IntToxFixed(-1);
-	transform.matrix[1][2] += IntToxFixed(crtc->mode.VDisplay);
+	transform.matrix[1][2] += IntToxFixed(crtc->mode.HDisplay);
 	break;
     }
 



More information about the xorg-commit mailing list