How do I get rid of half-filled circles??? Corrected URL
Dave S
maps at DSCHULTZSYSTEMS.COM
Thu Nov 18 07:59:57 PST 2004
2nd post - had the wrong URL in the last one. Dang newbies.
OK. I'm a newbie but I've gotten pretty far and now I'm stumped with this
stupid little thing. I can take a lat/long point and plot it on a map
using the setXY method on a point object. I can do this succesfully with
various symbols, except when I use a circle it appears half-filled instead
of a solid color.
What am I doing wrong? The map is here (note the dang half-circle):
http://www.nms-i.com/ca/ca.phtml
############################################
MAPFILE IS HERE:
############################################
NAME AK
STATUS on
SIZE 500 500
EXTENT -117.593716 32.539857 -116.08103 33.503547
IMAGETYPE PNG
IMAGECOLOR 255 255 255
SHAPEPATH "./data/"
UNITS METERS
LEGEND
STATUS EMBED
POSITION LR
END
WEB
IMAGEPATH "/home/httpd/vhosts/nms-i.com/httpdocs/tmp/"
IMAGEURL "/tmp/"
END
LAYER
NAME "INLINE"
TYPE POINT
STATUS ON
CLASS
NAME "0"
STYLE
COLOR 0 0 255
SYMBOL 'square'
SIZE 12
OUTLINECOLOR 0 0 0
END #style
END #class
CLASS
NAME "1"
STYLE
COLOR 0 255 0
SYMBOL 'circle'
SIZE 12
OUTLINECOLOR 0 0 0
END #style
END #class
END #layer
LAYER
GROUP roadCA
NAME FENAME
TYPE line
STATUS DEFAULT
DATA "tgr06073lkA"
class
backgroundcolor 128 128 128
color 255 000 000
name "Roads"
OUTLINECOLOR 0 0 0
end
END
SYMBOL
NAME 'circle'
TYPE ELLIPSE
POINTS 1 1 END
FILLED TRUE
END
SYMBOL
NAME 'square'
TYPE VECTOR
POINTS 0 0 0 1 1 1 1 0 END
FILLED TRUE
END
END
############################################
PHP FILE:
############################################
<?php
dl("php_mapscript425.so");
$map_file="./ca.map";
$map = ms_newMapObj($map_file);
$map->setExtent(-117.238, 32.80, -117.18, 32.81);
$img=$map->draw();
$layer = $map->getLayerByName('INLINE');
//THIS DRAWS THE SQUARE:
$pt = ms_newPointObj();
$pt-> setXY(-117.190847, 32.828373);
$pt->draw($map, $layer, $img, 0 ,'a');
//THIS DRAWS THE CIRCLE BUT IT IS HALF-FILLED:
$pt = ms_newPointObj();
$pt-> setXY (-117.235008, 32.808819);
$pt->draw($map, $layer, $img, 1 ,'b');
$image_url=$img->saveWebImage();
?>
<HTML>
<HEAD>
<TITLE>US state boundaries</TITLE>
</HEAD>
<BODY>
<img SRC="<?php echo $image_url?>">
More information about the MapServer-users
mailing list