diff options
author | Thomas Hellstrom <thellstrom@vmware.com> | 2010-10-19 09:35:16 +0200 |
---|---|---|
committer | Thomas Hellstrom <thellstrom@vmware.com> | 2010-10-19 11:28:08 +0200 |
commit | 0301c9ac6207f21bae9e35c7f0bc18ea12491162 (patch) | |
tree | 6ce97dc28f28602f5740d778227e0260b9e59b05 /src/gallium/state_trackers/xorg | |
parent | 0d0a6e9096f98cd6142d6a883e9a2884ccea0adb (diff) | |
download | external_mesa3d-0301c9ac6207f21bae9e35c7f0bc18ea12491162.zip external_mesa3d-0301c9ac6207f21bae9e35c7f0bc18ea12491162.tar.gz external_mesa3d-0301c9ac6207f21bae9e35c7f0bc18ea12491162.tar.bz2 |
st/xorg: Fix compilation errors for Xservers compiled without Composite
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Diffstat (limited to 'src/gallium/state_trackers/xorg')
-rw-r--r-- | src/gallium/state_trackers/xorg/xorg_xv.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/src/gallium/state_trackers/xorg/xorg_xv.c b/src/gallium/state_trackers/xorg/xorg_xv.c index f98bd93..f64959f 100644 --- a/src/gallium/state_trackers/xorg/xorg_xv.c +++ b/src/gallium/state_trackers/xorg/xorg_xv.c @@ -536,8 +536,10 @@ display_video(ScrnInfoPtr pScrn, struct xorg_xv_port_priv *pPriv, int id, dst_surf = xorg_gpu_surface(pPriv->r->pipe->screen, dst); hdtv = ((src_w >= RES_720P_X) && (src_h >= RES_720P_Y)); +#ifdef COMPOSITE REGION_TRANSLATE(pScrn->pScreen, dstRegion, -pPixmap->screen_x, -pPixmap->screen_y); +#endif dxo = dstRegion->extents.x1; dyo = dstRegion->extents.y1; @@ -562,11 +564,16 @@ display_video(ScrnInfoPtr pScrn, struct xorg_xv_port_priv *pPriv, int id, int box_y2 = pbox->y2; float diff_x = (float)src_w / (float)dst_w; float diff_y = (float)src_h / (float)dst_h; - float offset_x = box_x1 - dstX + pPixmap->screen_x; - float offset_y = box_y1 - dstY + pPixmap->screen_y; + float offset_x = box_x1 - dstX; + float offset_y = box_y1 - dstY; float offset_w; float offset_h; +#ifdef COMPOSITE + offset_x += pPixmap->screen_x; + offset_y += pPixmap->screen_y; +#endif + x = box_x1; y = box_y1; w = box_x2 - box_x1; |