当前位置: 首页>>代码示例>>Java>>正文


Java LayerManager类代码示例

本文整理汇总了Java中org.mapsforge.map.layer.LayerManager的典型用法代码示例。如果您正苦于以下问题:Java LayerManager类的具体用法?Java LayerManager怎么用?Java LayerManager使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


LayerManager类属于org.mapsforge.map.layer包,在下文中一共展示了LayerManager类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: MapView

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
public MapView() {
	super();

	this.model = new Model();

	this.fpsCounter = new FpsCounter(GRAPHIC_FACTORY,
			this.model.displayModel);
	this.frameBuffer = new FrameBuffer(this.model.frameBufferModel,
			this.model.displayModel, GRAPHIC_FACTORY);
	this.frameBufferController = FrameBufferController.create(
			this.frameBuffer, this.model);

	this.layerManager = new LayerManager(this, this.model.mapViewPosition,
			GRAPHIC_FACTORY);
	this.layerManager.start();
	LayerManagerController.create(this.layerManager, this.model);

	MapViewController.create(this, this.model);

	this.mapScaleBar = new DefaultMapScaleBar(this.model.mapViewPosition,
			this.model.mapViewDimension, GRAPHIC_FACTORY,
			this.model.displayModel);
}
 
开发者ID:ianmalcolm,项目名称:DeadReckoning,代码行数:24,代码来源:MapView.java

示例2: onCreateView

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
		Bundle savedInstanceState) {
	View rootView = inflater.inflate(R.layout.fragment_item_detail,
			container, false);

	if (this.dummyItem != null) {
		this.mapView = (MapView) rootView.findViewById(R.id.mapView);
		this.mapView.setClickable(true);
		this.mapView.getFpsCounter().setVisible(true);
		this.mapView.getMapScaleBar().setVisible(true);

		LayerManager layerManager = this.mapView.getLayerManager();
		Layers layers = layerManager.getLayers();

		MapViewPosition mapViewPosition = this.mapView.getModel().mapViewPosition;
		mapViewPosition.setZoomLevel((byte) 16);
		this.tileCache = AndroidUtil.createTileCache(this.getActivity(),
				"fragments",
				this.mapView.getModel().displayModel.getTileSize(), 1.0f,
				1.5);

		mapViewPosition.setCenter(this.dummyItem.location);
		layers.add(AndroidUtil.createTileRendererLayer(this.tileCache,
				mapViewPosition, getMapFile(),
				InternalRenderTheme.OSMARENDER, false, true));

	}

	return rootView;
}
 
开发者ID:emdete,项目名称:Simplicissimus,代码行数:32,代码来源:ItemDetailFragment.java

示例3: addLayers

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
private static void addLayers(MapView mapView, String MapPath) {
    LayerManager layerManager = mapView.getLayerManager();
    Layers layers = layerManager.getLayers();
    TileCache tileCache = createTileCache();
    layers.clear();
    layers.add(createTileRendererLayer(tileCache, mapView.getModel().mapViewPosition, layerManager, MapPath));
}
 
开发者ID:Longri,项目名称:cachebox3.0,代码行数:8,代码来源:MapPanel.java

示例4: destroyLayers

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
protected void destroyLayers() {
	for (LayerManager layerManager : this.layerManagers) {
		for (Layer layer : layerManager.getLayers()) {
			layerManager.getLayers().remove(layer);
			layer.onDestroy();
			Log.i("DESTROY", "Destroyed: " + layer.toString());
		}
	}
}
 
开发者ID:nirabpudasaini,项目名称:Mero-Bhada-Meter,代码行数:10,代码来源:OfflineMapActivity.java

示例5: createTileRendererLayer

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
private static Layer createTileRendererLayer(TileCache tileCache, MapViewPosition mapViewPosition, LayerManager layerManager, String MapPath) {
    java.io.File mapFile = new java.io.File(MapPath);
    TileRendererLayer tileRendererLayer = new TileRendererLayer(tileCache, new MapFile(mapFile), mapViewPosition, false, false, true, GRAPHIC_FACTORY);
    tileRendererLayer.setXmlRenderTheme(InternalRenderTheme.OSMARENDER);
    return tileRendererLayer;
}
 
开发者ID:Longri,项目名称:cachebox3.0,代码行数:7,代码来源:MapPanel.java

示例6: getLayerManager

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
@Override
public LayerManager getLayerManager() {
	return this.layerManager;
}
 
开发者ID:ianmalcolm,项目名称:DeadReckoning,代码行数:5,代码来源:MapView.java

示例7: redrawLayers

import org.mapsforge.map.layer.LayerManager; //导入依赖的package包/类
protected void redrawLayers() {
	for (LayerManager layerManager : this.layerManagers) {
		layerManager.redrawLayers();
	}
}
 
开发者ID:nirabpudasaini,项目名称:Mero-Bhada-Meter,代码行数:6,代码来源:OfflineMapActivity.java


注:本文中的org.mapsforge.map.layer.LayerManager类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。