Jump to content

  • Log In with Google      Sign In   
  • Create Account


How can PIX be used with WPF apps?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
4 replies to this topic

#1 Tsus   Members   -  Reputation: 1022

Like
0Likes
Like

Posted 24 February 2012 - 04:41 PM

Hi everyone!

I’m planning a project that will require a nice UI. I’m thinking of using ribbon toolbars, which is why I probably need WPF (I know there are lightweight versions for WinForms, but I didn’t came across something that wasn’t buggy, missed important things or was slow…)
I’d like to use SlimDX (currently I only have the September 2011 release installed). So, I looked into the WPF samples of SlimDX and I got confused…

When I tried to debug any of the WPF samples (DX9 or 10 didn’t matter) PIX didn’t show up anything. The D3D area was plain white and hitting F12 had no effect. I read that some people somehow managed to get PIX to do at least something (they got crashes, though…).

So my question is: Is it possible to write WPF apps that use SlimDX to render Direct3D 11 content and can be debugged in PIX?

Thanks in advance, dear people!

Acagamics e.V. – IGDA Student Game Development Club (University of Magdeburg, Germany)


Sponsor:

#2 Terin   Members   -  Reputation: 192

Like
1Likes
Like

Posted 05 March 2012 - 02:06 AM

Hope this points you in the right direction -- I'm leveraging my knowledge of WPF, but have no experience with SlimDX or PIX (I do WPF pretty extensively for work).

There are some issues with WPF applications when not running in Administrator mode -- especially when referencing other libraries. It sounds stupid, but I've had some intensive third-party 3D controls not work when not in Administrative mode, mostly because they failed impersonation, etc, in .NET. Does the process you're trying to do work in WinForms? If so, have you considered hosting a WinForms control inside WPF? (http://msdn.microsoft.com/en-us/library/ms750944.aspx -- WindowsFormHost is the key here) It plays pretty well with WPF -- haven't had any issues with it when having to use legacy controls (except for minor issues caused by the legacy controls rendering poorly to begin with).

Also, you're much smarter to stick with WPF than lightweight WinForms. I've found on a variety of projects that WPF is much faster than WinForms, especially when you have a graphic card. On some controls I'd written for clients, I saw increases in speed for rendering by as much as 200 - 250%. Average was about 170 - 180% faster -- never saw anything actually render slower.

#3 Tsus   Members   -  Reputation: 1022

Like
0Likes
Like

Posted 05 March 2012 - 03:33 AM

Thank you very much Terin! Posted Image

There are some issues with WPF applications when not running in Administrator mode -- especially when referencing other libraries. It sounds stupid, but I've had some intensive third-party 3D controls not work when not in Administrative mode, mostly because they failed impersonation, etc, in .NET.

The Administrator mode wasn’t the problem, but thanks for the tip. (I wouldn’t have thought of it in a million years.)

Does the process you're trying to do work in WinForms? If so, have you considered hosting a WinForms control inside WPF? (http://msdn.microsof...y/ms750944.aspx -- WindowsFormHost is the key here) It plays pretty well with WPF -- haven't had any issues with it when having to use legacy controls (except for minor issues caused by the legacy controls rendering poorly to begin with).

This sounds very promising, since I know it works with WinForms. I will definitely try that!

One feature of the framework should be, to let the 3D control be able to switch to fullscreen mode. This means, the WPF control that is currently hosting the 3D code isn’t used in that case. So, I was hoping that I could probably use PIX in full screen mode. Though, I haven’t had the time to test it yet. (This would be my fallback strategy. Posted Image)

Also, you're much smarter to stick with WPF than lightweight WinForms. I've found on a variety of projects that WPF is much faster than WinForms, especially when you have a graphic card. On some controls I'd written for clients, I saw increases in speed for rendering by as much as 200 - 250%. Average was about 170 - 180% faster -- never saw anything actually render slower.

Interesting! This is very good to know. I haven’t had much the chance to familiarize myself with WPF. It’s good to approach new things. Posted Image

Thanks again! Posted Image

Acagamics e.V. – IGDA Student Game Development Club (University of Magdeburg, Germany)


#4 Memories are Better   Prime Members   -  Reputation: 769

Like
0Likes
Like

Posted 06 March 2012 - 08:06 AM

Tsus, did you manage to get it working?

I still get that lame error and have 'temporarily' given up on PIX, but if you got it working, please do let me know what you did :D

#5 Tsus   Members   -  Reputation: 1022

Like
0Likes
Like

Posted 06 March 2012 - 10:19 AM

Tsus, did you manage to get it working?

I still get that lame error and have 'temporarily' given up on PIX, but if you got it working, please do let me know what you did Posted Image

I’ll let you know when I find a solution. I'll need PIX so I have to figure out a way. :)
Unfortunately, at the moment I barely have time to work on this project. I hope I can give it a try next week...

Acagamics e.V. – IGDA Student Game Development Club (University of Magdeburg, Germany)





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS