Hi!
I put de jai-imageio-1.1.jar in my JRE and now it's working.
Thanks again for the support!
2011/3/15 Javier Perez <[email protected]>
> HI!
>
> I'm still trying to launch a SEXTANTE alogrithm, using geotools bindings,
> as explained in SEXTANTE Programming Guide Edition 1.0 - Rev January 5,
> 2010.
>
> I get an exception from geotools I can not manage.
>
> This is the códe:
>
>
> File path = new File("D:\\Visual\\N43W009-24bit.tif");
> GeoTiffFormat tifFormat = new GeoTiffFormat();
> GeoTiffReader tifReader = (GeoTiffReader)
> tifFormat.getReader(path);
> GridCoverage2D coverage = (GridCoverage2D)
> tifReader.read(null);
> GTRasterLayer dem = new GTRasterLayer();
> dem.create(coverage);
>
>
> HorizonBlockageAlgorithm alg = new HorizonBlockageAlgorithm();
> ParametersSet params = alg.getParameters();
> Point2D.Double pt = new Point2D.Double(525207.43, 4780211.86);
>
> params.getParameter(HorizonBlockageAlgorithm.POINT).setParameterValue(pt);
>
> params.getParameter(HorizonBlockageAlgorithm.DEM).setParameterValue(dem);
>
> params.getParameter(HorizonBlockageAlgorithm.RADIUS).setParameterValue(new
> Double(3000));
>
> params.getParameter(HorizonBlockageAlgorithm.HEIGHT).setParameterValue(new
> Double(24.5));
>
> params.getParameter(HorizonBlockageAlgorithm.RADIUS).setParameterValue(new
> Double(3000));
>
>
>
> OutputFactory outputFactory = new GTOutputFactory();
>
>
> alg.execute(null, outputFactory);
>
> If I dont excecute de algorithm, everything seems to be fine (the
> GTRasterLayer is created whithout any visible trouble). It's when executing
> de algorithm when the exception raises:
>
>
> java.lang.NoSuchMethodError:
> com.sun.media.imageioimpl.common.ImageUtil.getDestinationType(Ljavax/imageio/ImageReadParam;Ljava/util/Iterator;)Ljavax/imageio/ImageTypeSpecifier;
> at
> it.geosolutions.imageioimpl.plugins.tiff.TIFFImageReader.prepareRead(TIFFImageReader.java:1004)
> at
> it.geosolutions.imageioimpl.plugins.tiff.TIFFImageReader.read(TIFFImageReader.java:1186)
> at
> com.sun.media.jai.imageioimpl.ImageReadOpImage.computeTile(ImageReadOpImage.java:667)
> at
> com.sun.media.jai.util.SunTileScheduler.scheduleTile(SunTileScheduler.java:912)
> at javax.media.jai.OpImage.getTile(OpImage.java:1139)
> at javax.media.jai.RenderedOp.getTile(RenderedOp.java:2268)
> at
> es.unex.sextante.geotools.GTRasterLayer.getTile(GTRasterLayer.java:266)
> at
> es.unex.sextante.geotools.GTRasterLayer.getCellValueInLayerCoords(GTRasterLayer.java:147)
> at
> es.unex.sextante.rasterWrappers.GridWrapper.getCellValueInLayerCoords(GridWrapper.java:102)
> at
> es.unex.sextante.rasterWrappers.GridWrapperNotInterpolated.getCellValueAsDouble(GridWrapperNotInterpolated.java:134)
> at
> es.unex.sextante.dataObjects.AbstractRasterLayer.getCellValueAsDouble(AbstractRasterLayer.java:131)
> at
> es.unex.sextante.lighting.horizonBlockage.HorizonBlockageAlgorithm.calculateHorizonData(HorizonBlockageAlgorithm.java:147)
> at
> es.unex.sextante.lighting.horizonBlockage.HorizonBlockageAlgorithm.calculateHorizon(HorizonBlockageAlgorithm.java:121)
> at
> es.unex.sextante.lighting.horizonBlockage.HorizonBlockageAlgorithm.processAlgorithm(HorizonBlockageAlgorithm.java:77)
> at es.unex.sextante.core.GeoAlgorithm.execute(GeoAlgorithm.java:207)
> at es.unex.sextante.core.GeoAlgorithm.execute(GeoAlgorithm.java:155)
> ...
>
>
> If it is usefull, here is the image:
>
> http://personales.ya.com/lobo/N43W009-24bit.tif
>
>
>
> I home someone could help.
>
> Thanks in advance
>
------------------------------------------------------------------------------
Enable your software for Intel(R) Active Management Technology to meet the
growing manageability and security demands of your customers. Businesses
are taking advantage of Intel(R) vPro (TM) technology - will your software
be a part of the solution? Download the Intel(R) Manageability Checker
today! http://p.sf.net/sfu/intel-dev2devmar
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users