aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/test/splines.cpp
diff options
context:
space:
mode:
authorGravatar Jeff <complexzeros@gmail.com>2014-07-10 12:03:42 -0600
committerGravatar Jeff <complexzeros@gmail.com>2014-07-10 12:03:42 -0600
commitb1169ce40cf615ec2cd8eb116ae905b48a849a3a (patch)
tree0fd9997417252e1e4bbe06d55f3889bcfd273a02 /unsupported/test/splines.cpp
parent08c615f1e425d6749ef45ffcbf574e550ba02fea (diff)
Fixed index that would cause crash with two point, two derivative interpolation. Added static_cast.
Diffstat (limited to 'unsupported/test/splines.cpp')
-rw-r--r--unsupported/test/splines.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/unsupported/test/splines.cpp b/unsupported/test/splines.cpp
index 0b43eefb8..97665af96 100644
--- a/unsupported/test/splines.cpp
+++ b/unsupported/test/splines.cpp
@@ -252,7 +252,7 @@ void check_global_interpolation_with_derivatives2d()
VectorXd derivativeIndices(numPoints);
for (Eigen::DenseIndex i = 0; i < numPoints; ++i)
- derivativeIndices(i) = i;
+ derivativeIndices(i) = static_cast<double>(i);
const Spline2d spline = SplineFitting<Spline2d>::InterpolateWithDerivatives(
points, derivatives, derivativeIndices, degree);