Hi,
We are considering whether to use WPF or the WinForms for a new project. To support our decision I creted two very small projects (10 lines of code) that load a large shapefile (2M lines), one WPF and one WinForms. I _expected_ the WPF edition to be faster than the WinForms edition since it renders using DirectX (using the GPU). However, it takes appr 33 seconds to render the file in WinForms and 50 seconds in WPF.
Why is the WPF edition is not faster at rendering a large amount of lines than the WinForms edition? (The WPF edition advertises "Blazingly fast renering").
Best regards, Thomas
Performance of WPF eidtion vs WinForms edition
Hi Thomas,
Thanks for considering our products! The below is my guesses on the difference behavior and some comparisons between the Winform Edition and Wpf Edition.
Based on my experiences on the winform edition and wpf edition, I always have a good impression on using WPF edition as the performance is better and the pan/zoom is more smooth than the winform edition. I can’t recreate the test result like yours with a large number of data, would you let me know how large your data is and how many records are in?
I also advice you can try to set the TileMode as SingleTile in LayerOverlay of WPF Edition and also the TileSize as 512 or 1024. Then do the comparison again to see if the result is difference.
Here are some big differences on WPF and Winform Edition:
- Forget the map suite wpf control, as all we know, comparing with traditional winform application, we owns tons of benefits from microsoft WPF framework. like you mentioned using GPU, flexible,good UI etc…
- Back to our map control, both of them are using the GDI+ to draw the map as image, so at this part, I think the performance should be the same.
- Wpf Edition enhances the performance in user experience and multi-thread especially when manager the large number data.
- Comparing with winform edition, wpf Edition is more flexible. we can easy to do all kinds of extensions to fit our custom requirements.
- Wpf Edition integrates a lots of useful tools and the marker or popup’s UI and performance has a big enhancement.
- Here are more Wpf performance threads. WPF Desktop Performance and Speed.
Btw, our end-use application GisEditor is also based on Wpf Edition and we can see it integrates a lots fantastic functions and the performance is good.
Hope those will help you.
Thanks,
Troy