Original Post
Should we continue to check HRESULTs when not in debug mode? I ask because the DXUT.h file has something like this: #if defined(DEBUG) || defined(_DEBUG) #ifndef V #define V(x) { hr = (x); if( FAILED(hr) ) { DXUTTrace( __FILE__, (DWORD)__LINE__, hr, L#x, true ); } } #endif #ifndef V_RETURN #define V_RETURN(x) { hr = (x); if( FAILED(hr) ) { return DXUTTrace( __FILE__, (DWORD)__LINE__, hr, L#x, true ); } } #endif #else #ifndef V #define V(x) { hr = (x); } #endif #ifndef V_RETURN #define V_RETURN(x) { hr = (x); if( FAILED(hr) ) { return hr; } } #endif #endif It seems reasonable not to. After all, once your game is burned to a CD you are out of luck if a resource is missing or you have shader bugs. This is especially true for consoles. On the other hand, displaying the error message, line number and file name can help you figure out the problem if you need to issue a patch online.