This post is a follow-up to this thread, but I've decided to post it in a separate thread because it focuses more on the PIX itself, than on the game.
I've ran EVE under PIX for another time, but now I've focused a bit more on PIX's features in the full frame analysis mode. I wasn't that interested in viewing counters, but that's what PIX is capable of, too.
First of all, thanks for pointing that out, .oisyn, it is possible to debug a single pixel. All you need to do is:
1. From the Events window, select a frame which you're interested in.
2. In Details window, click Render tab, zoom in, and right-click a pixel of interest and select "Debug This Pixel..." from the context menu.
3. A new tab in Details window should open up: Debugger. There you should be able to see entire history of the pixel in the frame:
- its ARGB values at the beginning of a frame
- its ARGB values after each Device call which affected it (together with the details of the call, such as primitive number in DrawIndexedPrimitive call, and the parameters of the call itself)
- pixel shader output of each call*
- frame buffer output of each call
- calls that failed tests (like: "pixel was eliminated because it failed alpha test")
- final framebuffer value
* I'm still confused about EVE - I'm not sure whether it runs using fixed function pipeline or the shaders (my guess is still fixed-function) - any calls to SetVertexShader I see in PIX's output pass NULL as parameter, there are no calls to SetPixelShader, only calls to SetFVF.
Another thing that is nice to see is the Mesh tab in Details. Every DrawXxx call has an associated view of what exactly happened in that call: Pre-Vertex Shader, Post-Vertex Shader and Viewport. It's a great way to see what areas were affected by that particular call (for example when you see a lot of stuff in Pre-Vertex Shader and none in Viewport, it's a hint that this call was just a waste of GPU cycles). Also, you can see the Vertex data Pre-VS and Post-VS in a table.
Another feature allows you to see the contents of Index and Vertex Buffers. It's possible when you click a SetStreamSource call in Events window, and then right-click on the highlighted parameter. You will need to specify buffer layout (float3 position; float3 normal; etc.), but that's also not a problem, because when you click the SetVertexDeclaration, you will be able to get it from there.
For the performance freaks, who can read GPU assembly, you're free to debug any Draw call for a particular vertex by clicking its number in PostVS sub-tab in Mesh tab in Details window (whew, that's far away).
More features: texture view (with selectable MIP-levels), device view (device creation parameters, and presentation parameters, input, tesselation, vertex, pixel and output states), all up-to-date for any call and moment in time.
Object window will show you all the objects and resources that were created and accessed in a particular frame (not sure if these are available on per-frame-lifetime or per-application-lifetime basis), their status, ref count, format, width, height, depth, creation and destruction timestamps, and a lot more. All is clickable and viewable, assuming its status is "Alive", not "Dead", e.g. the resource is still available.
Well, to wrap the things up - PIX is available as a part of DirectX SDK (October 2006 is the latest version that has been released), and available as a free download. It seems that is a powerful tool, but honestly, I can't appreciate it enough, as I'm just a beginner in 3D programming. I hope that I got at least some of you as interested in it, as I am :).
Cheers
Pix
Started by marcin.seredynski, Oct 17 2006 07:19 PM
No replies to this topic
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users












