use of org.activityinfo.shared.report.content.AiLatLng in project activityinfo by bedatadriven.
the class PPTMapRendererTest method createMap.
private MapReportElement createMap(BaseMap baseMap) {
MapContent content = new MapContent();
content.setBaseMap(baseMap);
content.setCenter(new AiLatLng(-0.07965085325106624, 29.326629638671875));
content.setZoomLevel(10);
content.setIndicators(Collections.EMPTY_SET);
content.setMarkers(Collections.EMPTY_LIST);
MapReportElement element = new MapReportElement();
element.setContent(content);
element.setWidth(1022);
element.setHeight(634);
return element;
}
use of org.activityinfo.shared.report.content.AiLatLng in project activityinfo by bedatadriven.
the class TileMathTest method inverse.
@Test
public void inverse() {
AiLatLng latlng = new AiLatLng(15, 30);
Point px = TileMath.fromLatLngToPixel(latlng, 6);
AiLatLng inverse = TileMath.inverse(px, 6);
assertThat("longitude", inverse.getLng(), equalTo(latlng.getLng()));
assertThat("latitude", inverse.getLat(), closeTo(latlng.getLat(), 0.0001));
}
Aggregations