ANNOTATION only for an extent?
James Net
james_marsnett at HOTMAIL.COM
Tue Feb 7 20:03:25 PST 2006
I am using several high quality aerial photographs, and each is copyright by
someone different. How do I display different "copyright" statements only
when viewing a certain extent?
I tried the following, but it displays the copyright statement whenever the
zoom level reaches 50,000. These layers MUST be in the same group, else I
would have made separate map files. So that when the user zoms in, they get
to see more detail.
Any ideas?
My map file:
LAYER
NAME "marble"
GROUP "mosaic"
TYPE RASTER
STATUS ON
MINSCALE 4000000.0
MAXSCALE 40000000.0
CONNECTION "http://wms.jpl.nasa.gov/wms.cgi?"
CONNECTIONTYPE WMS
METADATA
wms_title "marble"
wms_srs "EPSG:4326"
wms_abstract "NASA's next blue marble"
"wms_srs" "EPSG:4326"
"wms_name" "BMNG"
"wms_server_version" "1.1.1"
"wms_format" "image/jpeg"
END
END
LAYER
NAME "abc"
GROUP "mosaic"
DATA "abc.ECW"
TYPE RASTER
STATUS OFF
MAXSCALE 50000.0
TRANSPARENCY ALPHA
OFFSITE 255 255 255
PROJECTION
"init=epsg:28355"
END
METADATA
wms_title "abc"
wms_srs "EPSG:28355"
wms_abstract "abc"
wms_opaque "1" # Hint to the client
END
END
LAYER
NAME "xyz"
GROUP "mosaic"
DATA "xyz.ecw"
TYPE RASTER
STATUS OFF
MAXSCALE 50000.0
TRANSPARENCY ALPHA
OFFSITE 255 255 255
PROJECTION
"init=epsg:28355"
END
METADATA
wms_title "xyz"
wms_srs "EPSG:28355"
wms_abstract "xyz"
wms_opaque "1" # Hint to the client
END
END
LAYER
NAME "credits"
TYPE ANNOTATION
STATUS DEFAULT
REQUIRES "[abc]"
POSTLABELCACHE TRUE
TRANSFORM FALSE
FEATURE
POINTS
0 15 # This is the position of the text in image coordinates
(pixel).
END
TEXT 'Copyright abc'
END
CLASS
LABEL
ANTIALIAS true
FONT "sans"
COLOR 255 0 0
BACKGROUNDCOLOR 2 2 2
POSITION UR
END
END
END
_________________________________________________________________
New year, new job there's more than 100,00 jobs at SEEK
http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Fninemsn%2Eseek%2Ecom%2Eau&_t=752315885&_r=Jan05_tagline&_m=EXT
More information about the MapServer-users
mailing list