Thanks for the help! I've set up VisualStudio to use the Windows Symbol Server. I've also extremely slimmed down the problem-space in noticing that the same crash happens with the CreateDevice sample from the DirectX SDK. ^^;; So I guess this isn't a managed problem, just a DirectX problem in general on my system.
Now, as before, I get Windows breakpoint triggered inside of Direct3DCreate9...
if( NULL == ( g_pD3D = Direct3DCreate9( D3D_SDK_VERSION ) ) )I can't step in here, that triggers the breakpoint.
Here is the callstack with additional symbols loaded...
ntdll.dll!_DbgBreakPoint@0() d3d9d.dll!00beed3d() [Frames below may be incorrect and/or missing, no symbols loaded for d3d9d.dll] d3d9d.dll!00bee4cb() d3d9d.dll!00bee59b() ntdll.dll!_ZwClose@4() + 0xc bytes advapi32.dll!_BaseRegCloseKeyInternal@4() + 0x49 bytes d3d9d.dll!00be2db4() ntdll.dll!_RtlImageDirectoryEntryToData@16() + 0x3f bytes ntdll.dll!_LdrpGetProcedureAddress@20() + 0xe7 bytes ntdll.dll!_LdrGetProcedureAddress@16() + 0x18 bytes kernel32.dll!_GetProcAddress@8() + 0x3e bytes 0012fdc0() ntdll.dll!_RtlpImageNtHeader@4() + 0x4a bytes user32.dll!__CreateWindowEx@52() + 0xb1 bytes user32.dll!_CreateWindowExW@48() + 0x33 bytes > CreateDevice.exe!wWinMain(HINSTANCE__ * hInst=0x00400000, HINSTANCE__ * __formal=0x00000000, HINSTANCE__ * __formal=0x00000000, HINSTANCE__ * __formal=0x00000000) Line 155 + 0x2f bytes C++ CreateDevice.exe!__tmainCRTStartup() Line 324 + 0x35 bytes C CreateDevice.exe!wWinMainCRTStartup() Line 196 C kernel32.dll!_BaseProcessStart@4() + 0x23 bytes
Since this seems to be a problem with creating the Api itself, I don't think it's a HAL versus REF problem, I'm not even getting to the device creation, the actual API can't initialize. What's strange though is that if I put a breakpoint right before the Direct3DCreate9 function, I get there ok and the call stack looks all right, but when I try to get past that function, the call stack seems to change and the above call stack is displayed as a result... as if I failed on CreateWindowEx, which I already cleared previously... does this mean the stack was corrupted during the D3D initialization??
Again, the output window is sparse in terms of debug messages...
'CreateDevice.exe': Loaded 'D:\CreateDevice\Debug\CreateDevice.exe', Symbols loaded.'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\ntdll.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\kernel32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\d3d9.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\d3d8thk.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\gdi32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\user32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\msvcrt.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\advapi32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\rpcrt4.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\version.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\winmm.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\imm32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\lpk.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\usp10.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\MSCTF.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\MSCTFIME.IME', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\ole32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\IMJP9.IME', No symbols loaded.'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\shell32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\shlwapi.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\IMJP9K.DLL', No symbols loaded.'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\oleaut32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2982_x-ww_ac3f9c03\comctl32.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\uxtheme.dll', Symbols loaded (source information stripped).'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\d3d9d.dll', No symbols loaded.'CreateDevice.exe': Loaded 'C:\WINDOWS\system32\d3dx9d_33.dll', No symbols loaded.Direct3D9: :====> ENTER: DLLMAIN(00bee6e0): Process Attach: 00000e94, tid=00000764Direct3D9: :====> EXIT: DLLMAIN(00bee6e0): Process Attach: 00000e94Direct3D9: (INFO) :Direct3D9 Debug Runtime selected.Windows has triggered a breakpoint in CreateDevice.exe.This may be due to a corruption of the heap, and indicates a bug in CreateDevice.exe or any of the DLLs it has loaded.
To confirm, my Debug Output level for D3D is all the way right at "More", and I've selected "Use Debug Version of Direct3D 9", "Maximum Validation", "Enable Shader Debugging", "Break on D3D9 Error", "Enable Hardware Acceleration". However, toggling all of these checkboxes off and on has no effect.
Should I repost this over in a more general D3D forum, perhaps? :
Thanks for the help!!