MCPcopy Create free account
hub / github.com/PX4/eigen / casting

Function casting

test/basicstuff.cpp:184–191  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

182
183#ifdef EIGEN_TEST_PART_2
184void casting()
185{
186 Matrix4f m = Matrix4f::Random(), m2;
187 Matrix4d n = m.cast<double>();
188 VERIFY(m.isApprox(n.cast<float>()));
189 m2 = m.cast<float>(); // check the specialization when NewType == Type
190 VERIFY(m.isApprox(m2));
191}
192#endif
193
194template <typename Scalar>

Callers 1

test_basicstuffFunction · 0.85

Calls 1

isApproxMethod · 0.45

Tested by 1

test_basicstuffFunction · 0.68