May 5

Written by: Soul Solutions
Wednesday, 5 May 2010 

johnWeeGo[1]The MultiScaleImage control in Silverlight 4 can now optionally be hardware accelerated. This means those massive images or, in my case, maps of the world can be smoothly rendered by using your compatible video card to do the heavy lifting. So what difference does it make? Let’s take a look, my example went from 40-80% cpu usage to 5-10%!

HWPerfDifference

Take a spin of the hardware accelerated version here. Mouse wheel to zoom. If you right click you can even install out of browser.

What steps do we have to take to make this happen? First we have to enable the cachemode on the MSI control itself:


<MultiScaleImage x:Name="msi" CacheMode="BitmapCache" />

Then for the browser app we add a param to the plugin:


<param name="EnableGPUAcceleration" value="true" />

For “Out-Of-Browser” it is in the advanced options in the silverlight project:

OOBHW 

Download the full source here.

Tags:

1 comment(s) so far...

Re: Hardware accelerated DeepZoom in Silverlight 4

Cool. I'll definitely take a deeper look into this. I must say though, the red map background is a bit overwhelming =0)

By Ricky Brundritt on   Tuesday, 3 August 2010

Your name:
Your email:
(Optional) Email used only to show Gravatar.
Your website:
Title:
Comment:
Security Code
Enter the code shown above in the box below
Add Comment   Cancel 
Copyright © 2002-2009 Soul Solutions Pty Ltd. | Login