stanM


Hi,

I create a polyline to show an aircraft track(appr 10 points).

Everything is fine untill I zoom in closer and all of a sudden polyline jumps

and displays incorrectly.

When I zoom out it restores itself.

What is wrong here, a v5 bug!

And what is a ork around

Thanks,

stan




Re: polyline displaying incorrectly at higher zoom layers in v5

Duncan Garratt


I have had the same problem, which is not just confined to version 5, but also occurs in version 4. I believe this to be a bug in the Virtual Earth API, which occurs when a polygon or polyline is redrawn when the zoom event handler is fired. The problem particularly relates to when some or all of the points are outside the bounds of a map for the current zoom level.

This is an important area that the VE Development team need to look at urgently as it is clearly a bug and needs to be fixed.

Duncan Garratt

www.gis-logic.co.uk







Re: polyline displaying incorrectly at higher zoom layers in v5

stanM

Duncan,

You seem to have an advanced knowledge of virtual earth.

I have another problem which I wonder, maybe you encounted too.

My app is a tracking up(tracking aircraft).

What I do I create about a hundred shapes and change their locations dynamically by calling Shape.SetPoints

It seems to me that it causes a severe memory leak.

I wonder, have you encounted any problem like that and if so, maybe some suggested a solution to it.

THanks,

stan






Re: polyline displaying incorrectly at higher zoom layers in v5

Duncan Garratt

Ití»s an interesting point you make regarding the memory leak. What looks like may be happening is that when Shape.SetPoints is called a new VE Lat/long is created internally without the old one being destroyed. It would be worth trying to delete the shape object first, and re-plotting, preferably with the same id, and see if this resolves the leak problem. I know it is not ideal but might just solve the leak problem.

I would be very interested to know your results, as I write tracking systems, and this could be an issue. I currently use the following, which is version 4 code, but works just as well in version 5

  1. map.AddPolygon(poly);
  2. map.AddPolyline(poly);
  3. map.AddPushpin(pin);
  4. map.DeletePolyline(ID);
  5. map.DeletePolygon(ID);

Duncan Garratt

www.gis-logic.co.uk






Re: polyline displaying incorrectly at higher zoom layers in v5

stanM

In fact I did exactly that in v4.

I tried what you suggested. I seems like it helped somewhat but not much.

The interesting thing is that in both cases if I zoom in/out when a lot of pushpins are visible on the map that is the moment when the most memory is lost.

If I pan to the area where pushpins are not visible zoom in/out is OK no memory loss.

My problem is there is no way to reach those Microsoft guys to explain the situation they should know what causes it

and then I might of found a solution

stan





Re: polyline displaying incorrectly at higher zoom layers in v5

Duncan Garratt

Hi Stan

From what you describe it sounds like the pushpins are being redrawn when zooming in, and out. Therefore as the scale is different, the pushpins are being re-mounted on the map. This problem looks like another bug that needs urgent attention from the VE Development Team. It would appear that the API is using a new VELatLong() instead of the existing points. This would explain the memory leaks.

Please add it this problem to the VE 6 Wish List in the hope that the VE Development team will take notice and address these problems.

Regards

Duncan Garratt

www.gis-logic.co.uk