27 #include "../common/StringUtils.h"
28 #include "../common/STLUtils.h"
29 #include "../fe/Literal.h"
30 #include "../se/ExternalGraphic.h"
31 #include "../se/Fill.h"
32 #include "../se/Font.h"
33 #include "../se/Graphic.h"
34 #include "../se/GraphicStroke.h"
35 #include "../se/Halo.h"
36 #include "../se/LineSymbolizer.h"
37 #include "../se/PointSymbolizer.h"
38 #include "../se/PolygonSymbolizer.h"
39 #include "../se/Stroke.h"
40 #include "../se/SvgParameter.h"
41 #include "../se/Symbolizer.h"
42 #include "../se/TextSymbolizer.h"
43 #include "../se/Utils.h"
44 #include "../xlink/SimpleLink.h"
105 configDefaultPolygon();
110 config(stroke,
false);
141 configDefaultPoint();
157 m_canvas->setTextColor(color);
193 m_canvas->setTextContourEnabled(
true);
199 m_canvas->setTextContourColor(haloColor);
206 m_canvas->setTextContourWidth(width);
229 fromLineSymbolizer ? m_canvas->setLineColor(color) : m_canvas->setPolygonContourColor(color);
241 std::map<std::string, te::map::LineCapStyle>::iterator it = sm_lineCapMap.find(
te::se::GetString(linecap));
242 if(it != sm_lineCapMap.end())
243 fromLineSymbolizer ? m_canvas->setLineCapStyle(it->second) : m_canvas->setPolygonContourCapStyle(it->second);
250 std::map<std::string, te::map::LineJoinStyle>::iterator it = sm_lineJoinMap.find(
te::se::GetString(linejoin));
251 if(it != sm_lineJoinMap.end())
252 fromLineSymbolizer ? m_canvas->setLineJoinStyle(it->second) : m_canvas->setPolygonContourJoinStyle(it->second);
260 std::vector<double> pattern;
262 fromLineSymbolizer ? m_canvas->setLineDashStyle(pattern) : m_canvas->setPolygonContourDashStyle(pattern);
282 m_canvas->setPolygonFillColor(color);
305 std::size_t width = height;
333 const std::vector<te::se::Mark*> marks = graphic->
getMarks();
343 m_canvas->setPolygonFillPattern(rgba, width, height);
344 m_canvas->setPolygonPatternRotation(angle);
345 m_canvas->setPolygonPatternOpacity(alpha);
350 m_canvas->setPolygonContourPattern(rgba, width, height);
351 m_canvas->setPolygonContourPatternRotation(angle);
352 m_canvas->setPolygonContourPatternOpacity(alpha);
357 m_canvas->setLinePattern(rgba, width, height);
358 m_canvas->setLinePatternRotation(angle);
359 m_canvas->setLinePatternOpacity(alpha);
364 m_canvas->setPointPattern(rgba, width, height);
365 m_canvas->setPointPatternRotation(angle);
366 m_canvas->setPointPatternOpacity(alpha);
const ParameterValue * getRotation() const
A TextSymbolizer is used to render text labels according to various graphical parameters.
#define TE_SE_DEFAULT_HALO_RADIUS
It specifies the default halo radius (in pixels).
const Fill * getFill() const
Gets the Fill associates with the PolygonSymbolizer.
const SvgParameter * getLineCap() const
TESEEXPORT void GetColor(const te::se::Stroke *stroke, te::color::RGBAColor &color)
It gets the RGBA color from the Stroke element.
#define TE_SE_DEFAULT_HALO_COLOR
It specifies the default color used to show text halo.
#define TE_SE_DEFAULT_STROKE_BASIC_WIDTH
It specifies the default width used by stroke basic (solid colors).
const ParameterValue * getRadius() const
const Graphic * getGraphic() const
The Style defines the styling that is to be applied to a geographic dataset (vector geometries or cov...
This is a singleton for managing all external graphic renderers instances available in the system...
A PolygonSymbolizer is used to draw a polygon (or other area-type geometries), including filling its ...
const std::vector< ExternalGraphic * > getExternalGraphics() const
A Symbolizer describes how a feature is to appear on a map.
const SvgParameter * getLineJoin() const
#define TE_SE_MITRE_JOIN
It specifies the value "mitre" for stroke-linejoin parameter.
The CoverageStyle defines the styling that is to be applied to a subset of Coverage data...
const SvgParameter * getFamily() const
This is a singleton for managing all mark renderers instances available in the system.
A PointSymbolizer specifies the rendering of a graphic Symbolizer at a point.
TESEEXPORT double GetDouble(const te::se::ParameterValue *param)
It gets the parameter value as a double.
A Graphic is a graphic symbol with an inherent shape, color(s), and possibly size.
const SvgParameter * getWeight() const
The "ParameterValueType" uses WFS-Filter expressions to give values for SE graphic parameters...
#define TE_SE_BUTT_CAP
It specifies the value "butt" for stroke-linecap parameter.
const SvgParameter * getSize() const
#define TE_SE_BEVEL_JOIN
It specifies the value "bevel" for stroke-linejoin parameter.
void Free(std::vector< T * > *v)
This function can be applied to a pointer to a vector of pointers.
TEMAPEXPORT void GetDashStyle(const std::string &dasharray, std::vector< double > &style)
Converts a dasharray pattern coded by a string to a vector of double.
#define TE_SE_SQUARE_CAP
It specifies the value "square" for stroke-linecap parameter.
const Graphic * getGraphicFill() const
Gets the GraphicFill element associate to this Stroke.
static ExternalGraphicRendererManager & getInstance()
It returns a reference to the singleton instance.
The FeatureTypeStyle defines the styling that is to be applied to a dataset that can be viewed as a f...
#define TE_SE_DEFAULT_STROKE_BASIC_COLOR
It specifies the default color used by stroke basic (solid colors).
#define TE_OPAQUE
For an RGBA color this is the value of the alpha-channel for totally opaque.
const Graphic * getGraphicFill() const
Gets the GraphicFill element associate to this Fill.
#define TE_SE_DEFAULT_TEXT_COLOR
It specifies the default color used to show texts.
#define TE_SE_ROUND_JOIN
It specifies the value "round" for stroke-linejoin parameter.
A Font specifies the text font to use in a text symbolizer.
const Stroke * getStroke() const
Gets the Stroke associates with the PolygonSymbolizer.
The RasterSymbolizer describes how to render raster/matrix-coverage data (e.g., satellite photos...
#define TE_SE_ROUND_CAP
It specifies the value "round" for stroke-linecap parameter.
A Fill specifies the pattern for filling an area geometry.
#define TE_SE_DEFAULT_GRAPHIC_SIZE
It specifies the default graphic size.
const Font * getFont() const
const Stroke * getStroke() const
A canvas is an abstraction of a drawing area.
#define TE_SE_DEFAULT_FILL_BASIC_COLOR
It specifies the default color used by basic fill (solid colors).
const std::vector< Mark * > getMarks() const
const SvgParameter * getDashArray() const
virtual ReturnType accept(VisitorType &guest) const =0
It call the visit method from the guest object.
#define TE_TRANSPARENT
For an RGBA color this is the value of the alpha-channel for totally transparent. ...
A Stroke specifies the appearance of a linear geometry.
A helper class for 32-bit RGBA (Red-Green-Blue-Alpha channel) color.
TESEEXPORT int GetInt(const te::se::ParameterValue *param)
It gets the parameter value as an integer.
const Fill * getFill() const
const SvgParameter * getStyle() const
A LineSymbolizer is used to style a stroke along a linear geometry type, such as a string of line seg...
const Fill * getFill() const
A SvgParameter refers to an SVG/CSS graphical-formatting parameter.
A Halo is a type of Fill that is applied to the backgrounds of font glyphs.
const Halo * getHalo() const
const ParameterValue * getSize() const
TESEEXPORT std::string GetString(const te::se::ParameterValue *param)
It gets the parameter value as a string.
te::color::RGBAColor ** render(const te::se::Mark *mark, std::size_t size)
It generates the image pattern from the given Symbology Enconding Mark element.
te::color::RGBAColor ** render(const te::se::ExternalGraphic *eg, std::size_t height, std::size_t &width)
It generates the image pattern from the given Symbology Enconding External Graphic element...
const SvgParameter * getWidth() const
#define TE_SE_DEFAULT_FONT_SIZE
It specifies the default font size.
const ParameterValue * getOpacity() const