diff --git a/include/osgTerrain/Layer b/include/osgTerrain/Layer index e2c1613e5..534577333 100644 --- a/include/osgTerrain/Layer +++ b/include/osgTerrain/Layer @@ -320,7 +320,7 @@ class OSGTERRAIN_EXPORT ProxyLayer : public Layer virtual void close() {} /** Extract an ImageLayer from the ProxyLayer.*/ - virtual ImageLayer* extractImageLayer(unsigned int /*minX*/, unsigned int /*minY*/, unsigned int /*maxX*/, unsigned int /*maxY*/) { return 0; } + virtual ImageLayer* extractImageLayer(unsigned int /*sourceMinX*/, unsigned int /*sourceMinY*/, unsigned int /*sourceMaxX*/, unsigned int /*sourceMaxY*/, unsigned int /*targetWidth*/=0, unsigned int /*targetHeight*/=0) { return 0; } protected: diff --git a/src/osgPlugins/gdal/DataSetLayer.cpp b/src/osgPlugins/gdal/DataSetLayer.cpp index 2fa240d92..386f14548 100644 --- a/src/osgPlugins/gdal/DataSetLayer.cpp +++ b/src/osgPlugins/gdal/DataSetLayer.cpp @@ -70,11 +70,11 @@ unsigned int DataSetLayer::getNumRows() const return _dataset!=0 ? _dataset->GetRasterYSize() : 0; } -osgTerrain::ImageLayer* DataSetLayer::extractImageLayer(unsigned int minX, unsigned int minY, unsigned int maxX, unsigned int maxY) +osgTerrain::ImageLayer* DataSetLayer::extractImageLayer(unsigned int sourceMinX, unsigned int sourceMinY, unsigned int sourceMaxX, unsigned int sourceMaxY, unsigned int targetWidth, unsigned int targetHeight) { - if (!_dataset || maxX