Skip to main content
gamedev.net
🔒 Locked

Debug D3d runtime problem

Started by Lynyrd 5 replies 1.4k views
Original Post
Lynyrd
Lynyrd
I write a simple cubemap d3d9 app, it first render to six textures, then use it as cubemap texture.It runs well with retail d3d9 (March 2008). With debug d3d9, it renders nothing to the final render target. According to PIX, the cubemap texture has been rendered correctly, but nothing has been rendered to the final color target.When I try to debug a pixel in PIX, it crashed :( . How could I make it correct in debug runtime, does PIX work well in debug d3d9? Thanks in advance.
remigius
remigius

If it fails with the debug runtimes enabled, there should be more information on the problem in the debug output. Check your Visual Studio output window for the ouput of the debug runtimes, in particular errors and warnings. If it doesn't contain errors and/or warnings, make sure you've got the debug output slider in the control panel set to most and that that maximum validation is enabled.

In the unlikely event that this fails to produce debug output, switching to the reference rasterizer (check the SDK docs for info on this) may help to determine if it's a problem with your code or your graphics card. If it runs just fine on the reference rasterizer, there may be a problem with your card. In this case you could try updating your drivers or try the program on another machine if you have one available.
ET3D
ET3D
What hardware are you running on? I've had crashes in PIX on Intel integrated graphics, which I didn't get on ATI or NVIDIA cards. You might also try updating the drivers.
jollyjeffers
jollyjeffers
Yes, I've had odd things like this happen over the years.

99% of the time I've been doing something wrong that chokes the debug runtimes but not the real drivers. Some drivers "massage" incorrect parameters into correct ones or are simply more forgiving of crap code whereas the debug runtime just explodes (although, by design, it should just warn you rather than crash [headshake]).

I'd go with checking against the reference rasterizer. If that works correctly in the same way as the proper hardware then you could potentially have hit a bug somewhere. In which case, try the latest DXSDK if you're able to - things like PIX have changed quite a bit from release-to-release...

hth
Jack
<hr align="left" width="25%" />
Jack Hoxley <small>[</small><small> Forum FAQ | Revised FAQ |
Lynyrd
Lynyrd

I use 8800gt, it has the same issue on reference raster.
I used
V( pd3dDevice->Clear(0, NULL, D3DCLEAR_TARGET | D3DCLEAR_ZBUFFER, D3DCOLOR_ARGB(0, 45, 50, 170), 1.0f, 0) ) before render to cubemap. If I clear the target after render to cubemap and before the final render. It works correctly in d3d9 debug. It also can be debug in PIX.
In d3d9 retail, clearing target before or after render to cubemap is OK.
Is there some explaination about this ?
Thanks.





remigius
remigius
Quote:
Original post by Lynyrd
If I clear the target after render to cubemap and before the final render. It works correctly in d3d9 debug. It also can be debug in PIX.
In d3d9 retail, clearing target before or after render to cubemap is OK.
Is there some explaination about this ?


So it does work when you clear the buffer after rendering to the cube map? For some speculation, I'd guess it makes sense for this to break, since the rendered cubemap would have to be 'reinterpreted' as a normal render target if you don't clear before you continue with that. This reinterpreting is probably prone to unpredictable results, so the debug runtimes balk at it.

But that's just my 2ct [smile]
ElenaKr
ElenaKr
Hi there,
I am a tester on PIX team. I investigated the PIX for Windows issue you reported in this thread. I was able to repro a crash when trying to debug a pixel from cube map set as render target in March08 version of PIX. However, this issue has been fixed in June08 version.
If you indeed use older version of PIX we highly recommend you to switch to June08 version which has a lot of improvements over previous versions.
Please let me know if you have any other issues.

Thanks,
Lena

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.