|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object courselog.maputils.CalibratedMap
public class CalibratedMap
Field Summary | |
---|---|
static java.lang.String |
COORDINATESMARKUP
Markup for coordinates in KML path file. |
double |
dScPixelOnMeters
Map scaling factor. |
GeoPoint |
gpCenter
Map Center position |
int |
idxRP1
Index of first selected reference point. |
int |
idxRP2
Index of second selected reference point. |
protected ewe.fx.ImageData |
imageDataMap
Image data representation of the map that is used. |
protected ewe.fx.Image |
imageMap
Bitmap representation of the map that is used. |
int |
imgH
Image height |
int |
imgW
Image width |
double |
maxLat
Map upper left corner latitude. |
double |
maxLon
Map lower right corner longitude. |
double |
minLat
Map lower right corner latitude. |
double |
minLon
Map upper left corner longitude. |
static java.lang.String |
REFEXTENSION
Extension associated to files containing reference points. |
java.lang.String |
stMapFileName
File name of the image file. |
static int |
UNINITIALISEDSIZE
Extension associated to files containing reference points. |
GeoDirection |
vpEast
Center east direction |
GeoDirection |
vpNorth
Center north direction |
ewe.util.Vector |
vRefPoints
Vector of reference points associated to calibration. |
Constructor Summary | |
---|---|
CalibratedMap(java.lang.String imageFileName)
Creates a new instance from the map name |
Method Summary | |
---|---|
void |
computeTransformValues()
Compute transformation values from the 2 identified reference points. |
void |
computeTransformValues(MapReferencePoint pt1,
MapReferencePoint pt2)
Compute transformation values from 2 reference points. |
MapReferencePoint |
findClosestReferencepoint(ewe.fx.Point p,
double maxD)
Select closest reference point from a point position on the map. |
void |
findOptimalRefPoint()
Compute optimal reference points to use. |
void |
free()
Free image data |
ewe.fx.ImageData |
getImageDataMap()
|
ewe.fx.Image |
getImageMap()
|
ewe.fx.Point |
getMapPointFromPosition(GeoPoint pos,
GeoDirection tmp,
ewe.fx.Point pt)
Compute X and Y on map from geo position. |
GeoPoint |
getPointFromMap(int xx,
int yy,
GeoPoint dest)
Compute lat and long from position on map. |
java.lang.String |
getReferenceFileName()
Get the reference file name formed from the Map image file name with the REFEXTENSION extension. |
void |
initCalibratedMap()
Initialises a new instance from the bitmap name |
void |
initCalibratedMapImage()
Initialise current instance from the bitmap file name |
void |
initCalibratedMapImage(ewe.fx.Image img)
Initialise current instance from the bitmap image |
void |
initReferenceLocationsFromKML(ewe.io.File fKML)
Initialise current reference points from a kml path file. |
boolean |
saveReferenceFile(ewe.io.File fRef)
Save the reference points into a CSV file. |
boolean |
saveSubMap(ewe.fx.Rect rArea,
java.lang.String imageFileName,
CalibratedMap tmp)
Save a part of the bitmap to an image file and the corresponding reference file. |
void |
setImageMap(ewe.fx.Image imageMap)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String REFEXTENSION
public static final int UNINITIALISEDSIZE
public static final java.lang.String COORDINATESMARKUP
public ewe.util.Vector vRefPoints
public int idxRP1
public int idxRP2
protected ewe.fx.Image imageMap
protected ewe.fx.ImageData imageDataMap
public int imgW
public int imgH
public java.lang.String stMapFileName
public GeoPoint gpCenter
public GeoDirection vpNorth
public GeoDirection vpEast
public double dScPixelOnMeters
public double maxLat
public double minLon
public double minLat
public double maxLon
Constructor Detail |
---|
public CalibratedMap(java.lang.String imageFileName)
Method Detail |
---|
public ewe.fx.Image getImageMap()
public void setImageMap(ewe.fx.Image imageMap)
public ewe.fx.ImageData getImageDataMap()
public void initCalibratedMapImage()
public void initReferenceLocationsFromKML(ewe.io.File fKML)
public void initCalibratedMapImage(ewe.fx.Image img)
public void free()
public void initCalibratedMap()
public boolean saveReferenceFile(ewe.io.File fRef)
public boolean saveSubMap(ewe.fx.Rect rArea, java.lang.String imageFileName, CalibratedMap tmp)
public MapReferencePoint findClosestReferencepoint(ewe.fx.Point p, double maxD)
public void findOptimalRefPoint()
public void computeTransformValues()
public void computeTransformValues(MapReferencePoint pt1, MapReferencePoint pt2)
public GeoPoint getPointFromMap(int xx, int yy, GeoPoint dest)
getPointFromMap
in interface GeoGraphable
public ewe.fx.Point getMapPointFromPosition(GeoPoint pos, GeoDirection tmp, ewe.fx.Point pt)
getMapPointFromPosition
in interface GeoGraphable
pos
- geo position to transpose.tmp
- GeoDirection reference to compute intermediate direction.
If null a new object is allocated.pt
- point on bitmap image to compute.
If null a new Point object is allocated.
public java.lang.String getReferenceFileName()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |