Package org.geotools.coverage.processing

Examples of org.geotools.coverage.processing.CoverageProcessor$LogLevel


/*  776 */     return result;
/*      */   }
/*      */
/*      */   protected JMenuItem createSubMenuItem(LogLevel level) {
/*  780 */     JMenuItem result = new JMenuItem(level.toString());
/*  781 */     LogLevel logLevel = level;
/*  782 */     result.setMnemonic(level.toString().charAt(0));
/*  783 */     result.addActionListener(new ActionListener(result, logLevel) { private final JMenuItem val$result;
/*      */       private final LogLevel val$logLevel;
/*      */
/*  785 */       public void actionPerformed(ActionEvent e) { LogBrokerMonitor.this.showLogLevelColorChangeDialog(this.val$result, this.val$logLevel);
View Full Code Here


/* 1337 */     result.setSelectedItem(this._leastSevereDisplayedLogLevel);
/*      */
/* 1339 */     result.addActionListener(new ActionListener() {
/*      */       public void actionPerformed(ActionEvent e) {
/* 1341 */         JComboBox box = (JComboBox)e.getSource();
/* 1342 */         LogLevel level = (LogLevel)box.getSelectedItem();
/* 1343 */         LogBrokerMonitor.this.setLeastSevereDisplayedLogLevel(level);
/*      */       }
/*      */     });
/* 1346 */     result.setMaximumSize(result.getPreferredSize());
/* 1347 */     return result;
View Full Code Here

        else if ( Priority.ERROR == priority )
            return LogLevel.ERROR;
        else if ( Priority.FATAL_ERROR == priority )
            return LogLevel.FATAL;
        else
            return new LogLevel( priority.getName(), priority.getValue() );
    }
View Full Code Here

        {
            return LogLevel.FATAL;
        }
        else
        {
            return new LogLevel( priority.getName(), priority.getValue() );
        }
    }
View Full Code Here

        GridCoverage2D gridCoverage = (GridCoverage2D) factory.create(name,image,envelope);
       
        CoordinateReferenceSystem targetCRS = CRS.decode("EPSG:24882");

        RenderingHints hints = new RenderingHints(Hints.LENIENT_DATUM_SHIFT, Boolean.TRUE);       
        CoverageProcessor processor = new CoverageProcessor(hints);
       
        GridCoverage2D reprojected = gridCoverage.view(ViewType.GEOPHYSICS);
               
        ParameterValueGroup param = processor.getOperation("Resample").getParameters();
        param.parameter("Source").setValue( reprojected );
        param.parameter("CoordinateReferenceSystem").setValue(targetCRS);
        param.parameter("InterpolationType").setValue("NearestNeighbor");
       
        reprojected = (GridCoverage2D) processor.doOperation(param);
       
        reprojected = reprojected.view(ViewType.RENDERED);
       
        ImageViewer.show(gridCoverage, "Normal Grid Coverage");
        ImageViewer.show(reprojected, "Reprojected Grid Coverage");
View Full Code Here

        GridCoverage2D gridCoverage = (GridCoverage2D) factory.create(name,image,envelope);
       
        CoordinateReferenceSystem targetCRS = CRS.decode("EPSG:24882");

        RenderingHints hints = new RenderingHints(Hints.LENIENT_DATUM_SHIFT, Boolean.TRUE);       
        CoverageProcessor processor = new CoverageProcessor(hints);
       
        GridCoverage2D reprojected = gridCoverage.view(ViewType.GEOPHYSICS);
               
        ParameterValueGroup param = processor.getOperation("Resample").getParameters();
        param.parameter("Source").setValue( reprojected );
        param.parameter("CoordinateReferenceSystem").setValue(targetCRS);
        param.parameter("InterpolationType").setValue("NearestNeighbor");
       
        reprojected = (GridCoverage2D) processor.doOperation(param);
       
        reprojected = reprojected.view(ViewType.RENDERED);
       
        ViewerOld.show(gridCoverage, "Normal Grid Coverage");
        ViewerOld.show(reprojected, "Reprojected Grid Coverage");
View Full Code Here

    double xl = sourceEnvelope.getSpan(0);
    double yl = sourceEnvelope.getSpan(1);
    final GeneralEnvelope cropEnvelope = new GeneralEnvelope(new double[] {
        xc - xl / 4.0, yc - yl / 4.0 }, new double[] { xc + xl / 4.0,
        yc + yl / 4.0 });
    final CoverageProcessor processor = CoverageProcessor.getInstance();
    final ParameterValueGroup param = processor
        .getOperation("CoverageCrop").getParameters();
    param.parameter("Source").setValue(gc);
    param.parameter("Envelope").setValue(cropEnvelope);
    final GridCoverage2D cropped = (GridCoverage2D) processor.doOperation(param);

    // /////////////////////////////////////////////////////////////////////
    //
    // Check that we got everything correctly after the crop.
    //
View Full Code Here

          // //
          //
          // Do the actual band selection.
          //
          // //
          final CoverageProcessor processor = new CoverageProcessor(
              this.getHints());
          // get the source
          final ParameterValueGroup parameters = processor
              .getOperation("SelectSampleDimension")
              .getParameters();
          parameters.parameter("SampleDimensions").setValue(
              new int[] { bandIndex - 1 });
          parameters.parameter("Source").setValue(source);
View Full Code Here

        double yc = sourceEnvelope.getMedian(1);
        double xl = sourceEnvelope.getSpan(0);
        double yl = sourceEnvelope.getSpan(1);
        final GeneralEnvelope cropEnvelope = new GeneralEnvelope(new double[] { xc - xl / 4.0,
                yc - yl / 4.0 }, new double[] { xc + xl / 4.0, yc + yl / 4.0 });
        final CoverageProcessor processor = new CoverageProcessor();
        final ParameterValueGroup param = processor.getOperation("CoverageCrop").getParameters();
        param.parameter("Source").setValue(gc);
        param.parameter("Envelope").setValue(cropEnvelope);
        final GridCoverage2D cropped = (GridCoverage2D) processor.doOperation(param);

        // /////////////////////////////////////////////////////////////////////
        //
        // Check that we got everything correctly after the crop.
        //
View Full Code Here

            //////******************Show Source***************************///////

            // coverage.show();
            /* Reproject the image */
            CoverageProcessor processor = CoverageProcessor.getInstance();
            coverage = coverage.geophysics(false);

            final ParameterValueGroup param = processor.getOperation("Resample").getParameters();

            param.parameter("Source").setValue(coverage);
            param.parameter("CoordinateReferenceSystem").setValue(gridCRS);
            param.parameter("InterpolationType").setValue("bilinear");

            GridCoverage2D projected = (GridCoverage2D) processor.doOperation(param);
            final RenderedImage image = projected.getRenderedImage();
            projected = projected.geophysics(false);
                       
           
            WorldImageWriter writer = new WorldImageWriter((Object) (new File(
View Full Code Here

TOP

Related Classes of org.geotools.coverage.processing.CoverageProcessor$LogLevel

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.