Package de.yaams.extensions.basemap.tiled.mapeditor.util.cutter

Examples of de.yaams.extensions.basemap.tiled.mapeditor.util.cutter.BasicTileCutter


              int colorInt = Integer.parseInt(transStr, 16);
              Color color = new Color(colorInt);
              set.setTransparentColor(color);
            }

            set.importTileBitmap(sourcePath, new BasicTileCutter(tileWidth, tileHeight, tileSpacing, tileMargin));
          } else {
            Image image = unmarshalImage(child, tilesetBaseDir);
            String idValue = getAttributeValue(child, "id");
            int imageId = Integer.parseInt(idValue);
            set.addImage(image, imageId);
View Full Code Here


    cutter.setImage(tilebmp);

    tileDimensions = new Rectangle(cutter.getTileDimensions());
    if (cutter instanceof BasicTileCutter) {
      BasicTileCutter basicTileCutter = (BasicTileCutter) cutter;
      tileSpacing = basicTileCutter.getTileSpacing();
      tileMargin = basicTileCutter.getTileMargin();
      tilesPerRow = basicTileCutter.getTilesPerRow();
    }

    Image tile = cutter.getNextTile();
    while (tile != null) {
      Tile newTile = new Tile();
View Full Code Here

  }

  public TileCutter getCutter(int w, int h, int spacing, int margin) {
    final String selectedItem = (String) cutterBox.getSelectedItem();
    if (selectedItem.equalsIgnoreCase("basic")) {
      return new BasicTileCutter(w, h, spacing, margin);
    } else if (selectedItem.equalsIgnoreCase("border")) {
      return new BorderTileCutter();
    }

    return null;
View Full Code Here

TOP

Related Classes of de.yaams.extensions.basemap.tiled.mapeditor.util.cutter.BasicTileCutter

Copyright © 2018 www.massapicom. 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.