mirror of
https://github.com/qgis/QGIS.git
synced 2025-02-25 00:58:06 -05:00
Fix for shifted values in interpolation plugin
git-svn-id: http://svn.osgeo.org/qgis/trunk@11759 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
7a1091ae58
commit
214146b1b5
@ -55,7 +55,7 @@ int QgsGridFileWriter::writeFile( bool showProgressDialog )
|
||||
outStream.setRealNumberPrecision( 8 );
|
||||
writeHeader( outStream );
|
||||
|
||||
double currentYValue = mInterpolationExtent.yMaximum();
|
||||
double currentYValue = mInterpolationExtent.yMaximum() - mCellSizeY / 2.0; //calculate value in the center of the cell
|
||||
double currentXValue;
|
||||
double interpolatedValue;
|
||||
|
||||
@ -68,7 +68,7 @@ int QgsGridFileWriter::writeFile( bool showProgressDialog )
|
||||
|
||||
for ( int i = 0; i < mNumRows; ++i )
|
||||
{
|
||||
currentXValue = mInterpolationExtent.xMinimum();
|
||||
currentXValue = mInterpolationExtent.xMinimum() + mCellSizeX / 2.0; //calculate value in the center of the cell
|
||||
for ( int j = 0; j < mNumColumns; ++j )
|
||||
{
|
||||
if ( mInterpolator->interpolatePoint( currentXValue, currentYValue, interpolatedValue ) == 0 )
|
||||
|
Loading…
x
Reference in New Issue
Block a user