Back to project page SmartMap.
The source code is released under:
Apache License
If you think the Android project SmartMap listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.dennytech.smartmap.impl.autonavi; /*from www . ja v a 2s . co m*/ import android.graphics.Point; import com.amap.mapapi.core.GeoPoint; import com.amap.mapapi.map.Projection; import com.dennytech.smartmap.IGeoPoint; import com.dennytech.smartmap.IProjection; public class ANProjection implements IProjection { Projection real; public ANProjection wrap(Projection p) { real = p; return this; } @Override public Projection real() { return real; } @Override public IGeoPoint fromPixels(int x, int y) { return new ANGeoPoint().wrap(real.fromPixels(x, y)); } @Override public float metersToPixels(float meters) { return real.metersToEquatorPixels(meters); } @Override public float metersToPixels(float meters, byte zoom) { return real.metersToEquatorPixels(meters); } @Override public Point toPixels(IGeoPoint in, Point out) { return real.toPixels((GeoPoint) in.real(), out); } @Override public Point toPoint(IGeoPoint in, Point out, byte zoom) { return real.toPixels((GeoPoint) in.real(), out); } }