diff options
author | root <root@cr-znh.(none)> | 2008-08-11 15:31:13 +0800 |
---|---|---|
committer | root <root@cr-znh.(none)> | 2008-08-11 15:31:13 +0800 |
commit | 19ebdf1b24184c0a293a698d44c4e0571109d153 (patch) | |
tree | 1f0e41ef72951b7f8fee481338cd19e0ff2919c7 /src/i830_video.c | |
parent | 277632d8c37cf43c7c1178ae7d5a2e6d5705968c (diff) |
[i965-xvmc] bypass copy when put image with xvmc
Diffstat (limited to 'src/i830_video.c')
-rw-r--r-- | src/i830_video.c | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/i830_video.c b/src/i830_video.c index 7b81b04d..a52fac41 100644 --- a/src/i830_video.c +++ b/src/i830_video.c @@ -2290,6 +2290,11 @@ I830PutImage(ScrnInfoPtr pScrn, srcPitch = (width + 0x3ff) & ~0x3ff; srcPitch2 = ((width >> 1) + 0x3ff) & ~0x3ff; } + break; + case FOURCC_XVMC: + srcPitch = (width + 0x3) & ~0x3; + srcPitch2 = ((width >> 1) + 0x3) & ~0x3; + break; #endif break; case FOURCC_UYVY: @@ -2428,6 +2433,13 @@ I830PutImage(ScrnInfoPtr pScrn, break; #ifdef INTEL_XVMC case FOURCC_XVMC: + if (pPriv->rotation != RR_Rotate_0) { + top &= ~1; + nlines = ((((y2 + 0xffff) >> 16) + 1) & ~1) - top; + I830CopyPlanarData(pScrn, pPriv, buf, srcPitch, srcPitch2, dstPitch, + height, top, left, nlines, npixels, id); + } + break; #endif default: @@ -2468,6 +2480,14 @@ I830PutImage(ScrnInfoPtr pScrn, i830_fill_colorkey (pScreen, pPriv->colorKey, clipBoxes); } } else if (IS_I965G(pI830)) { + +#ifdef INTEL_XVMC + if (id == FOURCC_XVMC && pPriv->rotation == RR_Rotate_0) { + pPriv->YBuf0offset = buf - pI830->FbBase; + pPriv->UBuf0offset = pPriv->YBuf0offset + height*width; + pPriv->VBuf0offset = pPriv->UBuf0offset + height*width/4; + } +#endif I965DisplayVideoTextured(pScrn, pPriv, destId, clipBoxes, width, height, dstPitch, x1, y1, x2, y2, src_w, src_h, drw_w, drw_h, pPixmap); |