That's a great idea.  In the end, I need a way of using OpenGL to
manipulate the ModelView Matrix of my MapView.  For example, if the
mapview is output to a 2D texture then I can rotate that plane in 3D
space.  I was thinking about taking that Bitmap and storing it as a
texture every time the MapView invalidates, but now I think that might
be too slow.  Someone else recommended that I follow the PolytoPoly
API demo and use a Matrix to manipulate the geometry of my Map.
Perhaps I'll have to try both approaches to see which is more
efficient.

Thanks for you advice.  I didn't know I could just call
view.draw(canvas) on my own Bitmap.

On Oct 10, 5:02 pm, "Romain Guy" <[EMAIL PROTECTED]> wrote:
> getDrawingCache() will work only if you either enable the drawing
> cache on the View or call buildDrawingCache() first. If you do this
> manually make sure to disable/destroy the drawing cache when you are
> done. Otherwise, every time the view is invalidated, it will have to
> update the drawing cache. This is bad for Views that invalidate often,
> like MapView.
>
> Because the drawing cache API is a bit difficult to use properly, I
> recommend you instead simply create your own Bitmap, create a Canvas
> for that Bitmap and then call view.draw(canvas).
>
>
>
> On Fri, Oct 10, 2008 at 2:13 PM, sandroid <[EMAIL PROTECTED]> wrote:
>
> > Hello,
> >      I want to use getDrawingCache() to get a Bitmap from MapView,
> > but I'm not sure where or when to call the routine.  In my ViewGroup
> > there is a dispatchDraw(Canvas) routine, but it seems to me like I
> > want to call getDrawingCache() after or during the MapView draw()
> > routine.
>
> > Does anybody know much about getDrawingCache()?  I cannot find a good
> > example online or in the ApiDemos.  Ideally I would like to be able to
> > do this for any View.
>
> > -Marc
>
> --
> Romain Guywww.curious-creature.org
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to