Community of MapPoint and Virtual Earth Users and Developers
This is a discussion on How to draw radius circle of a specific altitude... within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi there, I'm working on a C# desktop application with MapPoint2004 ActiveX control for Europe. I've to allow user to ...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| How to draw radius circle of a specific altitude... I'm working on a C# desktop application with MapPoint2004 ActiveX control for Europe. I've to allow user to draw circles over the map. Everything looks fine until map is on default zoom/altitude. But when the map is zoomed in or zoomed out then circle drawn is not adjusted according to the map's zoom. While floating this question one of the member advised the link to see an article on microsoft site. Here is that link http://support.microsoft.com/?kbid=2...br /> Regards
__________________ Learn from cradle to the grave |
| |||
|
Hi, I dont understeand your question. Maybe it is because we speak different languages..
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
| Zoomin
Hi I had a similar problem - it seems that ConvertToPoint does not take into account the Zoom property of the MapSpecification object because it makes use of a View, not aMapSpecification. The View is then used by the MapSpecification and the MapSpecification is used by GetMap to render the map. Since ConvertToPoint doesn't have zoom info it can't take it into account. To overcome the problem I worked out a formula to adjust my pixel coordinates taking zoom into account. This seems to work. Perhaps it can be adapted to help with your problem. I am setting the locations of controls on my "pbMap" picturebox to the points worked out below. These controls were added previously. PixelCoord[] arrayPoints = new PixelCoord[listStatusObjects.Count]; arrayPoints = renderService.ConvertToPoint(arrayLatLong, currentView, pbMap.Width, pbMap.Height); for (int i = 0; i < listStatusObjects.Count; i++) //listStatusObjects.Count { double z = 1 / currentZoom; double Xtrans = (arrayPoints[i].X * z) - (pbMap.Width/2 * (z -1)); double Ytrans = (arrayPoints[i].Y * z) - (pbMap.Height/2 * (z -1)); pbMap.Controls[i].Left = (int)Xtrans; pbMap.Controls[i].Top = (int)Ytrans; } |
![]() |
| Tags |
| altitude, circle, draw, radius, specific |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| finding the radius of a drawed circle | Wilfried | MapPoint 2006/2009 Discussion | 4 | 3 Weeks Ago 09:27 PM |
| Radius of a Circle | Gianmaria | MapPoint 2006/2009 Discussion | 1 | 07-14-2006 01:32 PM |
| drawning manual radius circle according to selected zoom... | Learner | MapPoint 2006/2009 Discussion | 7 | 03-24-2006 07:06 AM |
| radius to altitude | sharkbait | MapPoint 2006/2009 Discussion | 1 | 06-23-2004 10:22 AM |
| How do I draw a circle, rectangle, ellipse or free.... | Anonymous | MapPoint 2006/2009 Discussion | 1 | 05-26-2000 12:35 PM |
Bodrum Holiday
Check out the picturesque towns on your Bodrum holiday... Book through UlookUbook!