Examples of ICompress


Examples of gov.lanl.adore.djatoka.ICompress

  public File processImage(File img, URI uri) throws DjatokaException {
    String imgPath = img.getAbsolutePath();
    String fmt = formatMap.get(imgPath.substring(imgPath.lastIndexOf('.') + 1).toLowerCase());
    try {
      if (fmt == null || !ImageProcessingUtils.isJp2Type(fmt)) {
        ICompress jp2 = new KduCompressExe();
        File jp2Local = File.createTempFile("cache" + uri.hashCode() + "-", ".jp2");
        jp2Local.delete();
        jp2.compressImage(img.getAbsolutePath(), jp2Local.getAbsolutePath(), new DjatokaEncodeParam());
        img.delete();
        img = jp2Local;
      } else {
        try {
          IExtract ex = new KduExtractExe();
View Full Code Here

Examples of gov.lanl.adore.djatoka.ICompress

    public File processImage(File img, final URI uri) throws DjatokaException {
        final String imgPath = img.getAbsolutePath();
        final String fmt = formatMap.get(imgPath.substring(imgPath.lastIndexOf('.') + 1).toLowerCase());
        try {
            if (fmt == null || !ImageProcessingUtils.isJp2Type(fmt)) {
                final ICompress jp2 = new KduCompressExe();
                final File jp2Local = File.createTempFile("cache" + uri.hashCode() + "-", ".jp2");
                if (!jp2Local.delete() && LOGGER.isWarnEnabled()) {
                    LOGGER.warn("File not deleted: {}", jp2Local);
                }
                jp2.compressImage(img.getAbsolutePath(), jp2Local.getAbsolutePath(), new DjatokaEncodeParam());
                if (!img.delete() && LOGGER.isWarnEnabled()) {
                    LOGGER.warn("File not deleted: {}", img);
                }
                img = jp2Local;
            } else {
View Full Code Here

Examples of org.swtchart.internal.compress.ICompress

            if (yAxis.isLogScaleEnabled()) {
                lower = ((Series) series).getYRange().lower;
            }
            config.setYRange(lower, upper);

            ICompress compressor = ((Series) series).getCompressor();
            compressor.compress(config);
        }
    }
View Full Code Here

Examples of org.swtchart.internal.compress.ICompress

                    .getXAxisId() : series.getYAxisId();
            if (axisId != axis.getId()) {
                continue;
            }

            ICompress compressor = ((Series) series).getCompressor();
            if (axis.isValidCategoryAxis()) {
                String[] categorySeries = axis.getCategorySeries();
                if (categorySeries == null) {
                    continue;
                }
                double[] xSeries = new double[categorySeries.length];
                for (int i = 0; i < xSeries.length; i++) {
                    xSeries[i] = i;
                }
                compressor.setXSeries(xSeries);
            } else if (((Series) series).getXSeries() != null) {
                compressor.setXSeries(((Series) series).getXSeries());
            }
        }
        compressAllSeries();
    }
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.