How to draw an Animated Overlay on a MapView

Put problem concerning MapActivities, MapViews, Overlays and GPS in this forum.

How to draw an Animated Overlay on a MapView

Postby achoukou » Fri Aug 07, 2009 6:25 pm

Hi everyone,

I have a problem with overlays.
the problem is that I cannot draw an animated overlay (gif image) on the map, like MyLocationOverlay do.
can anyone help me figure out this problem?
thanks in advance.
User avatar
achoukou
Once Poster
Once Poster
 
Posts: 1
Joined: Fri Aug 07, 2009 6:16 pm

Top

Postby Christoph » Sat Aug 08, 2009 1:27 pm

gif's are not realy good supported.
you can use a AnimationDrawable. that will work.
the mylocation-icon is also done this way.
User avatar
Christoph
Developer
Developer
 
Posts: 28
Joined: Thu Jul 02, 2009 3:34 am
Location: Bonn, Germany

Postby hc » Fri Aug 14, 2009 12:19 pm

Christoph wrote:gif's are not realy good supported.
you can use a AnimationDrawable. that will work.
the mylocation-icon is also done this way.


I'm trying out the same thing.. what I have it something like this

AnimationDrawable animatedPin = (AnimationDrawable)getResources().getDrawable(R.anim.animated_pin);
ItemizedOverlay overlay = new ItemizedOverlay(this, animatedPin);
....
....
animatedPin.start();

But my map is only showing the first frame of the animation. The animateddrawable works if it is an ImageView, so there is nothing wrong with my R.anim.animated_pin.
What else am I not doing right?
hc
Freshman
Freshman
 
Posts: 2
Joined: Fri Feb 20, 2009 4:59 pm

Top

Return to Map Problems

Who is online

Users browsing this forum: No registered users and 1 guest