Module: wine Branch: master Commit: 430bac5fadc2fa6a02827f69ff04d2feef24a047 URL: http://source.winehq.org/git/wine.git/?a=commit;h=430bac5fadc2fa6a02827f69ff...
Author: Henri Verbeet hverbeet@codeweavers.com Date: Mon Jun 20 23:21:10 2011 +0200
wined3d: Only bother checking block alignment for compressed surfaces in wined3d_device_update_surface().
---
dlls/wined3d/device.c | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 03f57ff..8a2058c 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -4810,8 +4810,9 @@ HRESULT CDECL wined3d_device_update_surface(struct wined3d_device *device, }
/* NPOT block sizes would be silly. */ - if ((update_w & (src_format->block_width - 1) || update_h & (src_format->block_height - 1)) - && (src_w != update_w || dst_w != update_w || src_h != update_h || dst_h != update_h)) + if ((src_format->flags & WINED3DFMT_FLAG_COMPRESSED) + && ((update_w & (src_format->block_width - 1) || update_h & (src_format->block_height - 1)) + && (src_w != update_w || dst_w != update_w || src_h != update_h || dst_h != update_h))) { WARN("Update rect not block-aligned.\n"); return WINED3DERR_INVALIDCALL;