From Mathias Froehlich, "Attached is a changed version of osgunittests.cpp. The __FUNCTION__
macro/string value is not portable. Instead the functions name is just put into the string."
This commit is contained in:
parent
6e095c4e60
commit
5b305e37b0
@ -238,7 +238,7 @@ void testGetQuatFromMatrix(const osg::Vec3d& scale)
|
|||||||
double yaw2step = 0.1;
|
double yaw2step = 0.1;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
std::cout << std::endl << "Starting " << __FUNCTION__ << ", it can take a while ..." << std::endl;
|
std::cout << std::endl << "Starting testGetQuatFromMatrix, it can take a while ..." << std::endl;
|
||||||
|
|
||||||
osg::Timer_t tstart, tstop;
|
osg::Timer_t tstart, tstop;
|
||||||
tstart = osg::Timer::instance()->tick();
|
tstart = osg::Timer::instance()->tick();
|
||||||
@ -292,7 +292,7 @@ void testGetQuatFromMatrix(const osg::Vec3d& scale)
|
|||||||
(fabs(out_quat1.y()-out_quat2.y())) > eps ||
|
(fabs(out_quat1.y()-out_quat2.y())) > eps ||
|
||||||
(fabs(out_quat1.z()-out_quat2.z())) > eps ||
|
(fabs(out_quat1.z()-out_quat2.z())) > eps ||
|
||||||
(fabs(out_quat1.w()-out_quat2.w())) > eps) {
|
(fabs(out_quat1.w()-out_quat2.w())) > eps) {
|
||||||
std::cout << __FUNCTION__ << " problem at: \n"
|
std::cout << "testGetQuatFromMatrix problem at: \n"
|
||||||
<< " r1=" << rol1
|
<< " r1=" << rol1
|
||||||
<< " p1=" << pit1
|
<< " p1=" << pit1
|
||||||
<< " y1=" << yaw1
|
<< " y1=" << yaw1
|
||||||
@ -310,7 +310,7 @@ void testGetQuatFromMatrix(const osg::Vec3d& scale)
|
|||||||
}
|
}
|
||||||
tstop = osg::Timer::instance()->tick();
|
tstop = osg::Timer::instance()->tick();
|
||||||
double duration = osg::Timer::instance()->delta_s(tstart,tstop);
|
double duration = osg::Timer::instance()->delta_s(tstart,tstop);
|
||||||
std::cout << "Time for " << __FUNCTION__ << " with " << count << " iterations: " << duration << std::endl << std::endl;
|
std::cout << "Time for testGetQuatFromMatrix with " << count << " iterations: " << duration << std::endl << std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
void testQuatRotate(const osg::Vec3d& from, const osg::Vec3d& to)
|
void testQuatRotate(const osg::Vec3d& from, const osg::Vec3d& to)
|
||||||
|
Loading…
Reference in New Issue
Block a user