[OpenLayers-Users] ImageLayer Basic Questions Tilecache and
Openlayers
Linda Rawson
linda.rawson at gmail.com
Wed Oct 17 22:21:43 EDT 2007
I have the following entry in TileCache
[MyImage]
type=ImageLayer
file=C:\\Inetpub\\wwwroot\\tilecache\\tilecache-1.9\\92B05.png
filebounds=-123.974436,48.487998,-123.700692,48.265073
Then in openlayers I have the following:
map = new OpenLayers.Map('map');
baseLayer = new OpenLayers.Layer.WMS( "VMap0",
"tilecache.cgi?", {layers: '2', format: 'image/gif' } );
baseLayer.addOptions({ isBaseLayer : true });
map.addLayer(baseLayer);
var bounds = new OpenLayers.Bounds(-123.974436,48.487998,-123.700692,
48.265073);
layer = new OpenLayers.Layer.WMS( "MyImage",
"tilecache.cgi?",
{layers: 'MyImage',
format: 'image/png',
transparent: 'TRUE'},
{maxExtent: bounds,
visibility: true});
map.addLayer(layer);
map.zoomToExtent(bounds);
The base layer shows up just like it should. The imagelayer does not show
up and is full of pink. It will show up if I take the filebounds entry out
of the configuration which tells me the path to the image is good but then
it does not represent the area it should it represents the default of
"-180,-90,180,90". If I take the URL out of the rendered page the error
returned is CGI ErrorThe specified CGI application misbehaved by not
returning a complete set of HTTP headers.
>From what I can tell the url is requesting lat/lon coordinates that are out
of bounds for this image. Again I think the maxextent should prevent the
layer from requesting anything from the service.
What am I doing wrong?
Thanks,
Linda Rawson
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20071017/a7f64bc5/attachment.html
More information about the Users
mailing list