diff options
-rw-r--r-- | src/mesa/drivers/dri/i915/intel_blit.c | 5 | ||||
-rw-r--r-- | src/mesa/drivers/dri/i965/intel_blit.c | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i915/intel_blit.c b/src/mesa/drivers/dri/i915/intel_blit.c index d4e269dc841..9a68625318a 100644 --- a/src/mesa/drivers/dri/i915/intel_blit.c +++ b/src/mesa/drivers/dri/i915/intel_blit.c @@ -271,9 +271,10 @@ intelEmitCopyBlit(struct intel_context *intel, dst_buffer, dst_pitch, dst_offset, dst_x, dst_y, w, h); /* Blit pitch must be dword-aligned. Otherwise, the hardware appears to drop - * the low bits. + * the low bits. Offsets must be naturally aligned. */ - if (src_pitch % 4 != 0 || dst_pitch % 4 != 0) + if (src_pitch % 4 != 0 || src_offset % cpp != 0 || + dst_pitch % 4 != 0 || dst_offset % cpp != 0) return false; /* For big formats (such as floating point), do the copy using 16 or 32bpp diff --git a/src/mesa/drivers/dri/i965/intel_blit.c b/src/mesa/drivers/dri/i965/intel_blit.c index 8d816718bf0..400d3d3d9e7 100644 --- a/src/mesa/drivers/dri/i965/intel_blit.c +++ b/src/mesa/drivers/dri/i965/intel_blit.c @@ -344,9 +344,10 @@ intelEmitCopyBlit(struct brw_context *brw, dst_buffer, dst_pitch, dst_offset, dst_x, dst_y, w, h); /* Blit pitch must be dword-aligned. Otherwise, the hardware appears to drop - * the low bits. + * the low bits. Offsets must be naturally aligned. */ - if (src_pitch % 4 != 0 || dst_pitch % 4 != 0) + if (src_pitch % 4 != 0 || src_offset % cpp != 0 || + dst_pitch % 4 != 0 || dst_offset % cpp != 0) return false; /* For big formats (such as floating point), do the copy using 16 or 32bpp |