Package org.geotools.coverage.processing

Examples of org.geotools.coverage.processing.CoverageProcessor.doOperation()


        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


        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

    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

                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

            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

        final ParameterValueGroup param = processor.getOperation("Resample").getParameters();
        param.parameter("Source").setValue(projected);
        param.parameter(arg1).setValue(value1);
        param.parameter(arg2).setValue(value2);

        projected = (GridCoverage2D) processor.doOperation(param);

        final RenderedImage image = projected.getRenderedImage();
        projected = projected.geophysics(false);

        String operation = null;
View Full Code Here

                    final CoverageProcessor processor = CoverageProcessor.getInstance();
                    final ParameterValueGroup param = processor.getOperation("CoverageCrop")
                            .getParameters();
                    param.parameter("Source").setValue(gridCoverage2D);
                    param.parameter("Envelope").setValue(new GeneralEnvelope(bbox));
                    final GridCoverage2D cropped = (GridCoverage2D) processor.doOperation(param);

                    ROI roi = null;
                    final int numGeometries = geometry.getNumGeometries();
                    for (int i = 0; i < numGeometries; i++) {
                        Geometry geometryN = geometry.getGeometryN(i);
View Full Code Here

        }
        if (operation != null) {
            final CoverageProcessor processor = CoverageProcessor.getInstance();
            final ParameterValueGroup param = processor.getOperation(operation).getParameters();
            param.parameter("Source").setValue(coverage);
            coverage = (GridCoverage2D) processor.doOperation(param);
        }
        Viewer viewer = new Viewer(coverage);
        viewer.setLocale(locale);
        viewer = show(viewer, coverage.getName().toString(locale));
        if (palette) {
View Full Code Here

        final CoverageProcessor processor = CoverageProcessor.getInstance(GeoTools
                .getDefaultHints());
        final ParameterValueGroup param = processor.getOperation("Resample").getParameters();
        param.parameter("Source").setValue(inputCoverage);
        param.parameter("CoordinateReferenceSystem").setValue(DefaultGeographicCRS.WGS84);
        coverage = (GridCoverage2D) processor.doOperation(param);
        // Reader disposal
        reader.dispose();
        // Definition of the Image Size
        pixelNumber = coverage.getRenderedImage().getHeight()
                * coverage.getRenderedImage().getWidth();
 
View Full Code Here

        ParameterValueGroup param = processor.getOperation("CoverageCrop").getParameters();
        param.parameter("Source").setValue(gc);
        param.parameter("Envelope").setValue(cropEnvelope);
        param.parameter("ConserveEnvelope").setValue(Boolean.TRUE);
        final GridCoverage2D cropped = (GridCoverage2D) processor.doOperation(param);

        // //
        //
        // Adjusting the resolution in order to be the same as for all the others coverage
        //
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.