changeset 453:537e663d6c0c

vertical cross section: Fixed problem with running to max depth on every column in interpolation. gnv-artifacts/trunk@501 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Mon, 04 Jan 2010 13:42:49 +0000
parents 4cd03910f97e
children 04cfb4e3da4f
files gnv-artifacts/ChangeLog gnv-artifacts/src/main/java/de/intevation/gnv/math/Interpolation3D.java
diffstat 2 files changed, 7 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/gnv-artifacts/ChangeLog	Mon Jan 04 13:14:27 2010 +0000
+++ b/gnv-artifacts/ChangeLog	Mon Jan 04 13:42:49 2010 +0000
@@ -1,3 +1,8 @@
+2010-01-04	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
+
+	* src/main/java/de/intevation/gnv/math/Interpolation3D.java:
+	  Fixed problem with running to max depth on every column.
+
 2010-01-04	Sascha L. Teichmann	<sascha.teichmann@intevation.de>
 
 	* src/main/java/de/intevation/gnv/state/timeseries/TimeSeriesOutputState.java:
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/math/Interpolation3D.java	Mon Jan 04 13:14:27 2010 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/math/Interpolation3D.java	Mon Jan 04 13:42:49 2010 +0000
@@ -210,7 +210,8 @@
                     center.x);
                 int j = i;
                 for (double z = -cellHeight*0.5; 
-                    j < raster.length; z -= cellHeight, j += width) {
+                    j < raster.length && z >= depth;
+                    z -= cellHeight, j += width) {
 
                     double v0 = neighbors[0].value(z);
                     double v1 = neighbors[1].value(z);

http://dive4elements.wald.intevation.org