Mercurial > dive4elements > river
diff flys-artifacts/src/main/java/de/intevation/flys/artifacts/math/LinearRemap.java @ 637:f0c1250d1e7b
Make "Berechnungsart 4" work independent of flow direction. Commented out back jump correction temporarily.
flys-artifacts/trunk@2013 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Thu, 26 May 2011 16:54:16 +0000 |
parents | 343f248e4c8c |
children |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/math/LinearRemap.java Thu May 26 15:55:48 2011 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/math/LinearRemap.java Thu May 26 16:54:16 2011 +0000 @@ -61,6 +61,8 @@ b = y1 - m*x1; } + if (from > to) { double t = from; from = to; to = t; } + head = new Segment(from, to, m, b, head); if (logger.isDebugEnabled()) {