Skip to content
Snippets Groups Projects

Resolve "Use armarx::Time as armem::Time instead of IceUtil::Time"

111 files
+ 758
639
Compare changes
  • Side-by-side
  • Inline
Files
111
@@ -87,7 +87,7 @@ namespace armarx::articulated_object
articulatedObjectReader->connect();
ARMARX_IMPORTANT << "Running example.";
start = armem::Time::now();
start = armem::Time::Now();
task = new PeriodicTask<ArticulatedObjectLocalizerExample>(
this, &ArticulatedObjectLocalizerExample::run,
@@ -108,7 +108,7 @@ namespace armarx::articulated_object
{
const std::string dishwasherName = "Kitchen/mobile-dishwasher";
const auto descriptions = articulatedObjectReader->queryDescriptions(IceUtil::Time::now());
const auto descriptions = articulatedObjectReader->queryDescriptions(armem::Time::Now());
ARMARX_INFO << "Found " << descriptions.size() << " articulated object descriptions";
@@ -155,20 +155,22 @@ namespace armarx::articulated_object
ARMARX_DEBUG << "Reporting articulated objects";
const IceUtil::Time now = TimeUtil::GetTime();
const float t = float((now - start).toSecondsDouble());
const armem::Time now = armem::Time::Now();
const float t = float((now - start).toSecondsDouble());
// move joints at certain frequency
const float k = (1 + std::sin(t / (M_2_PIf32))) / 2; // in [0,1]
const std::map<std::string, float> jointValues{{"dishwasher_door_joint", M_PIf32 / 2 * k},
{"drawer_joint", 350 * k}};
const std::map<std::string, float> jointValues
{
{"dishwasher_door_joint", M_PIf32 / 2 * k},
{"drawer_joint", 350 * k}
};
dishwasher->setGlobalPose(simox::math::pose(Eigen::Vector3f(1000, 0, 0)));
dishwasher->setJointValues(jointValues);
articulatedObjectWriter->storeArticulatedObject(dishwasher, IceUtil::Time::now());
articulatedObjectWriter->storeArticulatedObject(dishwasher, now);
}
} // namespace armarx::articulated_object
Loading