sna: Fix Drawable offsets prior to performing shadow discard
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
c27e6306e8
commit
01ce7efe73
|
|
@ -2704,6 +2704,13 @@ sna_drawable_move_region_to_cpu(DrawablePtr drawable,
|
|||
return _sna_pixmap_move_to_cpu(pixmap, flags);
|
||||
}
|
||||
|
||||
assert(priv->gpu_bo == NULL || priv->gpu_bo->proxy == NULL || (flags & MOVE_WRITE) == 0);
|
||||
|
||||
if (get_drawable_deltas(drawable, pixmap, &dx, &dy)) {
|
||||
DBG(("%s: delta=(%d, %d)\n", __FUNCTION__, dx, dy));
|
||||
RegionTranslate(region, dx, dy);
|
||||
}
|
||||
|
||||
if (priv->move_to_gpu) {
|
||||
DBG(("%s: applying move-to-gpu override\n", __FUNCTION__));
|
||||
if ((flags & MOVE_READ) == 0)
|
||||
|
|
@ -2714,13 +2721,6 @@ sna_drawable_move_region_to_cpu(DrawablePtr drawable,
|
|||
}
|
||||
}
|
||||
|
||||
assert(priv->gpu_bo == NULL || priv->gpu_bo->proxy == NULL || (flags & MOVE_WRITE) == 0);
|
||||
|
||||
if (get_drawable_deltas(drawable, pixmap, &dx, &dy)) {
|
||||
DBG(("%s: delta=(%d, %d)\n", __FUNCTION__, dx, dy));
|
||||
RegionTranslate(region, dx, dy);
|
||||
}
|
||||
|
||||
if (operate_inplace(priv, flags) &&
|
||||
region_inplace(sna, pixmap, region, priv, flags) &&
|
||||
sna_pixmap_create_mappable_gpu(pixmap, false)) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue