diff options
author | Michel Dänzer <michel.daenzer@amd.com> | 2014-04-25 09:17:51 +0900 |
---|---|---|
committer | Michel Dänzer <michel@daenzer.net> | 2014-04-25 09:17:51 +0900 |
commit | c84230d686c078aac1dc98d82153f8b02521b2e1 (patch) | |
tree | 9a20f2d4834d8dc57a123c7283074c72805a633c | |
parent | 48d3dbc8a0d3bfde88f46e402e530438f9317715 (diff) |
dri2: Handle PRIME for source buffer as well in radeon_dri2_copy_region2
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=77810
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r-- | src/radeon_dri2.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/radeon_dri2.c b/src/radeon_dri2.c index d47b0350..9a9918b0 100644 --- a/src/radeon_dri2.c +++ b/src/radeon_dri2.c @@ -409,7 +409,14 @@ radeon_dri2_copy_region2(ScreenPtr pScreen, dst_drawable = &dst_private->pixmap->drawable; if (src_private->attachment == DRI2BufferFrontLeft) { - src_drawable = drawable; +#ifdef USE_DRI2_PRIME + if (drawable->pScreen != pScreen) { + src_drawable = DRI2UpdatePrime(drawable, src_buffer); + if (!src_drawable) + return; + } else +#endif + src_drawable = drawable; } if (dst_private->attachment == DRI2BufferFrontLeft) { #ifdef USE_DRI2_PRIME |