This is a migrated thread and some comments may be shown as answers.

enableGpuAcceleration ?

3 Answers 103 Views
Map
This is a migrated thread and some comments may be shown as answers.
Kineas
Top achievements
Rank 1
Kineas asked on 22 Apr 2011, 02:04 PM
Hi, one quick question. I am experimenting with th map and I loaded the world.shp and zooming is horrible, 2-3 fps. The features there aren't that complex and that really boggled me. I enabled gpuacceleration and cachevisualisation and everything is red (so not cached)

Tried to enable cachemode manually on the items.

BitmapCache bmc = new BitmapCache();
bmc.RenderAtScale = 4d;
//Map.CacheMode = bmc;
foreach (ItemsControl itemsControl in (Map.Items))
{
 itemsControl.CacheMode = bmc;
foreach (UIElement el in itemsControl.Items)
{
  el.CacheMode = bmc;
  }
}


but no success. Everything is still red.

When I enable CacheMode for the map it becomes normal color, but the map itself doesn't need this cache but the elements within it, and the performance is still horrible.

Anyway. My question is: Am I doing this right? Am I enabling CacheMode on the correct items, because it sure does not feel like it. 

3 Answers, 1 is accepted

Sort by
0
Andrey
Telerik team
answered on 28 Apr 2011, 07:19 AM
Hello Kineas,

The 2-3 fps is not bad performance for the world.shp. This file contains 143 polygons, and 325 figures. When the spring animation is turned on, RadMap performs calculation of the screen coordinates for the polygons and figures several times for 1 zoom level. Unfortunately GPU acceleration will not help you in this case at all, because there is not something which can be cached.

Greetings,
Andrey Murzov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Kineas
Top achievements
Rank 1
answered on 28 Apr 2011, 10:23 AM
Thta's what I was guessing too, because I noticed that the vectors sometimes move in a strange way on the screen, mostly when the application is loaded. Then my question is why do you feel the need to make those calculations instead of simple transformations that would support BitmapCached data. 

I'm comparing this performance with some functionality that exists in flash map controls like openscales.
http://openscales.org/demo/index.html
The effect here is very clear and simple, no need to even look at the code. They handle a bitmap between zooms, that leaves some blank areas when zooming out but overall it is a nice looking map.

Also i'm comparing with some other silverlight map controls, like azukimap.
http://farm.azukimap.jp/case/miyake/
it does not have smooth zoom but it is still fast for a large number of vector features because of the cache. I used that thing in a project a year ago and the speed was quite nice.

Problem with the flash version is that, well, I hate flash with a great burning passion and with the azukimap that the application is nice, but sometimes horrible to control and debug.

You have a really nice line of products here with great integration and it would be a shame not to give it a full potential. Of course this is self serving too but I would really love to finally see a silverlight map control that has it all. You already started having custom projections, you don't have wms but it probably can be implemented  by users by using singleimageproviders and these plus the nice integration sure make me tempted to use it. We already have bought all the controls but mostly for the alphnumeric part, although all our products have maps too.

So. Why do you do those calculatioins? At some point some developer was creating a map in a project and he did a lot of extra calculation to move the vectors to coincide with the raster without thinking that it was easier to move the raster to fit the vector because there was a lot less math to do. Anyway, just my 2 cents.
0
Andrey
Telerik team
answered on 03 May 2011, 08:34 AM
Hi Kineas,

Most of our clients appreciate smooth zooming. We switched to a kind of "transformation" zooming some time ago, but it was removed, because of the numerous requests. The transformation approach does not give a precise positioning for the polygons as well. But many our customers require high accuracy in positionig. All this things require calculations and can't be achieved with rasters and transformations. There are several more reasons to do calculations and use vector shapes. I will not count them all, but just say that they are important for interactivity features. 

We are looking to make zooming faster, but we will use calcualtions in any way, because of the lot of things which can't be implemented without it.

Greetings,
Andrey Murzov
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Map
Asked by
Kineas
Top achievements
Rank 1
Answers by
Andrey
Telerik team
Kineas
Top achievements
Rank 1
Share this question
or