diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2010-04-08 13:29:04 +0200 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2010-04-08 17:21:18 +0200 |
commit | bdf0ee509c26ab35e60f3ed02549efa435be032f (patch) | |
tree | e1f3b69254e162a3fcb047423bba48dc69c62f4d | |
parent | f6cb28e909c8685474e69e8bd8600f146d3a74e9 (diff) |
i965 Xv: fix chroma pitch
In my recent fix for the chroma pitch for i915 xvmc I've forgotten about
i965 class hw. For videos with a non-even sized stride (measured in dwords)
the chroma pitch was internally incosistent and one dword off.
Fix this by using pitch2 for the chroma pitch in i965 textured video like
everywhere else.
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=27417
Tested-by: Nick Bowler <nbowler@draconx.ca>
Tested-by: Sven Arvidsson <sa@whiz.se>
-rw-r--r-- | src/i830_video.c | 2 | ||||
-rw-r--r-- | src/i830_video.h | 2 | ||||
-rw-r--r-- | src/i965_video.c | 5 |
3 files changed, 5 insertions, 4 deletions
diff --git a/src/i830_video.c b/src/i830_video.c index c8edcd60..45213cb1 100644 --- a/src/i830_video.c +++ b/src/i830_video.c @@ -1525,7 +1525,7 @@ I830PutImageTextured(ScrnInfoPtr scrn, if (IS_I965G(intel)) { I965DisplayVideoTextured(scrn, adaptor_priv, id, clipBoxes, - width, height, dstPitch, + width, height, dstPitch, dstPitch2, src_w, src_h, drw_w, drw_h, pixmap); } else { diff --git a/src/i830_video.h b/src/i830_video.h index fcdae737..b5753bf1 100644 --- a/src/i830_video.h +++ b/src/i830_video.h @@ -76,7 +76,7 @@ void I915DisplayVideoTextured(ScrnInfoPtr scrn, void I965DisplayVideoTextured(ScrnInfoPtr scrn, intel_adaptor_private *adaptor_priv, int id, RegionPtr dstRegion, short width, - short height, int video_pitch, + short height, int video_pitch, int video_pitch2, short src_w, short src_h, short drw_w, short drw_h, PixmapPtr pixmap); diff --git a/src/i965_video.c b/src/i965_video.c index 05dd2c3e..c5378608 100644 --- a/src/i965_video.c +++ b/src/i965_video.c @@ -980,7 +980,8 @@ void I965DisplayVideoTextured(ScrnInfoPtr scrn, intel_adaptor_private *adaptor_priv, int id, RegionPtr dstRegion, - short width, short height, int video_pitch, + short width, short height, + int video_pitch, int video_pitch2, short src_w, short src_h, short drw_w, short drw_h, PixmapPtr pixmap) { @@ -1023,7 +1024,7 @@ I965DisplayVideoTextured(ScrnInfoPtr scrn, src_surf_format = BRW_SURFACEFORMAT_R8_UNORM; src_width[1] = src_width[0] = width; src_height[1] = src_height[0] = height; - src_pitch[1] = src_pitch[0] = video_pitch * 2; + src_pitch[1] = src_pitch[0] = video_pitch2; src_width[4] = src_width[5] = src_width[2] = src_width[3] = width / 2; src_height[4] = src_height[5] = src_height[2] = src_height[3] = |