0

Ok, So I am overwriting MyLocationOverlay in the hopes of removing the blue accuracy ring.

I am overwriting drawMyLocation()

 @Override 
        protected void drawMyLocation(Canvas canvas, MapView mapView, Location lastFix, GeoPoint myLocation, long when) {
            // translate the GeoPoint to screen pixels
            Point screenPts = mapView.getProjection().toPixels(myLocation, null);



            // create a rotated copy of the marker
            Bitmap arrowBitmap = BitmapFactory.decodeResource( mContext.getResources(), android.THISISWHERETHEANIMATIONSHOULDGO);
            Matrix matrix = new Matrix();
            matrix.postRotate(mOrientation);
            Bitmap rotatedBmp = Bitmap.createBitmap(
                arrowBitmap, 
                0, 0, 
                arrowBitmap.getWidth(), 
                arrowBitmap.getHeight(), 
                matrix, 
                true
            );
            // add the rotated marker to the canvas
            canvas.drawBitmap(
                rotatedBmp, 
                screenPts.x - (rotatedBmp.getWidth()  / 2), 
                screenPts.y - (rotatedBmp.getHeight() / 2), 
                null
            );


        }

However, I am finding it impossible to get a reference to the original blue dot animation that is used. How can I go about adding this back in? One single frame of the animation would be acceptable. Thanks.

Aiden Fry
  • 1,672
  • 3
  • 21
  • 45

1 Answers1

-1

Can't you just use location to know the user's position ?

hanoo
  • 4,175
  • 2
  • 26
  • 19
  • Read my answer again. You say:"However, I am finding it impossible to get a reference to the original blue dot animation that is used. ": answer use your location because the dot is on your position. Do not plot the blue dot and accuracy and then add a dot using location. (read answer before down voting) – hanoo Jan 24 '13 at 18:25
  • This response answers the question (or at least provides an alternative), however your initial response did not. In fact I was trying to get a reference to the dot animation so i could plot it in the manner you suggested ie. R.drawable.location_dot_animation something like this. – Aiden Fry Jan 28 '13 at 09:39