st/nine: Fix StretchRect checks

Fixes Wine tests

Signed-off-by: Axel Davy <axel.davy@ens.fr>
This commit is contained in:
Axel Davy 2015-05-08 01:29:35 +02:00
parent c57f777b09
commit ef8ade6f09

View file

@ -1582,8 +1582,12 @@ NineDevice9_StretchRect( struct NineDevice9 *This,
user_assert(!scaled || dst != src, D3DERR_INVALIDCALL);
user_assert(!scaled ||
!NineSurface9_IsOffscreenPlain(dst) ||
!NineSurface9_IsOffscreenPlain(dst), D3DERR_INVALIDCALL);
user_assert(!NineSurface9_IsOffscreenPlain(dst) ||
NineSurface9_IsOffscreenPlain(src), D3DERR_INVALIDCALL);
user_assert(NineSurface9_IsOffscreenPlain(dst) ||
dst->desc.Usage & (D3DUSAGE_RENDERTARGET | D3DUSAGE_DEPTHSTENCIL),
D3DERR_INVALIDCALL);
user_assert(!scaled ||
(!util_format_is_compressed(dst->base.info.format) &&
!util_format_is_compressed(src->base.info.format)),