Not really. I just want to draw a straight line from point A to point B. --Valeriano
On Wed, Nov 12, 2008 at 6:32 AM, Dennis Wilmsmann <[EMAIL PROTECTED] > wrote: > > Do you want to show driving directions? I think this isn't possible > anymore without getting the information via HTTP vom Google Maps > directly. The class com.google.googlenav.DrivingDirection isn't > available anymore in the SDK 1.0. > > Dennis > > On 12 Nov., 01:47, "Allan Valeriano" <[EMAIL PROTECTED]> wrote: > > Hi all, > > > > I've been trying to draw a path line for a while, but had no success. I > > tried a dummy code just to see if it works, but couldn't make it draw > > anything. > > > > The code I'm using is: > > > > Path path = new Path(); > > > > > Projection proj = mapView.getProjection(); > > > GeoPoint point1 = new GeoPoint(37423157, -122085008); > > > GeoPoint point2 = new GeoPoint(37495999, -122457508); > > > Point p1 = new Point(); > > > Point p2 = new Point(); > > > > > proj.toPixels(point1, p1); > > > proj.toPixels(point2, p2); > > > > > path.moveTo(p1.x, p1.y); > > > path.lineTo(p2.x, p2.y); > > > > > this.pathPaint.setStrokeWidth(4); > > > this.pathPaint.setARGB(100, 113, 105, 252); > > > canvas.drawPath(path, pathPaint); > > > > This code is inside my overridden *draw* method, which is called every > time > > my location, on the map, changes. I found an example ( > http://www.anddev.org/google_driving_directions_-_mapview_overlayed-t...) > > on how to do this, but it uses an old API that is not available anymore. > > Anybody knows what am I doing wrong here? > > > > --Valeriano > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~----------~----~----~----~------~----~------~--~---