Welcome to MapForums!

Register, sign in, or use Facebook Connect above to join in and participate in the forum.

When you are signed in, this message, the ads in this row, and the red-underlined link ads all go away.

Subscribe to receive our newsletter.
Subscribe Unsubscribe
Results 1 to 3 of 3

Vehicle simulation and location detection

This is a discussion on Vehicle simulation and location detection within the MapPoint Desktop Discussion forums, part of the Map Forums category; I am coding a C# project using MapPoint Web Service 3 and would like to know if anyone has some ...

  1. #1
    frenstall is offline Junior Member White Belt
    Join Date
    Feb 2004
    Posts
    2

    Vehicle simulation and location detection

    I am coding a C# project using MapPoint Web Service 3 and would like to know if anyone has some ideas on how to solve my problems. My issue is that I require some way to simulate a vehicle traveling along a MapPoint route I then need to detect when a vehicle is within a specified distance of a lighted intersection and run a seperate class on this occurance.

    Currently all I can think of to simulate a vehicle is to continuously feel lat/lon points but this seems like a very poor method. Does anyone have a more elegant sugestion? All ideas are welcome and your help is greatly appreciated

  2. #2
    Anonymous is offline Senior Member Black Belt
    Join Date
    Jul 2002
    Posts
    5,137
    Hello,

    There probably isn't a real good way to do this for several reasons:

    1. When you get a result set containing directions it will include the lat/longs for the starting and ending points of a particular street segment. The problem here is that it doesn't not include lat/longs or pixel coords along that segment. So, if you have a long street segment there's really no way to know the pixels or lat/longs to pass in. The problem would show itself when that street is long and has a curve. Because you only have the start and end points you would have to figure the lat/longs (if you were getting a new image from MapPoint constantly as you moved along the segment) or pixels (if you were drawing on the client side) your self and there would be know way for you to know that the street curved. This would cause your simulated vehicle to cut across this curve and depending on the street could look pretty ugly.

    Note: Drawing the vehicle each time it moves using the web service is not a good idea because first, it a billable transaction for every getmap call and it also would be slow if you want make the vehicle movement look smooth. You would almost be forced to draw the movement on the client side.

    2. How are you determining/finding the 'lighted intersection'?

    The only part that is easy to determining the distance between the simulated vehicle and the intersection (if you can find a good way to determine these coords to start with). The SDK includes the code for calculating Great Circle Distance.


    Steven Pushee

    This posting is provided "AS IS" with no warranties, and confers no rights.
    You assume all risk for your use. 2003 Microsoft Corporation. All rights
    reserved.

  3. #3
    arsenic77 is offline Junior Member White Belt
    Join Date
    Jun 2003
    Posts
    5
    You tell that the result set containing directions include the lat/longs for the starting and ending points of a particular street segment. How can I get these starting and ending points ?

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. GPS simulation
    By Gary K in forum MapPoint Desktop Discussion
    Replies: 1
    Last Post: 07-26-2005, 04:28 PM
  2. plot history of vehicle
    By starbuck in forum MapPoint Desktop Discussion
    Replies: 4
    Last Post: 01-08-2005, 09:30 AM
  3. plot history of vehicle
    By starbuck in forum Bing Maps and MapPoint Web Service
    Replies: 0
    Last Post: 01-03-2005, 07:10 PM
  4. mappoint installed detection
    By Anonymous in forum MapPoint Desktop Discussion
    Replies: 1
    Last Post: 10-29-2004, 04:47 PM
  5. PushPin Selection detection in Delphi?
    By shadbell in forum MapPoint Desktop Discussion
    Replies: 3
    Last Post: 12-18-2003, 11:26 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25