mirror of
https://github.com/microsoft/DirectXTex
synced 2024-11-12 15:50:08 +00:00
10level9 drivers can return something other than E_INVALIDARG for this case, so we retry for any failure
This commit is contained in:
parent
a6c5c5939a
commit
e85504e967
@ -1205,7 +1205,7 @@ static HRESULT CreateTextureFromDDS( _In_ ID3D11Device* d3dDevice,
|
||||
{
|
||||
hr = CreateD3DResources( d3dDevice, resDim, twidth, theight, tdepth, mipCount - skipMip, arraySize, format, isCubeMap, initData.get(), texture, textureView );
|
||||
|
||||
if ( (hr == E_INVALIDARG) && !maxsize && (mipCount > 1) )
|
||||
if ( FAILED(hr) && !maxsize && (mipCount > 1) )
|
||||
{
|
||||
// Retry with a maxsize determined by feature level
|
||||
switch( d3dDevice->GetFeatureLevel() )
|
||||
|
Loading…
Reference in New Issue
Block a user