TheRealMJP / MSAAFilter

MSAA and Temporal AA Sample
MIT License
329 stars 39 forks source link

when I run the sloution in VS 2017, it reports error; #3

Closed Cyitao closed 3 years ago

Cyitao commented 4 years ago

line 42 : resource->SetPrivateData(WKPDID_D3DDebugObjectName, (UINT)strlen(buff), buff); //Textures.cpp,

Exception detail: Unhandled exception at 0x00007FFAF7F3A859 (KernelBase.dll) in MSAAFilter.exe: 0x0000087A (parameters: 0x0000000000000002, 0x000000C2950E9CC0, 0x000000C2950EBAB0). occurred

How to solve it ? thanks very much

TheRealMJP commented 4 years ago

Hey there,

I've not seen this crash before, and I'm not sure what the problem is. The code for setting the resource name actually came from a pull request, so I'm not familiar with the _b_str_t type. Does the string pointed to by buff look ok if you view it in the debugger?

Either way you can just comment out that line if you can't figure it out. It's just setting debug names for the textures that would be visible in debug layer messages and debugging tools like RenderDoc.

Cyitao commented 4 years ago

When I comment out this line ,another place will report a exception also. So where does the project from? you may tell me the original path, i try to build myself, thanks!

TheRealMJP commented 4 years ago

What's the other exception you're getting, and what's the callstack? Are you able to determine what the cause of the crash is?

I'm not sure what you mean when you mention the "original path", this repo has all of the original source code and was written by me. That one part with setting the debug name is the only part that came from someone else's pull request: https://github.com/TheRealMJP/MSAAFilter/pull/2

microqq commented 4 years ago

I have the same problem, i tried to build the solution with vs2017/vs2015/vs2013, the debug version would throw exception,but the release version works fine。

TheRealMJP commented 3 years ago

Fixed by pull request #4