|
deegree 2.3 (2010/04/09 10:10 build-4-official) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.deegree.graphics.transformation.WorldToScreenTransform
public class WorldToScreenTransform
the class WorldToScreenTransform implements GeoTransformInterface
and defines a transformation to a linear coordinat system with its orgin on top/left. this can be
used for realising a screen mapping of geometries.
| Constructor Summary | |
|---|---|
WorldToScreenTransform()
constructor initialices the transfromation rectangles with unique values (origin 0/0; widht 1; height 1) |
|
WorldToScreenTransform(double sourceXMin,
double sourceYMin,
double sourceXMax,
double sourceYMax,
double destXMin,
double destYMin,
double destXMax,
double destYMax)
constrctor |
|
WorldToScreenTransform(Envelope sourceRect,
Envelope destRect)
constructor initialices the transformation rectangle using the submitted source- and destination rectangle. |
|
| Method Summary | |
|---|---|
protected void |
calculateQX()
calculates the relation between the width of the destination and the source coordinate system. |
protected void |
calculateQY()
calculates the relation between the height of the destination and the source coordinate system. |
Position |
getDestPoint(Position point)
executes a coordinat transformation for the submitted point of the source coordinat system. |
Envelope |
getDestRect()
|
double |
getDestX(double xsource)
executes a coordinat transformation for the submitted x-coordinate of the source coordinat system. |
double |
getDestY(double ysource)
executes a coordinat transformation for the submitted y-coordinate of the source coordinat system. |
Position |
getSourcePoint(Position point)
executes a coordinat transformation for the submitted point of the destination coordinate system. |
Envelope |
getSourceRect()
|
double |
getSourceX(double xdest)
executes a coordinat transformation for the submitted x-coordinate of the destination coordinate system. |
double |
getSourceY(double ydest)
executes a coordinat transformation for the submitted y-coordinate of the destination coordinate system. |
void |
setDestRect(double xMin,
double yMin,
double xMax,
double yMax)
sets the destination rectangle |
void |
setDestRect(Envelope rect)
sets the destination rectangle. |
void |
setSourceRect(double xMin,
double yMin,
double xMax,
double yMax)
sets the source rectangle |
void |
setSourceRect(Envelope rect)
sets the source rectangle |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WorldToScreenTransform()
public WorldToScreenTransform(Envelope sourceRect,
Envelope destRect)
sourceRect - is the boundary of the source geometry.destRect - is the boundary of the destination rectangle (for example a region on the screen)
public WorldToScreenTransform(double sourceXMin,
double sourceYMin,
double sourceXMax,
double sourceYMax,
double destXMin,
double destYMin,
double destXMax,
double destYMax)
sourceXMin - minimum x-coordinate (source system) of the map.sourceYMin - minimum y-coordinate (source system) of the map.sourceXMax - maximum x-coordinate (source system) of the map.sourceYMax - maximum y-coordinate (source system) of the map.destXMin - minimum x-coordinate (destination system) of the map.destYMin - minimum y-coordinate (destination system) of the map.destXMax - maximum x-coordinate (destination system) of the map.destYMax - maximum y-coordinate (destination system) of the map.| Method Detail |
|---|
public void setSourceRect(Envelope rect)
setSourceRect in interface GeoTransformrect - is the boundary of the source geometry.
public void setSourceRect(double xMin,
double yMin,
double xMax,
double yMax)
setSourceRect in interface GeoTransformxMin - minimum x-coordinate (source system) of the map.yMin - minimum y-coordinate (source system) of the map.xMax - maximum x-coordinate (source system) of the map.yMax - maximum y-coordinate (source system) of the map.public Envelope getSourceRect()
getSourceRect in interface GeoTransformpublic void setDestRect(Envelope rect)
setDestRect in interface GeoTransformrect - is the boundary of the destination rectangle (for example a region on the screen)
public void setDestRect(double xMin,
double yMin,
double xMax,
double yMax)
setDestRect in interface GeoTransformxMin - minimum x-coordinate (destination system) of the map.yMin - minimum y-coordinate (destination system) of the map.xMax - maximum x-coordinate (destination system) of the map.yMax - maximum y-coordinate (destination system) of the map.public Envelope getDestRect()
getDestRect in interface GeoTransformpublic double getDestX(double xsource)
getDestX in interface GeoTransformxsource - x-coordinate of a point in the source coordinate system.
public double getDestY(double ysource)
getDestY in interface GeoTransformysource - y-coordinate of a point in the source coordinate system.
public Position getDestPoint(Position point)
getDestPoint in interface GeoTransformpoint - in the source coordinate system.
public double getSourceX(double xdest)
getSourceX in interface GeoTransformxdest - x-coordinate of a point in the destination coordinate system.
public double getSourceY(double ydest)
getSourceY in interface GeoTransformydest - y-coordinate of a point in the destination coordinate system.
public Position getSourcePoint(Position point)
getSourcePoint in interface GeoTransformpoint - in the destination coordinate system.
protected void calculateQX()
protected void calculateQY()
|
deegree 2.3 (2010/04/09 10:10 build-4-official) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org