mirror of
https://github.com/doitsujin/dxvk.git
synced 2024-12-11 10:24:10 +01:00
[d3d8] CopyRects validation tweaks
This commit is contained in:
parent
b13b875ca6
commit
1675aea857
@ -531,10 +531,6 @@ namespace dxvk {
|
||||
HRESULT res = D3D_OK;
|
||||
D3DLOCKED_RECT srcLocked, dstLocked;
|
||||
|
||||
// CopyRects cannot perform format conversions.
|
||||
if (srcDesc.Format != dstDesc.Format)
|
||||
return D3DERR_INVALIDCALL;
|
||||
|
||||
bool compressed = isDXT(srcDesc.Format);
|
||||
|
||||
res = src->LockRect(&srcLocked, &srcRect, D3DLOCK_READONLY);
|
||||
@ -650,10 +646,8 @@ namespace dxvk {
|
||||
|
||||
// This method cannot be applied to surfaces whose formats
|
||||
// are classified as depth stencil formats.
|
||||
if (unlikely(isDepthStencilFormat(D3DFORMAT(srcDesc.Format)) ||
|
||||
isDepthStencilFormat(D3DFORMAT(dstDesc.Format)))) {
|
||||
if (unlikely(isDepthStencilFormat(D3DFORMAT(srcDesc.Format))))
|
||||
return D3DERR_INVALIDCALL;
|
||||
}
|
||||
|
||||
StateChange();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user