Examples of RasterLayer


Examples of org.geomajas.layer.RasterLayer

    }
    ClientRasterLayerInfo rasterInfo = (ClientRasterLayerInfo) clientLayerInfo;
    RasterLayerRasterizingInfo extraInfo = (RasterLayerRasterizingInfo) rasterInfo
        .getWidgetInfo(RasterLayerRasterizingInfo.WIDGET_KEY);
    ReferencedEnvelope areaOfInterest = mapContext.getAreaOfInterest();
    RasterLayer layer = configurationService.getRasterLayer(clientLayerInfo.getServerLayerId());
    MapViewport port = mapContext.getViewport();
    double rasterScale = port.getScreenArea().getWidth() / port.getBounds().getWidth();
    List<RasterTile> tiles = rasterLayerService.getTiles(clientLayerInfo.getServerLayerId(),
        areaOfInterest.getCoordinateReferenceSystem(), areaOfInterest, rasterScale);
    RasterDirectLayer rasterLayer = new RasterDirectLayer(tiles, layer.getLayerInfo().getTileWidth(), layer
        .getLayerInfo().getTileHeight(), extraInfo.getCssStyle());
    rasterLayer.setTitle(clientLayerInfo.getLabel());
    rasterLayer.getUserData().put(USERDATA_KEY_SHOWING, extraInfo.isShowing());
    return rasterLayer;
  }
View Full Code Here

Examples of org.geomajas.layer.RasterLayer

    } else {
      String url = null;
      if (null != styleName && !"".equals(styleName)) {
        url = styleName;
      }
      RasterLayer rl = (RasterLayer) l;
      return createIcon(rl.getLayerInfo().getLayerType(), null, iconSize, url);
    }
  }
View Full Code Here

Examples of org.geomajas.layer.RasterLayer

  public void setId(String id) {
    this.id = id;
  }

  public void execute(PipelineContext context, List<RasterTile> response) throws GeomajasException {
    RasterLayer layer = context.get(PipelineCode.LAYER_KEY, RasterLayer.class);
    Envelope bounds = context.get(PipelineCode.BOUNDS_KEY, Envelope.class);
    double scale = context.get(PipelineCode.SCALE_KEY, Double.class);
    CoordinateReferenceSystem crs = context.get(PipelineCode.CRS_KEY, CoordinateReferenceSystem.class);
    List<RasterTile> images = layer.paint(crs, bounds, scale);
    response.addAll(images);
  }
View Full Code Here

Examples of org.geomajas.layer.RasterLayer

   *
   * @param layerId layer id
   * @return WMS layer or null if layer is not a WMS layer
   */
  private WmsLayer getLayer(String layerId) {
    RasterLayer layer = configurationService.getRasterLayer(layerId);
    if (layer instanceof WmsLayer) {
      return (WmsLayer) layer;
    }
    return null;
  }
View Full Code Here

Examples of org.geomajas.layer.RasterLayer

  private RasterLayer getRasterLayer(String layerId) throws GeomajasException {
    if (!securityContext.isLayerVisible(layerId)) {
      throw new GeomajasSecurityException(ExceptionCode.LAYER_NOT_VISIBLE, layerId, securityContext.getUserId());
    }
    RasterLayer layer = configurationService.getRasterLayer(layerId);
    if (null == layer) {
      throw new GeomajasException(ExceptionCode.RASTER_LAYER_NOT_FOUND, layerId);
    }
    return layer;
  }
View Full Code Here

Examples of org.geomajas.layer.RasterLayer

      throws GeomajasException {
    log.debug("getTiles start on layer {}", layerId);
    long ts = System.currentTimeMillis();
    PipelineContext context = pipelineService.createContext();
    context.put(PipelineCode.LAYER_ID_KEY, layerId);
    RasterLayer layer = getRasterLayer(layerId);
    context.put(PipelineCode.LAYER_KEY, layer);
    context.put(PipelineCode.CRS_KEY, crs);
    context.put(PipelineCode.BOUNDS_KEY, bounds);
    context.put(PipelineCode.SCALE_KEY, scale);
    List<RasterTile> response = new ArrayList<RasterTile>();
View Full Code Here

Examples of org.geomajas.puregwt.client.map.layer.RasterLayer

  }

  public void addLayer(ClientLayerInfo layerInfo) {
    switch (layerInfo.getLayerType()) {
      case RASTER:
        RasterLayer rLayer = new RasterLayer((ClientRasterLayerInfo) layerInfo, viewPort, eventBus);
        layers.add(rLayer);
        eventBus.fireEvent(new LayerAddedEvent(rLayer));
        break;
      default:
        VectorLayer vLayer = new VectorLayer((ClientVectorLayerInfo) layerInfo, viewPort, eventBus);
View Full Code Here

Examples of org.geotools.map.RasterLayer

        }
       

        // === look for BANDS layer
        final List<Layer> layers = content.layers();
        RasterLayer layer=null;
        for(Layer tempLayer:layers){
            if(tempLayer instanceof RasterLayer){
                String title = tempLayer.getTitle();
                LayerInfo layerInfo = catalog.getLayerByName(title);       
                if(layerInfo!=null){
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.