org.deegree.style.utils
Class ShapeHelper
java.lang.Object
org.deegree.style.utils.ShapeHelper
public class ShapeHelper
- extends Object
RenderHelper
- Version:
- $Revision: 29875 $, $Date: 2011-03-04 14:27:10 +0100 (Fri, 04 Mar 2011) $
- Author:
- Andreas Schmitz, last edited by: $Author: aschmitz $
Method Summary |
static Path2D.Double |
calculateStarPolygon(int edges,
int skip,
double size)
Example: calculateStarPolygon (5, 2) connects the first, third, fifth, second, fourth and again first edge in
that order. |
static Shape |
getShapeFromMark(Mark mark,
double size,
double rotation)
|
static Shape |
getShapeFromMark(Mark mark,
double size,
double rotation,
boolean translate,
double x,
double y)
|
static Shape |
getShapeFromSvg(InputStream in,
String url)
|
static Shape |
getShapeFromSvg(String url,
double size,
double rotation)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ShapeHelper
public ShapeHelper()
calculateStarPolygon
public static Path2D.Double calculateStarPolygon(int edges,
int skip,
double size)
- Example: calculateStarPolygon (5, 2) connects the first, third, fifth, second, fourth and again first edge in
that order.
- Parameters:
edges
- the number of edgesskip
- specifies, how to connect the edgessize
-
- Returns:
- a general path that draws the star polygon by the rule
getShapeFromMark
public static Shape getShapeFromMark(Mark mark,
double size,
double rotation)
- Parameters:
mark
- size
- rotation
-
- Returns:
- a shape representing the mark
getShapeFromMark
public static Shape getShapeFromMark(Mark mark,
double size,
double rotation,
boolean translate,
double x,
double y)
getShapeFromSvg
public static Shape getShapeFromSvg(String url,
double size,
double rotation)
- Parameters:
url
- size
- rotation
-
- Returns:
- a shape object from the given svg
getShapeFromSvg
public static Shape getShapeFromSvg(InputStream in,
String url)
- Parameters:
in
- url
-
- Returns:
- a shape object
Copyright © 2011. All Rights Reserved.