MapView saving the map as an image

Hi,

After trying, I read that you cant render anything over a MapView map.

I am wanting to use the map as the background image. I figured that I could just capture the display as an image and then use that image as the background. Like this:

local theMap = native.newMapView( 0, 0, display.contentWidth, display.contentHeight )  
theMap:setCenter(event.latitude, event.longitude, false)  
local theMapImage = display.captureScreen(false)  
theMap:removeSelf()  
theMap = nil  
theMapImage:toBack()  

However the backgrund (theMapImage) doesnt contain any map, just whatever display objects were below the map in the display.

Then I tried to save theMapImage as an image to the device. When I look at that image on the device in “Photos” there is no map, just whatever display objects were on the layers below it even though I only see the map on the UI.

eg.

local theMap = native.newMapView( 0, 0, display.contentWidth, display.contentHeight )  
local theMapImage = display.captureScreen(true)  

Ideally I would just like to render my display and use the map as a background. To get around that I thought I could create the map and then save it to an image and use that as the background but it doesnt look like it will work.

Does anyone know how to convert the map into an image? or another way to get a map as an image? [import]uid: 158162 topic_id: 28828 reply_id: 328828[/import]

To answer my own question - the simple way is to just use the Google static maps API. The default map image format didnt work (unsupported color space) but png32 worked. [import]uid: 158162 topic_id: 28828 reply_id: 116184[/import]