I'm walking through a directx tutorial (
http://www.directxtutorial.com/Lesson.aspx?lessonid=11-4-5)
I'm having problems with these two:
1 2
|
dev->CreateVertexShader(VS->GetBufferPointer(), VS->GetBufferSize(), NULL, &pVS);
dev->CreatePixelShader(PS->GetBufferPointer(), PS->GetBufferSize(), NULL, &pPS);
|
dev, VS and PS are not null. Buffer size is greater than zero.
Output:
First-chance exception at 0x000007FEFD0BBCCD in Test2.exe: Microsoft C++ exception: _com_error at memory location 0x000000000031F818.
|
Call stack:
KernelBase.dll!RaiseException() Unknown
msvcrt.dll!_CxxThrowException() Unknown
d3d11.dll!CDevice::CreateVertexShader_Worker(void const *,unsigned __int64,struct ID3D11ClassLinkage *,void * *,struct _GUID const &,bool) Unknown
d3d11.dll!CDevice::CreateVertexShader(void const *,unsigned __int64,struct ID3D11ClassLinkage *,struct ID3D11VertexShader * *) Unknown
> Test2.exe!InitPipeline() Line 279 C++
Test2.exe!InitD3D(HWND__ * hWnd=0x0000000000730806) Line 188 C++
Test2.exe!WinMain(HINSTANCE__ * hInstance=0x000000013f830000, HINSTANCE__ * hPrevInstance=0x0000000000000000, char * lpCmdLine=0x0000000000423e90, int nCmdShow=10) Line 88 C++
Test2.exe!__tmainCRTStartup() Line 528 C
Test2.exe!WinMainCRTStartup() Line 377 C
kernel32.dll!BaseThreadInitThunk() Unknown
ntdll.dll!RtlUserThreadStart() Unknown
Tried both x86 and x64, but same problem. I'm using visual studio 2012 on Windows 7 64, directx 11. If anyone has any ideas or can point me in the right direction it would be very appreciated.