views:

60

answers:

1

I have a problem where Device.Dispose() is taking a long time to execute when the application is closed. I am investigating whether this is due to unmanaged objects not being freed properly thus resulting in a long cleanup time.

Is there an easy way of tracing or viewing the unmanaged DirectX objects that have been allocated?

A: 

I've found out a way to trace all the calls made to DirectX.

Download and install the DirectX SDK (I installed the August 2009).

Run an application called PIX for Windows in the DirectX SDK -> DirectX Utilities

Create a new experiment from the File menu. Select "a replayable Direct3D call stream, saved to file:", enter a filename and select your application.

When you exit your application a complete trace of all DirectX calls will be shown complete with a timeline.

Matt Breckon