geoserver点样式研究——特定图片渲染点
geoserver点样式研究——特定图片渲染点
渲染点数据,用自己想要的图片。代码如下:
<?xml version=”1.0″ encoding=”UTF-8″?>
<StyledLayerDescriptor version=”1.0.0″
xsi:schemaLocation=”http://www.opengis.net/sld StyledLayerDescriptor.xsd”
xmlns=”http://www.opengis.net/sld” xmlns:ogc=”http://www.opengis.net/ogc”
xmlns:xlink=”http://www.w3.org/1999/xlink”
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance“>
<NamedLayer> <Name> jiuyuan </Name>
<UserStyle>
<FeatureTypeStyle>
<Rule>
<Name>Rule 1</Name>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<!– 图片名称叫helpman.png,存储在geoserver/data/styles/下 –>
<OnlineResource xlink:type=”simple” xlink:href=”helpman.png”/>
<Format>image/png</Format>
</ExternalGraphic>
<!– 图片显示的大小是20*20–>
<Size><ogc:Literal>20</ogc:Literal></Size>
</Graphic>
</PointSymbolizer>
</Rule>
</FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</StyledLayerDescriptor>
转载自:https://blog.csdn.net/cyw8998/article/details/4103128