/**
   * Returns a table listing the output parameters of this algorithm (usually just labels used to
   * obtain output image names later).
   *
   * @return A parameter table listing the outputs of this algorithm.
   */
  public ParameterTable createOutputParameters() {
    final ParameterTable table = new ParameterTable();

    try {
      table.put(new ParameterImage(AlgorithmParameters.RESULT_IMAGE));
    } catch (final ParserException e) {
      // this shouldn't really happen since there isn't any real parsing going on...
      e.printStackTrace();
    }

    return table;
  }
  /**
   * Returns a table listing the input parameters of this algorithm (which should match up with the
   * scripting parameters used in {@link #setGUIFromParams()}).
   *
   * @return A parameter table listing the inputs of this algorithm.
   */
  public ParameterTable createInputParameters() {
    final ParameterTable table = new ParameterTable();

    try {

      table.put(new ParameterExternalImage(AlgorithmParameters.getInputImageLabel(1)));
      table.put(new ParameterBoolean(AlgorithmParameters.DO_OUTPUT_NEW_IMAGE, true));
    } catch (final ParserException e) {
      // this shouldn't really happen since there isn't any real parsing going on...
      e.printStackTrace();
    }

    return table;
  }