Revision 10626 trunk/extensions/extGeoreferencing/src/org/gvsig/georeferencing/gui/dialog/GeoreferencingDialog.java
GeoreferencingDialog.java | ||
---|---|---|
62 | 62 |
import org.gvsig.georeferencing.utils.StackZoom; |
63 | 63 |
|
64 | 64 |
import com.iver.andami.PluginServices; |
65 |
import com.iver.cit.gvsig.fmap.DriverException; |
|
66 | 65 |
import com.iver.cit.gvsig.fmap.MapControl; |
67 | 66 |
import com.iver.cit.gvsig.fmap.ViewPort; |
68 | 67 |
import com.iver.cit.gvsig.fmap.drivers.RasterDriver; |
... | ... | |
436 | 435 |
|
437 | 436 |
//Calculamos las coordenadas de georreferenciaci?n |
438 | 437 |
GeoOperations go = new GeoOperations(getLyrPoints()); |
439 |
|
|
438 |
|
|
440 | 439 |
double[] begin = go.transformPoint(0, 0, go.getAffine()); |
441 | 440 |
double[] end = go.transformPoint((int)lyrGeoRaster.getImageWidth(), (int)lyrGeoRaster.getImageHeight(), go.getAffine()); |
442 | 441 |
Extent ext = new Extent(begin[0], begin[1], end[0], end[1]); |
... | ... | |
490 | 489 |
//Eliminamos la capa |
491 | 490 |
lyrs.removeLayer(i); |
492 | 491 |
File fich = new File(getLyrGeoRaster().getSource().getFiles()[0].getName()); |
493 |
try{ |
|
494 |
//Creamos la nueva capa GeoRaster y la a?adimos al TOC. |
|
495 |
FLyrRaster lyrRaster = GeoLayerFactory.createLayer(getLyrGeoRaster().getName().substring(1, getLyrGeoRaster().getName().length()), |
|
496 |
(RasterDriver)getLyrGeoRaster().getSource().getDriver(), |
|
497 |
fich, |
|
498 |
getLyrGeoRaster().getProjection()); |
|
499 |
lyrs.addLayer(lyrRaster); |
|
500 |
theView.getMapControl().getMapContext().invalidate(); |
|
501 |
}catch(DriverException exc){ |
|
502 |
|
|
503 |
} |
|
492 |
//Creamos la nueva capa GeoRaster y la a?adimos al TOC. |
|
493 |
FLyrRaster lyrRaster = GeoLayerFactory.createLayer(getLyrGeoRaster().getName().substring(1, getLyrGeoRaster().getName().length()), |
|
494 |
(RasterDriver)getLyrGeoRaster().getSource().getDriver(), |
|
495 |
fich, |
|
496 |
getLyrGeoRaster().getProjection()); |
|
497 |
lyrs.addLayer(lyrRaster); |
|
498 |
theView.getMapControl().getMapContext().invalidate(); |
|
504 | 499 |
break; |
505 | 500 |
} |
506 | 501 |
} |
... | ... | |
736 | 731 |
bProcesar.setToolTipText(PluginServices.getText(this,"process_tip")); |
737 | 732 |
bProcesar.setEnabled(true); |
738 | 733 |
bProcesar.addActionListener(this); |
739 |
|
|
734 |
|
|
740 | 735 |
//TODO: Descomentar cuando se pueda procesar al vuelo la imagen |
741 | 736 |
bProcesar.setVisible(false); |
742 | 737 |
} |
Also available in: Unified diff