public void zoomIn() {
    Dimension asz = this.getSize();
    int maxzf = 3;
    int coef = 1;
    int r;

    cmdline =
        "/bin/sh get.sh "
            + j2kfilename
            + " "
            + iw
            + " "
            + ih
            + " "
            + rect.x
            + " "
            + rect.y
            + " "
            + rect.width
            + " "
            + rect.height;
    Exec.execPrint(cmdline);

    rect.x = rect.y = rect.width = rect.height = 0;

    img = pgm.open("out.pgm");

    iw = img.getWidth(this);
    ih = img.getHeight(this);
    bi = new BufferedImage(iw, ih, BufferedImage.TYPE_INT_RGB);
    big = bi.createGraphics();
    selected = 0;
    fullRefresh = true;
    repaint();
  }
  public void init() {
    String str;
    int port;

    imgId = 4;
    if (isApplet && (((hostname = this.getParameter("hostname")) == null) || hostname.equals("")))
      hostname = "localhost";
    if (!isApplet || ((str = this.getParameter("cmdPort")) == null)) {
      port = 3000;
    } else {
      port = new Integer(str).intValue();
    }

    this.setSize(512, 512);
    Dimension asz = this.getSize();
    zl.x2 = asz.width;
    zl.y2 = asz.height;

    cmdline =
        "/bin/sh get.sh "
            + j2kfilename
            + " "
            + asz.width
            + " "
            + asz.height
            + " "
            + zl.x1
            + " "
            + zl.y1
            + " "
            + zl.x2
            + " "
            + zl.y2;
    Exec.execPrint(cmdline);
    img = pgm.open("out.pgm");

    iw = img.getWidth(this);
    ih = img.getHeight(this);

    setBackground(Color.black);
    bi = new BufferedImage(iw, ih, BufferedImage.TYPE_INT_RGB);
    big = bi.createGraphics();
    myMML = new MML(this);
    addMouseListener(myMML);
    addMouseMotionListener(myMML);
  }