use of net.osmand.plus.views.OsmAndMapLayersView in project Osmand by osmandapp.
the class MapActivity method setupOpenGLView.
private void setupOpenGLView(boolean init) {
if (settings.USE_OPENGL_RENDER.get() && NativeCoreContext.isInit()) {
ViewStub stub = (ViewStub) findViewById(R.id.atlasMapRendererViewStub);
atlasMapRendererView = (AtlasMapRendererView) stub.inflate();
OsmAndMapLayersView ml = (OsmAndMapLayersView) findViewById(R.id.MapLayersView);
ml.setVisibility(View.VISIBLE);
atlasMapRendererView.setAzimuth(0);
atlasMapRendererView.setElevationAngle(90);
NativeCoreContext.getMapRendererContext().setMapRendererView(atlasMapRendererView);
ml.setMapView(mapView);
mapViewTrackingUtilities.setMapView(mapView);
mapView.setMapRender(atlasMapRendererView);
OsmAndMapSurfaceView surf = (OsmAndMapSurfaceView) findViewById(R.id.MapView);
surf.setVisibility(View.GONE);
} else {
OsmAndMapSurfaceView surf = (OsmAndMapSurfaceView) findViewById(R.id.MapView);
surf.setVisibility(View.VISIBLE);
surf.setMapView(mapView);
}
}
Aggregations