Ejemplo n.º 1
0
 private String collectBinTilesByName(String name) {
   String binsString = "";
   for (ImagePyramidBin bin : bins) {
     PyramidBinTile tile = bin.getTile(name);
     if (tile != null) {
       binsString += tile.toString();
     }
   }
   return binsString;
 }
Ejemplo n.º 2
0
  public static PyramidBinTile fromString(String str, String name) throws IOException {
    int[] paras = parseString(str, ",");

    int scale = paras[0];
    int row = paras[1];
    int col = paras[2];
    int binWidth = paras[3];
    int binHeight = paras[4];
    int x = paras[5];
    int y = paras[6];
    int width = paras[7];
    int height = paras[8];

    ImagePyramidBin bin = new ImagePyramidBin(scale, row, col);
    bin.setImageArea(binWidth, binHeight);

    PyramidBinTile tile = new PyramidBinTile(bin, name);
    tile.setLocationInBin(x, y);
    tile.setScaledDims(width, height);

    return tile;
  }