[mapserver-users] MapScript scalebar and reference map

Lowell Filak lfilak at medinaco.org
Mon Feb 17 13:59:47 PST 2003


What do you mean by "add a scalebar and reference map"?
If you mean render them in mapscript when the definition exists in the mapfile:

$rimg = $rmap->drawScalebar();
$rimg->saveImage("../html$image_name",$mapscript::MS_PNG,$rmap->{transparent},$rmap->{interlace},0);

$rimg = $rmap->drawReferenceMap();
$rimg->saveImage("../html/tmp/references/$hr$min$sec$spid.png",$mapscript::MS_PNG,$rmap->{transparent},$rmap->{interlace},0);

HTH
Lowell F.

The following message was sent by "wendyandtony" <wendyandtony at lineone.net> on Fri, 7 Feb 2003 02:07:52 -0000.

> Hi
> 
> I have built a basic Perl MapScript interface by adapting the > mapquakes.pl example and using my own data. Now I'd like to add a > scalebar and reference map, but don't know where to begin. I've been > through the archives several times and there is next to nothing on this > subject. The actual Perl MapScript reference is not much use either - > both these topics lack any example code.
> 
> Would anyone be able to point me in the right direction, or be willing > to share an example?
> 
> Thanks
> 
> Tony
> 




More information about the MapServer-users mailing list