I have used your example to 'GetPixelSize' but it is unclear exactly what this is returning, can you explain what the 'Size' represents?
In my scenario the user draws a rectangle on the map and uploads a custom image which represents the 'map' that covers that region.
Then they are able to later on, use the map control to add items inside their defined area. In this case, the image needs to fit the visible map area which needs to sit exactly in the region they have defined.
Note, the same image is used for all zoom levels.
I understand the image needs to be the correct size but I am trying to understand how to resize the image using a combination of the current zoom level and the rectangle size/geobounds that he/she has put on the map surface.
I don't need code to resize the bitmap, I can do that, but I do need to know how to extract the size the image should be
from the various informatinon available to me at runtime.
ResizeImage( int iZoomLevel, RadMapRectangle Rectangle)
UriImageProvider_ImageWidth = CalcWidth() <-- based on iZoomlevel and Rectangle properties, how?
UriImageProvider_ImageHeight = CalcHeight() <-- based on iZoomlevel and Rectangle properties, how?
UriImageProvider_iImageResolution = CalcRes() <- important?
ResizeImage( UriImageProvider_ImageWidth, UriImageProvider_ImageHeight, UriImageProvider_iImageResolution )
UriProviderGeobounds = somecalc()
Can you help? How do I calculate the correct image dimensions on the fly? I have searched the manual and forums extensivly but can't fathom out how to make these calculations. Can someone point me in the right direction?