Oleg Ignatov


I want to add my tile layer on the map.

I use method:

function GetTiles()

{

...

tileSourceSpec.TileSource = http://mySite/myPicture.png;

...

}

But my picture is not displayed correct. My picture paved all map. But I want to display picture in one copy.

How can I resolve this problem




Re: Problem with my tile layer

Derek Chan


Well you didn't stick it in quotes perhaps

tileSourceSpec.TileSource = "http://mySite/myPicture.png";





Re: Problem with my tile layer

Duncan Lawler

I think the issue is a misunderstanding of how tile layers work.

The TileSource you specify will be requested for every tile in view. So if you specify a single static URI, then that image will appear on all tiles in view.

If you have a single image you want positioned somewhere on the map, then you need to use a tool like MapCruncher to position it and break it up into tiles.

If it's already exactly the size of one tile, then you need to use the bounding box to make the request only happen for one tile.






Re: Problem with my tile layer

Derek Chan

Derek Chan wrote:
Well you didn't stick it in quotes perhaps

tileSourceSpec.TileSource = "http://mySite/myPicture.png";[/quote]

Oops, thought this was an issue with tiles not rendering properly.