Skip to content

Commit a62adfe

Browse files
committedMay 20, 2015
fix total curvature calculation (fix #5967)
1 parent 8ad1883 commit a62adfe

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎src/analysis/raster/qgstotalcurvaturefilter.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,8 @@ float QgsTotalCurvatureFilter::processNineCellWindow( float* x11, float* x21, fl
4141

4242
double cellSizeAvg = ( mCellSizeX + mCellSizeY ) / 2.0;
4343
double dxx = ( *x32 - 2 * *x22 + *x12 ) / ( mCellSizeX * mCellSizeX );
44-
double dyy = ( -*x11 + *x31 + *x13 - *x33 ) / ( 4 * cellSizeAvg * cellSizeAvg );
45-
double dxy = ( *x21 - 2 * *x22 + *x23 ) / ( mCellSizeY * mCellSizeY );
44+
double dxy = ( -*x11 + *x31 + *x13 - *x33 ) / ( 4 * cellSizeAvg * cellSizeAvg );
45+
double dyy = ( *x21 - 2 * *x22 + *x23 ) / ( mCellSizeY * mCellSizeY );
4646

4747
return dxx*dxx + 2*dxy*dxy + dyy*dyy;
4848
}

0 commit comments

Comments
 (0)
Please sign in to comment.