简体   繁体   中英

DirectX 11 errors equivalent to DirectX 9

I need a reference for finding equivalent error codes for DirectX 11 that was used in DirectX 9 implementations like following:

D3DERR_INVALIDDEVICE
D3DERR_DRIVERINVALIDCALL
D3DERR_TOOMANYOPERATIONS
D3DERR_DEVICELOST
D3DERR_DEVICENOTRESET
D3DERR_NOTAVAILABLE

I have found that winerror.h contains all the DXGI error codes but could not find equivalent code for the above mentioned errors in DiretcX 9. Please help me finding a reference or wiki to find an equivalent error code.

DXGI-based versions of Direct3D do not have 'lost device' scenarios, only TDR and device removed , so the D3DERR_DEVICELOST , D3DERR_DEVICENOTRESET , D3DERR_DRIVERINTERNALERROR , and D3DERR_NOTAVAILABLE cases never happen with Direct3D 10 or later.

As documented on Microsoft Docs , you will never get D3DERR_DRIVERINVALIDCALL .

D3DERR_TOOMANYOPERATIONS , D3DERR_CONFLICTINGRENDERSTATE , D3DERR_CONFLICTINGTEXTUREFILTER , etc. applies to the legacy fixed-function pipeline which doesn't exist for Direct3D 10 or later.

A number of these older errors like D3DERR_UNSUPPORTEDALPHAARG , D3DERR_UNSUPPORTEDALPHAOPERATION , etc. were related to the old legacy "caps bits" which is not how things are managed for Direct3D 10 or later. Instead, it uses Direct3D hardware feature levels .

In cases where Direct3D9 would return D3DERR_INVALIDDEVICE you probably get E_INVALIDARG now.

You may want to look at this blog post

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM