Bug report #5967

Wrong Formula in Raster Terrain Analysis' curvature filter

Added by Hugo Loi over 7 years ago. Updated over 4 years ago.

Status:Closed
Priority:Normal
Assignee:Marco Hugentobler
Category:C++ Plugins
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:15386

Description

Hi,
There is an error in the following file:

qgis-1.7.4/src/analysis/raster/qgstotalcurvaturefilter.cpp

(QGis version: 1.7.4, but it has not changed in the new one)
The "dyy" and "dxy" formulas are inverted. This causes the final result to be wrong. Before posting the bug here, i made sure that it is truly an error and asked it here:
http://gis.stackexchange.com/questions/27155/qgis-raster-terrain-analysis-the-curvature-filter-puzzles-me

The only correction to do is, in the function
float QgsTotalCurvatureFilter::processNineCellWindow(...)
to exchange the initialization of local variables "dyy" and "dxy". Everything else can be let unchanged.

Thanks for your attention!

Associated revisions

Revision a62adfe4
Added by Alexander Bruy over 4 years ago

fix total curvature calculation (fix #5967)

Revision b7a4e985
Added by Marco Hugentobler over 4 years ago

Merge pull request #2048 from alexbruy/fix-curvature-filter

fix total curvature calculation (fix #5967)

History

#1 Updated by Marco Hugentobler over 7 years ago

  • Assignee set to Marco Hugentobler

#2 Updated by Paolo Cavallini about 7 years ago

  • Target version set to Version 2.0.0

#3 Updated by Jürgen Fischer over 5 years ago

  • Category set to C++ Plugins

#4 Updated by Giovanni Manghi over 5 years ago

  • Target version changed from Version 2.0.0 to Version 2.4

#5 Updated by Jürgen Fischer over 5 years ago

  • Target version changed from Version 2.4 to Future Release - High Priority

#6 Updated by Marco Hugentobler over 4 years ago

  • Status changed from Open to Closed

Also available in: Atom PDF